A class representing a rich text dimension, including units and position.
See also
wx.richtext.RichTextAttr, wx.richtext.RichTextCtrl, wx.richtext.TextAttrDimensions
Default constructor. |
|
Apply the dimension, but not those identical to compareWith if present. |
|
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. |
|
Partial equality test. |
|
Gets the dimension flags. |
|
Gets the position flags. |
|
Gets the units of the dimension. |
|
Returns the integer value of the dimension. |
|
Returns the floating-pointing value of the dimension in mm. |
|
Returns |
|
Resets the dimension value and flags. |
|
Sets the dimension flags. |
|
Sets the position flags. |
|
Sets the units of the dimension. |
|
Sets the valid flag. |
|
Sets the integer value of the dimension. |
|
Sets the value of the dimension in mm. |
|
Equality operator. |
See |
|
See |
|
A public C++ attribute of type TextAttrDimensionFlags . |
|
A public C++ attribute of type |
wx.richtext.
TextAttrDimension
(object)¶Possible constructors:
TextAttrDimension()
TextAttrDimension(value, units=TEXT_ATTR_UNITS_TENTHS_MM)
A class representing a rich text dimension, including units and position.
__init__
(self, *args, **kw)¶__init__ (self)
Default constructor.
__init__ (self, value, units=TEXT_ATTR_UNITS_TENTHS_MM)
Constructor taking value and units flag.
value (int) –
units (TextAttrUnits) –
Apply
(self, dim, compareWith=None)¶Apply the dimension, but not those identical to compareWith if present.
dim (wx.richtext.TextAttrDimension) –
compareWith (wx.richtext.TextAttrDimension) –
bool
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.
attr (wx.richtext.TextAttrDimension) –
clashingAttr (wx.richtext.TextAttrDimension) –
absentAttr (wx.richtext.TextAttrDimension) –
EqPartial
(self, dim, weakTest=True)¶Partial equality test.
If weakTest is True
, attributes of this object do not have to be present if those attributes of dim are present. If weakTest is False
, the function will fail if an attribute is present in dim but not in this object.
dim (wx.richtext.TextAttrDimension) –
weakTest (bool) –
bool
GetFlags
(self)¶Gets the dimension flags.
wx.richtext.TextAttrDimensionFlags
GetPosition
(self)¶Gets the position flags.
GetUnits
(self)¶Gets the units of the dimension.
GetValue
(self)¶Returns the integer value of the dimension.
int
GetValueMM
(self)¶Returns the floating-pointing value of the dimension in mm.
float
IsValid
(self)¶Returns True
if the dimension is valid.
bool
Reset
(self)¶Resets the dimension value and flags.
SetFlags
(self, flags)¶Sets the dimension flags.
flags (wx.richtext.TextAttrDimensionFlags) –
SetPosition
(self, pos)¶Sets the position flags.
pos (TextBoxAttrPosition) –
SetUnits
(self, units)¶Sets the units of the dimension.
units (TextAttrUnits) –
SetValid
(self, b)¶Sets the valid flag.
b (bool) –
SetValue
(self, *args, **kw)¶SetValue (self, value)
Sets the integer value of the dimension.
value (int) –
SetValue (self, value, flags)
Sets the integer value of the dimension, passing dimension flags.
value (int) –
flags (wx.richtext.TextAttrDimensionFlags) –
SetValue (self, dim)
Sets the dimension.
dim (wx.richtext.TextAttrDimension) –
SetValueMM
(self, value)¶Sets the value of the dimension in mm.
value (float) –
__bool__
(self)¶int
__nonzero__
(self)¶int
__eq__
(self)¶Equality operator.
dim (wx.richtext.TextAttrDimension) –
Position
¶See GetPosition
and SetPosition
ValueMM
¶See GetValueMM
and SetValueMM
m_flags
¶A public C++ attribute of type TextAttrDimensionFlags .
m_value
¶A public C++ attribute of type int
.