wx.richtext.TextAttrDimension¶
A class representing a rich text dimension, including units and position.
Class Hierarchy¶
Methods Summary¶
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. |
Properties Summary¶
See |
|
See |
|
A public C++ attribute of type TextAttrDimensionFlags . |
|
A public C++ attribute of type |
Class API¶
- class wx.richtext.TextAttrDimension(object)¶
Possible constructors:
TextAttrDimension() -> None TextAttrDimension(value, units=TEXT_ATTR_UNITS_TENTHS_MM) -> None
A class representing a rich text dimension, including units and position.
Methods¶
- __init__(self, *args, **kw)¶
-
__init__ (self)
Default constructor.
- Return type:
None
__init__ (self, value, units=TEXT_ATTR_UNITS_TENTHS_MM)
Constructor taking value and units flag.
- Parameters:
value (int)
units (TextAttrUnits)
- Return type:
None
- Apply(self, dim, compareWith=None)¶
Apply the dimension, but not those identical to compareWith if present.
- Parameters:
compareWith (wx.richtext.TextAttrDimension)
- Return type:
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.
- Parameters:
clashingAttr (wx.richtext.TextAttrDimension)
absentAttr (wx.richtext.TextAttrDimension)
- Return type:
None
- 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 isFalse, the function will fail if an attribute is present in dim but not in this object.- Parameters:
weakTest (bool)
- Return type:
bool
- GetFlags(self)¶
Gets the dimension flags.
- Return type:
wx.richtext.TextAttrDimensionFlags
- GetPosition(self)¶
Gets the position flags.
- Return type:
- GetUnits(self)¶
Gets the units of the dimension.
- Return type:
- GetValue(self)¶
Returns the integer value of the dimension.
- Return type:
int
- GetValueMM(self)¶
Returns the floating-pointing value of the dimension in mm.
- Return type:
float
- IsValid(self)¶
Returns
Trueif the dimension is valid.- Return type:
bool
- Reset(self)¶
Resets the dimension value and flags.
- Return type:
None
- SetFlags(self, flags)¶
Sets the dimension flags.
- Parameters:
flags (wx.richtext.TextAttrDimensionFlags)
- Return type:
None
- SetPosition(self, pos)¶
Sets the position flags.
- Parameters:
pos (TextBoxAttrPosition)
- Return type:
None
- SetUnits(self, units)¶
Sets the units of the dimension.
- Parameters:
units (TextAttrUnits)
- Return type:
None
- SetValid(self, b)¶
Sets the valid flag.
- Parameters:
b (bool)
- Return type:
None
- SetValue(self, *args, **kw)¶
-
SetValue (self, value)
Sets the integer value of the dimension.
- Parameters:
value (int)
- Return type:
None
SetValue (self, value, flags)
Sets the integer value of the dimension, passing dimension flags.
- Parameters:
value (int)
flags (wx.richtext.TextAttrDimensionFlags)
- Return type:
None
SetValue (self, dim)
Sets the dimension.
- Parameters:
- Return type:
None
- SetValueMM(self, value)¶
Sets the value of the dimension in mm.
- Parameters:
value (float)
- Return type:
None
- __bool__(self)¶
- Return type:
bool
- __nonzero__(self)¶
- Return type:
bool
- __eq__(self, dim)¶
Equality operator.
- Parameters:
- Return type:
bool
Properties¶
- Position¶
See
GetPositionandSetPosition
- ValueMM¶
See
GetValueMMandSetValueMM
- m_flags¶
A public C++ attribute of type TextAttrDimensionFlags .
- m_value¶
A public C++ attribute of type
int.
