Q regarding what is/isnt exposed to the API

I see that tool presses still bubble up to the main SketchUp window causing unwanted changes in the active tool.

The most difficult part might be a MaterialsObserver and an AppObserver if you’re not up to speed on coding observers.

If the material is nil then a listing should pop up so that it can be chosen (without activating the Paint Bucket tool.)

Regarding the shortcuts for the buttons and dials, the SketchUp plugin would need to define menu items so that the user can assign keyboard shortcuts. (The API does not allow code to set the keychords for commands. It is considered a user function.)

This means that at the very least, a menu item command for each button (that you wish to use with SketchUp) and 2 menu item commands (a + and -,) for each dial.

Somehow the user’s shortcut settings would then need to be “communicated” to the SD+ settings.

I would suggest creating commands labeled “Dial 1 +”, “Dial 1 -” … etc.
and letting the current mode determine what setting is incremented or decremented.

This would need to be the rightmost dial. Ie RGBA where A is the Alpha channel (opacity) setting.
It would be the same for any of the 3 color setting modes.


The buttons would fire menu commands to change the mode: RGB, HSL, HSB, Texture Size, etc.

I think You are only really ever working with SRGB values, but SketchUp’s own interface converts those values to HSL , HSV and vice versa for your own ease.
I suspect you’d actually be doing that conversion in a plugin itself because you can’t control the SketchUp UI itself.

It looks like you can have HSL values in the ruby API also.

Where do you see this ? I only see RGB setters for the Color class.

HSV to RGB formula HSV to RGB conversion | color conversion

unless I’m misunderstanding -( quite likely)

Class: Sketchup::Material — SketchUp Ruby API Documentation

Try to be more specific, what method … you’ll find none.

Yes I also think there is a example somewhere in the SketchUp docs or examples on GitHub.

There is a typo again a they’ve spelled it HLS