The fact that MythTV has so many features can be both a strength, and a weakness. With so many features, the menu structure can be quite difficult to navigate, and it's almost certain that there are some features you will *never* use.
Wouldn't it be nice to trim the MythTV menus to just what you use. Or, how about simply re-ordering them to suit your preferences? The good news is that you can, and quite easily.
First, a bit on how MythTV's menu system works.
The menu's are driven by XML files (
located in /usr/share/mythtv/). Here is a snippet from the
mainmenu.xml file:
<button>
<type>TV_WATCH_TV</type>
<text>Watch TV</text>
<text lang="FR">Regarder la TV</text>
... [more languages snipped]
<action>TV_WATCH_LIVE</action>
</button>
<button>
<type>MENU_MEDIA_LIBRARY</type>
<text>Media Library</text>
<text lang="FR">Médiathèque</text>
... [more languages snipped]
<action>MENU library.xml</action>
</button>
The important parts are the
menu title:
<text>Media Library</text>and the
action <action>MENU library.xml</action>There are two types of actions:
- link to another menu (
MENU menuname.xml)
- launch an action (
TV_WATCH_LIVE)
Needless to say, linking to another menu simply loads another menu XML file. Launching an action will run the MythTV feature that you select.
Don't start editing those files just yet! Let's run through an example and I'll show you how to safely go about editing the menus.
Example: Remove MythPhone and Netflix from Info Menu
Let's say that I never use MythPhone, or NetFlix, and I want to remove them from the Information menu. You might think.. "Hey, no problem, I'll just bring up
/usr/share/mythtv/info_menu.xml up in my favorite editor (vi.. right?) and hack away!"
Nope... Once again, the MythTV devs have outdone themselves. You can make a local copy of the entire mythtv menu system in mythtv's home directory
~mythtv/.mythtv and when you fire up mythfrontend, it will read
those files instead.
So.. go ahead..
$cp /usr/share/mythtv/*.xml ~mythtv/.mythtv
Just for reference, here is a quick screenshot of the offending menu (with MythPhone and NetFlix)

O.K. Now lets fire up vi and start editing your local copy of
~mythtv/.mythtv/info_menu.xmlHere is the menu entry for MythPhone
<button>
<type>PHONE</type>
<text>Phone</text>
<action>PLUGIN mythphone</action>
<depends>mythphone</depends>
</button>
Simply remove the section above (everything,
including the <button> tags), and MythPhone will be removed from the menu.
Find the entry for NetFlix, and do the same.
Save the file, and re-run mythfrontend.
Viola, here's our new menu. sans MythPhone and NetFlix

As you can see, this process is quite simple.
Additional Notes:
Now, let's say MythTV upgrades to 0.20 and the devs add a new menu item. Unfortunately, you're custom menus won't be updated with the rest of MythTV, and this could leave you in a lurch. What I would recommend is making a diff file of your modified xml file with the original. Then after an upgrade, you should be able to re-apply your diff to the new menus. If you want to be safe, you can also diff your file with the new original and compare the two diff's, and handle the entire situation manually.
You can re-arrange
any menu action and move it into
any menu. You can create your own menus. One thing you can't do that I would love is to assign a shell action to a menu item.
Comments, Questions? Post 'em, I'll try and answer any question.
Coming up next: Transcoding profiles for HDTV folks.