![]() |
Kodi Documentation 18.0
Kodi is an open source media player and entertainment hub.
|
Code based skin access. More...
Modules | |
Subclass - ControlSpin | |
Used for cycling up/down controls. | |
Subclass - ControlLabel | |
Used to show some lines of text. | |
Subclass - ControlEdit | |
Subclass - ControlList | |
Used for a scrolling lists of items. Replaces the list control. | |
Subclass - ControlFadeLabel | |
Used to show multiple pieces of text in the same position, by fading from one to the other. | |
Subclass - ControlTextBox | |
Used to show a multi-page piece of text. | |
Subclass - ControlImage | |
Used to show an image. | |
Subclass - ControlProgress | |
Used to show the progress of a particular operation. | |
Subclass - ControlButton | |
A standard push button control. | |
Subclass - ControlGroup | |
Used to group controls together.. | |
Subclass - ControlRadioButton | |
For control a radio button (as used for on/off settings). | |
Subclass - ControlSlider | |
Used for a volume slider. | |
Classes | |
class | XBMCAddon::xbmcgui::Control |
Code based skin access.
Offers classes and functions that manipulate the add-on gui controls.
Class: Control()
Code based skin access.
Kodi is noted as having a very flexible and robust framework for its GUI, making theme-skinning and personal customization very accessible. Users can create their own skin (or modify an existing skin) and share it with others.
Kodi includes a new GUI library written from scratch. This library allows you to skin/change everything you see in Kodi, from the images, the sizes and positions of all controls, colours, fonts, and text, through to altering navigation and even adding new functionality. The skin system is quite complex, and this portion of the manual is dedicated to providing in depth information on how it all works, along with tips to make the experience a little more pleasant.
void XBMCAddon::xbmcgui::Control::controlDown | ( | ... | ) |
Set's the controls down navigation.
control | control object - control to navigate to on down. |
TypeError | if one of the supplied arguments is not a control type. |
ReferenceError | if one of the controls is not added to a window. |
Example:
void XBMCAddon::xbmcgui::Control::controlLeft | ( | ... | ) |
Set's the controls left navigation.
control | control object - control to navigate to on left. |
TypeError | if one of the supplied arguments is not a control type. |
ReferenceError | if one of the controls is not added to a window. |
Example:
void XBMCAddon::xbmcgui::Control::controlRight | ( | ... | ) |
Set's the controls right navigation.
control | control object - control to navigate to on right. |
TypeError | if one of the supplied arguments is not a control type. |
ReferenceError | if one of the controls is not added to a window. |
Example:
void XBMCAddon::xbmcgui::Control::controlUp | ( | ... | ) |
Set's the controls up navigation.
control | control object - control to navigate to on up. |
TypeError | if one of the supplied arguments is not a control type. |
ReferenceError | if one of the controls is not added to a window. |
Example:
XBMCAddon::xbmcgui::Control::getHeight | ( | ) |
Returns the control's current height as an integer.
Example:
XBMCAddon::xbmcgui::Control::getId | ( | ) |
Returns the control's current id as an integer.
Example:
XBMCAddon::xbmcgui::Control::getWidth | ( | ) |
Returns the control's current width as an integer.
Example:
XBMCAddon::xbmcgui::Control::getX | ( | ) |
Returns the control's current X position.
Example:
XBMCAddon::xbmcgui::Control::getY | ( | ) |
Returns the control's current Y position.
Example:
bool XBMCAddon::xbmcgui::Control::isVisible | ( | ... | ) |
Get the control's visible/hidden state.
Example:
void XBMCAddon::xbmcgui::Control::setAnimations | ( | ... | ) |
Set's the control's animations.
[(event,attr,)*]: list - A list of tuples consisting of event and attributes pairs.
event | string - The event to animate. |
attr | string - The whole attribute string separated by spaces. |
Example:
void XBMCAddon::xbmcgui::Control::setEnableCondition | ( | ... | ) |
Set's the control's enabled condition.
Allows Kodi to control the enabled status of the control.
enable | string - Enable condition. |
Example:
void XBMCAddon::xbmcgui::Control::setEnabled | ( | ... | ) |
Set's the control's enabled/disabled state.
enabled | bool - True=enabled / False=disabled. |
Example:
void XBMCAddon::xbmcgui::Control::setHeight | ( | ... | ) |
Set's the controls height.
height | integer - height of control. |
Example:
void XBMCAddon::xbmcgui::Control::setNavigation | ( | ... | ) |
Set's the controls navigation.
up | control object - control to navigate to on up. |
down | control object - control to navigate to on down. |
left | control object - control to navigate to on left. |
right | control object - control to navigate to on right. |
TypeError | if one of the supplied arguments is not a control type. |
ReferenceError | if one of the controls is not added to a window. |
Example:
void XBMCAddon::xbmcgui::Control::setPosition | ( | ... | ) |
Set's the controls position.
x | integer - x coordinate of control. |
y | integer - y coordinate of control. |
Example:
void XBMCAddon::xbmcgui::Control::setVisible | ( | ... | ) |
Set's the control's visible/hidden state.
visible | bool - True=visible / False=hidden. |
Example:
void XBMCAddon::xbmcgui::Control::setVisibleCondition | ( | ... | ) |
Set's the control's visible condition.
Allows Kodi to control the visible status of the control.
visible | string - Visible condition |
allowHiddenFocus | [opt] bool - True=gains focus even if hidden |
Example:
void XBMCAddon::xbmcgui::Control::setWidth | ( | ... | ) |
Set's the controls width.
width | integer - width of control. |
Example: