Text2skin-skin reference: Difference between revisions

From VDR Wiki
Jump to navigation Jump to search
(initial)
 
No edit summary
Line 69: Line 69:
!Description
!Description
|-
|-
| x1 || ZAHL || Position of the left border
| x1 || NUMBER || Position of the left border
|-
|-
| y1 || ZAHL || Position of the top border
| y1 || NUMBER || Position of the top border
|-
|-
| x2 || ZAHL || Position of the right border
| x2 || NUMBER || Position of the right border
|-
|-
| y2 || ZAHL || Position of the bottom border
| y2 || NUMBER || Position of the bottom border
|-
|-
| bpp || ZAHL || [[Text2skin-skin creation#Colors|Color]] depth of the drawing area
| bpp || NUMBER || [[Text2skin-skin creation#Colors|Color]] depth of the drawing area
|- bgcolor=#efefef
|- bgcolor=#efefef
!Beispiel
!Beispiel
Line 104: Line 104:
!Description
!Description
|-
|-
| x1 || ZAHL || Position of the left border
| x1 || NUMBER || Position of the left border
|-
|-
| y1 || ZAHL || Position of the top border
| y1 || NUMBER || Position of the top border
|-
|-
| x2 || ZAHL || Position of the right border
| x2 || NUMBER || Position of the right border
|-
|-
| y2 || ZAHL || Position of the bottom border
| y2 || NUMBER || Position of the bottom border
|-
|-
| condition || FUNKTION/TOKEN || Complex condition
| condition || FUNCTION/TOKEN || Complex condition
|-
|-
| color || STRING || [[Text2skin-skin creation#Colors|Color]] of the rectangle
| color || STRING || [[Text2skin-skin creation#Colors|Color]] of the rectangle
Line 132: Line 132:
!Description
!Description
|-
|-
| x1 || ZAHL || Position of the left border
| x1 || NUMBER || Position of the left border
|-
|-
| y1 || ZAHL || Position of the top border
| y1 || NUMBER || Position of the top border
|-
|-
| y2 || ZAHL || Position of the right border
| y2 || NUMBER || Position of the right border
|-
|-
| x2 || ZAHL || Position of the bottom border
| x2 || NUMBER || Position of the bottom border
|-
|-
| condition || FUNKTION/TOKEN || Complex condition
| condition || FUNCTION/TOKEN || Complex condition
|-
|-
| color || STRING || Text [[Text2skin-skin creation#Colors|color]]
| color || STRING || Text [[Text2skin-skin creation#Colors|color]]
Line 168: Line 168:
!Description
!Description
|-
|-
| x || ZAHL || Position of the left border (keine Skalierung)
| x || NUMBER || Position of the left border (keine Skalierung)
|-
|-
| y || ZAHL || Position of the top border (keine Skalierung)
| y || NUMBER || Position of the top border (keine Skalierung)
|-
|-
| x1 || ZAHL || Position of the left border (mit Skalierung)
| x1 || NUMBER || Position of the left border (mit Skalierung)
|-
|-
| y1 || ZAHL || Position of the top border (mit Skalierung)
| y1 || NUMBER || Position of the top border (mit Skalierung)
|-
|-
| x2 || ZAHL || Position of the right border (mit Skalierung)
| x2 || NUMBER || Position of the right border (mit Skalierung)
|-
|-
| y2 || ZAHL || Position of the bottom border (mit Skalierung)
| y2 || NUMBER || Position of the bottom border (mit Skalierung)
|-
|-
| condition || FUNKTION/TOKEN || Complex condition
| condition || FUNCTION/TOKEN || Complex condition
|-
|-
| alpha || ZAHL || [[Text2skin-skin creation#Colors|Transparence (0-255)]]
| alpha || NUMBER || [[Text2skin-skin creation#Colors|Transparence (0-255)]]
|-
|-
| color || STRING ||
| color || STRING ||
Line 207: Line 207:
!Description
!Description
|-
|-
| x1 || ZAHL || Position of the left border
| x1 || NUMBER || Position of the left border
|-
|-
| y1 || ZAHL || Position of the top border
| y1 || NUMBER || Position of the top border
|-
|-
| y2 || ZAHL || Position of the right border
| y2 || NUMBER || Position of the right border
|-
|-
| x2 || ZAHL || Position of the bottom border
| x2 || NUMBER || Position of the bottom border
|-
|-
| condition || FUNKTION/TOKEN || Complex condition
| condition || FUNCTION/TOKEN || Complex condition
|-
|-
| color || STRING || [[Text2skin-skin creation#Colors|Color]]
| color || STRING || [[Text2skin-skin creation#Colors|Color]]
|-
|-
| arc || ZAHL || pitch circle
| arc || NUMBER || pitch circle
|- bgcolor=#efefef
|- bgcolor=#efefef
!Beispiel
!Beispiel
Line 237: Line 237:
!Description
!Description
|-
|-
| x1 || ZAHL || Position of the left border
| x1 || NUMBER || Position of the left border
|-
|-
| y1 || ZAHL || Position of the top border
| y1 || NUMBER || Position of the top border
|-
|-
| y2 || ZAHL || Position of the right border
| y2 || NUMBER || Position of the right border
|-
|-
| x2 || ZAHL || Position of the bottom border
| x2 || NUMBER || Position of the bottom border
|-
|-
| condition || FUNKTION/TOKEN || Complex condition
| condition || FUNCTION/TOKEN || Complex condition
|-
|-
| color || STRING || [[Text2skin-skin creation#Colors|Color]]
| color || STRING || [[Text2skin-skin creation#Colors|Color]]
|-
|-
| arc || ZAHL || Direction
| arc || NUMBER || Direction
|- bgcolor=#efefef
|- bgcolor=#efefef
!Beispiel
!Beispiel
Line 267: Line 267:
!Description
!Description
|-
|-
| x1 || ZAHL || Position of the left border
| x1 || NUMBER || Position of the left border
|-
|-
| y1 || ZAHL || Position of the top border
| y1 || NUMBER || Position of the top border
|-
|-
| y2 || ZAHL || Position of the right border
| y2 || NUMBER || Position of the right border
|-
|-
| x2 || ZAHL || Position of the bottom border
| x2 || NUMBER || Position of the bottom border
|-
|-
| condition || FUNKTION/TOKEN || Complex condition
| condition || FUNCTION/TOKEN || Complex condition
|-
|-
| color || STRING || [[Text2skin-skin creation#Colors|Color]] of the bar
| color || STRING || [[Text2skin-skin creation#Colors|Color]] of the bar
Line 287: Line 287:
| keep || STRING || [[Text2skin-skin creation#Colors|Color]] of the video area to keep
| keep || STRING || [[Text2skin-skin creation#Colors|Color]] of the video area to keep
|-
|-
| current || ZAHL/TOKEN || Current index value
| current || NUMBER/TOKEN || Current index value
|-
|-
| total || ZAHL/TOKEN || Maximum index value
| total || NUMBER/TOKEN || Maximum index value
|- bgcolor=#efefef
|- bgcolor=#efefef
!Beispiel
!Beispiel
Line 307: Line 307:
!Description
!Description
|-
|-
| x1 || ZAHL || Position of the left border
| x1 || NUMBER || Position of the left border
|-
|-
| y1 || ZAHL || Position of the top border
| y1 || NUMBER || Position of the top border
|-
|-
| y2 || ZAHL || Position of the right border
| y2 || NUMBER || Position of the right border
|-
|-
| x2 || ZAHL || Position of the bottom border
| x2 || NUMBER || Position of the bottom border
|-
|-
| condition || FUNKTION/TOKEN || Complex condition
| condition || FUNCTION/TOKEN || Complex condition
|-
|-
| color || STRING || [[Text2skin-skin creation#Colors|Color]] of the Texte
| color || STRING || [[Text2skin-skin creation#Colors|Color]] of the Texte
Line 346: Line 346:
!Description
!Description
|-
|-
| x1 || ZAHL || Position of the left border
| x1 || NUMBER || Position of the left border
|-
|-
| y1 || ZAHL || Position of the top border
| y1 || NUMBER || Position of the top border
|-
|-
| y2 || ZAHL || Position of the right border
| y2 || NUMBER || Position of the right border
|-
|-
| x2 || ZAHL || Position of the bottom border
| x2 || NUMBER || Position of the bottom border
|-
|-
| condition || FUNKTION/TOKEN || Complex condition
| condition || FUNCTION/TOKEN || Complex condition
|-
|-
| color || STRING || [[Text2skin-skin creation#Colors|Color]] of the bar
| color || STRING || [[Text2skin-skin creation#Colors|Color]] of the bar
Line 376: Line 376:
!Description
!Description
|-
|-
| condition || FUNKTION || Complex condition
| condition || FUNCTION || Complex condition
|- bgcolor=#efefef
|- bgcolor=#efefef
!Beispiel
!Beispiel
Line 397: Line 397:
!Description
!Description
|-
|-
| x1 || ZAHL || Position of the left border
| x1 || NUMBER || Position of the left border
|-
|-
| y1 || ZAHL || Position of the top border
| y1 || NUMBER || Position of the top border
|-
|-
| y2 || ZAHL || Position of the right border
| y2 || NUMBER || Position of the right border
|-
|-
| x2 || ZAHL || Position of the bottom border
| x2 || NUMBER || Position of the bottom border
|-
|-
| condition || FUNKTION/TOKEN || Complex condition
| condition || FUNCTION/TOKEN || Complex condition
|- bgcolor=#efefef
|- bgcolor=#efefef
!Beispiel
!Beispiel
Line 432: Line 432:
| condition || FUNKTION/TOKEN || Complex condition
| condition || FUNKTION/TOKEN || Complex condition
|-
|-
| height || ZAHL || Height of one list item
| height || NUMBER || Height of one list item
|- bgcolor=#efefef
|- bgcolor=#efefef
!Beispiel
!Beispiel

Revision as of 19:50, 17 December 2004

Elements

<skin>

This is the root element of the skins. All further elements go inside this container.

Attribute Value Description
version VERSION Version of the skin-format
name NAME Name to display in the VDR-OSD
screenBase "relative","absolute" Should the skin be drawn relative' to the VDR setup of absolute to the coordinates 720x576
Beispiel
<?xml version="1.0"?>
<skin version="1.0" name="brushed Aluminium" screenBase="relative">
  .
  .
  .
</skin>

<display>

For each type of a OSD display a <display>-section is required.

Attribute Value Description
id
  • channelInfo
  • channelSmall
  • volume
  • message
  • replayInfo
  • replaySmall
  • menu
Type of the OSD display
Beispiel
<?xml version="1.0"?>
<skin version="1.0" name="brushed Aluminium" screenBase="relative">
  <display id="replayInfo">
   .
   .
   .
  </display>
</skin>

<window>

Each <display>-container has to start with a definition of drawing areas.

Attribute Value Description
x1 NUMBER Position of the left border
y1 NUMBER Position of the top border
x2 NUMBER Position of the right border
y2 NUMBER Position of the bottom border
bpp NUMBER Color depth of the drawing area
Beispiel
<?xml version="1.0"?>
<skin version="1.0" name="brushed Aluminium" screenBase="relative">
  <display id="replayInfo">
    <window x1="0" x2="619" y1="-113" y2="-84" bpp="4" />
    <window x1="20" x2="99" y1="-83" y2="-44" bpp="4" />
     .
     .
     .
  </display>
</skin>

<rectangle>

Draws a filled rectangle.

Attribute Value Description
x1 NUMBER Position of the left border
y1 NUMBER Position of the top border
x2 NUMBER Position of the right border
y2 NUMBER Position of the bottom border
condition FUNCTION/TOKEN Complex condition
color STRING Color of the rectangle
Beispiel
<rectangle x1="20" x2="99" y1="-83" y2="-44" color="#00000000" />

<text>

A static or compound text.

Attribute Value Description
x1 NUMBER Position of the left border
y1 NUMBER Position of the top border
y2 NUMBER Position of the right border
x2 NUMBER Position of the bottom border
condition FUNCTION/TOKEN Complex condition
color STRING Text color
align
  • center
  • right
  • left
Alignment of the text
font STRING Font name
Beispiel
<text x1="42" x2="571" y1="-113" y2="-86" color="#FF000000" font="Osd">{ReplayTitle}</text>

<image>

Display an image.

Attribute Value Description
x NUMBER Position of the left border (keine Skalierung)
y NUMBER Position of the top border (keine Skalierung)
x1 NUMBER Position of the left border (mit Skalierung)
y1 NUMBER Position of the top border (mit Skalierung)
x2 NUMBER Position of the right border (mit Skalierung)
y2 NUMBER Position of the bottom border (mit Skalierung)
condition FUNCTION/TOKEN Complex condition
alpha NUMBER Transparence (0-255)
color STRING
bgColor STRING
path STRING/TOKEN Image file
Beispiel
<image x="0" y="-70" path="Aluminium_volumebar.png" />
<image x="585" y="138" condition="{CanScrollUp}" path="symbols/arrowup.xpm" color="#AFFFFF00" />

<ellipse>

Draws a circle, a pitch circle, or a ellipse.

Attribute Value Description
x1 NUMBER Position of the left border
y1 NUMBER Position of the top border
y2 NUMBER Position of the right border
x2 NUMBER Position of the bottom border
condition FUNCTION/TOKEN Complex condition
color STRING Color
arc NUMBER pitch circle
Beispiel
;-(

<slope>

Draws a curve.

Attribute Value Description
x1 NUMBER Position of the left border
y1 NUMBER Position of the top border
y2 NUMBER Position of the right border
x2 NUMBER Position of the bottom border
condition FUNCTION/TOKEN Complex condition
color STRING Color
arc NUMBER Direction
Beispiel
;-(

<progress>

A progressbar.

Attribute Value Description
x1 NUMBER Position of the left border
y1 NUMBER Position of the top border
y2 NUMBER Position of the right border
x2 NUMBER Position of the bottom border
condition FUNCTION/TOKEN Complex condition
color STRING Color of the bar
bgColor STRING Color of the background
mark STRING Color of the cutting marks
active STRING Color of the active area
keep STRING Color of the video area to keep
current NUMBER/TOKEN Current index value
total NUMBER/TOKEN Maximum index value
Beispiel
<progress x1="19" x2="556" y1="-17" y2="-7" color="#AF000000" current="{VolumeCurrent}" total="{VolumeTotal}" />

<scrolltext>

A multiline text.

Attribute Value Description
x1 NUMBER Position of the left border
y1 NUMBER Position of the top border
y2 NUMBER Position of the right border
x2 NUMBER Position of the bottom border
condition FUNCTION/TOKEN Complex condition
color STRING Color of the Texte
align
  • center
  • right
  • left
Alignment of the text
font STRING Fontname
Beispiel
<scrolltext x1="24" y1="138" y2="-72" x2="583" font="helmetr.ttf:20" color="#AFFFFF00">
{PresentShortText}
{PresentDescription}
</scrolltext>

<scrollbar>

A scrollbar.

Attribute Value Description
x1 NUMBER Position of the left border
y1 NUMBER Position of the top border
y2 NUMBER Position of the right border
x2 NUMBER Position of the bottom border
condition FUNCTION/TOKEN Complex condition
color STRING Color of the bar
bgColor STRING Color of the background
Beispiel
<scrollbar x1="585" x2="608" y1="162" y2="-110" color="#AFFFFF00" bgColor="#8F2B1B9E" />

<block>

A <block></block> pools several objects together.

Attribute Value Description
condition FUNCTION Complex condition
Beispiel
<block condition="file('logos/{ChannelName}.mng')"> 
 <rectangle x1="4" x2="67" y1="4" y2="51" color="#AF000000" />
 <image x="0" y="0" path="logos/{ChannelName}.mng" />
</block>

<list>

Defines a list in the menu.

Attribute Value Description
x1 NUMBER Position of the left border
y1 NUMBER Position of the top border
y2 NUMBER Position of the right border
x2 NUMBER Position of the bottom border
condition FUNCTION/TOKEN Complex condition
Beispiel
<list x1="24" y1="62" x2="569" y2="-82">
  <item height="28"/>
  <text x1="25" x2="569" y1="3" y2="27" color="#AF00FFFF" font="Sml">{MenuGroup}</text>
  <text x1="25" x2="569" y1="3" y2="27" color="#AFFFFFFF" font="Sml">{MenuItem}</text>
  <rectangle x1="0" x2="579" y1="0" y2="27" color="#FF2B1B9E" condition="{IsMenuCurrent}" />
  <text x1="22" x2="569" y1="0" y2="27" color="#AFFFFFFF" font="Osd">{MenuCurrent}</text>
  <text x1="0" x2="25" y1="0" y2="27" color="#AFFFFFFF" font="Osd">-></text>
</list>

<item>

Defines an item for the list.

Attribute Value Description
condition FUNKTION/TOKEN Complex condition
height NUMBER Height of one list item
Beispiel
<list x1="24" y1="62" x2="569" y2="-82">
  <item height="28" />
  <text x1="25" x2="569" y1="3" y2="27" color="#AF00FFFF" font="Sml">{MenuGroup}</text>
  <text x1="25" x2="569" y1="3" y2="27" color="#AFFFFFFF" font="Sml">{MenuItem}</text>
  <rectangle x1="0" x2="579" y1="0" y2="27" color="#FF2B1B9E" condition="{IsMenuCurrent}" />
  <text x1="22" x2="569" y1="0" y2="27" color="#AFFFFFFF" font="Osd">{MenuCurrent}</text>
  <text x1="0" x2="25" y1="0" y2="27" color="#AFFFFFFF" font="Osd">-></text>
</list>

Token

Common

Token Comment Description
DateTime (s.h. "man strftime")

Channel Display

Token Comment Description
ChannelNumber
ChannelName
ChannelShortName
ChannelBouquet
ChannelPortal
ChannelSource
PresentStartDateTime (also in #Menu Display)
PresentVPSDateTime (also in #Menu Display)
PresentEndDateTime (also in #Menu Display)
PresentDuration (also in #Menu Display)
PresentProgress (also in #Menu Display)
PresentTitle (also in #Menu Display)
PresentShortText (also in #Menu Display)
PresentDescription (also in #Menu Display)
FollowingStartDateTime
FollowingVPSDateTime
FollowingEndDateTime
FollowingDuration
FollowingTitle
FollowingShortText
FollowingDescription
Language
HasTeletext
HasMultilang
HasDolby
IsEncrypted
IsRadio
IsRecording
HasVPS (also in #Menu Display)
HasTimer (also in #Menu Display)
IsRunning (also in #Menu Display)

Volume Display

Token Comment Description
VolumeCurrent
VolumeTotal
IsMute

Message Display

Token Comment Description
Message
MessageStatus
MessageInfo
MessageWarning
MessageError

Replay Display

Token Comment Description
ReplayTitle
ReplayPositionIndex
ReplayDurationIndex
ReplayPrompt
IsPlaying
IsFastForward
IsFastRewind
IsSlowForward
IsSlowRewind
IsPausing
ReplayPosition
ReplayDuration
ReplayMode

Menu Display

Token Comment Description
MenuTitle Attribute: "clean"
MenuGroup
IsMenuGroup
MenuItem
IsMenuItem
MenuCurrent
IsMenuCurrent
MenuText Attribute: "clean"
ButtonRed
ButtonGreen
ButtonYellow
ButtonBlue
CanScrollUp
CanScrollDown
PresentStartDateTime (also in #Channel Display)
PresentVPSDateTime (also in #Channel Display)
PresentEndDateTime (also in #Channel Display)
PresentDuration (also in #Channel Display)
PresentProgress (also in #Channel Display)
PresentTitle (also in #Channel Display)
PresentShortText (also in #Channel Display)
PresentDescription (also in #Channel Display)
HasVPS (also in #Channel Display)
HasTimer (also in #Channel Display)
IsRunning (also in #Channel Display)


Functions

not

Negation of the term.

not(equal({PresentStartDateTime},{PresentVPSDateTime}))

and

True, if all parameter are true.

and({CanScrollUp},{CanScrollDown})

or

True, if one parameter is true.

or({CanScrollUp},{CanScrollDown})

equal

True, if both parameters are true.

equal('Kanäle', trans('Channels'))

file

Returns the parameter, if the file exists in the skin directory.

file('logos/{ChannelName}.png')

trans

Rreturn the translation (i18n) of the parameter, false, if no translation is found.

equal('Kanäle', trans('Channels'))