Added conversion from points
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@74931 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -13292,6 +13292,8 @@ int wxTextAttrDimensionConverter::GetPixels(const wxTextAttrDimension& dim, int
|
|||||||
return ConvertTenthsMMToPixels(dim.GetValue());
|
return ConvertTenthsMMToPixels(dim.GetValue());
|
||||||
else if (dim.GetUnits() == wxTEXT_ATTR_UNITS_PIXELS)
|
else if (dim.GetUnits() == wxTEXT_ATTR_UNITS_PIXELS)
|
||||||
return dim.GetValue();
|
return dim.GetValue();
|
||||||
|
else if (dim.GetUnits() == wxTEXT_ATTR_UNITS_POINTS)
|
||||||
|
return (int)((double(dim.GetValue()) * (double(m_ppi)/72.0)) + 0.5);
|
||||||
else if (dim.GetUnits() == wxTEXT_ATTR_UNITS_PERCENTAGE)
|
else if (dim.GetUnits() == wxTEXT_ATTR_UNITS_PERCENTAGE)
|
||||||
{
|
{
|
||||||
wxASSERT(m_parentSize != wxDefaultSize);
|
wxASSERT(m_parentSize != wxDefaultSize);
|
||||||
|
Reference in New Issue
Block a user