Fix a few more double-pomotion errors
This commit is contained in:
parent
2ba984fcbb
commit
0601a19d38
|
@ -55,13 +55,13 @@ coretext_font_size_from_ptem (float ptem)
|
||||||
* https://developer.apple.com/library/content/documentation/GraphicsAnimation/Conceptual/HighResolutionOSX/Explained/Explained.html
|
* https://developer.apple.com/library/content/documentation/GraphicsAnimation/Conceptual/HighResolutionOSX/Explained/Explained.html
|
||||||
*/
|
*/
|
||||||
ptem *= 96.f / 72.f;
|
ptem *= 96.f / 72.f;
|
||||||
return ptem <= 0.f ? HB_CORETEXT_DEFAULT_FONT_SIZE : ptem;
|
return (CGFloat) (ptem <= 0.f ? HB_CORETEXT_DEFAULT_FONT_SIZE : ptem);
|
||||||
}
|
}
|
||||||
static float
|
static float
|
||||||
coretext_font_size_to_ptem (CGFloat size)
|
coretext_font_size_to_ptem (CGFloat size)
|
||||||
{
|
{
|
||||||
size *= 72.f / 96.f;
|
size *= 72. / 96.;
|
||||||
return size <= 0.f ? 0 : size;
|
return size <= 0 ? 0 : size;
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
|
|
Loading…
Reference in New Issue