How to change the colour of Handles.Label?

Hi all,

I'm using Handles.Label in OnDrawGizmos, and I was wondering, how do you change the colour of a label?
I see in the docs you can set a GUIStlye but I have no idea how to set the colour.
Can someone point me in the right direction there?

Thanks!
Pete

GUIStyle style = new GUIStyle();
style.normal.textColor = Color.red;
Handles.Label(position, text, style);
5 Likes

Thanks @adamgolden , that’s great!

1 Like

You can also use a GUIStyle with richText=true and then set the color using a rich text tag like:
"Now this text is red"

3 Likes

Cool thanks @ExNinja !

[quote=“adamgolden”, post:2, topic: 860875]

GUIStyle style = new GUIStyle();
style.normal.textColor = Color.red;
Handles.Label(position, text, style);

[/quote]

Thanks!!!

1 Like