.. wxPython Phoenix documentation

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

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

.. include:: headings.inc

.. currentmodule:: wx.lib.ogl.basic

.. highlight:: python



.. _wx.lib.ogl.basic.ShapeRegion:

==========================================================================================================================================
|phoenix_title|  **wx.lib.ogl.basic.ShapeRegion**
==========================================================================================================================================

The :class:`ShapeRegion` class.



|

|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>ShapeRegion</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.ogl.basic.ShapeRegion_inheritance.png" alt="Inheritance diagram of ShapeRegion" 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.ogl.basic.ShapeRegion.html" title="wx.lib.ogl.basic.ShapeRegion" alt="" coords="5,5,216,35"/> </map> 
   </p>
   </div>

|


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

================================================================================ ================================================================================
:meth:`~wx.lib.ogl.basic.ShapeRegion.__init__`                                   Default class constructor
:meth:`~wx.lib.ogl.basic.ShapeRegion.ClearText`                                  Clear the text.
:meth:`~wx.lib.ogl.basic.ShapeRegion.GetActualColourObject`                      Get the actual colour object from the :class:`wx.ColourDatabase`.
:meth:`~wx.lib.ogl.basic.ShapeRegion.GetActualPen`                               Get actual pen.
:meth:`~wx.lib.ogl.basic.ShapeRegion.GetColour`                                  Get the colour.
:meth:`~wx.lib.ogl.basic.ShapeRegion.GetFont`                                    Get the font.
:meth:`~wx.lib.ogl.basic.ShapeRegion.GetFormatMode`                              Get the format mode.
:meth:`~wx.lib.ogl.basic.ShapeRegion.GetFormattedText`                           Get the formatted text.
:meth:`~wx.lib.ogl.basic.ShapeRegion.GetHeight`                                  Get the height.
:meth:`~wx.lib.ogl.basic.ShapeRegion.GetMinSize`                                 Get the minimum size.
:meth:`~wx.lib.ogl.basic.ShapeRegion.GetName`                                    Get the name.
:meth:`~wx.lib.ogl.basic.ShapeRegion.GetPenColour`                               Get the pen colour
:meth:`~wx.lib.ogl.basic.ShapeRegion.GetPenStyle`                                Get the pen style.
:meth:`~wx.lib.ogl.basic.ShapeRegion.GetPosition`                                Get the position.
:meth:`~wx.lib.ogl.basic.ShapeRegion.GetProportion`                              Get the proportion.
:meth:`~wx.lib.ogl.basic.ShapeRegion.GetSize`                                    Get the size.
:meth:`~wx.lib.ogl.basic.ShapeRegion.GetText`                                    Get the text.
:meth:`~wx.lib.ogl.basic.ShapeRegion.GetWidth`                                   Get the width.
:meth:`~wx.lib.ogl.basic.ShapeRegion.SetColour`                                  Set the colour.
:meth:`~wx.lib.ogl.basic.ShapeRegion.SetFont`                                    Set the font.
:meth:`~wx.lib.ogl.basic.ShapeRegion.SetFormatMode`                              Set the format mode of the region.
:meth:`~wx.lib.ogl.basic.ShapeRegion.SetMinSize`                                 Set the minumum size.
:meth:`~wx.lib.ogl.basic.ShapeRegion.SetName`                                    Set the name.
:meth:`~wx.lib.ogl.basic.ShapeRegion.SetPenColour`                               Set the pen colour.
:meth:`~wx.lib.ogl.basic.ShapeRegion.SetPenStyle`                                Set the pen style.
:meth:`~wx.lib.ogl.basic.ShapeRegion.SetPosition`                                Set the position.
:meth:`~wx.lib.ogl.basic.ShapeRegion.SetProportions`                             Set the proportions.
:meth:`~wx.lib.ogl.basic.ShapeRegion.SetSize`                                    Set the size.
:meth:`~wx.lib.ogl.basic.ShapeRegion.SetText`                                    Set the text.
================================================================================ ================================================================================


|


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


.. class:: ShapeRegion(object)

   The :class:`ShapeRegion` class.

   .. method:: __init__(self, region = None)

      Default class constructor
      
      :param `region`: a parent region or None???


   .. method:: ClearText(self)

      Clear the text.


   .. method:: GetActualColourObject(self)

      Get the actual colour object from the :class:`wx.ColourDatabase`.


   .. method:: GetActualPen(self)

      Get actual pen.
      
      :note: Returns NULL if the pen is invisible
       (different to pen being transparent; indicates that
       region boundary should not be drawn.)
      
       


   .. method:: GetColour(self)

      Get the colour.


   .. method:: GetFont(self)

      Get the font.


   .. method:: GetFormatMode(self)

      Get the format mode.


   .. method:: GetFormattedText(self)

      Get the formatted text.


   .. method:: GetHeight(self)

      Get the height.


   .. method:: GetMinSize(self)

      Get the minimum size.


   .. method:: GetName(self)

      Get the name.


   .. method:: GetPenColour(self)

      Get the pen colour


   .. method:: GetPenStyle(self)

      Get the pen style.


   .. method:: GetPosition(self)

      Get the position.


   .. method:: GetProportion(self)

      Get the proportion.


   .. method:: GetSize(self)

      Get the size.


   .. method:: GetText(self)

      Get the text.


   .. method:: GetWidth(self)

      Get the width.


   .. method:: SetColour(self, col)

      Set the colour.
      
      :param str `col`: a valid colour name,
       see :class:`wx.ColourDatabase`


   .. method:: SetFont(self, f)

      Set the font.
      
      :param `f`: an instance of :class:`wx.Font`


   .. method:: SetFormatMode(self, mode)

      Set the format mode of the region.
      
      :param `mode`: can be a bit list of the following
      
      ============================== ==============================
      Format mode                    Description
      ============================== ==============================
      `FORMAT_NONE`                  No formatting
      `FORMAT_CENTRE_HORIZ`          Horizontal centring
      `FORMAT_CENTRE_VERT`           Vertical centring
      ============================== ==============================


   .. method:: SetMinSize(self, w, h)

      Set the minumum size.
      
      :param `w`: the minimum width
      :Param `h`: the minimum height


   .. method:: SetName(self, s)

      Set the name.
      
      :param str `s`: the name


   .. method:: SetPenColour(self, col)

      Set the pen colour.
      
      :param str `col`: a valid colour name,
       see :class:`wx.ColourDatabase`


   .. method:: SetPenStyle(self, style)

      Set the pen style.
      
      :param `style`: the style, see :class:`wx.Pen`


   .. method:: SetPosition(self, xp, yp)

      Set the position.
      
      :param `xp`: the x position
      :Param `yp`: the y position


   .. method:: SetProportions(self, xp, yp)

      Set the proportions.
      
      :param `xp`: the x region proportion
      :Param `yp`: the y region proportion


   .. method:: SetSize(self, w, h)

      Set the size.
      
      :param `w`: the width
      :Param `h`: the jeight


   .. method:: SetText(self, s)

      Set the text.
      
      :param str `s`: the text


