- Home /
How to speed up TextField input?
Hi,
I've got a TextField that I'm trying to work with in a GUI. However, the displaying of the text is terribly slow. Using the following code, I have verified in the console window that the characters are indeed being received, but the actual display of the text is not occurring until 3-4 seconds after I finish typing. Any thoughts as to how I can speed up the process?
String m_test = "";
public override void OnGUI()
{
String tmp = m_test;
tmp = GUI.TextField(new Rect(0, 0, 300, 22), tmp);
if (tmp != m_test)
{
m_test = tmp;
Debug.Log("m_test = " + m_test);
}
}
Comment
Your answer
![](https://koobas.hobune.stream/wayback/20220613101806im_/https://answers.unity.com/themes/thub/images/avi.jpg)