Home » Community » Newbie corner » How to modify the back colour of a Static Text
Re: How to modify the back colour of a Static Text [message #27286 is a reply to message #27281] |
Sun, 11 July 2010 02:12 |
|
Or simple - Add StaticRect behind of StaticText.
StaticRect has Color() member. Use it.
dlg.txt = t_("You do not have any choice. Select the appropriate job and click OK."); //set text of foreground control
dlg.txt.SetInk(White()).SetFont(StdFont().Bold()); //set color of foreground control
dlg.txt_back.Color(LtRed()); //set color of background control.
PS
Text version of my .lay file.
LAYOUT(PositionSelectLayout, 480, 288)
ITEM(StaticRect, txt_back, HSizePosZ(16, 16).TopPosZ(16, 23))
ITEM(StaticText, txt, SetAlign(ALIGN_CENTER).HSizePosZ(16, 16).TopPosZ(16, 23))
ITEM(Button, ok, SetLabel(t_("OK")).HCenterPosZ(136, -84).BottomPosZ(16, 48))
ITEM(Button, cancelimport, SetLabel(t_("Stop import")).HCenterPosZ(136, 84).BottomPosZ(16, 48))
END_LAYOUT
SergeyNikitin<U++>( linux, wine )
{
under( Ubuntu || Debian || Raspbian );
}
|
|
|
Goto Forum:
Current Time: Thu May 09 19:10:36 CEST 2024
Total time taken to generate the page: 0.01865 seconds
|