.. wxPython Phoenix documentation

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

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

.. include:: headings.inc

.. currentmodule:: wx.lib.mixins.rubberband

.. highlight:: python



.. _wx.lib.mixins.rubberband.RubberBand:

==========================================================================================================================================
|phoenix_title|  **wx.lib.mixins.rubberband.RubberBand**
==========================================================================================================================================

A stretchable border which is drawn on top of an
image to define an area.



|

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

.. raw:: html

   <div class="collabsible-wrapper">
      <input id="collapsible-inheritance" class="collapsible-checkbox" type="checkbox">
      <label for="collapsible-inheritance" tabindex="0" title="Show inheritance diagram" class="collapsible-label">Inheritance diagram for class <strong>RubberBand</strong>:</label>
      <div class="collapsible-content">
         <p class="graphviz">
            <center><img src="_static/images/inheritance/wx.lib.mixins.rubberband.RubberBand_inheritance.svg" alt="Inheritance diagram of RubberBand" usemap="#dummy" class="inheritance invert-in-dark-mode"/></center>
            <map id="dummy" name="dummy"> <area shape="rect" id="node1" href="wx.lib.mixins.rubberband.RubberBand.html" title="A stretchable border which is drawn on top of an" alt="" coords="5,5,306,34"/> </map> 
         </p>
      </div>
   </div>
   <script type="text/javascript" src="_static/inheritancetoggle.js"></script>



|


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

================================================================================ ================================================================================
:meth:`~wx.lib.mixins.rubberband.RubberBand.__init__`                            Initialize self.  See help(type(self)) for accurate signature.
:meth:`~wx.lib.mixins.rubberband.RubberBand.getCurrentExtent`                    Return (x0, y0, x1, y1) or None if
:meth:`~wx.lib.mixins.rubberband.RubberBand.reset`                               Clear the existing rubberband
================================================================================ ================================================================================


|


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

================================================================================ ================================================================================
:attr:`~wx.lib.mixins.rubberband.RubberBand.enabled`                             True if I am responding to mouse events
================================================================================ ================================================================================


|


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


.. class:: RubberBand

   A stretchable border which is drawn on top of an
   image to define an area.

   .. method:: __init__(self, drawingSurface, aspectRatio=None)

      Initialize self.  See help(type(self)) for accurate signature.


   .. method:: getCurrentExtent(self)

      Return (x0, y0, x1, y1) or None if
      no drawing has yet been done.


   .. method:: reset(self, aspectRatio=None)

      Clear the existing rubberband


   .. attribute:: enabled

      True if I am responding to mouse events


