is it possible to have a StaticText with a background color?
i tried
<Window Type="TaharezLook/StaticImage" Name="Testing">
<Property Name="BackgroundEnabled" Value="true"/>
<Property Name="BackgroundColours" Value="tl:FFDFDFDF tr:FFDFDFDF bl:FFDFDFDF br:FFDFDFDF" />
...
but it didn't seem to do anything
static text background colors
Moderators: CEGUI MVP, CEGUI Team
Re: static text background colors
i also tried editing the sample demo "first window"
and added this before the return true;
CEGUI::Window * w = winMgr.createWindow("TaharezLook/StaticText", "text");
w->setPosition(UVector2(cegui_reldim(0.25f), cegui_reldim( 0.25f)));
w->setSize(UVector2(cegui_reldim(0.5f), cegui_reldim( 0.5f)));
w->setProperty("Text", "testing");
w->setProperty("BackgroundEnabled", "true");
w->setProperty("FrameEnabled", "true");
w->setProperty("BackgroundColours", "tl:FFFF0000 tr:FFFF0000 bl:FFFF0000 br:FFFF0000");
wnd->addChildWindow(w);
the window shows up, but doesn't have any coloring
any ideas?
and added this before the return true;
CEGUI::Window * w = winMgr.createWindow("TaharezLook/StaticText", "text");
w->setPosition(UVector2(cegui_reldim(0.25f), cegui_reldim( 0.25f)));
w->setSize(UVector2(cegui_reldim(0.5f), cegui_reldim( 0.5f)));
w->setProperty("Text", "testing");
w->setProperty("BackgroundEnabled", "true");
w->setProperty("FrameEnabled", "true");
w->setProperty("BackgroundColours", "tl:FFFF0000 tr:FFFF0000 bl:FFFF0000 br:FFFF0000");
wnd->addChildWindow(w);
the window shows up, but doesn't have any coloring
any ideas?
overlord wrote:is it possible to have a StaticText with a background color?
i tried
<Window Type="TaharezLook/StaticImage" Name="Testing">
<Property Name="BackgroundEnabled" Value="true"/>
<Property Name="BackgroundColours" Value="tl:FFDFDFDF tr:FFDFDFDF bl:FFDFDFDF br:FFDFDFDF" />
...
but it didn't seem to do anything
I've tried but failed.
One clue may be found within taharezlook.looknfeel:
versus WindowsLook.looknfeel:
One clue may be found within taharezlook.looknfeel:
Code: Select all
<WidgetLook name="TaharezLook/StaticShared">
<ImagerySection name="background">
<Image imageset="TaharezLook" image="StaticBackdrop" />
<!--<ColourRectProperty name="BackgroundColours" />-->
<Colours topLeft="FFFFFFFF" topRight="FFFFFFFF" ...
versus WindowsLook.looknfeel:
Code: Select all
<WidgetLook name="WindowsLook/Static">
<StateImagery name="WithFrameEnabledBackground">
<Layer>
<Section look="WindowsLook/StaticShared" section="background">
<ColourRectProperty name="BackgroundColours" />
Who is online
Users browsing this forum: Baidu [Spider] and 9 guests