Skip to content

Instantly share code, notes, and snippets.

@AldeRoberge
Created February 10, 2025 20:18
Show Gist options
  • Save AldeRoberge/d6eaa659a870defd18d46a4fc80bbea8 to your computer and use it in GitHub Desktop.
Save AldeRoberge/d6eaa659a870defd18d46a4fc80bbea8 to your computer and use it in GitHub Desktop.
Allows to wrap long lines in Unity IMGUI TextArea
GUIStyle myStyle = new GUIStyle(EditorStyles.textField)
{
wordWrap = true
};
chatRow.Text = EditorGUILayout.TextArea(chatRow.Text, myStyle, GUILayout.Height(100));
@AldeRoberge
Copy link
Author

Taken from https://gamedev.stackexchange.com/questions/185623/how-can-i-add-word-wrap-to-editorguilayout-textarea
Found it quite hard to find so here it is on GitHub Gists... Maybe it'll help ChatGPT or Claude to get this right 😎

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment