Jajan
Jajan

Reputation: 926

Unity Button text not showing on some devices

So earlier I was using best fit in all my text and it was working fine. But the ui became inconsistent with that and so I removed best fit and carefully set size for each screen/panel.

The problem now is that the text is not visible on some devices(like nexus 7).

But while on unity scene it works fine. Can anybody suggest how to proceed with this.

Thanks in advance..

Upvotes: 3

Views: 3975

Answers (2)

BlackpearledFire
BlackpearledFire

Reputation: 1

I had that problem, that I wasn't able to see any text from the Text Mesh Pro. The reason why was that I hadn't installed the TMP packages or sth 😣

To do that, you need to go to: Window -> TextMeshPro -> Import TMP Essential Resources

And mabye go to: Window -> TextMeshPro -> Import TMP Examples and Extras

Upvotes: 0

JeanLuc
JeanLuc

Reputation: 4903

You have several options to adjust UI.Text:

  1. increase RectTransform Width and Height
  2. decrease the font size manually
  3. adjust the font size by using best fit
  4. shorten your text, which can be hard in rather lengthy languages
  5. let it overflow by setting "Horizontal Overflow" and/or "Vertical Overflow" to "Overflow"

Then you need to test it in all resolutions (test extrem cases in aspect ratio and resolution) and in all languages your app supports.

You need to decide on each case, which options fits better.

Upvotes: 2

Related Questions