Im using CEGUI 0.8 and Im trying to display an ImageButtom with ImageNormal, ImageHover, etc. The image never appears on the screen.
Thats what i have:
My scheme:
Code: Select all
<?xml version="1.0" ?>
<GUIScheme Name="StuffedGUI">
<Imageset Name="StuffedALook" Filename="StuffedALook.imageset"/>
<Imageset Name="Traps" Filename="Traps.imageset"/>
</GUIScheme>
My imageset
Code: Select all
<?xml version="1.0" encoding="UTF-8"?>
<Imageset Name="Traps" Imagefile="Traps.png" NativeHorzRes="128"
NativeVertRes="128" AutoScaled="true">
<Image Name="btnNormal" XPos="0" YPos="0" Width="64" Height="64" />
<Image Name="btnHover" XPos="0" YPos="64" Width="64" Height="64" />
<Image Name="btnPushed" XPos="64" YPos="0" Width="64" Height="64" />
<Image Name="btnDisabl" XPos="64" YPos="64" Width="64" Height="64" />
</Imageset>
and finally my layaout
Code: Select all
<?xml version="1.0" encoding="UTF-8"?>
<GUILayout version="4">
<Window Type="OgreTray/FrameWindow" Name="Time" >
<Property Name="Font" Value="DejaVuSans-10" />
<Property Name="Text" Value="Time: 0" />
<Property Name="AlwaysOnTop" Value="True" />
<Property Name="CaptionFont" Value="DejaVuSans-10" />
<Property Name="TitlebarEnabled" Value="True" />
<Property Name="Area" Value="{{0,0},{0,0},{0.25,0},{0.1,0}}" />
</Window>
<Window Type="TaharezLook/ImageButton" Name="btnNewGame">
<Property Name="NormalImage" Value="Traps/btnNormal" />
<Property Name="HoverImage" Value="Traps/btnHover" />
<Property Name="PushedImage" Value="Traps/btnPushed" />
<Property Name="DisabledImage" Value="Traps/btnDisabled" />
<Property Name="Area" Value="{{0.25,0},{0.1,0},{0.35,0},{0.2,0}}" />
</Window>
</GUILayout>
I think there is a problem with the "Name" fields in the layout. Are "NormalImage", "HoverImage" etc still supported on 0.8? If not, how can i do this?
pd i load the layout and the scheme on the .cpp source files!