GRASS Programmer's Manual  6.5.svn(2012)-r51648
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Defines
prompt.TextCtrlAutoComplete Class Reference

Auto complete text area used by GPromptPopUp. More...

Inheritance diagram for prompt.TextCtrlAutoComplete:

Public Member Functions

def __init__
 Constructor works just like wx.TextCtrl except you can pass in a list of choices.
def GetListCtrl
 Method required by listmix.ColumnSorterMixin.
def SetChoices
 Sets the choices available in the popup wx.ListBox.
def OnClick
def OnCommandSelect
 Command selected from history.
def OnListClick
 Left mouse button pressed.
def OnListDClick
 Mouse button double click.
def OnListColClick
 Left mouse button pressed on column.
def OnListItemSelected
 Item selected.
def OnEnteredText
 Text entered.
def OnKeyDown
 Do some work when the user press on the keys: up and down: move the cursor left and right: move the search.
def OnControlChanged
 Control changed.

Data Fields

 statusbar
 itemDataMap
 dropdown
 dropdownlistbox
 popupsize

Detailed Description

Auto complete text area used by GPromptPopUp.

Definition at line 47 of file prompt.py.


Constructor & Destructor Documentation

def prompt.TextCtrlAutoComplete.__init__ (   self,
  parent,
  statusbar,
  id = wx.ID_ANY,
  choices = [],
  kwargs 
)

Constructor works just like wx.TextCtrl except you can pass in a list of choices.

You can also change the choice list at any time by calling setChoices.

Inspired by http://wiki.wxpython.org/TextCtrlAutoComplete

Definition at line 50 of file prompt.py.


Member Function Documentation

Method required by listmix.ColumnSorterMixin.

Definition at line 250 of file prompt.py.

References prompt.TextCtrlAutoComplete.dropdownlistbox.

def prompt.TextCtrlAutoComplete.OnClick (   self,
  event 
)
Left mouse button pressed

Definition at line 285 of file prompt.py.

References prompt.TextCtrlAutoComplete._listItemVisible(), and prompt.TextCtrlAutoComplete._showDropDown().

def prompt.TextCtrlAutoComplete.OnControlChanged (   self,
  event 
)

Control changed.

Definition at line 461 of file prompt.py.

References prompt.TextCtrlAutoComplete._showDropDown().

def prompt.TextCtrlAutoComplete.OnListClick (   self,
  evt 
)

Left mouse button pressed.

Definition at line 303 of file prompt.py.

def prompt.TextCtrlAutoComplete.OnListColClick (   self,
  evt 
)

Left mouse button pressed on column.

Definition at line 314 of file prompt.py.

References prompt.TextCtrlAutoComplete._ascending, and prompt.TextCtrlAutoComplete._colSearch.

def prompt.TextCtrlAutoComplete.OnListDClick (   self,
  evt 
)

Mouse button double click.

Definition at line 310 of file prompt.py.

References prompt.TextCtrlAutoComplete._setValueFromSelected().

Item selected.

Definition at line 324 of file prompt.py.

References prompt.TextCtrlAutoComplete._setValueFromSelected().

def prompt.TextCtrlAutoComplete.SetChoices (   self,
  choices,
  type = 'module' 
)

Sets the choices available in the popup wx.ListBox.

The items will be sorted case insensitively.

Parameters:
choiceslist of choices
typetype of choices (module, param, flag, raster, vector)

Definition at line 254 of file prompt.py.

References prompt.TextCtrlAutoComplete._choices, prompt.TextCtrlAutoComplete._choiceType, prompt.TextCtrlAutoComplete._colFetch, prompt.TextCtrlAutoComplete._colSearch, prompt.TextCtrlAutoComplete._setListSize(), prompt.TextCtrlAutoComplete._updateDataList(), and utils.ListSortLower().

Referenced by prompt.TextCtrlAutoComplete.OnEnteredText().


Field Documentation

Definition at line 79 of file prompt.py.

Definition at line 57 of file prompt.py.


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