I am creating a toolbar icon in SketchUp for my extension. How to change the color of the toolbar icon on hover as shown in the pic ? Is there a method in UI::toolbar or a way to do that. All the icons have the default hover color but it is not being applied to my extension toolbar icon.
Note, relative paths should not begin with a '/' otherwise the system believes you are starting from the current drives root. If the path is relative to the location of the ruby file, then you can use:
(2) You cannot make any custom hover color for toolbar icons. It is controlled by the SketchUp application according to how it sets the hover style for its’ Qt interface.
And, … the button hover highlighting is working fine for me on an Nvidia GTX-1060 in SketchUp 24. However there have been complaints that the hover style is too much (exactly) like the pressed style for toolbar buttons.
So basically if this is the icon (Example) on hovering over it, the blue background is not shown but for other existing icons it does. Even the ones downloaded form extension warehouse, those icons on hover shows the same color. So that’s why I am confused whether there is a property for this or some method
And additional info. Native toolbar buttons and Ruby toolbar buttons are handled differently.
We (users) cannot place Ruby buttons on native toolbars or visa versa.
You can use a transparent background for your images. Then the highlighting that you see will show through. Also, the icons should be square. The reason you see the blue in your example is that the icon image is rectangular.
The Microsoft Snipping Tool has resizing and Remove Background options.