2010-12-17, 00:58
I'm in the process of altering (Read: butchering) Confluence to get my head around skinning and eventually create my own skin. I'll post some basic questions here that I couldn't find answers to in the Wiki or by trial and error.
I'm wondering how to space list items different distances apart. EG. in the screenshot I'm trying to get Video, Audio and Image grouped to the left but have System right aligned while still being selectable in the same list. Does that make sense?
Here's the code section. You'll notice I created a separate itemlayout control with a different posx to use for System but I don't think its being told to affect the System item correctly?
I actually took this part of code from Alaska Revisited because I couldn't get Confluence code to display my images correctly. This code worked right away but now the button image displays as the background as well. I haven't tried to tackle that yet but if anyone has any tips to stop that I'm all ears. *EDIT* Got this background thing sorted. All good.
Oh and one last thing while I'm posting, is it possible to underline the submenu items when they are focused?
I'm wondering how to space list items different distances apart. EG. in the screenshot I'm trying to get Video, Audio and Image grouped to the left but have System right aligned while still being selectable in the same list. Does that make sense?
Here's the code section. You'll notice I created a separate itemlayout control with a different posx to use for System but I don't think its being told to affect the System item correctly?
Code:
<control type="list" id="9000">
<posx>-175</posx>
<posy>202r</posy>
<width>1515</width>
<height>100</height>
<onleft>9000</onleft>
<onright>9000</onright>
<onup>10</onup>
<ondown>9001</ondown>
<pagecontrol>-</pagecontrol>
<focusposition>1</focusposition>
<orientation>horizontal</orientation>
<animation effect="fade" start="0" end="100" time="200">Visible</animation>
<animation effect="fade" start="100" end="30" time="200" condition="Window.IsVisible(1113) | ControlGroup(9001).HasFocus | ControlGroup(10).HasFocus | Control.HasFocus(8000) | Control.HasFocus(8001)">conditional</animation>
<itemlayout height="100" width="150">
<control type="image">
<posx>355</posx>
<posy>21</posy>
<width>121</width>
<height>31</height>
<texture>$INFO[ListItem.Icon]</texture>
</control>
<control type="image">
<posx>580</posx>
<posy>21</posy>
<width>121</width>
<height>31</height>
<texture>$INFO[ListItem.Icon2]</texture>
</control>
</itemlayout>
<focusedlayout height="100" width="150">
<control type="image">
<posx>355</posx>
<posy>21</posy>
<width>121</width>
<height>31</height>
<texture>$INFO[ListItem.Icon]</texture>
</control>
<control type="image">
<posx>580</posx>
<posy>21</posy>
<width>121</width>
<height>31</height>
<texture>$INFO[ListItem.Icon2]</texture>
</control>
</focusedlayout>
<content>
<item id="2">
<description>Videos</description>
<label>3</label>
<onclick>ActivateWindow(Videos)</onclick>
<icon>special://skin/media/Video.png</icon>
<visible>!Skin.HasSetting(HomeMenuNoVideosButton)</visible>
</item>
<item id="3">
<description>Audio</description>
<label>2</label>
<onclick>ActivateWindow(Music)</onclick>
<icon>special://skin/media/Audio.png</icon>
<visible>!Skin.HasSetting(HomeMenuNoMusicButton)</visible>
</item>
<item id="4">
<description>Image</description>
<label>1</label>
<onclick>ActivateWindow(Pictures)</onclick>
<icon>special://skin/media/Image.png</icon>
<visible>!Skin.HasSetting(HomeMenuNoPicturesButton)</visible>
</item>
<item id="5">
<description>System</description>
<label2>13000</label2>
<onclick>ActivateWindow(Settings)</onclick>
<icon>special://skin/media/System.png</icon>
</item>
</content>
</control>
I actually took this part of code from Alaska Revisited because I couldn't get Confluence code to display my images correctly. This code worked right away but now the button image displays as the background as well. I haven't tried to tackle that yet but if anyone has any tips to stop that I'm all ears. *EDIT* Got this background thing sorted. All good.
Oh and one last thing while I'm posting, is it possible to underline the submenu items when they are focused?