Titlebar text not appearing

For help with general CEGUI usage:
- Questions about the usage of CEGUI and its features, if not explained in the documentation.
- Problems with the CMAKE configuration or problems occuring during the build process/compilation.
- Errors or unexpected behaviour.

Moderators: CEGUI MVP, CEGUI Team

vimes
Just popping in
Just popping in
Posts: 10
Joined: Wed May 24, 2006 00:05

Titlebar text not appearing

Postby vimes » Wed May 24, 2006 01:55

I've been trying to add a title to my menus by using titlebars but even though the titlebar seems active (it responds to double click and drag) it isn't displaying the text I want it to display.
Here is the incriminated code in my layout

Code: Select all

   <Window Type="GlobalLook/FrameWindow" Name="Campaign" >
      <Property Name="CaptionColour" Value="00FFFFFF" />
      <Property Name="ClippedByParent" Value="False" />
      <Property Name="CloseButtonEnabled" Value="False" />
      <Property Name="EWSizingCursorImage" Value="set:GlobalLook image:MouseEsWeCursor" />
      <Property Name="Font" Value="Tahoma-12" />
      <Property Name="MouseCursorImage" Value="set:GlobalLook image:MouseTarget" />
      <Property Name="NESWSizingCursorImage" Value="set:GlobalLook image:MouseNeSwCursor" />
      <Property Name="NSSizingCursorImage" Value="set:GlobalLook image:MouseNoSoCursor" />
      <Property Name="NWSESizingCursorImage" Value="set:GlobalLook image:MouseNwSeCursor" />
      <Property Name="Text" Value="New Campaign" />
      <Property Name="TitlebarEnabled" Value="True" />
      <Property Name="TitlebarFont" Value="Tahoma-12" />
      <Property Name="UnifiedAreaRect" Value="{{0.5,-100},{0.5,-150},{0.5,100},{0.5,150}}" />
      <Property Name="UnifiedMaxSize" Value="{{1,0},{1,0}}" />
      <Property Name="Visible" Value="False" />
</Window >

and in the looknfeel (if that can be of some use)

Code: Select all

