mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-09-04 18:40:29 +02:00
examples: fix lazfreetype example
git-svn-id: trunk@52152 -
This commit is contained in:
parent
8977b0ad0c
commit
4ffd3756f3
@ -1,4 +1,4 @@
|
|||||||
<?xml version="1.0"?>
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
<CONFIG>
|
<CONFIG>
|
||||||
<ProjectOptions>
|
<ProjectOptions>
|
||||||
<Version Value="9"/>
|
<Version Value="9"/>
|
||||||
@ -17,8 +17,38 @@
|
|||||||
<VersionInfo>
|
<VersionInfo>
|
||||||
<StringTable ProductVersion=""/>
|
<StringTable ProductVersion=""/>
|
||||||
</VersionInfo>
|
</VersionInfo>
|
||||||
<BuildModes Count="1">
|
<BuildModes Count="2">
|
||||||
<Item1 Name="Default" Default="True"/>
|
<Item1 Name="Debug" Default="True"/>
|
||||||
|
<Item2 Name="Release">
|
||||||
|
<CompilerOptions>
|
||||||
|
<Version Value="11"/>
|
||||||
|
<PathDelim Value="\"/>
|
||||||
|
<Target>
|
||||||
|
<Filename Value="lazfreetypetest"/>
|
||||||
|
</Target>
|
||||||
|
<SearchPaths>
|
||||||
|
<IncludeFiles Value="$(ProjOutDir)"/>
|
||||||
|
<UnitOutputDirectory Value="lib\$(TargetCPU)-$(TargetOS)"/>
|
||||||
|
</SearchPaths>
|
||||||
|
<CodeGeneration>
|
||||||
|
<SmartLinkUnit Value="True"/>
|
||||||
|
<Optimizations>
|
||||||
|
<OptimizationLevel Value="3"/>
|
||||||
|
</Optimizations>
|
||||||
|
</CodeGeneration>
|
||||||
|
<Linking>
|
||||||
|
<Debugging>
|
||||||
|
<GenerateDebugInfo Value="False"/>
|
||||||
|
</Debugging>
|
||||||
|
<LinkSmart Value="True"/>
|
||||||
|
<Options>
|
||||||
|
<Win32>
|
||||||
|
<GraphicApplication Value="True"/>
|
||||||
|
</Win32>
|
||||||
|
</Options>
|
||||||
|
</Linking>
|
||||||
|
</CompilerOptions>
|
||||||
|
</Item2>
|
||||||
</BuildModes>
|
</BuildModes>
|
||||||
<PublishOptions>
|
<PublishOptions>
|
||||||
<Version Value="2"/>
|
<Version Value="2"/>
|
||||||
@ -39,7 +69,6 @@
|
|||||||
<Unit0>
|
<Unit0>
|
||||||
<Filename Value="lazfreetypetest.lpr"/>
|
<Filename Value="lazfreetypetest.lpr"/>
|
||||||
<IsPartOfProject Value="True"/>
|
<IsPartOfProject Value="True"/>
|
||||||
<UnitName Value="lazfreetypetest"/>
|
|
||||||
</Unit0>
|
</Unit0>
|
||||||
<Unit1>
|
<Unit1>
|
||||||
<Filename Value="mainform.pas"/>
|
<Filename Value="mainform.pas"/>
|
||||||
@ -47,7 +76,6 @@
|
|||||||
<ComponentName Value="Form1"/>
|
<ComponentName Value="Form1"/>
|
||||||
<HasResources Value="True"/>
|
<HasResources Value="True"/>
|
||||||
<ResourceBaseClass Value="Form"/>
|
<ResourceBaseClass Value="Form"/>
|
||||||
<UnitName Value="mainform"/>
|
|
||||||
</Unit1>
|
</Unit1>
|
||||||
</Units>
|
</Units>
|
||||||
</ProjectOptions>
|
</ProjectOptions>
|
||||||
@ -61,9 +89,24 @@
|
|||||||
<IncludeFiles Value="$(ProjOutDir)"/>
|
<IncludeFiles Value="$(ProjOutDir)"/>
|
||||||
<UnitOutputDirectory Value="lib\$(TargetCPU)-$(TargetOS)"/>
|
<UnitOutputDirectory Value="lib\$(TargetCPU)-$(TargetOS)"/>
|
||||||
</SearchPaths>
|
</SearchPaths>
|
||||||
|
<Parsing>
|
||||||
|
<SyntaxOptions>
|
||||||
|
<IncludeAssertionCode Value="True"/>
|
||||||
|
</SyntaxOptions>
|
||||||
|
</Parsing>
|
||||||
|
<CodeGeneration>
|
||||||
|
<Checks>
|
||||||
|
<IOChecks Value="True"/>
|
||||||
|
<RangeChecks Value="True"/>
|
||||||
|
<OverflowChecks Value="True"/>
|
||||||
|
<StackChecks Value="True"/>
|
||||||
|
</Checks>
|
||||||
|
</CodeGeneration>
|
||||||
<Linking>
|
<Linking>
|
||||||
<Debugging>
|
<Debugging>
|
||||||
|
<DebugInfoType Value="dsDwarf2Set"/>
|
||||||
<UseHeaptrc Value="True"/>
|
<UseHeaptrc Value="True"/>
|
||||||
|
<UseExternalDbgSyms Value="True"/>
|
||||||
</Debugging>
|
</Debugging>
|
||||||
<Options>
|
<Options>
|
||||||
<Win32>
|
<Win32>
|
||||||
@ -71,12 +114,6 @@
|
|||||||
</Win32>
|
</Win32>
|
||||||
</Options>
|
</Options>
|
||||||
</Linking>
|
</Linking>
|
||||||
<Other>
|
|
||||||
<CompilerMessages>
|
|
||||||
<UseMsgFile Value="True"/>
|
|
||||||
</CompilerMessages>
|
|
||||||
<CompilerPath Value="$(CompPath)"/>
|
|
||||||
</Other>
|
|
||||||
</CompilerOptions>
|
</CompilerOptions>
|
||||||
<Debugging>
|
<Debugging>
|
||||||
<Exceptions Count="3">
|
<Exceptions Count="3">
|
||||||
|
Binary file not shown.
@ -14,7 +14,7 @@ object Form1: TForm1
|
|||||||
OnPaint = FormPaint
|
OnPaint = FormPaint
|
||||||
OnShow = FormShow
|
OnShow = FormShow
|
||||||
Position = poDefault
|
Position = poDefault
|
||||||
LCLVersion = '1.1'
|
LCLVersion = '1.7'
|
||||||
object Panel_Option: TPanel
|
object Panel_Option: TPanel
|
||||||
Left = 0
|
Left = 0
|
||||||
Height = 40
|
Height = 40
|
||||||
@ -50,15 +50,15 @@ object Form1: TForm1
|
|||||||
end
|
end
|
||||||
object Label1: TLabel
|
object Label1: TLabel
|
||||||
Left = 6
|
Left = 6
|
||||||
Height = 13
|
Height = 15
|
||||||
Top = 12
|
Top = 12
|
||||||
Width = 26
|
Width = 32
|
||||||
Caption = 'Zoom'
|
Caption = 'Zoom'
|
||||||
ParentColor = False
|
ParentColor = False
|
||||||
end
|
end
|
||||||
object SpinEdit_Zoom: TSpinEdit
|
object SpinEdit_Zoom: TSpinEdit
|
||||||
Left = 48
|
Left = 48
|
||||||
Height = 21
|
Height = 23
|
||||||
Top = 8
|
Top = 8
|
||||||
Width = 40
|
Width = 40
|
||||||
MaxValue = 9
|
MaxValue = 9
|
||||||
@ -68,10 +68,10 @@ object Form1: TForm1
|
|||||||
Value = 1
|
Value = 1
|
||||||
end
|
end
|
||||||
object CheckBox_Rect: TCheckBox
|
object CheckBox_Rect: TCheckBox
|
||||||
Left = 393
|
Left = 392
|
||||||
Height = 17
|
Height = 19
|
||||||
Top = 10
|
Top = 10
|
||||||
Width = 42
|
Width = 43
|
||||||
Anchors = [akTop, akRight]
|
Anchors = [akTop, akRight]
|
||||||
Caption = 'Rect'
|
Caption = 'Rect'
|
||||||
OnChange = CheckBox_RectChange
|
OnChange = CheckBox_RectChange
|
||||||
|
@ -10,8 +10,8 @@ uses
|
|||||||
|
|
||||||
IntfGraphics, GraphType, //Intf basic routines
|
IntfGraphics, GraphType, //Intf basic routines
|
||||||
|
|
||||||
EasyLazFreeType, LazFreeTypeIntfDrawer //EasyFreeType with Intf
|
EasyLazFreeType, LazFreeTypeIntfDrawer, //EasyFreeType with Intf
|
||||||
|
LazFreeTypeFontCollection
|
||||||
;
|
;
|
||||||
|
|
||||||
type
|
type
|
||||||
@ -65,7 +65,7 @@ var
|
|||||||
|
|
||||||
function LoadFont: TFreeTypeFont;
|
function LoadFont: TFreeTypeFont;
|
||||||
var
|
var
|
||||||
FileName: string;
|
FileName, FontFamilyName: string;
|
||||||
begin
|
begin
|
||||||
result := nil;
|
result := nil;
|
||||||
inc(n);
|
inc(n);
|
||||||
@ -81,8 +81,9 @@ var
|
|||||||
else
|
else
|
||||||
exit;
|
exit;
|
||||||
end;
|
end;
|
||||||
|
FontFamilyName := FontCollection.AddFile(FileName).Family.FamilyName;
|
||||||
result := TFreeTypeFont.Create;
|
result := TFreeTypeFont.Create;
|
||||||
result.Name := FileName;
|
result.Name := FontFamilyName;
|
||||||
LastFileName:= FileName;
|
LastFileName:= FileName;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user