ooodev.adapter.awt.combo_box_partial module

class ooodev.adapter.awt.combo_box_partial.ComboBoxPartial(component, interface=com.sun.star.awt.XComboBox)[source]

Bases: object

Partial class for XComboBox.

Parameters:
  • component (XComboBox) –

  • interface (UnoInterface | None) –

__init__(component, interface=com.sun.star.awt.XComboBox)[source]

Constructor

Parameters:
  • component (XComboBox) – UNO Component that implements com.sun.star.awt.XComboBox interface.

  • interface (UnoInterface, optional) – The interface to be validated. Defaults to XComboBox.

Return type:

None

add_action_listener(listener)[source]

registers a listener for action events.

Return type:

None

Parameters:

listener (com.sun.star.awt.XActionListener) –

add_item(item, pos)[source]

Adds an item at the specified position.

Return type:

None

Parameters:
  • item (str) –

  • pos (int) –

add_item_listener(listener)[source]

Registers a listener for item events.

Return type:

None

Parameters:

listener (com.sun.star.awt.XItemListener) –

add_items(pos, *items)[source]

Adds multiple items at the specified position.

Return type:

None

Parameters:
  • pos (int) –

  • items (str) –

get_drop_down_line_count()[source]

Returns the number of visible lines in the drop down mode.

Return type:

int

get_item(pos)[source]

Gets the item at the specified position.

Return type:

str

Parameters:

pos (int) –

get_item_count()[source]

Gets the number of items in the combo box.

Return type:

int

get_items()[source]

Gets all items of the combo box.

Return type:

Tuple[str, ...]

remove_action_listener(listener)[source]

Un-registers a listener for action events.

Return type:

None

Parameters:

listener (com.sun.star.awt.XActionListener) –

remove_item_listener(listener)[source]

Un-registers a listener for item events.

Return type:

None

Parameters:

listener (com.sun.star.awt.XItemListener) –

remove_items(pos, count)[source]

Removes a number of items at the specified position.

Return type:

None

Parameters:
  • pos (int) –

  • count (int) –

set_drop_down_line_count(lines)[source]

Sets the number of visible lines for drop down mode.

Return type:

None

Parameters:

lines (int) –