Package kiwi :: Package ui :: Package widgets :: Module combo :: Class ProxyComboBox
[frames | no frames]

Type ProxyComboBox

      object --+    
               |    
      ComboMixin --+
                   |
      object --+   |
               |   |
  PropertyObject --+
                   |
      object --+   |
               |   |
ProxyWidgetMixin --+
                   |
      object --+   |
               |   |
        _GObject --+
                   |
                  ProxyComboBox

Known Subclasses:
ComboBox

Method Summary
  clear(self)
Removes all items from list
  prefill(self, itemdata, sort)
Fills the Combo with listitems corresponding to the itemdata provided.
Must matche the data-type property. read(self)
Get the content of the widget.
  update(self, data)
    Inherited from PropertyObject
  do_get_property(self, pspec)
  do_set_property(self, pspec, value)
  get_attribute_names(self)
  is_default_value(self, attr, value)
    Inherited from ComboMixin
  append_item(self, label, data)
Adds a single item to the Combo.
  get_model_items(self)
  get_model_strings(self)
  get_selected(self)
  get_selected_data(self)
  get_selected_label(self)
  select(self, data)
  select_item_by_data(self, data)
  select_item_by_label(self, label)
  select_item_by_position(self, pos)
  set_mode(self, mode)
    Inherited from ProxyWidgetMixin
  prop_set_data_type(self, data_type)
Set the data type for the widget
  set_data_format(self, format)

Class Variable Summary
tuple allowed_data_types: A list of types which we are allowed to use in this class.

Instance Method Details

clear(self)

Removes all items from list
Overrides:
kiwi.ui.combomixin.ComboMixin.clear (inherited documentation)

prefill(self, itemdata, sort=False)

Fills the Combo with listitems corresponding to the itemdata provided.

Parameters:
  • itemdata is a list of strings or tuples, each item corresponding to a listitem. The simple list format is as follows:
    
    
    >>> [ label0, label1, label2 ]
    If you require a data item to be specified for each item, use a 2-item tuple for each element. The format is as follows:
    
    
    >>> [ ( label0, data0 ), (label1, data1), ... ]
  • Sort is a boolean that specifies if the list is to be sorted by label or not. By default it is not sorted
Overrides:
kiwi.ui.combomixin.ComboMixin.prefill (inherited documentation)

read(self)

Get the content of the widget. The type of the return value
Returns:
None if the user input a invalid value
           (type=Must matche the data-type property.)
Overrides:
kiwi.ui.proxywidget.ProxyWidgetMixin.read (inherited documentation)

Class Variable Details

allowed_data_types

A list of types which we are allowed to use in this class.
Type:
tuple
Value:
(<type 'basestring'>,
 <type 'object'>,
 <type 'int'>,
 <type 'float'>,
 <type 'long'>,
 <class 'decimal.Decimal'>)                                            

Generated by Epydoc 2.1 on Thu Oct 19 03:18:13 2006 http://epydoc.sf.net