Kodi Development  20.0
for Binary and Script based Add-Ons

Inherits Control.

Public Member Functions

 addItem (...)
 

Function: addItem(item)


Add a new item to this list control. More...
 
 addItems (...)
 

Function: addItems(items)


Adds a list of listitems or strings to this list control. More...
 
bool canAcceptMessages (int actionId) override
 
 ControlList (long x, long y, long width, long height, const char *font=NULL, const char *textColor=NULL, const char *buttonTexture=NULL, const char *buttonFocusTexture=NULL, const char *selectedColor=NULL, long _imageWidth=10, long _imageHeight=10, long _itemTextXOffset=CONTROL_TEXT_OFFSET_X, long _itemTextYOffset=CONTROL_TEXT_OFFSET_Y, long _itemHeight=27, long _space=2, long _alignmentY=XBFONT_CENTER_Y)
 
CGUIControl * Create () override
 
 getItemHeight ()
 

Function: getItemHeight()


Returns the control's current item height as an integer. More...
 
 getListItem (...)
 

Function: getListItem(index)


Returns a given ListItem in this List. More...
 
 getSelectedItem ()
 

Function: getSelectedItem()


Returns the selected item as a ListItem object. More...
 
 getSelectedPosition ()
 

Function: getSelectedPosition()


Returns the position of the selected item as an integer. More...
 
 getSpace ()
 

Function: getSpace()


Returns the control's space between items as an integer. More...
 
 getSpinControl ()
 

Function: getSpinControl()


Returns the associated ControlSpin object. More...
 
 removeItem (...)
 

Function: removeItem(index)


Remove an item by index number. More...
 
 reset ()
 

Function: reset()


Clear all ListItems in this control list. More...
 
 selectItem (...)
 

Function: selectItem(item)


Select an item by index number. More...
 
void sendLabelBind (int tail)
 
 setImageDimensions (...)
 

Function: setImageDimensions(imageWidth, imageHeight)


Sets the width/height of items icon or thumbnail. More...
 
 setItemHeight (...)
 

Function: setItemHeight(itemHeight)


Sets the height of items. More...
 
 setPageControlVisible (...)
 

Function: setPageControlVisible(visible)


Sets the spin control's visible/hidden state. More...
 
 setSpace (...)
 

Function: setSpace(space)


Sets the space between items. More...
 
 setStaticContent (...)
 

Function: setStaticContent(items)


Fills a static list with a list of listitems. More...
 
 size ()
 

Function: size()


Returns the total number of items in this list control as an integer. More...
 
- Public Member Functions inherited from Control
 controlDown (...)
 

Function: controlDown(control)


Sets the controls down navigation. More...
 
 controlLeft (...)
 

Function: controlLeft(control)


Sets the controls left navigation. More...
 
 controlRight (...)
 

Function: controlRight(control)


Sets the controls right navigation. More...
 
 controlUp (...)
 

Function: controlUp(control)


Sets the controls up navigation. More...
 
 getHeight ()
 

Function: getHeight()


Returns the control's current height as an integer. More...
 
 getId () inline bool operator
 

Function: getId()


Returns the control's current id as an integer. More...
 
 getWidth ()
 

Function: getWidth()


Returns the control's current width as an integer. More...
 
 getX ()
 

Function: getX()


Returns the control's current X position. More...
 
 getY ()
 

Function: getY()


Returns the control's current Y position. More...
 
 isVisible (...)
 

Function: isVisible()


Get the control's visible/hidden state with respect to the container/window More...
 
 setAnimations (...)
 

Function: setAnimations([(event, attr,)*])


Sets the control's animations. More...
 
 setEnableCondition (...)
 

Function: setEnableCondition(enable)


Sets the control's enabled condition. More...
 
 setEnabled (...)
 

Function: setEnabled(enabled)


Sets the control's enabled/disabled state. More...
 
 setHeight (...)
 

Function: setHeight(height)


Sets the controls height. More...
 
 setNavigation (...)
 

Function: setNavigation(up, down, left, right)


Sets the controls navigation. More...
 
 setPosition (...)
 

Function: setPosition(x, y)


Sets the controls position. More...
 
 setVisible (...)
 

Function: setVisible(visible)


Sets the control's visible/hidden state. More...
 
 setVisibleCondition (...)
 

Function: setVisibleCondition(visible[,allowHiddenFocus])


Sets the control's visible condition. More...
 
 setWidth (...)
 

Function: setWidth(width)


Sets the controls width. More...
 

Public Attributes

uint32_t alignmentY
 
int imageHeight = 0
 
int imageWidth = 0
 
int itemHeight = 0
 
int itemTextOffsetX = 0
 
int itemTextOffsetY = 0
 
AddonClass::Ref< ControlSpinpControlSpin
 
UTILS::COLOR::Color selectedColor
 
int space = 0
 
std::string strFont
 
std::string strTextureButton
 
std::string strTextureButtonFocus
 
UTILS::COLOR::Color textColor
 
std::vector< AddonClass::Ref< ListItem > > vecItems
 
- Public Attributes inherited from Control
int dwHeight = 0
 
int dwPosX = 0
 
int dwPosY = 0
 
int dwWidth = 0
 
int iControlDown = 0
 
int iControlId = 0
 
int iControlLeft = 0
 
int iControlRight = 0
 
int iControlUp = 0
 
int iParentId = 0
 
std::string m_label {}
 
bool m_visible {true}
 
CGUIControl * pGUIControl = nullptr
 

Member Function Documentation

◆ setItemHeight()

setItemHeight (   ...)

Function: setItemHeight(itemHeight)


Sets the height of items.

Parameters
itemHeightinteger - height of items.

Example:

...
cList.setItemHeight(25)
...

The documentation for this class was generated from the following file: