A class to make it easier to convert dimensions.
__init__ |
Constructor. |
ConvertPixelsToTenthsMM |
Converts pixels to tenths of a mm. |
ConvertTenthsMMToPixels |
Converts tenths of a mm to pixels. |
GetPixels |
Gets the pixel size for the given dimension. |
GetTenthsMM |
Gets the mm size for the given dimension. |
m_parentSize |
A public C++ attribute of type Size . |
m_ppi |
A public C++ attribute of type int . |
m_scale |
A public C++ attribute of type float . |
wx.richtext.
TextAttrDimensionConverter
(object)¶Possible constructors:
TextAttrDimensionConverter(dc, scale=1.0, parentSize=DefaultSize)
TextAttrDimensionConverter(ppi, scale=1.0, parentSize=DefaultSize)
A class to make it easier to convert dimensions.
__init__
(self, *args, **kw)¶Constructor.
__init__ (self, dc, scale=1.0, parentSize=DefaultSize)
Parameters: |
---|
__init__ (self, ppi, scale=1.0, parentSize=DefaultSize)
Parameters: |
|
---|
ConvertPixelsToTenthsMM
(self, pixels)¶Converts pixels to tenths of a mm.
Parameters: | pixels (int) – |
---|---|
Return type: | int |
ConvertTenthsMMToPixels
(self, units)¶Converts tenths of a mm to pixels.
Parameters: | units (int) – |
---|---|
Return type: | int |
GetPixels
(self, dim, direction=HORIZONTAL)¶Gets the pixel size for the given dimension.
Parameters: |
|
---|---|
Return type: | int |
GetTenthsMM
(self, dim)¶Gets the mm size for the given dimension.
Parameters: | dim (wx.richtext.TextAttrDimension) – |
---|---|
Return type: | int |
m_ppi
¶A public C++ attribute of type int
.
m_scale
¶A public C++ attribute of type float
.