List of boolean conditions: Difference between revisions
No edit summary |
Update Boolean conditions from Doxygen |
||
| (5 intermediate revisions by the same user not shown) | |||
| Line 5: | Line 5: | ||
=== Global === | === Global === | ||
{| class="wikitable sortable" width="100%" | {| class="wikitable sortable" width="100%" | ||
! Labels | ! Labels | ||
! style="80%" | Description | ! style="80%" | Description | ||
|- | |||
| <code>false</code> | |||
| Returns | |||
:Always evaluates to '''false'''. | |||
|- | |||
| <code>no</code> | |||
| Returns | |||
:same as '''false'''. | |||
|- | |- | ||
| <code>true</code> | | <code>true</code> | ||
| Returns | | Returns | ||
:Always evaluates to '''true'''. | :Always evaluates to '''true'''. | ||
|- | |- | ||
| <code>yes</code> | | <code>yes</code> | ||
| Returns | | Returns | ||
:same as '''true'''. | :same as '''true'''. | ||
|} | |} | ||
=== Addon === | === Addon === | ||
{| class="wikitable sortable" width="100%" | {| class="wikitable sortable" width="100%" | ||
! Labels | ! Labels | ||
| Line 50: | Line 48: | ||
! style="80%" | Description | ! style="80%" | Description | ||
! Version | ! Version | ||
|- | |- | ||
| <code>Container(id).Column(column_number)</code> | | <code>Container(id).Column(column_number)</code> | ||
| Line 229: | Line 150: | ||
This is slightly delayed from the actual scroll start.<br> | This is slightly delayed from the actual scroll start.<br> | ||
Use Container(id).OnScrollNext/OnScrollPrevious to trigger animations immediately on scroll.}} | Use Container(id).OnScrollNext/OnScrollPrevious to trigger animations immediately on scroll.}} | ||
| | | | ||
|- | |- | ||
| <code>Container(id).SubItem</code> | | <code>Container(id).SubItem</code> | ||
| Line 236: | Line 157: | ||
{{highlight|'''Note'''<br> | {{highlight|'''Note'''<br> | ||
If no id is specified it grabs the current container.}} | If no id is specified it grabs the current container.}} | ||
| | |||
|- | |||
| <code>Container.CanFilter</code> | |||
| '''Returns''' | |||
:'''True''' when the current container can be filtered. | |||
| | |||
|- | |||
| <code>Container.CanFilterAdvanced</code> | |||
| '''Returns''' | |||
:'''True''' when advanced filtering can be applied to the current container. | |||
| | |||
|- | |||
| <code>Container.Content(parameter)</code> | |||
| '''Returns''' | |||
:'''True''' if the current container you are in contains the following: | |||
:*actors | |||
:*addons | |||
:*albums | |||
:*artists | |||
:*directors | |||
:*episodes | |||
:*files | |||
:*genres | |||
:*livetv | |||
:*movies | |||
:*musicvideos | |||
:*playlists | |||
:*plugins | |||
:*seasons | |||
:*sets | |||
:*songs | |||
:*studios | |||
:*tags | |||
:*tvshows | |||
:*years | |||
{{highlight|'''Note'''<br> | |||
These currently only work in the Video and Music Library, unless a Plugin has set the value.}} | |||
| | |||
|- | |||
| <code>Container.Filtered</code> | |||
| '''Returns''' | |||
:'''True''' when a mediafilter is applied to the current container. | |||
| | |||
|- | |||
| <code>Container.HasFiles</code> | |||
| '''Returns''' | |||
:'''True''' if the container contains files. | |||
| | |||
|- | |||
| <code>Container.HasFolders</code> | |||
| '''Returns''' | |||
:'''True''' if the container contains folders. | |||
| | |||
|- | |||
| <code>Container.HasThumb</code> | |||
| '''Returns''' | |||
:'''True''' if the current container you are in has a thumb assigned to it. | |||
| | |||
|- | |||
| <code>Container.IsStacked</code> | |||
| '''Returns''' | |||
:'''True''' if the container is currently in stacked mode. | |||
| | |||
|- | |||
| <code>Container.SortDirection(ascending)</code> | |||
| '''Returns''' | |||
:'''True''' if the sort direction of a container is ascending. | |||
| | |||
|- | |||
| <code>Container.SortDirection(descending)</code> | |||
| '''Returns''' | |||
:'''True''' if the sort direction of a container is descending. | |||
| | |||
|- | |||
| <code>Container.Sortmethod(sortid)</code> | |||
| '''Returns''' | |||
:'''True''' if the current sort method matches the specified SortID [[https://kodi.wiki/view/List_of_built-in_functions#List_of_sort_methods see list of sort methods]]. | |||
| | | | ||
|} | |} | ||
| Line 320: | Line 318: | ||
! style="80%" | Description | ! style="80%" | Description | ||
! Version | ! Version | ||
|- | |||
| <code>Library.HasContent(Role,Composer)</code> | |||
| Tag can be Composer, Conductor, Orchestra, Lyricist, Remixer, Arranger, Engineer, Producer, DJMixer or Mixer. Returns true if there are any artists with that role in the library | |||
| v17 | |||
|- | |- | ||
| <code>Library.HasContent(string)</code> | | <code>Library.HasContent(string)</code> | ||
| Returns true if the Kodi libraries have the content from string. Valid Strings are (Video, Music, Movies, TVShows, MusicVideos, MovieSets, BoxSets) | | Returns true if the Kodi libraries have the content from string. Valid Strings are (Video, Music, Movies, TVShows, MusicVideos, MovieSets, BoxSets) | ||
| | | | ||
|- | |||
| <code>Library.HasNode(path)</code> | |||
| Returns True if the specified node is available (example: Library.HasNode(library://video/movies/titles.xml)) | |||
| v19 | |||
|- | |||
| <code>Library.IsScanning</code> | |||
| '''Returns''' | |||
:'''True''' if the library is being scanned. | |||
| | |||
|- | |- | ||
| <code>Library.IsScanningMusic</code> | | <code>Library.IsScanningMusic</code> | ||
| Returns true if the music library is being updated | | Returns true if the music library is being updated | ||
| | | | ||
|- | |- | ||
| <code>Library.IsScanningVideo</code> | | <code>Library.IsScanningVideo</code> | ||
| Returns true if the video library is being updated | | Returns true if the video library is being updated | ||
| | | | ||
|} | |} | ||
| Line 347: | Line 350: | ||
! style="80%" | Description | ! style="80%" | Description | ||
! Version | ! Version | ||
|- | |||
| <code>ListItem.HasArchive</code> | |||
| Returns True when the selected channel has a server-side back buffer (PVR) | |||
| v19 | |||
|- | |||
| <code>ListItem.HasEpg</code> | |||
| Returns true when the selected programme has epg info (PVR) | |||
| | |||
|- | |||
| <code>ListItem.HasRecording</code> | |||
| '''Returns''' | |||
:'''True''' if a given epg tag item currently gets recorded or has been recorded. | |||
| | |||
|- | |||
| <code>ListItem.HasReminder</code> | |||
| Returns True if the item has a reminder set (PVR) | |||
| v19 | |||
|- | |||
| <code>ListItem.HasReminderRule</code> | |||
| Returns True if the item was scheduled by a reminder timer rule (PVR) | |||
| v19 | |||
|- | |||
| <code>ListItem.HasTimer</code> | |||
| Returns true when a recording timer has been set for the selected programme (PVR) | |||
| | |||
|- | |||
| <code>ListItem.HasTimerSchedule</code> | |||
| Whether the item is part of a repeating timer schedule (PVR). | |||
| v16 | |||
|- | |||
| <code>ListItem.HasVideoExtras</code> | |||
| Returns true if the ListItem has video extras | |||
| | |||
|- | |- | ||
| <code>ListItem.HasVideoVersions</code> | | <code>ListItem.HasVideoVersions</code> | ||
| Returns true if the ListItem has video versions | | Returns true if the ListItem has video versions | ||
| | | | ||
|- | |||
| <code>ListItem.InProgress</code> | |||
| '''Returns''' | |||
:'''True''' if the EPG event item is currently active (time-wise). | |||
| | |||
|- | |||
| <code>ListItem.IsAutoUpdateable</code> | |||
| Returns True if this add-on can be updated automatically | |||
| v19 | |||
|- | |- | ||
| <code>ListItem. | | <code>ListItem.IsBoxset</code> | ||
| Returns true if the | | Returns True if the item is part of a boxset album | ||
| | | v19 | ||
|- | |||
| <code>ListItem.IsCollection</code> | |||
| Returns true when the current ListItem is a movie set | |||
| | |||
|- | |||
| <code>ListItem.IsEncrypted</code> | |||
| Returns true when the selected programme is encrypted (PVR) | |||
| | |||
|- | |||
| <code>ListItem.IsFinale</code> | |||
| Returns true if the item is a finale (for example, a season finale showing on Live TV) | |||
| v19 | |||
|- | |- | ||
| <code>ListItem.IsFolder</code> | | <code>ListItem.IsFolder</code> | ||
| Returns whether the current ListItem is a folder | | Returns whether the current ListItem is a folder | ||
| | | | ||
|- | |||
| <code>ListItem.IsLive</code> | |||
| Returns true if the item is live (for example, a Live TV sports event) | |||
| v19 | |||
|- | |||
| <code>ListItem.IsNew</code> | |||
| Returns true if the item is a premiere (for example, a Live TV show that will be first aired) (PVR) | |||
| v19 | |||
|- | |||
| <code>ListItem.IsParentFolder</code> | |||
| Returns true is the slected item is the 'up' item | |||
| v17 | |||
|- | |||
| <code>ListItem.IsPlayable</code> | |||
| Returns True when the selected programme can be played (PVR) | |||
| v19 | |||
|- | |- | ||
| <code>ListItem.IsPlaying</code> | | <code>ListItem.IsPlaying</code> | ||
| Returns whether the current ListItem.* [[InfoLabels|info labels]] and images are currently Playing media | | Returns whether the current ListItem.* [[InfoLabels|info labels]] and images are currently Playing media | ||
| | | | ||
|- | |||
| <code>ListItem.IsPremiere</code> | |||
| Returns true if the item is a premiere (for example, a Movie first showing or season first on Live TV) | |||
| v19 | |||
|- | |||
| <code>ListItem.IsRecording</code> | |||
| Returns true when the selected programme is being recorded (PVR) | |||
| | |||
|- | |- | ||
| <code>ListItem.IsResumable</code> | | <code>ListItem.IsResumable</code> | ||
| Returns true when the current ListItem has been partially played | | Returns true when the current ListItem has been partially played | ||
| | | | ||
|- | |- | ||
| <code>ListItem.IsSelected</code> | | <code>ListItem.IsSelected</code> | ||
| Returns whether the current ListItem is selected (f.e. currently playing in playlist window) | | Returns whether the current ListItem is selected (f.e. currently playing in playlist window) | ||
| | | | ||
|- | |||
| <code>ListItem.IsStereoscopic</code> | |||
| Returns true when the selected video is a 3D (stereoscopic) video | |||
| | |||
|- | |||
| <code>ListItem.IsVideoExtra</code> | |||
| '''Returns''' | |||
:'''True''' when the selected item is a video extra. | |||
| | |||
|- | |||
| <code>ListItem.Property(Addon.HasUpdate)</code> | |||
| Returns true when there's an update available for the selected addon. | |||
| | |||
|- | |- | ||
| <code>ListItem. | | <code>ListItem.Property(Addon.IsBinary)</code> | ||
| Returns | | Returns true for binary addons | ||
| v19 | | v19 | ||
|- | |- | ||
| <code>ListItem. | | <code>ListItem.Property(Addon.IsEnabled)</code> | ||
| Returns true when the selected | | Returns true when the selected addon is enabled (for use in the addon info dialog only). | ||
| | | | ||
|- | |- | ||
| <code>ListItem. | | <code>ListItem.Property(Addon.IsFromOfficialRepo)</code> | ||
| Returns | | Returns true if the addon is from an official repository | ||
| v19 | | v19 | ||
|- | |- | ||
| <code>ListItem. | | <code>ListItem.Property(Addon.IsInstalled)</code> | ||
| Returns True if | | Returns true when the selected addon is installed (for use in the addon info dialog only). | ||
| | |||
|- | |||
| <code>ListItem.Property(Addon.IsUpdate)</code> | |||
| Returns True if this add-on is a valid update of an installed outdated add-on | |||
| v19 | | v19 | ||
|- | |- | ||
| <code>ListItem. | | <code>ListItem.Property(Addon.Orphaned)</code> | ||
| Returns true | | Returns true if the slected addon is orphaned (not needed anymore by any other addon) | ||
| | | v17 | ||
|- | |- | ||
| <code>ListItem. | | <code>ListItem.Property(DateLabel)</code> | ||
| | | Can be used in the rulerlayout of the epggrid control. Will return true if the item is a date label, returns false if the item is a time label. | ||
| | | | ||
|- | |- | ||
| <code>ListItem. | | <code>ListItem.Property(IsSpecial)</code> | ||
| Returns whether the current Season/Episode is a Special | |||
| | |||
| Returns | |||
| | |||
|- | |- | ||
| <code>ListItem.Property(Stream.Is3D)</code> | | <code>ListItem.Property(Stream.Is3D)</code> | ||
| Line 436: | Line 526: | ||
| v22 | | v22 | ||
|- | |- | ||
| <code>ListItem. | | <code>ListItem.TimerHasConflict</code> | ||
| | | Whether the item has a timer and it won't be recorded because of a conflict (PVR). | ||
| v17 | |||
| | |||
|- | |- | ||
| <code>ListItem.TimerHasError</code> | | <code>ListItem.TimerHasError</code> | ||
| Whether the item has a timer and it won't be recorded because of an error (PVR). | | Whether the item has a timer and it won't be recorded because of an error (PVR). | ||
| v17 | | v17 | ||
|- | |- | ||
| Line 472: | Line 538: | ||
| v17 | | v17 | ||
|- | |- | ||
| <code>ListItem. | | <code>ListItem.TotalDiscs</code> | ||
| Returns | | '''Returns''' | ||
:The total number of discs belonging to an album. | |||
| | |||
| | |||
|} | |} | ||
=== Network === | === Network === | ||
{| class="wikitable sortable" width="100%" | {| class="wikitable sortable" width="100%" | ||
! InfoLabels | ! InfoLabels | ||
| Line 530: | Line 552: | ||
| <code>Network.IsDHCP</code> | | <code>Network.IsDHCP</code> | ||
| '''Returns''' | | '''Returns''' | ||
: | :'''True''' if the network type is DHCP. | ||
{{highlight|'''Note'''<br> | {{highlight|'''Note'''<br> | ||
Network type can be either DHCP or FIXED.}} | Network type can be either DHCP or FIXED.}} | ||
| Line 542: | Line 564: | ||
! Version | ! Version | ||
|- | |- | ||
| <code>Player. | | <code>Player.Caching</code> | ||
| Returns true if the player | | Returns true if the player is current <span class="nobr">re-caching</span> data (internet based video playback). | ||
| | | | ||
|- | |- | ||
| <code>Player. | | <code>Player.ChannelPreviewActive</code> | ||
| Returns true if | | Returns true if PVR channel preview is active (used channel tag different from played tag) | ||
| | | | ||
|- | |- | ||
| <code>Player. | | <code>Player.DisplayAfterSeek</code> | ||
| Returns true | | Returns true for the first 2.5 seconds after a seek. | ||
| | |||
| | |||
|- | |- | ||
| <code>Player.Forwarding</code> | | <code>Player.Forwarding</code> | ||
| Returns true if the player is fast forwarding. | | Returns true if the player is fast forwarding. | ||
| | | | ||
|- | |||
| <code>Player.Forwarding16x</code> | |||
| Returns true if the player is fast forwarding at 16x. | |||
| | |||
|- | |- | ||
| <code>Player.Forwarding2x</code> | | <code>Player.Forwarding2x</code> | ||
| Returns true if the player is fast forwarding at 2x. | | Returns true if the player is fast forwarding at 2x. | ||
| | | | ||
|- | |||
| <code>Player.Forwarding32x</code> | |||
| Returns true if the player is fast forwarding at 32x. | |||
| | |||
|- | |- | ||
| <code>Player.Forwarding4x</code> | | <code>Player.Forwarding4x</code> | ||
| Returns true if the player is fast forwarding at 4x. | | Returns true if the player is fast forwarding at 4x. | ||
| | | | ||
|- | |- | ||
| <code>Player.Forwarding8x</code> | | <code>Player.Forwarding8x</code> | ||
| Returns true if the player is fast forwarding at 8x. | | Returns true if the player is fast forwarding at 8x. | ||
| | | | ||
|- | |- | ||
| <code>Player. | | <code>Player.FrameAdvance</code> | ||
| Returns true if | | Returns true if player is in frame advance mode | ||
| | | v18 | ||
|- | |- | ||
| <code>Player. | | <code>Player.HasAudio</code> | ||
| Returns true if the player | | Returns true if the player has an audio file. | ||
| | | | ||
|- | |- | ||
| <code>Player. | | <code>Player.HasBookmarks</code> | ||
| Returns | | '''Returns''' | ||
| | :'''True''' if the item being played has bookmarks, '''False''' otherwise | ||
| | |||
|- | |- | ||
| <code>Player. | | <code>Player.HasDuration</code> | ||
| Returns true if | | Returns true if Media isn't a true stream | ||
| | | | ||
|- | |- | ||
| <code>Player. | | <code>Player.HasGame</code> | ||
| Returns true if the player is | | Returns true if the player is playing a game | ||
| | | v18 | ||
|- | |- | ||
| <code>Player. | | <code>Player.HasMedia</code> | ||
| Returns true if the player | | Returns true if the player has an audio or video file. | ||
| | | | ||
|- | |- | ||
| <code>Player. | | <code>Player.HasPerformedSeek(interval)</code> | ||
| Returns | | '''Returns''' | ||
| | :'''True''' if the Player has performed a seek operation in the last provided second <code>interval</code>, '''False''' otherwise. | ||
'''Parameters''' | |||
:interval - the time interval (in seconds) | |||
| | |||
|- | |- | ||
| <code>Player. | | <code>Player.HasPrograms</code> | ||
| Returns | | '''Returns''' | ||
| | :'''True''' if the media file being played has programs, i.e. groups of streams. | ||
{{highlight|'''Note'''<br>Ex: if a media file has multiple streams (quality, channels, etc) a program represents a particular stream combo.}} | |||
| | |||
|- | |- | ||
| <code>Player. | | <code>Player.HasResolutions</code> | ||
| Returns true | | Returns true when multiple resolutions are available | ||
| | | v18 | ||
|- | |- | ||
| <code>Player. | | <code>Player.HasSceneMarkers</code> | ||
| Returns | | '''Returns''' | ||
| | :'''True''' if the item being played has scene markers, '''False''' otherwise | ||
| | |||
|- | |- | ||
| <code>Player. | | <code>Player.HasVideo</code> | ||
| Returns true | | Returns true if the player has a video file. | ||
| | | | ||
|- | |- | ||
| <code>Player. | | <code>Player.IsExternal</code> | ||
| Returns | | '''Returns''' | ||
| | :'''True''' if the playing player is an external player, '''False''' otherwise | ||
| | |||
|- | |- | ||
| <code>Player. | | <code>Player.IsInternetStream</code> | ||
| Returns true if player | | Returns true if the player is playing an internet stream. | ||
| | | | ||
|- | |- | ||
| <code>Player. | | <code>Player.IsLive</code> | ||
| Returns | | Returns if the inputstream of the player is a live stream (a.k.a. real time stream). | ||
| | | v22 | ||
|- | |- | ||
| <code>Player. | | <code>Player.IsRemote</code> | ||
| Returns | | '''Returns''' | ||
| | :'''True''' if the playing player is a remote player (e.g. UPnP), '''False''' otherwise | ||
| | |||
|- | |- | ||
| <code>Player. | | <code>Player.IsTempo</code> | ||
| Returns true if the | | Returns true if the current playbackspeed is not equal to 1 | ||
| | | v17 | ||
|- | |- | ||
| <code>Player.Muted</code> | | <code>Player.Muted</code> | ||
| Returns true if the volume is muted. | | Returns true if the volume is muted. | ||
| | | | ||
|- | |||
| <code>Player.Passthrough</code> | |||
| Returns true if the player is using audio passthrough. | |||
| | |||
|- | |||
| <code>Player.Paused</code> | |||
| Returns true if the player is paused. | |||
| | |||
|- | |||
| <code>Player.PauseEnabled</code> | |||
| Returns true if the currently playing stream can be paused. | |||
| | |||
|- | |||
| <code>Player.Playing</code> | |||
| Returns true if the player is currently playing (ie not ffwding, rewinding or paused.) | |||
| | |||
|- | |- | ||
| <code>Player.Process(videohwdecoder)</code> | | <code>Player.Process(videohwdecoder)</code> | ||
| Line 658: | Line 697: | ||
| v17 | | v17 | ||
|- | |- | ||
| <code>Player. | | <code>Player.Rewinding</code> | ||
| Returns true if the | | Returns true if the player is rewinding. | ||
| | | | ||
|- | |||
| <code>Player.Rewinding16x</code> | |||
| Returns true if the player is rewinding at 16x. | |||
| | |||
|- | |||
| <code>Player.Rewinding2x</code> | |||
| Returns true if the player is rewinding at 2x. | |||
| | |||
|- | |||
| <code>Player.Rewinding32x</code> | |||
| Returns true if the player is rewinding at 32x. | |||
| | |||
|- | |||
| <code>Player.Rewinding4x</code> | |||
| Returns true if the player is rewinding at 4x. | |||
| | |||
|- | |||
| <code>Player.Rewinding8x</code> | |||
| Returns true if the player is rewinding at 8x. | |||
| | |||
|- | |- | ||
| <code>Player. | | <code>Player.SeekEnabled</code> | ||
| Returns true if | | Returns true if player can seek | ||
| | | | ||
|- | |- | ||
| <code>Player. | | <code>Player.Seeking</code> | ||
| Returns true if | | Returns true if a seek is in progress | ||
| | | | ||
|- | |- | ||
| <code>Player. | | <code>Player.ShowInfo</code> | ||
| Returns true | | Returns true if the user has requested the song info to show (occurs in visualisation fullscreen and slideshow) | ||
| | | | ||
|- | |- | ||
| <code>Player. | | <code>Player.ShowTime</code> | ||
| Returns true if | | Returns true if the user has requested the time to show (occurs in video fullscreen) | ||
| | | | ||
|- | |- | ||
| <code>Player. | | <code>Player.TempoEnabled</code> | ||
| Returns true if | | Returns true if the current player supports changing the playback speed | ||
| | | v17 | ||
|} | |} | ||
| Line 688: | Line 747: | ||
! style="80%" | Description | ! style="80%" | Description | ||
! Version | ! Version | ||
|- | |||
| <code>MusicPlayer.Exists(relative,position)</code> | |||
| '''Returns''' | |||
:'''True''' if the currently playing playlist has a song queued at the given position. | |||
'''Parameters''' | |||
:relative - bool - If the position is relative | |||
:position - int - The position of the song | |||
{{highlight|'''Note'''<br>It is possible to define whether the position is relative or not, default is '''false'''.}} | |||
| | |||
|- | |- | ||
| <code>MusicPlayer.HasNext</code> | | <code>MusicPlayer.HasNext</code> | ||
| Line 712: | Line 780: | ||
| Returns true if the current album consists of two or more discs | | Returns true if the current album consists of two or more discs | ||
| v19 | | v19 | ||
|- | |||
| <code>MusicPlayer.PlaylistPlaying</code> | |||
| '''Returns''' | |||
:'''True''' if a playlist is currently playing. | |||
| | |||
|} | |||
=== RetroPlayer === | |||
{| class="wikitable sortable" width="100%" | |||
! Labels | |||
! style="80%" | Description | |||
! Version | |||
|- | |||
| <code>RetroPlayer.DiscEjected</code> | |||
| '''Returns''' | |||
:'''True''' if the game's disc is ejected (tray is open), '''False''' if the game isn't disc-based or the tray is closed. | |||
| | |||
|- | |||
| <code>RetroPlayer.EmptyTray</code> | |||
| '''Returns''' | |||
:'''True''' if the selected disc state is "No disc", '''False''' if a disc is selected or the game isn't disc-based. | |||
| | |||
|- | |||
| <code>RetroPlayer.SupportsEject</code> | |||
| '''Returns''' | |||
:'''True''' if the game's disc can be ejected, '''False''' if the game isn't disc-based or doesn't support ejecting the disc. | |||
| | |||
|} | |} | ||
| Line 719: | Line 815: | ||
! style="80%" | Description | ! style="80%" | Description | ||
! Version | ! Version | ||
|- | |||
| <code>VideoPlayer.CanResumeLiveTV</code> | |||
| '''Returns''' | |||
:'''True''' if a in-progress PVR recording is playing an the respective live TV channel is available. | |||
| | |||
|- | |- | ||
| <code>VideoPlayer.HasVideoVersions</code> | | <code>VideoPlayer.HasVideoVersions</code> | ||
| Line 763: | Line 864: | ||
| <code>VideoPlayer.HasTeletext</code> | | <code>VideoPlayer.HasTeletext</code> | ||
| Returns true when teletext is available. | | Returns true when teletext is available. | ||
| | | | ||
|} | |} | ||
| Line 782: | Line 883: | ||
| <code>Playlist.IsRepeatOne</code> | | <code>Playlist.IsRepeatOne</code> | ||
| Returns true if the player is in repeat one mode. | | Returns true if the player is in repeat one mode. | ||
| | | | ||
|} | |} | ||
| Line 791: | Line 892: | ||
! Version | ! Version | ||
|- | |- | ||
| <code>Pvr. | | <code>Pvr.ActStreamIsEncrypted</code> | ||
| Returns true | | Returns true if the stream is encrypted | ||
| | |||
|- | |||
| <code>Pvr.CanRecordPlayingChannel</code> | |||
| Returns true if the player can record the current internet stream. | |||
| v18 | |||
|- | |||
| <code>Pvr.HasNonRecordingRadioTimer</code> | |||
| Returns true if there are radio timers present who currently not do recording | |||
| v17 | |||
| | | | ||
|- | |- | ||
| <code>Pvr.HasNonRecordingTimer</code> | | <code>Pvr.HasNonRecordingTimer</code> | ||
| Returns true when a non recording timer is active. | | Returns true when a non recording timer is active. | ||
| | |||
|- | |||
| <code>Pvr.HasNonRecordingTVTimer</code> | |||
| Returns true if there are tv timers present who currently not do recording | |||
| v17 | |||
|- | |||
| <code>Pvr.HasRadioChannels</code> | |||
| Returns true if there are radio channels available | |||
| | |||
|- | |||
| <code>Pvr.HasRadioTimer</code> | |||
| Returns true if at least one radio timer is active. | |||
| v17 | |||
|- | |||
| <code>Pvr.HasTimer</code> | |||
| Returns true when a recording timer is active. | |||
| | | | ||
|- | |- | ||
| Line 803: | Line 929: | ||
| | | | ||
|- | |- | ||
| <code>Pvr. | | <code>Pvr.HasTVTimer</code> | ||
| Returns true if | | Returns true if at least one tv timer is active. | ||
| | | v17 | ||
|- | |||
| <code>Pvr.IsPlayingActiveRecording</code> | |||
| Returns true when Kodi is currently playing a recording that is in progress. | |||
| v19 | |||
|- | |- | ||
| <code> | | <code>PVR.IsPlayingEpgTag</code> | ||
| Returns | | '''Returns''' | ||
:'''True''' when an epg tag is being watched. | |||
| | | | ||
|- | |- | ||
| Line 817: | Line 948: | ||
| <code>Pvr.IsPlayingRecording</code> | | <code>Pvr.IsPlayingRecording</code> | ||
| Returns true when a recording is being watched. | | Returns true when a recording is being watched. | ||
| | |||
|- | |||
| <code>Pvr.IsPlayingTv</code> | |||
| Returns true when live tv is being watched. | |||
| | | | ||
|- | |- | ||
| Line 823: | Line 958: | ||
| | | | ||
|- | |- | ||
| <code>Pvr. | | <code>Pvr.IsRecordingPlayingChannel</code> | ||
| Returns true | | Returns true if the player is recording the current internet stream. | ||
| | | v18 | ||
|- | |- | ||
| <code>Pvr. | | <code>Pvr.IsRecordingRadio</code> | ||
| Returns true | | Returns true when the system is recording a radio programme. | ||
| v17 | | v17 | ||
|- | |- | ||
| Line 839: | Line 970: | ||
| v17 | | v17 | ||
|- | |- | ||
| <code>Pvr. | | <code>Pvr.IsTimeShift</code> | ||
| Returns true | | Returns true when the playback is timeshifted. | ||
| | | | ||
|- | |- | ||
| <code> | | <code>PVR.NextTimer</code> | ||
| Returns | | '''Returns''' | ||
| | :The next timer date. | ||
| | |||
|- | |- | ||
| <code>Pvr. | | <code>Pvr.RadioNextRecordingChannelIcon</code> | ||
| | | Icon of the next recording radio channel | ||
| v17 | | v17 | ||
|} | |} | ||
| Line 879: | Line 990: | ||
! Version | ! Version | ||
|- | |- | ||
| <code>RDS. | | <code>RDS.HasHotline</code> | ||
| Returns true if | | Returns true if a hotline phone number is present (Only be available on RadiotextPlus) | ||
| | | | ||
|- | |- | ||
| Line 891: | Line 1,002: | ||
| | | | ||
|- | |- | ||
| <code>RDS. | | <code>RDS.HasRds</code> | ||
| Returns true if | | Returns true if RDS is present | ||
| | | | ||
|- | |- | ||
| <code>RDS.HasStudio</code> | | <code>RDS.HasStudio</code> | ||
| Returns true if a studio name is present (Only be available on RadiotextPlus) | | Returns true if a studio name is present (Only be available on RadiotextPlus) | ||
| | | | ||
|} | |} | ||
| Line 905: | Line 1,016: | ||
! style="80%" | Description | ! style="80%" | Description | ||
! Version | ! Version | ||
|- | |||
| <code>Skin.HasSetting(setting)</code> | |||
| Returns the state of the <span class="nobr">skin-specified</span> setting ?setting?. You can toggle a setting from a button by using <onclick>Skin.ToggleSetting(setting)</onclick>. | |||
| | |||
|- | |- | ||
| <code>Skin.HasTheme(theme)</code> | | <code>Skin.HasTheme(theme)</code> | ||
| Returns true if the user has selected the theme with name ?theme?. | | Returns true if the user has selected the theme with name ?theme?. | ||
| | | | ||
|- | |- | ||
| Line 920: | Line 1,031: | ||
| <code>Skin.String(string1,string2)</code> | | <code>Skin.String(string1,string2)</code> | ||
| Same as String.IsEqual(Skin.String(string1),string2). Returns true if Skin.String(string1) equals string2. | | Same as String.IsEqual(Skin.String(string1),string2). Returns true if Skin.String(string1) equals string2. | ||
| | | | ||
|- | |||
| <code>Skin.TimerIsRunning(timer)</code> | |||
| '''Returns''' | |||
:'''True''' if the given <code>timer</code> is active, '''false''' otherwise. | |||
'''Parameters''' | |||
:timer - the timer name | |||
| | |||
|} | |} | ||
| Line 943: | Line 1,061: | ||
| <code>Slideshow.IsVideo</code> | | <code>Slideshow.IsVideo</code> | ||
| Returns true if the picture slideshow is playing a video | | Returns true if the picture slideshow is playing a video | ||
| | | | ||
|} | |} | ||
| Line 951: | Line 1,069: | ||
! style="80%" | Description | ! style="80%" | Description | ||
! Version | ! Version | ||
|- | |||
| <code>String.Contains([[InfoLabels|info]],substring)</code> | |||
| Returns true if the [[InfoLabels|info]] contains the given substring.<br />Example of info: ListItem.Title, ListItem.Genre. Please note that string can also be a $LOCALIZE[] or [[InfoLabels|info label]] (without $INFO prefix). Also note that in a panelview or similar this only works on the focused item. | |||
| v17 | |||
|- | |||
| <code>String.EndsWith([[InfoLabels|info]],substring)</code> | |||
| Returns true if the [[InfoLabels|info]] ends with the given substring.<br />Example of info: ListItem.Title, ListItem.Genre. Please note that string can also be a $LOCALIZE[] or [[InfoLabels|info label]] (without $INFO prefix). Also note that in a panelview or similar this only works on the focused item. | |||
| v17 | |||
|- | |- | ||
| <code>String.IsEmpty([[InfoLabels|info]])</code> | | <code>String.IsEmpty([[InfoLabels|info]])</code> | ||
| Line 962: | Line 1,088: | ||
| <code>String.StartsWith([[InfoLabels|info]],substring)</code> | | <code>String.StartsWith([[InfoLabels|info]],substring)</code> | ||
| Returns true if the [[InfoLabels|info]] starts with the given substring.<br />Example of info: ListItem.Title, ListItem.Genre. Please note that string can also be a $LOCALIZE[] or [[InfoLabels|info label]] (without $INFO prefix). Also note that in a panelview or similar this only works on the focused item. | | Returns true if the [[InfoLabels|info]] starts with the given substring.<br />Example of info: ListItem.Title, ListItem.Genre. Please note that string can also be a $LOCALIZE[] or [[InfoLabels|info label]] (without $INFO prefix). Also note that in a panelview or similar this only works on the focused item. | ||
| v17 | | v17 | ||
|} | |} | ||
| Line 982: | Line 1,100: | ||
| Returns true if the specified addon is enabled on the system | | Returns true if the specified addon is enabled on the system | ||
| v19 | | v19 | ||
|- | |||
| <code>System.AlarmLessOrEqual(alarmname,seconds)</code> | |||
| Returns true if the alarm with ?alarmname? has less or equal to ?seconds? left. Standard use would be system.alarmlessorequal(shutdowntimer,119), which would return true when the shutdowntimer has less then 2 minutes left. | |||
| | |||
|- | |||
| <code>System.CanHibernate</code> | |||
| Returns true if Kodi can hibernate the system. | |||
| | |||
|- | |||
| <code>System.CanPowerDown</code> | |||
| Returns true if Kodi can powerdown the system. | |||
| | |||
|- | |||
| <code>System.CanReboot</code> | |||
| Returns true if Kodi can reboot the system. | |||
| | |||
|- | |||
| <code>System.CanSuspend</code> | |||
| Returns true if Kodi can suspend the system. | |||
| | |||
|- | |||
| <code>System.Date(startDate,endDate)</code> | |||
| Returns true if the current system date is >= startDate and < endDate. endDate is optional. Date must be specified in the format MM-DD. | |||
| | |||
|- | |||
| <code>System.DPMSActive</code> | |||
| '''Returns''' | |||
:'''True''' if DPMS (VESA Display Power Management Signaling) mode is active. | |||
| | |||
|- | |||
| <code>System.DVDReady</code> | |||
| '''Returns''' | |||
:'''True''' if the disc is ready to use. | |||
| | |||
|- | |||
| <code>System.GetBool(boolean)</code> | |||
| Returns the value of any standard system boolean setting. Will not work with settings in advancedsettings.xml | |||
| | |||
|- | |||
| <code>System.HasActiveModalDialog</code> | |||
| Returns true true when a modal dialog is active, disregarding any animations (Leia (v18) and newer versions) | |||
| v18 | |||
|- | |- | ||
| <code>System.HasAddon(id)</code> | | <code>System.HasAddon(id)</code> | ||
| Returns true if the specified addon is installed on the system. | | Returns true if the specified addon is installed on the system. | ||
| | | | ||
|- | |- | ||
| Line 995: | Line 1,151: | ||
| | | | ||
|- | |- | ||
| <code>System. | | <code>System.HasCMS</code> | ||
| Returns true if | | Returns true if colour management is supported in Kodi. | ||
| v17 | |||
|- | |||
| <code>System.HasCoreId(id)</code> | |||
| '''Returns''' | |||
:'''True''' if the CPU core with the given 'id' exists. | |||
'''Parameters''' | |||
:id - the id of the CPU core | |||
| | | | ||
|- | |- | ||
| <code>System. | | <code>System.HasHiddenInput</code> | ||
| | | Return true when to osd keyboard/numeric dialog requests a password/pincode. | ||
| | | | ||
|- | |- | ||
| <code>System. | | <code>System.HasLocks</code> | ||
| Returns true if the | | Returns true if the profile has lock preferences configured | ||
| | | | ||
|- | |- | ||
| <code>System. | | <code>System.HasLoginScreen</code> | ||
| Returns true if | | Returns true if the [[Profiles| profile]] login screen is enabled | ||
| | | | ||
|- | |- | ||
| Line 1,015: | Line 1,178: | ||
| v18 | | v18 | ||
|- | |- | ||
| <code>System. | | <code>System.HasMediaBlurayPlaylist</code> | ||
| Returns | | '''Returns''' | ||
:'''True''' if there is a bluray in the drive that has been played before. '''False''' if no drive available, empty drive, other medium or new bluray. | |||
| | | | ||
|- | |- | ||
| <code>System. | | <code>System.HasMediadvd</code> | ||
| Returns true if | | Returns true if there is a CD or DVD in the <span class="nobr">DVD-ROM</span> drive. | ||
| | | | ||
|- | |- | ||
| <code>System. | | <code>System.HasNetwork</code> | ||
| Returns true if | | Returns true if the ethernet cable is plugged in. | ||
| | | | ||
|- | |- | ||
| <code>System. | | <code>System.HasPVR</code> | ||
| Returns | | '''Returns''' | ||
:'''True''' if PVR is supported from Kodi. | |||
{{highlight|'''Note'''<br>normally always '''true'''}} | |||
| | | | ||
|- | |- | ||
| <code>System. | | <code>System.HasPVRAddon</code> | ||
| Returns true if the | | Returns true if at least one PVR addon is installed on the system. | ||
| | | | ||
|- | |- | ||
| <code>System. | | <code>System.HasShutdown</code> | ||
| Returns | | Returns true when shutdown on idle is enabled. | ||
| | | | ||
|- | |- | ||
| <code>System.HasVisibleModalDialog</code> | | <code>System.HasVisibleModalDialog</code> | ||
| Line 1,043: | Line 1,209: | ||
| v18 | | v18 | ||
|- | |- | ||
| <code>System. | | <code>System.IdleShutdownInhibited</code> | ||
| Returns | | '''Returns''' | ||
:'''True''' when shutdown on idle is disabled. | |||
| | | | ||
|- | |- | ||
| <code>System. | | <code>System.IdleTime(time)</code> | ||
| Returns true if | | Returns true if Kodi has had no input for ?time? amount of seconds. | ||
| | | | ||
|- | |- | ||
| <code>System. | | <code>System.InternetState</code> | ||
| Returns true if | | Returns true if the system is connected to the internet, returns false in case no internet connection is available. | ||
| | | | ||
|- | |- | ||
| <code>System. | | <code>System.IsFullscreen</code> | ||
| Returns true if Kodi is running | | Returns true if Kodi is running fullscreen. | ||
| | | | ||
|- | |- | ||
| <code>System. | | <code>System.IsInhibit</code> | ||
| Returns true | | Returns true when shutdown on idle is disabled. | ||
| | | | ||
|- | |- | ||
| <code>System. | | <code>System.IsLoggedOn</code> | ||
| Returns true if | | Returns true if a user is currently logged on under a [[Profiles| profile]] | ||
| | | | ||
|- | |- | ||
| <code>System. | | <code>System.IsMaster</code> | ||
| Returns true if | | Returns true if the profile has entered the master mode | ||
| | | | ||
|- | |- | ||
| <code>System. | | <code>System.IsScreensaverInhibited</code> | ||
| Returns | | '''Returns''' | ||
:'''True''' when screensaver on idle is disabled. | |||
| | | | ||
|- | |- | ||
| <code>System. | | <code>System.IsStandalone</code> | ||
| Returns true if Kodi is running | | Returns true if Kodi is running in standalone mode. | ||
| | | | ||
|- | |- | ||
| <code>System. | | <code>System.LoggedOn</code> | ||
| Returns | | '''Returns''' | ||
:'''True''' if a user is currently logged on under a profile. | |||
| | | | ||
|- | |- | ||
| <code>System. | | <code>System.Platform.Android</code> | ||
| Returns true if Kodi | | Returns true if Kodi is running on an android device. | ||
| | | | ||
|- | |- | ||
| <code>System. | | <code>System.Platform.Darwin</code> | ||
| Returns true if Kodi | | Returns true if Kodi is running on an OSX or IOS system. | ||
| | | | ||
|- | |- | ||
| <code>System. | | <code>System.Platform.IOS</code> | ||
| | | Returns true if Kodi is running on an IOS device. | ||
| | | | ||
|- | |- | ||
| <code>System. | | <code>System.Platform.Linux</code> | ||
| Returns true if Kodi | | Returns true if Kodi is running on a linux/unix based computer. | ||
| | | | ||
|- | |- | ||
| <code>System. | | <code>System.Platform.OSX</code> | ||
| Returns true if | | Returns true if Kodi is running on an OSX based computer. | ||
| | | | ||
|- | |- | ||
| <code>System. | | <code>System.Platform.TVOS</code> | ||
| Returns | | '''Returns''' | ||
:'''True''' if Kodi is running on a tvOS device. | |||
| | | | ||
|- | |- | ||
| <code>System. | | <code>System.Platform.UWP</code> | ||
| Returns true | | Returns true if Kodi is running on Universal Windows Platform (UWP). | ||
| v18 | |||
|- | |||
| <code>System.Platform.WebOS</code> | |||
| '''Returns''' | |||
:'''True''' if Kodi is running on a WebOS device. | |||
| | | | ||
|- | |- | ||
| <code>System. | | <code>System.Platform.Windows</code> | ||
| Returns true | | Returns true if Kodi is running on a windows based computer. | ||
| | | | ||
|- | |- | ||
| <code>System. | | <code>System.ScreenSaverActive</code> | ||
| Returns true if | | Returns true if ScreenSaver is active. | ||
| | | | ||
|- | |- | ||
| <code>System. | | <code>System.Setting(hidewatched)</code> | ||
| Returns true if | | Returns true if 'hide watched items' is selected. | ||
| | | | ||
|- | |- | ||
| <code>System. | | <code>System.ShowExitButton</code> | ||
| Returns | | '''Returns''' | ||
:'''True''' if the exit button should be shown (configurable via advanced settings). | |||
| | | | ||
|- | |- | ||
| Line 1,134: | Line 1,306: | ||
| Return True if the system provides CPU info | | Return True if the system provides CPU info | ||
| v19 | | v19 | ||
|- | |||
| <code>System.Time(startTime,endTime)</code> | |||
| Returns true if the current system time is >= startTime and < endTime. endTime is optional. Time must be specified in the format HH:mm, using a 24 hour clock. | |||
| | |||
|- | |||
| <code>System.TrayOpen</code> | |||
| '''Returns''' | |||
:'''True''' if the disc tray is open. | |||
| | |||
|} | |} | ||
| Line 1,152: | Line 1,333: | ||
| <code>Visualisation.Locked</code> | | <code>Visualisation.Locked</code> | ||
| Returns true if the current visualisation preset is locked (e.g. in Milkdrop.) | | Returns true if the current visualisation preset is locked (e.g. in Milkdrop.) | ||
| | | | ||
|} | |} | ||
| Line 1,163: | Line 1,344: | ||
| <code>Weather.IsFetched</code> | | <code>Weather.IsFetched</code> | ||
| Returns true if the weather data has been downloaded. | | Returns true if the weather data has been downloaded. | ||
| | | | ||
|- | |||
| <code>Weather.IsUpdating</code> | |||
| '''Returns''' | |||
:'''True''' if weather data are currently updating. | |||
| | |||
|} | |} | ||
| Line 1,172: | Line 1,358: | ||
! Version | ! Version | ||
|- | |- | ||
| <code>Window. | | <code>Window.Is(name)</code> | ||
| | | Useful in xml files that are shared between multiple windows/dialogs. Will return true if the window with the given name is visible | ||
| | | v17 | ||
|- | |- | ||
| <code>Window.IsActive(window)</code> | | <code>Window.IsActive(window)</code> | ||
| Returns true if the window with id or title ?window? is active (excludes fade out time on dialogs) [[Window IDs| See here for a list of windows]] | | Returns true if the window with id or title ?window? is active (excludes fade out time on dialogs) [[Window IDs| See here for a list of windows]] | ||
| | |||
|- | |||
| <code>Window.IsDialogTopmost(dialog)</code> | |||
| '''Returns''' | |||
:'''True''' if the dialog with id or title dialog is on top of the dialog stack. | |||
'''Parameters''' | |||
:window - the id or name of the window | |||
{{highlight|'''Note'''<br>Excludes fade out time on dialogs}} | |||
| | |||
|- | |||
| <code>Window.IsMedia</code> | |||
| Returns true if this window is a media window (programs, music, video, scripts, pictures) | |||
| | |||
|- | |||
| <code>Window.IsModalDialogTopmost(dialog)</code> | |||
| '''Returns''' | |||
:'''True''' if the dialog with id or title dialog is on top of the modal dialog stack | |||
{{highlight|'''Note'''<br>Excludes fade out time on dialogs}} | |||
| | | | ||
|- | |- | ||
| Line 1,184: | Line 1,388: | ||
| | | | ||
|- | |- | ||
| <code>Window. | | <code>Window.IsVisible(window)</code> | ||
| Returns true if | | Returns true if the window is visible (includes fade out time on dialogs) | ||
| | | | ||
|- | |- | ||
| Line 1,195: | Line 1,399: | ||
| Returns true if the window with id or title ?window? is being moved from. [[Window IDs| See here for a list of windows]]. Only valid while windows are changing. | | Returns true if the window with id or title ?window? is being moved from. [[Window IDs| See here for a list of windows]]. Only valid while windows are changing. | ||
| | | | ||
|} | |} | ||
<section end="main content" /> | <section end="main content" /> | ||
Latest revision as of 13:57, 22 June 2026
Skins can use boolean conditions with the <visible> tag or with condition attributes. Scripts can read boolean conditions with xbmc.getCondVisibility(condition).
Global
| Labels | Description |
|---|---|
false
|
Returns
|
no
|
Returns
|
true
|
Returns
|
yes
|
Returns
|
Addon
| Labels | Description | Version |
|---|---|---|
Addon.SettingBool(addon_id,setting_id)
|
Returns
Parameters
Note |
v20 |
Container
| Labels | Description | Version |
|---|---|---|
Container(id).Column(column_number)
|
Returns
Parameters
Note |
|
Container(id).HasFocus(item_number)
|
Returns
Note |
|
Container(id).HasNext
|
Returns
Note |
|
Container(id).HasParent
|
Returns
Note |
|
Container(id).HasPrevious
|
Returns
Note |
|
Container(id).IsUpdating
|
Returns
Note |
|
Container(id).OnNext
|
Returns
Note |
|
Container(id).OnPrevious
|
Returns
Note |
|
Container(id).OnScrollNext
|
Returns
Note |
|
Container(id).OnScrollPrevious
|
Returns
Note |
|
Container(id).Position(position_number)
|
Returns
Parameters
Note |
|
Container(id).Row(row_number)
|
Returns
Parameters
Note |
|
Container(id).Scrolling
|
Returns
Note |
|
Container(id).SubItem
|
Returns
Note |
|
Container.CanFilter
|
Returns
|
|
Container.CanFilterAdvanced
|
Returns
|
|
Container.Content(parameter)
|
Returns
Note |
|
Container.Filtered
|
Returns
|
|
Container.HasFiles
|
Returns
|
|
Container.HasFolders
|
Returns
|
|
Container.HasThumb
|
Returns
|
|
Container.IsStacked
|
Returns
|
|
Container.SortDirection(ascending)
|
Returns
|
|
Container.SortDirection(descending)
|
Returns
|
|
Container.Sortmethod(sortid)
|
Returns
|
Control
| Labels | Description | Version |
|---|---|---|
Control.HasFocus(id)
|
Returns
Parameters
|
|
Control.IsEnabled(id)
|
Returns
Parameters
|
|
Control.IsVisible(id)
|
Returns
Parameters
|
|
ControlGroup(group).HasFocus(id)
|
Returns
Parameters
Note |
Integer
| Labels | Description | Version |
|---|---|---|
Integer.IsEqual(info,number)
|
Returns true if the value of the infolabel is equal to the supplied number. Example: Integer.IsEqual(ListItem.Year,2000) |
v17 |
Integer.IsEven(info)
|
Returns true if the value of the infolabel is even. Example: Integer.IsEven(ListItem.CurrentItem) |
v19 |
Integer.IsGreater(info,number)
|
Returns true if the value of the infolabel is greater than to the supplied number. Example: Integer.IsGreater(ListItem.Year,2000) |
v17 |
Integer.IsGreaterOrEqual(info,number)
|
Returns true if the value of the infolabel is greater or equal to the supplied number. Example: Integer.IsGreaterOrEqual(ListItem.Year,2000) |
v17 |
Integer.IsLess(info,number)
|
Returns true if the value of the infolabel is less than the supplied number. Example: Integer.IsLess(ListItem.Year,2000) |
v17 |
Integer.IsLessOrEqual(info,number)
|
Returns true if the value of the infolabel is less or equal to the supplied number. Example: Integer.IsLessOrEqual(ListItem.Year,2000) |
v17 |
Integer.IsOdd(info)
|
Returns true if the value of the infolabel is odd. Example: Integer.IsOdd(ListItem.CurrentItem) |
v19 |
Library
| Labels | Description | Version |
|---|---|---|
Library.HasContent(Role,Composer)
|
Tag can be Composer, Conductor, Orchestra, Lyricist, Remixer, Arranger, Engineer, Producer, DJMixer or Mixer. Returns true if there are any artists with that role in the library | v17 |
Library.HasContent(string)
|
Returns true if the Kodi libraries have the content from string. Valid Strings are (Video, Music, Movies, TVShows, MusicVideos, MovieSets, BoxSets) | |
Library.HasNode(path)
|
Returns True if the specified node is available (example: Library.HasNode(library://video/movies/titles.xml)) | v19 |
Library.IsScanning
|
Returns
|
|
Library.IsScanningMusic
|
Returns true if the music library is being updated | |
Library.IsScanningVideo
|
Returns true if the video library is being updated |
ListItem
| Labels | Description | Version |
|---|---|---|
ListItem.HasArchive
|
Returns True when the selected channel has a server-side back buffer (PVR) | v19 |
ListItem.HasEpg
|
Returns true when the selected programme has epg info (PVR) | |
ListItem.HasRecording
|
Returns
|
|
ListItem.HasReminder
|
Returns True if the item has a reminder set (PVR) | v19 |
ListItem.HasReminderRule
|
Returns True if the item was scheduled by a reminder timer rule (PVR) | v19 |
ListItem.HasTimer
|
Returns true when a recording timer has been set for the selected programme (PVR) | |
ListItem.HasTimerSchedule
|
Whether the item is part of a repeating timer schedule (PVR). | v16 |
ListItem.HasVideoExtras
|
Returns true if the ListItem has video extras | |
ListItem.HasVideoVersions
|
Returns true if the ListItem has video versions | |
ListItem.InProgress
|
Returns
|
|
ListItem.IsAutoUpdateable
|
Returns True if this add-on can be updated automatically | v19 |
ListItem.IsBoxset
|
Returns True if the item is part of a boxset album | v19 |
ListItem.IsCollection
|
Returns true when the current ListItem is a movie set | |
ListItem.IsEncrypted
|
Returns true when the selected programme is encrypted (PVR) | |
ListItem.IsFinale
|
Returns true if the item is a finale (for example, a season finale showing on Live TV) | v19 |
ListItem.IsFolder
|
Returns whether the current ListItem is a folder | |
ListItem.IsLive
|
Returns true if the item is live (for example, a Live TV sports event) | v19 |
ListItem.IsNew
|
Returns true if the item is a premiere (for example, a Live TV show that will be first aired) (PVR) | v19 |
ListItem.IsParentFolder
|
Returns true is the slected item is the 'up' item | v17 |
ListItem.IsPlayable
|
Returns True when the selected programme can be played (PVR) | v19 |
ListItem.IsPlaying
|
Returns whether the current ListItem.* info labels and images are currently Playing media | |
ListItem.IsPremiere
|
Returns true if the item is a premiere (for example, a Movie first showing or season first on Live TV) | v19 |
ListItem.IsRecording
|
Returns true when the selected programme is being recorded (PVR) | |
ListItem.IsResumable
|
Returns true when the current ListItem has been partially played | |
ListItem.IsSelected
|
Returns whether the current ListItem is selected (f.e. currently playing in playlist window) | |
ListItem.IsStereoscopic
|
Returns true when the selected video is a 3D (stereoscopic) video | |
ListItem.IsVideoExtra
|
Returns
|
|
ListItem.Property(Addon.HasUpdate)
|
Returns true when there's an update available for the selected addon. | |
ListItem.Property(Addon.IsBinary)
|
Returns true for binary addons | v19 |
ListItem.Property(Addon.IsEnabled)
|
Returns true when the selected addon is enabled (for use in the addon info dialog only). | |
ListItem.Property(Addon.IsFromOfficialRepo)
|
Returns true if the addon is from an official repository | v19 |
ListItem.Property(Addon.IsInstalled)
|
Returns true when the selected addon is installed (for use in the addon info dialog only). | |
ListItem.Property(Addon.IsUpdate)
|
Returns True if this add-on is a valid update of an installed outdated add-on | v19 |
ListItem.Property(Addon.Orphaned)
|
Returns true if the slected addon is orphaned (not needed anymore by any other addon) | v17 |
ListItem.Property(DateLabel)
|
Can be used in the rulerlayout of the epggrid control. Will return true if the item is a date label, returns false if the item is a time label. | |
ListItem.Property(IsSpecial)
|
Returns whether the current Season/Episode is a Special | |
ListItem.Property(Stream.Is3D)
|
Returns true if the video stream is a 3D (stereoscopic) video, for use in dialogselect.xml | v22 |
ListItem.Property(Stream.IsDefault)
|
Returns true if the audio/video/subtitle stream is default, for use in dialogselect.xml | v22 |
ListItem.Property(Stream.IsExternal)
|
Returns true if the subtitle stream is external, for use in dialogselect.xml | v22 |
ListItem.Property(Stream.IsForced)
|
Returns true if the audio/subtitle stream is forced, for use in dialogselect.xml | v22 |
ListItem.Property(Stream.IsHearingImpaired)
|
Returns true if the subtitle stream is for the hearing impaired (aka SDH-Subtitles for the Deaf or Hard-of-Hearing/CC-Closed Captions), for use in dialogselect.xml | v22 |
ListItem.Property(Stream.IsOriginal)
|
Returns true if the audio/subtitle stream is in the original language, for use in dialogselect.xml | v22 |
ListItem.Property(Stream.IsVisualImpaired)
|
Returns true if the audio stream is for the visually impaired (aka AD-Audio Description), for use in dialogselect.xml | v22 |
ListItem.TimerHasConflict
|
Whether the item has a timer and it won't be recorded because of a conflict (PVR). | v17 |
ListItem.TimerHasError
|
Whether the item has a timer and it won't be recorded because of an error (PVR). | v17 |
ListItem.TimerIsActive
|
Whether the item has a timer that will be recorded, i.e. the timer is enabled (PVR). | v17 |
ListItem.TotalDiscs
|
Returns
|
Network
| InfoLabels | Description | Version |
|---|---|---|
Network.IsDHCP
|
Returns
Note |
Player
| Labels | Description | Version |
|---|---|---|
Player.Caching
|
Returns true if the player is current re-caching data (internet based video playback). | |
Player.ChannelPreviewActive
|
Returns true if PVR channel preview is active (used channel tag different from played tag) | |
Player.DisplayAfterSeek
|
Returns true for the first 2.5 seconds after a seek. | |
Player.Forwarding
|
Returns true if the player is fast forwarding. | |
Player.Forwarding16x
|
Returns true if the player is fast forwarding at 16x. | |
Player.Forwarding2x
|
Returns true if the player is fast forwarding at 2x. | |
Player.Forwarding32x
|
Returns true if the player is fast forwarding at 32x. | |
Player.Forwarding4x
|
Returns true if the player is fast forwarding at 4x. | |
Player.Forwarding8x
|
Returns true if the player is fast forwarding at 8x. | |
Player.FrameAdvance
|
Returns true if player is in frame advance mode | v18 |
Player.HasAudio
|
Returns true if the player has an audio file. | |
Player.HasBookmarks
|
Returns
|
|
Player.HasDuration
|
Returns true if Media isn't a true stream | |
Player.HasGame
|
Returns true if the player is playing a game | v18 |
Player.HasMedia
|
Returns true if the player has an audio or video file. | |
Player.HasPerformedSeek(interval)
|
Returns
Parameters
|
|
Player.HasPrograms
|
Returns
Note |
|
Player.HasResolutions
|
Returns true when multiple resolutions are available | v18 |
Player.HasSceneMarkers
|
Returns
|
|
Player.HasVideo
|
Returns true if the player has a video file. | |
Player.IsExternal
|
Returns
|
|
Player.IsInternetStream
|
Returns true if the player is playing an internet stream. | |
Player.IsLive
|
Returns if the inputstream of the player is a live stream (a.k.a. real time stream). | v22 |
Player.IsRemote
|
Returns
|
|
Player.IsTempo
|
Returns true if the current playbackspeed is not equal to 1 | v17 |
Player.Muted
|
Returns true if the volume is muted. | |
Player.Passthrough
|
Returns true if the player is using audio passthrough. | |
Player.Paused
|
Returns true if the player is paused. | |
Player.PauseEnabled
|
Returns true if the currently playing stream can be paused. | |
Player.Playing
|
Returns true if the player is currently playing (ie not ffwding, rewinding or paused.) | |
Player.Process(videohwdecoder)
|
Returns true if the currently playing video is decoded in hardware | v17 |
Player.Rewinding
|
Returns true if the player is rewinding. | |
Player.Rewinding16x
|
Returns true if the player is rewinding at 16x. | |
Player.Rewinding2x
|
Returns true if the player is rewinding at 2x. | |
Player.Rewinding32x
|
Returns true if the player is rewinding at 32x. | |
Player.Rewinding4x
|
Returns true if the player is rewinding at 4x. | |
Player.Rewinding8x
|
Returns true if the player is rewinding at 8x. | |
Player.SeekEnabled
|
Returns true if player can seek | |
Player.Seeking
|
Returns true if a seek is in progress | |
Player.ShowInfo
|
Returns true if the user has requested the song info to show (occurs in visualisation fullscreen and slideshow) | |
Player.ShowTime
|
Returns true if the user has requested the time to show (occurs in video fullscreen) | |
Player.TempoEnabled
|
Returns true if the current player supports changing the playback speed | v17 |
MusicPlayer
| Labels | Description | Version |
|---|---|---|
MusicPlayer.Exists(relative,position)
|
Returns
Parameters
Note |
|
MusicPlayer.HasNext
|
Returns true if the music player has a next song queued in the Playlist. | |
MusicPlayer.HasPrevious
|
Returns true if the music player has a a Previous Song in the Playlist . | |
MusicPlayer.Offset(number).Exists
|
Returns true if the music players playlist has a song queued in position (number). | |
MusicPlayer.Content(parameter)
|
Returns true if the current audio you are playing matches the specified content. The following values are accepted: files, livetv | |
MusicPartyMode.Enabled
|
Returns true if Party Mode is enabled | |
MusicPlayer.IsMultiDisc
|
Returns true if the current album consists of two or more discs | v19 |
MusicPlayer.PlaylistPlaying
|
Returns
|
RetroPlayer
| Labels | Description | Version |
|---|---|---|
RetroPlayer.DiscEjected
|
Returns
|
|
RetroPlayer.EmptyTray
|
Returns
|
|
RetroPlayer.SupportsEject
|
Returns
|
VideoPlayer
| Labels | Description | Version | |
|---|---|---|---|
VideoPlayer.CanResumeLiveTV
|
Returns
|
||
VideoPlayer.HasVideoVersions
|
Returns true if the currently playing video has versions. | v21 | |
VideoPlayer.UsingOverlays
|
Returns true if the video player is using the hardware overlays render method. Useful, as with hardware overlays you have no alpha blending to the video image, so shadows, etc. need redoing, or disabling. | ||
VideoPlayer.IsFullscreen
|
Returns true if the video player is in fullscreen mode. | ||
VideoPlayer.HasMenu
|
Returns true if the video player has a menu (ie is playing a DVD) | ||
VideoPlayer.HasInfo
|
Returns true if the current playing video has information from the library or from a plugin (e.g. director, plot, etc). | ||
VideoPlayer.Content(parameter)
|
Returns true if the current Video you are playing is contained in corresponding Video Library sections. The following values are accepted : files, movies, episodes, musicvideos, livetv | ||
VideoPlayer.HasSubtitles
|
Returns true if there are subtitles available for video. (available for version 11.0 and above) | ||
VideoPlayer.IsStereoscopic
|
Returns true when the currently playing video is a 3D (stereoscopic) video | ||
VideoPlayer.SubtitlesEnabled
|
Returns true if subtitles are turned on for video. (available for version 11.0 and above) | ||
VideoPlayer.HasEpg
|
Returns true when epg information is available for the currently playing programme (PVR). | ||
VideoPlayer.HasTeletext
|
Returns true when teletext is available. |
PlayList
| Labels | Description | Version |
|---|---|---|
Playlist.IsRandom
|
Returns true if the player is in random mode. | |
Playlist.IsRepeat
|
Returns true if the player is in repeat all mode. | |
Playlist.IsRepeatOne
|
Returns true if the player is in repeat one mode. |
PVR
| Labels | Description | Version | |
|---|---|---|---|
Pvr.ActStreamIsEncrypted
|
Returns true if the stream is encrypted | ||
Pvr.CanRecordPlayingChannel
|
Returns true if the player can record the current internet stream. | v18 | |
Pvr.HasNonRecordingRadioTimer
|
Returns true if there are radio timers present who currently not do recording | v17 | |
Pvr.HasNonRecordingTimer
|
Returns true when a non recording timer is active. | ||
Pvr.HasNonRecordingTVTimer
|
Returns true if there are tv timers present who currently not do recording | v17 | |
Pvr.HasRadioChannels
|
Returns true if there are radio channels available | ||
Pvr.HasRadioTimer
|
Returns true if at least one radio timer is active. | v17 | |
Pvr.HasTimer
|
Returns true when a recording timer is active. | ||
Pvr.HasTVChannels
|
Returns true if there are tv channels available | ||
Pvr.HasTVTimer
|
Returns true if at least one tv timer is active. | v17 | |
Pvr.IsPlayingActiveRecording
|
Returns true when Kodi is currently playing a recording that is in progress. | v19 | |
PVR.IsPlayingEpgTag
|
Returns
|
||
Pvr.IsPlayingRadio
|
Returns true when live radio is being listened to. | ||
Pvr.IsPlayingRecording
|
Returns true when a recording is being watched. | ||
Pvr.IsPlayingTv
|
Returns true when live tv is being watched. | ||
Pvr.IsRecording
|
Returns true when the system is recording a tv programme. | ||
Pvr.IsRecordingPlayingChannel
|
Returns true if the player is recording the current internet stream. | v18 | |
Pvr.IsRecordingRadio
|
Returns true when the system is recording a radio programme. | v17 | |
Pvr.IsRecordingTV
|
Returns true when the system is recording a tv programme. | v17 | |
Pvr.IsTimeShift
|
Returns true when the playback is timeshifted. | ||
PVR.NextTimer
|
Returns
|
||
Pvr.RadioNextRecordingChannelIcon
|
Icon of the next recording radio channel | v17 |
RDS
| Labels | Description | Version |
|---|---|---|
RDS.HasHotline
|
Returns true if a hotline phone number is present (Only be available on RadiotextPlus) | |
RDS.HasRadioText
|
Returns true if RDS contains also Radiotext | |
RDS.HasRadioTextPlus
|
Returns true if RDS with Radiotext contains also the plus information | |
RDS.HasRds
|
Returns true if RDS is present | |
RDS.HasStudio
|
Returns true if a studio name is present (Only be available on RadiotextPlus) |
Skin
| Labels | Description | Version |
|---|---|---|
Skin.HasSetting(setting)
|
Returns the state of the skin-specified setting ?setting?. You can toggle a setting from a button by using <onclick>Skin.ToggleSetting(setting)</onclick>. | |
Skin.HasTheme(theme)
|
Returns true if the user has selected the theme with name ?theme?. | |
Skin.String(string)
|
Returns whether the skin string (set via Skin.SetString, Skin.SetPath, or Skin.SetImage) is non-empty. | |
Skin.String(string1,string2)
|
Same as String.IsEqual(Skin.String(string1),string2). Returns true if Skin.String(string1) equals string2. | |
Skin.TimerIsRunning(timer)
|
Returns
Parameters
|
SlideShow
| Labels | Description | Version |
|---|---|---|
Slideshow.IsActive
|
Returns true if the picture slideshow is running | |
Slideshow.IsPaused
|
Returns true if the picture slideshow is paused | |
Slideshow.IsRandom
|
Returns true if the picture slideshow is in random mode | |
Slideshow.IsVideo
|
Returns true if the picture slideshow is playing a video |
String
| Labels | Description | Version |
|---|---|---|
String.Contains(info,substring)
|
Returns true if the info contains the given substring. Example of info: ListItem.Title, ListItem.Genre. Please note that string can also be a $LOCALIZE[] or info label (without $INFO prefix). Also note that in a panelview or similar this only works on the focused item. |
v17 |
String.EndsWith(info,substring)
|
Returns true if the info ends with the given substring. Example of info: ListItem.Title, ListItem.Genre. Please note that string can also be a $LOCALIZE[] or info label (without $INFO prefix). Also note that in a panelview or similar this only works on the focused item. |
v17 |
String.IsEmpty(info)
|
Returns true if the info is empty. Example of info: ListItem.Title, ListItem.Genre. Please note that string can also be a $LOCALIZE[]. Also note that in a panelview or similar this only works on the focused item. |
v17 |
String.IsEqual(info,string)
|
Returns true if the info is equal to the given string. Example of info: ListItem.Title, ListItem.Genre. Please note that string can also be a $LOCALIZE[] or info label (without $INFO prefix). Also note that in a panelview or similar this only works on the focused item. |
v17 |
String.StartsWith(info,substring)
|
Returns true if the info starts with the given substring. Example of info: ListItem.Title, ListItem.Genre. Please note that string can also be a $LOCALIZE[] or info label (without $INFO prefix). Also note that in a panelview or similar this only works on the focused item. |
v17 |
System
| Labels | Description | Version |
|---|---|---|
System.AddonIsEnabled(id)
|
Returns true if the specified addon is enabled on the system | v19 |
System.AlarmLessOrEqual(alarmname,seconds)
|
Returns true if the alarm with ?alarmname? has less or equal to ?seconds? left. Standard use would be system.alarmlessorequal(shutdowntimer,119), which would return true when the shutdowntimer has less then 2 minutes left. | |
System.CanHibernate
|
Returns true if Kodi can hibernate the system. | |
System.CanPowerDown
|
Returns true if Kodi can powerdown the system. | |
System.CanReboot
|
Returns true if Kodi can reboot the system. | |
System.CanSuspend
|
Returns true if Kodi can suspend the system. | |
System.Date(startDate,endDate)
|
Returns true if the current system date is >= startDate and < endDate. endDate is optional. Date must be specified in the format MM-DD. | |
System.DPMSActive
|
Returns
|
|
System.DVDReady
|
Returns
|
|
System.GetBool(boolean)
|
Returns the value of any standard system boolean setting. Will not work with settings in advancedsettings.xml | |
System.HasActiveModalDialog
|
Returns true true when a modal dialog is active, disregarding any animations (Leia (v18) and newer versions) | v18 |
System.HasAddon(id)
|
Returns true if the specified addon is installed on the system. | |
System.HasAlarm(alarm)
|
Returns true if the system has the ?alarm? alarm set. | |
System.HasCMS
|
Returns true if colour management is supported in Kodi. | v17 |
System.HasCoreId(id)
|
Returns
Parameters
|
|
System.HasHiddenInput
|
Return true when to osd keyboard/numeric dialog requests a password/pincode. | |
System.HasLocks
|
Returns true if the profile has lock preferences configured | |
System.HasLoginScreen
|
Returns true if the profile login screen is enabled | |
System.HasMediaAudioCD
|
Returns true if there is an audio CD in the optical drive. False if no drive available, empty drive or other medium. | v18 |
System.HasMediaBlurayPlaylist
|
Returns
|
|
System.HasMediadvd
|
Returns true if there is a CD or DVD in the DVD-ROM drive. | |
System.HasNetwork
|
Returns true if the ethernet cable is plugged in. | |
System.HasPVR
|
Returns
Note |
|
System.HasPVRAddon
|
Returns true if at least one PVR addon is installed on the system. | |
System.HasShutdown
|
Returns true when shutdown on idle is enabled. | |
System.HasVisibleModalDialog
|
Returns true if a modal dialog is visible, e.g. when the animations are finished (Leia (v18) and newer versions) | v18 |
System.IdleShutdownInhibited
|
Returns
|
|
System.IdleTime(time)
|
Returns true if Kodi has had no input for ?time? amount of seconds. | |
System.InternetState
|
Returns true if the system is connected to the internet, returns false in case no internet connection is available. | |
System.IsFullscreen
|
Returns true if Kodi is running fullscreen. | |
System.IsInhibit
|
Returns true when shutdown on idle is disabled. | |
System.IsLoggedOn
|
Returns true if a user is currently logged on under a profile | |
System.IsMaster
|
Returns true if the profile has entered the master mode | |
System.IsScreensaverInhibited
|
Returns
|
|
System.IsStandalone
|
Returns true if Kodi is running in standalone mode. | |
System.LoggedOn
|
Returns
|
|
System.Platform.Android
|
Returns true if Kodi is running on an android device. | |
System.Platform.Darwin
|
Returns true if Kodi is running on an OSX or IOS system. | |
System.Platform.IOS
|
Returns true if Kodi is running on an IOS device. | |
System.Platform.Linux
|
Returns true if Kodi is running on a linux/unix based computer. | |
System.Platform.OSX
|
Returns true if Kodi is running on an OSX based computer. | |
System.Platform.TVOS
|
Returns
|
|
System.Platform.UWP
|
Returns true if Kodi is running on Universal Windows Platform (UWP). | v18 |
System.Platform.WebOS
|
Returns
|
|
System.Platform.Windows
|
Returns true if Kodi is running on a windows based computer. | |
System.ScreenSaverActive
|
Returns true if ScreenSaver is active. | |
System.Setting(hidewatched)
|
Returns true if 'hide watched items' is selected. | |
System.ShowExitButton
|
Returns
|
|
System.SupportsCPUUsage
|
Return True if the system provides CPU info | v19 |
System.Time(startTime,endTime)
|
Returns true if the current system time is >= startTime and < endTime. endTime is optional. Time must be specified in the format HH:mm, using a 24 hour clock. | |
System.TrayOpen
|
Returns
|
Visualisation
| Labels | Description | Version |
|---|---|---|
Visualisation.Enabled
|
Returns true if any visualisation has been set in settings (so not None). | |
Visualisation.HasPresets
|
Returns true if the visualisation has built in presets. | |
Visualisation.Locked
|
Returns true if the current visualisation preset is locked (e.g. in Milkdrop.) |
Weather
| Labels | Description | Version |
|---|---|---|
Weather.IsFetched
|
Returns true if the weather data has been downloaded. | |
Weather.IsUpdating
|
Returns
|
Window
| Labels | Description | Version |
|---|---|---|
Window.Is(name)
|
Useful in xml files that are shared between multiple windows/dialogs. Will return true if the window with the given name is visible | v17 |
Window.IsActive(window)
|
Returns true if the window with id or title ?window? is active (excludes fade out time on dialogs) See here for a list of windows | |
Window.IsDialogTopmost(dialog)
|
Returns
Parameters
Note |
|
Window.IsMedia
|
Returns true if this window is a media window (programs, music, video, scripts, pictures) | |
Window.IsModalDialogTopmost(dialog)
|
Returns
Note |
|
Window.IsTopMost(window)
|
Returns true if the window with id or title ?window? is on top of the window stack (excludes fade out time on dialogs) See here for a list of windows | |
Window.IsVisible(window)
|
Returns true if the window is visible (includes fade out time on dialogs) | |
Window.Next(window)
|
Returns true if the window with id or title ?window? is being moved to. See here for a list of windows. Only valid while windows are changing. | |
Window.Previous(window)
|
Returns true if the window with id or title ?window? is being moved from. See here for a list of windows. Only valid while windows are changing. |
See also
Development:
| Return to top |
|---|