How to change font size of GUITextCtrl in Gui editor?
by Sammy · in General Discussion · 04/19/2006 (6:02 am) · 5 replies
Hi all,
How to change font size of GUITextCtrl in Gui editor?
(It seems that there is no properties like fontSize, fontbold, etc.)
Thanks in advance
Sammy
How to change font size of GUITextCtrl in Gui editor?
(It seems that there is no properties like fontSize, fontbold, etc.)
Thanks in advance
Sammy
#3
04/20/2006 (6:21 pm)
Does anyone know of a way of changing the fontSize on the fly? There was some mention of it in some threads a while back, but I didn't hear of any particular solutions.
#4
Hey
Hey
or whatever the syntax is (: I don't remember, but that's the basics.
04/21/2006 (8:28 am)
You either modify the profile at runtime or you use a MLcontrol and modify the text directly, for example.Hey
or whatever the syntax is (: I don't remember, but that's the basics.
#5
Edit: Now I remember...I tried changing the fontsize of the profile itself. The correct way is to create a profile beforehand with a different fontsize.
Though I'm not sure how you could do that while allowing the player to specify the fontsize they want, without creating a profile for every fontsize...
04/21/2006 (9:05 am)
Criminy, I must have done something wrong before; I tried it again and switching the profile did the trick. Thanks.Edit: Now I remember...I tried changing the fontsize of the profile itself. The correct way is to create a profile beforehand with a different fontsize.
Though I'm not sure how you could do that while allowing the player to specify the fontsize they want, without creating a profile for every fontsize...
Torque Owner Tom Bushby
For example using "GUIText24Profile" will mean your font is larger, and using the standard profile, it's going to be smaller. :)
Look in /common/gui/profiles.cs, around line 366 is the profile for the larger font, it works off the default "GUITextProfile", but just changes the size.
Also, look through lines 129 to 142.
Hope that helps,
Tom.