.. 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



.. _wx.richtext.TextAttrSize:

==========================================================================================================================================
|phoenix_title|  **wx.richtext.TextAttrSize**
==========================================================================================================================================

A class for representing width and height.          







         



.. seealso:: :ref:`wx.richtext.RichTextAttr`, :ref:`wx.richtext.RichTextCtrl`, :ref:`wx.richtext.TextAttrDimension`    







|

|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>TextAttrSize</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.richtext.TextAttrSize_inheritance.png" alt="Inheritance diagram of TextAttrSize" 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.richtext.TextAttrSize.html" title="wx.richtext.TextAttrSize" alt="" coords="5,5,183,35"/> </map> 
   </p>
   </div>

|


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

================================================================================ ================================================================================
:meth:`~wx.richtext.TextAttrSize.__init__`                                       Default constructor.
:meth:`~wx.richtext.TextAttrSize.Apply`                                          Apply to this object, but not if the same as `compareWith`.
:meth:`~wx.richtext.TextAttrSize.CollectCommonAttributes`                        Collects the attributes that are common to a range of content, building up a note of which attributes are absent in some objects and which clash in some objects.
:meth:`~wx.richtext.TextAttrSize.EqPartial`                                      Partial equality test.
:meth:`~wx.richtext.TextAttrSize.GetHeight`                                      Gets the height.
:meth:`~wx.richtext.TextAttrSize.GetWidth`                                       Returns the width.
:meth:`~wx.richtext.TextAttrSize.IsValid`                                        Is the size valid?
:meth:`~wx.richtext.TextAttrSize.RemoveStyle`                                    Removes the specified attributes from this object.
:meth:`~wx.richtext.TextAttrSize.Reset`                                          Resets the width and height dimensions.
:meth:`~wx.richtext.TextAttrSize.SetHeight`                                      Sets the height.
:meth:`~wx.richtext.TextAttrSize.SetWidth`                                       Sets the width.
:meth:`~wx.richtext.TextAttrSize.__bool__`                                       
:meth:`~wx.richtext.TextAttrSize.__nonzero__`                                    
:meth:`~wx.richtext.TextAttrSize.__eq__`                                         Equality operator.
================================================================================ ================================================================================


|


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

================================================================================ ================================================================================
:attr:`~wx.richtext.TextAttrSize.Height`                                         See :meth:`~wx.richtext.TextAttrSize.GetHeight` and :meth:`~wx.richtext.TextAttrSize.SetHeight`
:attr:`~wx.richtext.TextAttrSize.Width`                                          See :meth:`~wx.richtext.TextAttrSize.GetWidth` and :meth:`~wx.richtext.TextAttrSize.SetWidth`
:attr:`~wx.richtext.TextAttrSize.m_height`                                       A public C++ attribute of type :ref:`~wx.richtext.TextAttrDimension`.
:attr:`~wx.richtext.TextAttrSize.m_width`                                        A public C++ attribute of type :ref:`~wx.richtext.TextAttrDimension`.
================================================================================ ================================================================================


|


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


.. class:: wx.richtext.TextAttrSize(object)

   **Possible constructors**::

       TextAttrSize()
       
   
   A class for representing width and height.



   .. method:: __init__(self)

      Default constructor.                   





   .. method:: Apply(self, dims, compareWith=None)

      Apply to this object, but not if the same as `compareWith`.                  


      :param `dims`: 
      :type `dims`: wx.richtext.TextAttrSize
      :param `compareWith`: 
      :type `compareWith`: wx.richtext.TextAttrSize




      :rtype: `bool`








   .. method:: CollectCommonAttributes(self, attr, clashingAttr, absentAttr)

      Collects the attributes that are common to a range of content, building up a note of which attributes are absent in some objects and which clash in some objects.                  


      :param `attr`: 
      :type `attr`: wx.richtext.TextAttrSize
      :param `clashingAttr`: 
      :type `clashingAttr`: wx.richtext.TextAttrSize
      :param `absentAttr`: 
      :type `absentAttr`: wx.richtext.TextAttrSize







   .. method:: EqPartial(self, size, weakTest=True)

      Partial equality test.                  

      If `weakTest`  is ``True``, attributes of this object do not have to be present if those attributes of `size`  are present. If `weakTest`  is ``False``, the function will fail if an attribute is present in `size`  but not in this object.                  


      :param `size`: 
      :type `size`: wx.richtext.TextAttrSize
      :param `weakTest`: 
      :type `weakTest`: bool




      :rtype: `bool`








   .. method:: GetHeight(self)

      Gets the height.                  

      :rtype: :ref:`wx.richtext.TextAttrDimension`








   .. method:: GetWidth(self)

      Returns the width.                  

      :rtype: :ref:`wx.richtext.TextAttrDimension`








   .. method:: IsValid(self)

      Is the size valid?                  

      :rtype: `bool`








   .. method:: RemoveStyle(self, attr)

      Removes the specified attributes from this object.                  


      :param `attr`: 
      :type `attr`: wx.richtext.TextAttrSize




      :rtype: `bool`








   .. method:: Reset(self)

      Resets the width and height dimensions.                   





   .. method:: SetHeight(self, *args, **kw)

      Sets the height.                   


      |overload| Overloaded Implementations:

      :html:`<hr class="overloadsep" /><br />`

      
      **SetHeight** `(self, value, flags)`
      
      
      
      
      :param `value`: 
      :type `value`: int
      :param `flags`: 
      :type `flags`: wx.richtext.TextAttrDimensionFlags
      
      
      
      
      
      
      :html:`<hr class="overloadsep" /><br />`

      
      **SetHeight** `(self, dim)`
      
      
      
      
      :param `dim`: 
      :type `dim`: wx.richtext.TextAttrDimension
      
      
      
      
      
      
      :html:`<hr class="overloadsep" /><br />`






   .. method:: SetWidth(self, *args, **kw)

      Sets the width.                   


      |overload| Overloaded Implementations:

      :html:`<hr class="overloadsep" /><br />`

      
      **SetWidth** `(self, value, flags)`
      
      
      
      
      :param `value`: 
      :type `value`: int
      :param `flags`: 
      :type `flags`: wx.richtext.TextAttrDimensionFlags
      
      
      
      
      
      
      :html:`<hr class="overloadsep" /><br />`

      
      **SetWidth** `(self, dim)`
      
      
      
      
      :param `dim`: 
      :type `dim`: wx.richtext.TextAttrDimension
      
      
      
      
      
      
      :html:`<hr class="overloadsep" /><br />`






   .. method:: __bool__(self)



      :rtype: `int`








   .. method:: __nonzero__(self)



      :rtype: `int`








   .. method:: __eq__(self)

      Equality operator.                  


      :param `size`: 
      :type `size`: wx.richtext.TextAttrSize







   .. attribute:: Height

      See :meth:`~wx.richtext.TextAttrSize.GetHeight` and :meth:`~wx.richtext.TextAttrSize.SetHeight`


   .. attribute:: Width

      See :meth:`~wx.richtext.TextAttrSize.GetWidth` and :meth:`~wx.richtext.TextAttrSize.SetWidth`


   .. attribute:: m_height

      A public C++ attribute of type :ref:`~wx.richtext.TextAttrDimension`.


   .. attribute:: m_width

      A public C++ attribute of type :ref:`~wx.richtext.TextAttrDimension`.

