Background Color

Discuss OrbForms Designer and PocketC Architect

Postby trajecto on Sat Dec 28, 2002 1:47 am

handler mainForm.onopen() {
// TODO: handle onopen event

How do I set my mainForm background color to black?

Posts: 51
Joined: Wed Aug 21, 2002 1:53 am
Location: USA

Postby Main Chen on Sun Dec 29, 2002 6:23 am

handler mainForm.onopen() {
Draw draw;

draw.rect(clrFG, 0, 0, 160, 160, 0);
Main Chen
Posts: 22
Joined: Tue Jul 30, 2002 10:52 am

Postby design4use on Mon Dec 30, 2002 12:41 am

i think if you do the above, the form will be drawn in black only once, at its opening event. Anytime something displays on top like a dialog the form will show a white rectangle once that is gone.
Better put those draw commands into the ondraw event, that way redrawing of the black background gets called automatically anytime anything needs to be redrawn on the form.
Posts: 128
Joined: Fri May 10, 2002 3:31 pm

Postby trajecto on Tue Dec 31, 2002 3:45 am

Thank you very much guys that's exactly what I needed to know.

I experimented with the sample just like it is and the "about" screen left black underneath and was ok, but yes a button when selected and moved by changing x,y coordinates did leave white beneath. That's ok for what I needed though so thanks much!!!
Posts: 51
Joined: Wed Aug 21, 2002 1:53 am
Location: USA

Return to OrbForms Designer and PocketC Architect

Who is online

Users browsing this forum: No registered users and 1 guest