.. wxPython Phoenix documentation

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

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

.. include:: headings.inc

.. currentmodule:: wx.lib.agw.aui.auibook

.. highlight:: python



.. _wx.lib.agw.aui.auibook.CommandNotebookEvent:

==========================================================================================================================================
|phoenix_title|  **wx.lib.agw.aui.auibook.CommandNotebookEvent**
==========================================================================================================================================

A specialized command event class for events sent by :class:`AuiNotebook` . 



|

|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>CommandNotebookEvent</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.agw.aui.auibook.CommandNotebookEvent_inheritance.png" alt="Inheritance diagram of CommandNotebookEvent" usemap="#dummy" class="inheritance"/></center>
   <script type="text/javascript">toggleVisibilityOnLoad(document.getElementById('toggleBlock'))</script>
   <map id="dummy" name="dummy"> <area shape="rect" id="node1" href="wx.lib.agw.aui.auibook.CommandNotebookEvent.html" title="A specialized command event class for events sent by AuiNotebook ." alt="" coords="5,315,355,344"/> <area shape="rect" id="node2" href="wx.PyCommandEvent.html" title="PyCommandEvent can be used as a base class for implementing" alt="" coords="96,237,264,267"/> <area shape="rect" id="node3" href="wx.CommandEvent.html" title="This event class contains information about command events, which originate from a variety of simple controls." alt="" coords="104,160,256,189"/> <area shape="rect" id="node4" href="wx.Event.html" title="An event is a structure holding information about an event passed to a callback or member function." alt="" coords="139,83,221,112"/> <area shape="rect" id="node5" href="wx.Object.html" title="This is the root class of many of the wxWidgets classes." alt="" coords="136,5,224,35"/> </map> 
   </p>
   </div>

|


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

:class:`wx.lib.agw.aui.auibook.AuiNotebookEvent`

|


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

:class:`wx.PyCommandEvent`

|


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

================================================================================ ================================================================================
:meth:`~wx.lib.agw.aui.auibook.CommandNotebookEvent.__init__`                    Default class constructor.
:meth:`~wx.lib.agw.aui.auibook.CommandNotebookEvent.GetDispatched`               Returns whether the event was dispatched (used for automatic :class:`AuiNotebook` ).
:meth:`~wx.lib.agw.aui.auibook.CommandNotebookEvent.GetDragSource`               Returns the drag and drop source.
:meth:`~wx.lib.agw.aui.auibook.CommandNotebookEvent.GetLabel`                    Returns the label-itemtext (for ``EVT_AUINOTEBOOK_BEGIN`` | ``END_LABEL_EDIT`` only).
:meth:`~wx.lib.agw.aui.auibook.CommandNotebookEvent.GetOldSelection`             Returns the page that was selected before the change, or -1 if none was
:meth:`~wx.lib.agw.aui.auibook.CommandNotebookEvent.GetSelection`                Returns the currently selected page, or -1 if none was selected.
:meth:`~wx.lib.agw.aui.auibook.CommandNotebookEvent.IsEditCancelled`             Returns the edit cancel flag (for ``EVT_AUINOTEBOOK_BEGIN`` | ``END_LABEL_EDIT`` only).
:meth:`~wx.lib.agw.aui.auibook.CommandNotebookEvent.SetDispatched`               Sets the event as dispatched (used for automatic :class:`AuiNotebook` ).
:meth:`~wx.lib.agw.aui.auibook.CommandNotebookEvent.SetDragSource`               Sets the drag and drop source.
:meth:`~wx.lib.agw.aui.auibook.CommandNotebookEvent.SetEditCanceled`             Sets the edit cancel flag (for ``EVT_AUINOTEBOOK_BEGIN`` | ``END_LABEL_EDIT`` only).
:meth:`~wx.lib.agw.aui.auibook.CommandNotebookEvent.SetLabel`                    Sets the label. Useful only for ``EVT_AUINOTEBOOK_END_LABEL_EDIT``.
:meth:`~wx.lib.agw.aui.auibook.CommandNotebookEvent.SetOldSelection`             Sets the id of the page selected before the change.
:meth:`~wx.lib.agw.aui.auibook.CommandNotebookEvent.SetSelection`                Sets the selection member variable.
================================================================================ ================================================================================


|


|property_summary| Properties Summary
=====================================

================================================================================ ================================================================================
:attr:`~wx.lib.agw.aui.auibook.CommandNotebookEvent.Page`                        
:attr:`~wx.lib.agw.aui.auibook.CommandNotebookEvent.Selection`                   
================================================================================ ================================================================================


|


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


.. class:: CommandNotebookEvent(wx.PyCommandEvent)

   A specialized command event class for events sent by :class:`AuiNotebook` . 

   .. method:: __init__(self, command_type=None, win_id=0)

      Default class constructor.
      
      :param `command_type`: the event kind or an instance of :class:`PyCommandEvent`.
      :param integer `win_id`: the window identification number.


   .. method:: GetDispatched(self)

      Returns whether the event was dispatched (used for automatic :class:`AuiNotebook` ). 


   .. method:: GetDragSource(self)

      Returns the drag and drop source. 


   .. method:: GetLabel(self)

      Returns the label-itemtext (for ``EVT_AUINOTEBOOK_BEGIN`` | ``END_LABEL_EDIT`` only).


   .. method:: GetOldSelection(self)

      Returns the page that was selected before the change, or -1 if none was
      selected.


   .. method:: GetSelection(self)

      Returns the currently selected page, or -1 if none was selected. 


   .. method:: IsEditCancelled(self)

      Returns the edit cancel flag (for ``EVT_AUINOTEBOOK_BEGIN`` | ``END_LABEL_EDIT`` only).


   .. method:: SetDispatched(self, b)

      Sets the event as dispatched (used for automatic :class:`AuiNotebook` ).
      
      :param `b`: whether the event was dispatched or not.


   .. method:: SetDragSource(self, s)

      Sets the drag and drop source.
      
      :param `s`: the drag source.


   .. method:: SetEditCanceled(self, editCancelled)

      Sets the edit cancel flag (for ``EVT_AUINOTEBOOK_BEGIN`` | ``END_LABEL_EDIT`` only).
      
      :param bool `editCancelled`: whether the editing action has been cancelled or not.


   .. method:: SetLabel(self, label)

      Sets the label. Useful only for ``EVT_AUINOTEBOOK_END_LABEL_EDIT``.
      
      :param string `label`: the new label.


   .. method:: SetOldSelection(self, s)

      Sets the id of the page selected before the change.
      
      :param integer `s`: the old selection.


   .. method:: SetSelection(self, s)

      Sets the selection member variable.
      
      :param integer `s`: the new selection.