[mythtv] Question about new theme: menu-ui.xml

Jean-Yves Avenard jyavenard at gmail.com
Wed Mar 25 22:39:54 UTC 2009


Hi

I'm working on porting some themes from 0.21 to 0.22...

I'm not having much luck with some of them and the documentation
doesn't seem to be up to date.

http://www.mythtv.org/wiki/MythUI_Theme_Development

"The base.xml file is the first file loaded by your theme. The
base.xml file is the core definitions for each widget in your theme.
Here you will define popup menus, font names, progress bars, dropdown
menus, and all the other basic widgets used in the Myth UI. The
base.xml file is a fantastic place to put all the definitions you
intend to use later, which you can then call by name. "

However, there's the new menu-ui.xml
without much documentation : http://www.mythtv.org/wiki/Menu-ui.xml

so far, it seems that only menu-ui.xml is relevant at defining the menu.

The problem I currently have is that menu-ui.xml doesn't seem to use
any of the various definitions I've set in base.xml like font etc...

For example, my base.xml contains things like
<mythuitheme>
  <window name="backgroundwindow">
        <imagetype name="backimg">
            <filename>bkg/grey.png</filename>
        </imagetype>

    <font name="white" face="HandelGotD">
      <size>20</size>
      <size:small>18</size:small>
      <size:big>22</size:big>
      <color>#FFFFFF</color>
    </font>

    <font name="clock" from="white">
      <size>80</size>
      <shadowcolor>#000000</shadowcolor>
      <shadowoffset>4,4</shadowoffset>
      <shadowalpha>64</shadowalpha>
      <outlinecolor>#000000</outlinecolor>
      <outlinesize>4</outlinesize>
      <outlinealpha>64</outlinealpha>
      <bold>yes</bold>
    </font>
</window>
</mythuitheme>

In menu-ui.xml I have:
<mythuitheme>
  <window name="mainmenu">
     <clock name="clock">
      <area>600,590,630,100</area>
      <font>clock</font>
      <alpha>10</alpha>
      <format>%TIME%</format>
      <!-- <colonflash>yes</colonflash> -->
      <secondflash>no</secondflash>
      <align>right</align>
      <!-- <colorcycle start="#000000" end="#ffffff" steps="255"/> -->
    </clock>

However, font "clock" doesn't seem to be defined there as I can't see
any particular use of my font in the main menu when displaying the
clock...
I tried definited menu-ui.xml to use explicitely the window settings I
put in base.xml with:
<mythuitheme>
  <window name="mainmenu" from="backgroundwindow">

but no difference...

So far, the only way I managed to get my font properly set is by
duplicating all the code of base.xml into menu-ui.xml

In 0.21 base.xml was the place you defined almost everything ;
background pictures etc ...
I'm yet to achieve that result with 0.22 :(

I looked in the existing 0.22 theme, and they do just like what I do ...

Any help would be appreciated...

Thanks
Jean-Yves


More information about the mythtv-dev mailing list