mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-13 11:29:19 +02:00
TFont.Assign now looks at source font PixelsPerInch to set font height
git-svn-id: trunk@8338 -
This commit is contained in:
parent
49122cc61f
commit
e8571efcd2
@ -548,6 +548,11 @@ begin
|
|||||||
try
|
try
|
||||||
CharSet:= TFont(Source).CharSet;
|
CharSet:= TFont(Source).CharSet;
|
||||||
SetColor(TFont(Source).Color,TFPCanvasHelper(Source).FPColor);
|
SetColor(TFont(Source).Color,TFPCanvasHelper(Source).FPColor);
|
||||||
|
if TFont(Source).PixelsPerInch <> FPixelsPerInch then
|
||||||
|
// use size to convert source height pixels to current resolution
|
||||||
|
Size := TFont(Source).Size
|
||||||
|
else
|
||||||
|
// use height which users could have changed directly
|
||||||
Height := TFont(Source).Height;
|
Height := TFont(Source).Height;
|
||||||
Name := TFont(Source).Name;
|
Name := TFont(Source).Name;
|
||||||
Pitch := TFont(Source).Pitch;
|
Pitch := TFont(Source).Pitch;
|
||||||
|
Loading…
Reference in New Issue
Block a user