<!--
    ***************************************************
        GlobalLook/Titlebar
    ***************************************************
    -->
    <WidgetLook name="GlobalLook/Titlebar">
        <Property name="CaptionColour" value="FFFFFFFF" />
        <ImagerySection name="main">
            <ImageryComponent>
                <Area>
                    <Dim type="LeftEdge" ><AbsoluteDim value="0" /></Dim>
                    <Dim type="TopEdge" ><AbsoluteDim value="0" /></Dim>
                    <Dim type="Width" ><UnifiedDim scale="1.0" type="Width" /></Dim>
                    <Dim type="Height" ><UnifiedDim scale="1.0" type="Height" /></Dim>
                </Area>
                <Image imageset="GlobalLook" image="NewTitlebarLeft" />
                <VertFormat type="Stretched" />
            </ImageryComponent>
            <ImageryComponent>
                <Area>
                    <Dim type="LeftEdge" ><AbsoluteDim value="0" /></Dim>
                    <Dim type="TopEdge" ><AbsoluteDim value="0" /></Dim>
                    <Dim type="RightEdge" >
                        <UnifiedDim scale="1" type="RightEdge">
                            <DimOperator op="Subtract">
                                <ImageDim imageset="GlobalLook" image="SysAreaRight" dimension="Width">
                                    <DimOperator op="Add">
                                        <ImageDim imageset="GlobalLook" image="SysAreaMiddle" dimension="Width" />
                                    </DimOperator>
                                </ImageDim>
                            </DimOperator>
                        </UnifiedDim>
                    </Dim>
                    <Dim type="Height" ><UnifiedDim scale="1.0" type="Height" /></Dim>
                </Area>
                <Image imageset="GlobalLook" image="NewTitlebarRight" />
                <VertFormat type="Stretched" />
                <HorzFormat type="RightAligned" />
            </ImageryComponent>
            <ImageryComponent>
                <Area>
                    <Dim type="LeftEdge" ><AbsoluteDim value="0" /></Dim>
                    <Dim type="TopEdge" ><AbsoluteDim value="0" /></Dim>
                    <Dim type="RightEdge" >
                        <UnifiedDim scale="1" type="RightEdge">
                            <DimOperator op="Subtract">
                                <ImageDim imageset="GlobalLook" image="SysAreaRight" dimension="Width" />
                            </DimOperator>
                        </UnifiedDim>
                    </Dim>
                    <Dim type="Height" ><UnifiedDim scale="1.0" type="Height" /></Dim>
                </Area>
                <Image imageset="GlobalLook" image="SysAreaMiddle" />
                <VertFormat type="Stretched" />
                <HorzFormat type="RightAligned" />
            </ImageryComponent>
            <ImageryComponent>
                <Area>
                    <Dim type="LeftEdge" ><AbsoluteDim value="0" /></Dim>
                    <Dim type="TopEdge" ><AbsoluteDim value="0" /></Dim>
                    <Dim type="Width" ><UnifiedDim scale="1.0" type="Width" /></Dim>
                    <Dim type="Height" ><UnifiedDim scale="1.0" type="Height" /></Dim>
                </Area>
                <Image imageset="GlobalLook" image="SysAreaRight" />
                <VertFormat type="Stretched" />
                <HorzFormat type="RightAligned" />
            </ImageryComponent>
            <ImageryComponent>
                <Area>
                    <Dim type="LeftEdge" ><ImageDim imageset="GlobalLook" image="NewTitlebarLeft" dimension="Width" /></Dim>
                    <Dim type="TopEdge" ><AbsoluteDim value="0" /></Dim>
                    <Dim type="RightEdge" >
                        <UnifiedDim scale="1" type="RightEdge">
                            <DimOperator op="Subtract">
                                <ImageDim imageset="GlobalLook" image="SysAreaRight" dimension="Width">
                                    <DimOperator op="Add">
                                        <ImageDim imageset="GlobalLook" image="SysAreaMiddle" dimension="Width">
                                            <DimOperator op="Add">
                                                <ImageDim imageset="GlobalLook" image="NewTitlebarRight" dimension="Width" />
                                            </DimOperator>
                                        </ImageDim>
                                    </DimOperator>
                                </ImageDim>
                            </DimOperator>
                        </UnifiedDim>
                    </Dim>
                    <Dim type="Height" ><UnifiedDim scale="1.0" type="Height" /></Dim>
                </Area>
                <Image imageset="GlobalLook" image="NewTitlebarMiddle" />
                <VertFormat type="Stretched" />
                <HorzFormat type="Stretched" />
            </ImageryComponent>
        </ImagerySection>
        <ImagerySection name="caption">
            <TextComponent>
                <Area>
                    <Dim type="LeftEdge" ><ImageDim imageset="GlobalLook" image="NewTitlebarLeft" dimension="Width" /></Dim>
                    <Dim type="TopEdge" ><AbsoluteDim value="0" /></Dim>
                    <Dim type="Width" ><UnifiedDim scale="1" offset="-75" type="Width" /></Dim>
                    <Dim type="Height" ><UnifiedDim scale="1" type="Height" /></Dim>
                </Area>
                <ColourProperty name="CaptionColour" />
                <VertFormat type="CentreAligned" />
            </TextComponent>
        </ImagerySection>
        <StateImagery name="Active">
            <Layer>
                <Section section="main" />
                <Section section="caption" />
            </Layer>
        </StateImagery>
        <StateImagery name="Inactive">
            <Layer>
                <Section section="main" />
                <Section section="caption" />
            </Layer>
        </StateImagery>
        <StateImagery name="Disabled">
            <Layer>
                <Section section="main">
                    <Colours topLeft="FF7F7F7F" topRight="FF7F7F7F" bottomLeft="FF7F7F7F" bottomRight="FF7F7F7F" />
                </Section>
                <Section section="caption">
                    <Colours topLeft="FF7F7F7F" topRight="FF7F7F7F" bottomLeft="FF7F7F7F" bottomRight="FF7F7F7F" />
                </Section>
            </Layer>
        </StateImagery>
    </WidgetLook>

User avatar
Van
Just can't stay away
Just can't stay away
Posts: 225
Joined: Fri Jan 21, 2005 20:29
Contact:

Postby Van » Mon Jun 12, 2006 15:29

We are having the same problem.

If a FrameWindow is loaded from an XML file, the text for the title bar is NOT displayed - even if we attempt to set the text in code.

If a FrameWindow is created in code, then the text for the title bar IS displayed.

Anyone know what the problem is?

User avatar
Van
Just can't stay away
Just can't stay away
Posts: 225
Joined: Fri Jan 21, 2005 20:29
Contact:

Postby Van » Wed Jun 14, 2006 20:29

*bump*

I hate to be a pain in the ass about this, but I sure would appreciate a CEGUI dev team persons comment on this...

User avatar
lindquist
CEGUI Team (Retired)
Posts: 770
Joined: Mon Jan 24, 2005 21:20
Location: Copenhagen, Denmark

Postby lindquist » Wed Jun 14, 2006 20:49

Code: Select all

<Property Name="CaptionColour" Value="00FFFFFF" />

will effectively make the caption text invisible

User avatar
Van
Just can't stay away
Just can't stay away
Posts: 225
Joined: Fri Jan 21, 2005 20:29
Contact:

Postby Van » Wed Jun 14, 2006 21:51

Thank You.

And I can't believe I missed that..

Bit,yet again, by the CEGUILayout Editor. :x

vimes
Just popping in
Just popping in
Posts: 10
Joined: Wed May 24, 2006 00:05

Postby vimes » Mon Jun 26, 2006 01:07

Oops, forgot to answer that... too bad I noticed the solution just now : I rebuilt everything from the demo8 files and it worked.
Anyway, thanks for the answer.


Return to “Help”

Who is online

Users browsing this forum: No registered users and 14 guests