Label Formatting: Difference between revisions

From Official Kodi Wiki
Jump to navigation Jump to search
No edit summary
Line 3: Line 3:
This works on all labels throughout the interface. The syntax is similar to the "phpBB" syntax seen on some bulletin board software.
This works on all labels throughout the interface. The syntax is similar to the "phpBB" syntax seen on some bulletin board software.


[[Label Parsing|The $INFO and $LOCALIZE syntaxes are explained in more detail here.]]
[[Label Parsing|The $INFO, $LOCALIZE, and $ADDON syntaxes are explained in more detail here.]]


=== Examples ===
=== Examples ===

Revision as of 01:59, 20 September 2015

XBMC has a sophisticated label formatting engine, allowing the skinner to format up a particular label using bold, italics, full caps, lower case, and coloured text.

This works on all labels throughout the interface. The syntax is similar to the "phpBB" syntax seen on some bulletin board software.

The $INFO, $LOCALIZE, and $ADDON syntaxes are explained in more detail here.

Examples

This is a long label that features different [COLOR red]colours[/COLOR] and [I]styles[/I].

[LOWERCASE]$LOCALIZE[12345][/LOWERCASE] can be used to force a localize string to lowercase.

Keywords

The following keywords are used.

  • $INFO[ListItem.Title,prefix,postfix] - for specifying an info label.
  • $LOCALIZE[12345] - for specifying a localized string.
  • $ADDON[script.music.foobar 12345] - for specifying a string provided by an addon.
  • $NUMBER[] - for specifying a numerical value.
  • [B]bold[/B] - bold text.
  • [I]italics[/I] - italic text.
  • [COLOR red]red text[/COLOR] - colored text.
  • [UPPERCASE]force text uppercase[/UPPERCASE] - force text to uppercase
  • [LOWERCASE]Force Text Lowercase[/LOWERCASE] - force text to lowercase
  • [CAPITALIZE]Force first letter to uppercase[/CAPITALIZE] - makes the first letter of a sentence a capital letter (Isengard only)
  • [CR] - carriage return (line break).

See also

Development: