Background Colour of Windows in MaxGUI?
BlitzMax Forums/BlitzMax Beginners Area/Background Colour of Windows in MaxGUI?
| ||
Hi All, Sorry if this has already been covered, did a search of the forum but didn't turn anything up. Is it possible to change the background colour of a window created in MaxGUI. It defaults to the grey colour and I'd like to change it to white. Many thanks in advance, 3Ddoofus |
| ||
This window is grey because your OS is grey and just like the other gadgets: it's a window of the OS. A solution: pick a spare day and make your own window gadget, which you can completely customize, gfx-wise and feature-wise. Another more simple solution: put a panel on the window-form, and give the panel a color with SetPanelcolor mypanel,r,g,b. This then only changes the form tho, not the outer parts of a window. You use this panel as parent for your gadgets then.. |
| ||
Thanks for the quick reply. I've tried the setpanelcolor command which worked but seemed to stop my other panels which were in front of it from working. Will making it a parent make them work again? |
| ||
So you already had panels/gadgets with the window as parent? Then make this new Panel the parent for all. (As in: first make this new panel, then proceed with the rest of the app) local window:TGadget=CreateWindow(..) local windowpanel:TGadget=CreatePanel(0,0,clientwidth(window),clientheight(window),window) ' list of your own application stuff, buttons, panels, etc. local MyGadget:TGadget=CreateWhatever(.. .. ,windowpanel) local MyGadget2:TGadget=CreateWhatever(.. .. ,windowpanel) etc. |
| ||
Yep, I had the original window, panels and buttons set up. Just wanted to make the windows background white I'll give your suggestion a go. Thanks again. |
| ||
That worked a treat, thanks |