[mythtv] New theme "sleek"

Chris Pinkham cpinkham at bc2va.org
Sat Nov 15 00:22:26 EST 2003


> One other comment on the theming code in myth. Is it possible to add 
> some of the text formating stuff that's in the osd code? For instance I 
> would like to combine some of the things in to one textarea. Something 
> like this:
> 
> [%CHANNELNUM%] - %CHANNELNAME%%SPACE(200)%%RECORDINGTYPE%
> 
> With the ability to add codes like %TAB% and %BR%. Or something like 
> that. It would also be nice to group tags, so that if one of them is 
> zero length (ie. doesn't exist) then the whole group is omitted.

I haven't tried this, but can't you just put a real tab and/or linefeed
in the theme file and get them to display?

> %TITLE% %(- %SUBTITLE%)%
> 
> In that example the - %SUBTITLE% would be omitted from the final string 
> if the subtitle doesn't exist.

This is already supported as well since about 3-4 weeks ago when I
committed a patch by David Engel.

The format is:   %FIELD|prefix|suffix|ifnull%

So in your example above, you'd want this:

%TITLE%%SUBTITLE| - ||%

So the prefix is " - " and only is displayed if the value is non-empty.
The suffix is empty in the definition.
The 'ifnull' is empty since you don't want to display anything if the
	value is empty.

Prefix, suffix, and ifnull are all optional fields.

Search in the mythtv-dev mailing list for a thread entitled
"[PATCH] OSD regexp substitution" for more examples.  It was around
October 22nd.

-- 

Chris



More information about the mythtv-dev mailing list