TGUI Forum

General Category => Help requests => Topic started by: Lilian on 24 October 2013, 08:30:37

Title: Text font issue
Post by: Lilian on 24 October 2013, 08:30:37
Hello,

I have some problem with text widget (EditBox, Label, ListBox, ...).
Fonts are not displayed, instead I get squares (one square instead of each letter).
But if I put multiple Label, this problem appears on the first Label widget, but not on the others.

If anybody has an idea...

TGUI : 0.6
SMFL : 2.0
GCC 4.6.3

Thank you !
Title: Re: Text font issue
Post by: texus on 24 October 2013, 09:33:44
On which operating system?

Do you have the same problem with just using sf::Text?

Could you provide a small code example which fails for you?
Title: Re: Text font issue
Post by: Lilian on 24 October 2013, 11:38:36
My system is Ubuntu 12.04

I tried to reproduce the problem with https://tgui.eu/example-code/v06/full-example/

You will see the result in the screenshot.

Thank you for your help !
Title: Re: Text font issue
Post by: Lilian on 24 October 2013, 11:47:43
Another interesting behavior :
- if my chatbox doesn't contain any scrollbar, there are some glitch
- when scrollbar appears, glitch disappears
Title: Re: Text font issue
Post by: texus on 24 October 2013, 11:52:29
This looks like it has more to do with your graphics driver than with tgui. I wouldn't have any idea what else could cause this.

But one question remained unanswered: can you reproduce it with just using sf::Text?

Edit: Also, are you compiling with the -std=c++0x flag?
Title: Re: Text font issue
Post by: Lilian on 24 October 2013, 14:23:18
This looks like it has more to do with your graphics driver than with tgui. I wouldn't have any idea what else could cause this.

But one question remained unanswered: can you reproduce it with just using sf::Text?

Edit: Also, are you compiling with the -std=c++0x flag?

Yes, I'm using the c++0x flag.
I can't reproduce this problem with sf::Text, but I've flickering issue with this kind of text.

You're probably right about graphics driver, I tried my software on another linux machine without any problem.
Thank you for your fast answers !