I created a custom editor but the font is not as crisp as the rest of the editor. It is kinda pixelated.
How do I fix this?
How do I get the same perfect font that Unity Editor uses by default?
Example:
I created a custom editor but the font is not as crisp as the rest of the editor. It is kinda pixelated.
How do I fix this?
How do I get the same perfect font that Unity Editor uses by default?
Example:
Are you using TextMesh or TextMesh Pro? If it is indeed TextMesh (Legacy), then the writing is most likely too large for Unity’s built-in font. Try changing the font by getting a different OTF file for the font, then once it is in your assets, drag it to the object. If you want the same font, try looking up “Legacy Runtime” or “Liberation Sans” and try to get a higher quality version. Another good fix is to keep the font size decently large so that the writing does not have to compress and ruin how neat it is. I have only used Legacy, so I do not know what it could be if you are using TMP.
I’m not using anything in particular. I don’t use the UI Builder or UXML.
It is just C# code with new Label()
So I assume it should use the default editor font?
Do you know how to define the font in the USS or C#?
I think I found what you could be looking for.
Font size:
https://docs.unity3d.com/Packages/com.unity.textmeshpro@4.0/manual/RichTextSize.html
Font in general:
Mate, this thread is about UI Toolkit not TMPro.
Oops. I guess I didn’t see that it was about TMP in the side bar. I just thought that that part in the center was code. I couldn’t find anything else on text size though.
Hey! Could you double-check you are indeed using the same font as the default editor one ? You could do so by inspecting your UI with the UI Debugger.