PDA

View Full Version : Qt white font on Nokia N8, block screen orientation



Asus_G72GX
23rd December 2012, 10:25
Hello!

I have collided with font problem, in my programm i have few QLabel's. test1=new QLabel("Test"); grid1->addWidget(test1,0,1); Wheen I run my programm for PC build, text appear's in black color, and it's readable. But when I build my programm for Symbian Belle and run it on my Nokia N8, text color become's white and it impossible to read it, one of solution I used is test1->setText("<b><font color=red>test1</font></b>"); But it's complicated when I have a numerous "if cases" for my QLabel's. Another question is how to lock albom screen orientation, so when I willl run my programm on N8, it will be opened only in album orientation, and portrait will be locked? I code with out any forms, I use Layout's. Thanks for your answers!

Lykurg
24th December 2012, 09:20
For your color problem have a look at QPalette. For the locking the screen see http://www.developer.nokia.com/Community/Wiki/Archived:Lock_application_orientation_in_Qt

Asus_G72GX
26th December 2012, 08:11
Thanks for help!
setAttribute(Qt::WA_LockLandscapeOrientation,true) ; checked works on N8, for QLabel I used label2->setStyleSheet("color: black"); Strange that by default my app on N8 view white font instead black as on PC. By the way does anyone know on which e-mail I should write in order to get UID and certificate, I want to publish my app to Nokia Store, PublishToOvi.Support@nokia.com not work's anymore. Thanks again!