backgrounf color on IStatic box | developer.brewmp.com backgrounf color on IStatic box | developer.brewmp.com

Developer

backgrounf color on IStatic box

Forums:

I want to have background color on
IStatic box . My code for that is :

ISTATIC_SetProperties(pMe->m_pIStatic, ST_NOSCROLL);
ISTATIC_SetText( pMe->m_pIStatic,
title,
direct,
AEE_FONT_BOLD,
AEE_FONT_NORMAL);
ISTATIC_SetActive (pMe->m_pIStatic, TRUE);
IDISPLAY_SetColor( ((AEEApplet *)
GETAPPINSTANCE())->m_pIDisplay,
CLR_USER_BACKGROUND,
MAKE_RGB( 0,0, 255)
);

ISTATIC_Redraw(pMe->m_pIStatic);

I am always getting , white background.
but when I use
IDISPLAY_SetColor( ((AEEApplet *)
GETAPPINSTANCE())->m_pIDisplay,
CLR_USER_TEXT,
MAKE_RGB( 0,0, 255)
);
I am able to get blue text.

Can anybody please tell me how to get colorful IStatic
box.

Thanks in advance
-Uma

i think there is no way to set background color for text box in BREW
Thanks!
kumar

i think there is no way to set background color for text box in BREW
Thanks!
kumar

you could implement your own IFONT, and within your IFONT_DrawText() routine, ignore the background color argument, and set the background to the desired color.

you could implement your own IFONT, and within your IFONT_DrawText() routine, ignore the background color argument, and set the background to the desired color.

Set using IDISPLAY_SetColor(...)
1- CLR_USER_BACKGROUND for text background;
2- CLR_USER_TEXT for text foreground;
3- CLR_USER_LINE for the scroll bar line.
That's all BREW allows you to customize...
Do it before you call ISTATIC_Redraw(...)
Rgds,

Set using IDISPLAY_SetColor(...)
1- CLR_USER_BACKGROUND for text background;
2- CLR_USER_TEXT for text foreground;
3- CLR_USER_LINE for the scroll bar line.
That's all BREW allows you to customize...
Do it before you call ISTATIC_Redraw(...)
Rgds,

Hai
Thanks for your help.
As you said
Set using IDISPLAY_SetColor(...)
1- CLR_USER_BACKGROUND for text background;
I have tried that it does work on BREW 2.1 .
But the same code when I am running on Brew 2.0 Emulator .
Background color does not come. But what I observe is If I have Scrollbar On(automtaic Scrolling) in IStatic Text box
and when scroll bar comes down first time then I see the background color.
BTW I desiging my application for LG VX6000 phone.
Please let me know if you know any particular issue with coloring of IStatic Box on this phone.
Thanks in advance
-Uma

Hai
Thanks for your help.
As you said
Set using IDISPLAY_SetColor(...)
1- CLR_USER_BACKGROUND for text background;
I have tried that it does work on BREW 2.1 .
But the same code when I am running on Brew 2.0 Emulator .
Background color does not come. But what I observe is If I have Scrollbar On(automtaic Scrolling) in IStatic Text box
and when scroll bar comes down first time then I see the background color.
BTW I desiging my application for LG VX6000 phone.
Please let me know if you know any particular issue with coloring of IStatic Box on this phone.
Thanks in advance
-Uma

Humm... I see your point....
Just guessing, but I'd suggest you to call ISTATIC_SetRect(...) and ISTATIC_GoToLine(..., 0) just before ISTATIC_Redraw(...) to check if it has some effect over drawing the background.
I don't work with the LG VX6600, so I haven't seen such problem. :( Can't help on it.
Let me know if you got any improvement with those suggestions.
Rgds,

Humm... I see your point....
Just guessing, but I'd suggest you to call ISTATIC_SetRect(...) and ISTATIC_GoToLine(..., 0) just before ISTATIC_Redraw(...) to check if it has some effect over drawing the background.
I don't work with the LG VX6600, so I haven't seen such problem. :( Can't help on it.
Let me know if you got any improvement with those suggestions.
Rgds,

Look at http://www.qualcomm.com/brew/developer/resources/ds/faq/techfaq6.html#T1I
It works exactly as you described...
It´s not a LG VX6600 problem, but it's a BREW bug instead...
nothing to be done.
Rgds,

Look at http://www.qualcomm.com/brew/developer/resources/ds/faq/techfaq6.html#T1I
It works exactly as you described...
It´s not a LG VX6600 problem, but it's a BREW bug instead...
nothing to be done.
Rgds,