GIMP 2.99/ Python3 Gegl.Color two questions

In there is

 _color ="black")
 _color.set_rgba(0.94, 0, 0, 1.0)

Why is it “black” when the set colour is a reddish tone?

And is there a possibility to use the 255, 255, 255 notation?

Hi! It’s just being initialized to black as a default, then set to the actual color with set_rgba(). You could also do“rgb(0.94,1.0,1.0)”):, but I think it’s easier to have the IDE confirm the values are right if it’s not set as a string.

I think floating point notation is the only one available, but you could just divide each value by 255 to get to it (or switch to 0…100 format in the Color Selection dialogue to see it).

Thank you.
It’s clearer to me now.

This topic was automatically closed 45 days after the last reply. New replies are no longer allowed.