Cabbage Logo
Back to Cabbage Site

Trying to match a colour

I’m trying to match a colour. On my Mac the Digital Color Meter tells me it is (137, 255, 146). I then enter that in Cabbage for my Widget:

rslider bounds(296, 162, 100, 100), channel("gain"), range(0, 1, 0, 1, .01), text("Gain"), trackerColour(137,255,146), outlineColour(0, 0, 0, 50), textColour("black")

When I use Digital Color Meter on the Cabbage window, it tells me the colour is: (104, 232, 100).

I do not understand what is going on. Why does (137, 255, 146) become (104, 232, 100)? How can I compensate for this?

I assume this is the mouse over colour, which applies a slight alpha blend. The problem is you can’t check the regular tracker colour without hovering over the widget?

Oh, maybe! I hadn’t noticed that slider changing with the mouse over. Hmm.

I did a screenshot so that I could look at the colour without the mouseover issue. That definitely helped, though not completely. Oddly, a colour like (255,0,0) ends up more like (255,40,0). Strange, but maybe it is compensating for my display in a way that I don’t understand. I really know very little about this stuff.

I’d say this could be a result of how the painting is done. I’d need to look over the code but I do recall juce doing some funky things in its implementation of the sliders, which could have propagated its way into my classes. The colours in version 3 are more closely aligned with reality :joy: