.. wxPython Phoenix documentation

   This file was generated by Phoenix's sphinx generator and associated
   tools, do not edit by hand.

   Copyright: (c) 2011-2017 by Total Control Software
   License:   wxWindows License

.. include:: headings.inc

.. currentmodule:: wx.lib.masked.combobox

.. highlight:: python



.. _wx.lib.masked.combobox.BaseMaskedComboBox:

==========================================================================================================================================
|phoenix_title|  **wx.lib.masked.combobox.BaseMaskedComboBox**
==========================================================================================================================================

Base class for generic masked edit comboboxes; allows auto-complete of values.
It is not meant to be instantiated directly, but rather serves as a base class
for any subsequent refinements.



|

|class_hierarchy| Class Hierarchy
=================================

.. raw:: html

   <div id="toggleBlock" onclick="return toggleVisibility(this)" class="closed" style="cursor:pointer;">
   <img id="toggleBlock-trigger" src="_static/images/closed.png"/>
   Inheritance diagram for class <strong>BaseMaskedComboBox</strong>:
   </div>
   <div id="toggleBlock-summary" style="display:block;"></div>
   <div id="toggleBlock-content" style="display:none;">
   <p class="graphviz">
   <center><img src="_static/images/inheritance/wx.lib.masked.combobox.BaseMaskedComboBox_inheritance.png" alt="Inheritance diagram of BaseMaskedComboBox" usemap="#dummy" class="inheritance"/></center>
   </div>
   <script type="text/javascript">toggleVisibilityOnLoad(document.getElementById('toggleBlock'))</script>
   <map id="dummy" name="dummy"> <area shape="rect" id="node1" href="wx.ItemContainer.html" title="wx.ItemContainer" alt="" coords="469,315,603,344"/> <area shape="rect" id="node11" href="wx.ComboBox.html" title="wx.ComboBox" alt="" coords="328,392,439,421"/> <area shape="rect" id="node2" href="wx.ItemContainerImmutable.html" title="wx.ItemContainerImmutable" alt="" coords="444,237,647,267"/> <area shape="rect" id="node3" href="wx.lib.masked.maskededit.MaskedEditMixin.html" title="wx.lib.masked.maskededit.MaskedEditMixin" alt="" coords="5,392,303,421"/> <area shape="rect" id="node12" href="wx.lib.masked.combobox.BaseMaskedComboBox.html" title="wx.lib.masked.combobox.BaseMaskedComboBox" alt="" coords="101,469,437,499"/> <area shape="rect" id="node4" href="wx.TextEntry.html" title="wx.TextEntry" alt="" coords="215,315,315,344"/> <area shape="rect" id="node5" href="wx.Trackable.html" title="wx.Trackable" alt="" coords="267,5,368,35"/> <area shape="rect" id="node6" href="wx.EvtHandler.html" title="wx.EvtHandler" alt="" coords="319,83,429,112"/> <area shape="rect" id="node10" href="wx.WindowBase.html" title="wx.WindowBase" alt="" coords="314,160,435,189"/> <area shape="rect" id="node7" href="wx.Object.html" title="wx.Object" alt="" coords="392,5,473,35"/> <area shape="rect" id="node8" href="wx.Control.html" title="wx.Control" alt="" coords="340,315,428,344"/> <area shape="rect" id="node9" href="wx.Window.html" title="wx.Window" alt="" coords="330,237,419,267"/> </map> 
   </p>

|


|sub_classes| Known Subclasses
==============================

:class:`wx.lib.masked.combobox.ComboBox`, :class:`wx.lib.masked.combobox.PreMaskedComboBox`

|


|super_classes| Known Superclasses
==================================

:class:`wx.ComboBox`, :class:`wx.lib.masked.maskededit.MaskedEditMixin`

|


|method_summary| Methods Summary
================================

================================================================================ ================================================================================
:meth:`~wx.lib.masked.combobox.BaseMaskedComboBox.__init__`                      Default class constructor.
:meth:`~wx.lib.masked.combobox.BaseMaskedComboBox.Append`                        This base control function override is necessary so the control can keep
:meth:`~wx.lib.masked.combobox.BaseMaskedComboBox.AppendItems`                   :meth:`~lib.masked.combobox.ComboBox.AppendItems` is handled in terms
:meth:`~wx.lib.masked.combobox.BaseMaskedComboBox.Clear`                         This base control function override is necessary so the derived control
:meth:`~wx.lib.masked.combobox.BaseMaskedComboBox.Cut`                           This function redefines the externally accessible :meth:`ComboBox.Cut`
:meth:`~wx.lib.masked.combobox.BaseMaskedComboBox.GetMark`                       
:meth:`~wx.lib.masked.combobox.BaseMaskedComboBox.IsEmpty`                       
:meth:`~wx.lib.masked.combobox.BaseMaskedComboBox.OnWindowDestroy`               
:meth:`~wx.lib.masked.combobox.BaseMaskedComboBox.Paste`                         This function redefines the externally accessible :meth:`ComboBox.Paste`
:meth:`~wx.lib.masked.combobox.BaseMaskedComboBox.Refresh`                       This function redefines the externally accessible :meth:`ComboBox.Refresh`
:meth:`~wx.lib.masked.combobox.BaseMaskedComboBox.SetFont`                       Set the font, then recalculate control size, if appropriate.
:meth:`~wx.lib.masked.combobox.BaseMaskedComboBox.SetSelection`                  Necessary override for bookkeeping on choice selection, to keep current
:meth:`~wx.lib.masked.combobox.BaseMaskedComboBox.SetValue`                      This function redefines the externally accessible :meth:`ComboBox.SetValue`
:meth:`~wx.lib.masked.combobox.BaseMaskedComboBox.Undo`                          This function defines the undo operation for the control.
================================================================================ ================================================================================


|


|api| Class API
===============


.. class:: BaseMaskedComboBox( wx.ComboBox, MaskedEditMixin )

   Base class for generic masked edit comboboxes; allows auto-complete of values.
   It is not meant to be instantiated directly, but rather serves as a base class
   for any subsequent refinements.

   .. method:: __init__( self, parent, id=-1, value = '', pos = wx.DefaultPosition, size = wx.DefaultSize, choices = [], style = wx.CB_DROPDOWN, validator = wx.DefaultValidator, name = "maskedComboBox", setupEventHandling = True, \*\*kwargs)

      Default class constructor.
      
      :param wx.Window `parent`: the window parent. Must not be ``None``;
      :param integer `id`: window identifier. A value of -1 indicates a default value;
      :param string `value`: value to be shown;
      :param `pos`: the control position. A value of (-1, -1) indicates a default position,
       chosen by either the windowing system or wxPython, depending on platform;
      :type `pos`: tuple or :class:`wx.Point`
      :param `size`: the control size. A value of (-1, -1) indicates a default size,
       chosen by either the windowing system or wxPython, depending on platform;
      :param list `choices`: a list of valid choices;
      :param integer `style`: the window style;
      :param wx.Validator `validator`: this is mainly provided for data-transfer, as control does
        its own validation;
      :param string `name`: the window name;
      :param boolean `setupEventHandling`: setup event handling by default.


   .. method:: Append( self, choice, clientData=None )

      This base control function override is necessary so the control can keep
      track of any additions to the list of choices, because :class:`ComboBox`
      doesn't have an accessor for the choice list.  The code here is the same
      as in the SetParameters() mixin function, but is done for the individual
      value as appended, so the list can be built incrementally without speed
      penalty.


   .. method:: AppendItems( self, choices )

      :meth:`~lib.masked.combobox.ComboBox.AppendItems` is handled in terms
      of :meth:`lib.masked.combobox.ComboBox.Append`, to avoid code replication.


   .. method:: Clear( self )

      This base control function override is necessary so the derived control
      can keep track of any additions to the list of choices, because
      :class:`ComboBox`  doesn't have an accessor for the choice list.


   .. method:: Cut(self)

      This function redefines the externally accessible :meth:`ComboBox.Cut`
      to be a smart "erase" of the text in question, so as not to corrupt the
      masked control.
      
      .. note::
      
        This must be done in the class derived from the base wx control.


   .. method:: GetMark(self)


   .. method:: IsEmpty(\*args, \*\*kw)


   .. method:: OnWindowDestroy(self, event)


   .. method:: Paste(self)

      This function redefines the externally accessible :meth:`ComboBox.Paste`
      to be a smart "paste" of the text in question, so as not to corrupt the
      masked control.
      
      .. note::
      
        This must be done in the class derived from the base wx control.


   .. method:: Refresh(self)

      This function redefines the externally accessible :meth:`ComboBox.Refresh`
      to validate the contents of the masked control as it refreshes.
      
      .. note::
      
        This must be done in the class derived from the base wx control.


   .. method:: SetFont(self, \*args, \*\*kwargs)

      Set the font, then recalculate control size, if appropriate.
      
      see :meth:`ComboBox.SetFont` for valid arguments


   .. method:: SetSelection(self, index)

      Necessary override for bookkeeping on choice selection, to keep current
      value current.
      
      :param integer `index`: index to choice item to be set


   .. method:: SetValue(self, value)

      This function redefines the externally accessible :meth:`ComboBox.SetValue`
      to be a smart "paste" of the text in question, so as not to corrupt the
      masked control.
      
      .. note::
      
        This must be done in the class derived from the base wx control.


   .. method:: Undo(self)

      This function defines the undo operation for the control.
      (The default undo is 1-deep.)


