mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-15 11:59:45 +02:00
Cocoa: Fix font size bug
git-svn-id: trunk@43734 -
This commit is contained in:
parent
8bce6066ca
commit
692c4c1ef3
@ -527,7 +527,7 @@ begin
|
|||||||
FSize := Round(NSFont.systemFontSize);
|
FSize := Round(NSFont.systemFontSize);
|
||||||
end
|
end
|
||||||
else
|
else
|
||||||
FSize := ALogFont.lfHeight;
|
FSize := Abs(ALogFont.lfHeight);
|
||||||
|
|
||||||
// create font attributes
|
// create font attributes
|
||||||
Win32Weight := ALogFont.lfWeight;
|
Win32Weight := ALogFont.lfWeight;
|
||||||
@ -543,7 +543,7 @@ begin
|
|||||||
|
|
||||||
Attributes := NSDictionary.dictionaryWithObjectsAndKeys(
|
Attributes := NSDictionary.dictionaryWithObjectsAndKeys(
|
||||||
NSStringUTF8(FName), NSFontFamilyAttribute,
|
NSStringUTF8(FName), NSFontFamilyAttribute,
|
||||||
NSNumber.numberWithFloat(ALogFont.lfHeight), NSFontSizeAttribute,
|
NSNumber.numberWithFloat(FSize), NSFontSizeAttribute,
|
||||||
nil);
|
nil);
|
||||||
|
|
||||||
Descriptor := NSFontDescriptor.fontDescriptorWithFontAttributes(Attributes);
|
Descriptor := NSFontDescriptor.fontDescriptorWithFontAttributes(Attributes);
|
||||||
|
Loading…
Reference in New Issue
Block a user