Buckcherry
24-03-2008 09:38:37
Hi everybody,
I do not why I am having problems using the method setText for a Label.
When I do:
mLabel->setText("Test");
On the screen it appears "est". The first character does not appear.
Any idea?
kungfoomasta
24-03-2008 17:19:03
Can you post more code? I haven't seen this issue with labels on my end.
Buckcherry
24-03-2008 19:53:12
These are the lines:
mLabel = mSheet->createLabel("DebugText");
mLabel->setText("Test");
mLabel->setPosition(250,550);
mLabel->setSize(200,40);
What is wrong?
kungfoomasta
24-03-2008 20:20:51
If you remove the call to setSize, does the label display properly? Also is scrolling involved in any way, and what is the size of of the sheet?
Buckcherry
25-03-2008 07:35:05
I have removed the setSize line and it does the same. The label autosizes, but showing the text uncorrectly.
I have 2 labels, and when I change the text in one of them, also changes the text in the another one (it remobves the first character of the text).
Is not scrolling involved.
I have not set the size of the sheet, I have just done:
mSheet = mGUIManager->getDefaultSheet();
Any idea?
kungfoomasta
25-03-2008 18:42:18
Sorry, I've never seen what you describe, and altering one label should not affect any other labels. If you create a label in the demo does it produce similar behavior? Can you show a screenshot of the provided demo?
Buckcherry
28-03-2008 22:14:50
I was using the v.0.9.7 Prereleased version, I have migrated to v.0.9.7 and it seems to work perfectly.
Thanks