Search Unity

Anybody else having issues with GUI.Label on newer versions of Android?

Discussion in 'Immediate Mode GUI (IMGUI)' started by fatgram10, Jun 26, 2013.

  1. fatgram10

    fatgram10

    Joined:
    Jun 19, 2013
    Posts:
    2
    When I use GUI.Label calls such that the text would be larger than the supplied Rect, all GUI Labels on the screen start to miss letters or distort in an odd way. I've only been able to reproduce this on a Samsung S3 and S4, running Android 4.1.2 and 4.2.2 respectively.

    I originally posted about this here*: http://answers.unity3d.com/questions/477614/why-are-my-gui-labels-distorted-on-a-samsung-s4.html. Unfortunately nobody seems to have any thoughts there.

    The even weirder part is that if I place the following line of code before the rest of my OnGUI code, everything seems to work fine and I don't see any missing letters or distorted text in the rest of my GUI Labels:

    Code (csharp):
    1.  
    2. GUI.Label(new Rect(0, 0, 100, 100), ".");
    3.  
    Don't ask me why the above line of code fixes the observed issue, but it does. If I remove it, the issue comes back. I've been banging my head against this for long enough that I'm ready to just accept that this fixes whatever unknown issue I was seeing and move on. Not knowing what's really happening worries me a lot though, and makes me concerned that there's some instability just waiting to happen in my app.


    * I'll follow up on my answers.unity3d.com post with whatever I can conclude from this forum post.
     
  2. robhuhn

    robhuhn

    Joined:
    Jun 21, 2009
    Posts:
    113
    I'm just facing the same issue on S4 Android 4.2.2 (Galaxy Nexus Android 4.1.1 works). Unfortunately creating a label on top doesn't fix that in my case. I will look for another solution. Did you send a bug report already?
     
  3. fatgram10

    fatgram10

    Joined:
    Jun 19, 2013
    Posts:
    2
    I did not end up creating a bug report. Good luck!