Dear Rooters,
I’m trying to change the text color of my TGLOverlayButton to kRed but it doesn’t work.
When I try SetTextColor(kRed) the text becomes black with a white contour, what I’m missing?
Thanks for any kind of explanation.
Cheers.
Dear Rooters,
I’m trying to change the text color of my TGLOverlayButton to kRed but it doesn’t work.
When I try SetTextColor(kRed) the text becomes black with a white contour, what I’m missing?
Thanks for any kind of explanation.
Cheers.
Hi,
The argument of TGLOverlayButton::SetTextColor() is of type Pixel_t (see the class documentation)
Then you should try with SetTextColor(0xff0000) (for red)
Cheers, Bertrand.
Hi Bertrand,
Thanks very much, it is in hex code, and Gimp doesn’t help me !
Thanks another time,
Cheers
Well, it is a widely used format (RGB)… So to be more clear the format is 0xRRGGBB, from 0x000000 (black) to 0xffffff (white)
I think it is possible to get the hexadecimal color value in Gimp: Opening a color dialog, you have a “Hex Triplet” field with the hexadecimal value of the selected color (at least with Gimp 2.05)
And you’re welcome
Cheers, Bertrand.