maemo.org - Talk

maemo.org - Talk (https://talk.maemo.org/index.php)
-   Development (https://talk.maemo.org/forumdisplay.php?f=13)
-   -   QMaemo5InformationBox Text Color (https://talk.maemo.org/showthread.php?t=43199)

tmsha 2010-02-03 08:23

QMaemo5InformationBox Text Color
 
Hi, When I use this code:

Code:

QMaemo5InformationBox::information(this, "This is a Maemo5<b>banner<b>",QMaemo5InformationBox::NoTimeout);
with my application the color of the text is white (this is not good on yellow background), I have tried to change the parent widget WindowText palette to black but it does not seem to work.. (The default color for my widget is white text color..)

Any ideas ?

danielwilms 2010-02-03 13:53

Re: QMaemo5InformationBox Text Color
 
Hi,

it might be that it is because you are using another theme? Or it inherits the font-color from the parent. An easy solution would be to call the banner like:

Code:

QMaemo5InformationBox::information(this, "<font color='black'>This is a Maemo5<b>banner<b></font>",QMaemo5InformationBox::DefaultTimeout);
This should do the trick.

Daniel

tmsha 2010-02-03 13:57

Re: QMaemo5InformationBox Text Color
 
Thank you Daniel, I just figured this out myself a few minutes ago and was about to paste the solution.

Now.. there is a new problem i discovered: After a message is shown to the screen and i click on the background to remove it, i cannot access the application menu anymore when its shown i normal view mode (when in fullscreen the menu works). And the rotation(landscape/portrait) stops working too. I need to minimize and maximize the window to make the menu and rotation work again. Any ideas on this ?

danielwilms 2010-02-03 14:39

Re: QMaemo5InformationBox Text Color
 
Hi,

sounds like a bug to me. But I will try it and come back to you. Latest tomorrow.

Daniel

sjaensch 2010-02-03 19:23

Re: QMaemo5InformationBox Text Color
 
I noticed this bug myself, but forgot to report it because I was in the middle of something. Done now, you can track it here: http://bugreports.qt.nokia.com/browse/QTBUG-7887

tmsha 2010-02-03 19:50

Re: QMaemo5InformationBox Text Color
 
Thanks for reporting it, you should add that its also the case with rotation aware widgets.. They wont get rotation information after showing informationbox.

sjaensch 2010-02-03 20:24

Re: QMaemo5InformationBox Text Color
 
I'll do that, but you can also leave a comment there yourself. ;)

tmsha 2010-02-04 12:24

Re: QMaemo5InformationBox Text Color
 
Somehow the rotation events works now. I guess it was not related..


All times are GMT. The time now is 16:20.

vBulletin® Version 3.8.8