- Home /
How to changes font, color & size of the text in textfield?
Hello.. Please help me about changing the size of the text and color and font of a textfield? idont know how :( Thank you in advance ...
Name = GUI.TextField(new Rect(755,210,135,32),Name);
Answer by KellyThomas · Dec 27, 2013 at 11:35 AM
One of the overloads of `GUI.TextField()` will accept a `GUIStyle`.
This GUIStyle
can be extensively customized using the Inspector as documented here.
Funny how the same question was asked around the same time by someone else as well..
http://answers.unity3d.com/questions/603858/how-to-increase-font-size-of-text-displayed.html
Answer by Swaminathan · Apr 15, 2014 at 11:44 AM
Try this .. c# code
public string email;
public GUIStyle username_style;
username = GUI.TextField(new Rect(45,415,550,100),username,25,username_style);
Now you can edit or change Font size, font style etc in unity inspector as shown in figure.
NOTE: Write this code inside OnGUI(){}
Your answer
![](https://koobas.hobune.stream/wayback/20220613124941im_/https://answers.unity.com/themes/thub/images/avi.jpg)