fpvviewer: Fix compilation and operation with rsvg-convert on Windows

git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@9350 8e941d3f-bd1b-0410-a28a-d453659cc2b4
This commit is contained in:
wp_xxyyzz 2024-05-11 15:49:43 +00:00
parent 9f9ac7cd2a
commit a7fe32c308
6 changed files with 34 additions and 41 deletions

View File

@ -6,9 +6,9 @@ object frmFPVViewer: TfrmFPVViewer
Caption = 'Free Pascal Vectorial Viewer'
ClientHeight = 600
ClientWidth = 485
LCLVersion = '3.99.0.0'
OnCreate = FormCreate
OnDestroy = FormDestroy
LCLVersion = '1.7'
object notebook: TNotebook
Left = 0
Height = 408
@ -32,7 +32,6 @@ object frmFPVViewer: TfrmFPVViewer
Align = alBottom
Anchors = [akTop, akLeft, akRight, akBottom]
BorderSpacing.Top = 7
DefaultItemHeight = 18
TabOrder = 0
end
object editSearchInTokens: TEdit
@ -49,8 +48,8 @@ object frmFPVViewer: TfrmFPVViewer
Top = 0
Width = 155
Caption = 'Search in Token Tree'
OnClick = btnSearchInTokensClick
TabOrder = 2
OnClick = btnSearchInTokensClick
end
end
object pageDebug: TPage
@ -84,7 +83,7 @@ object frmFPVViewer: TfrmFPVViewer
Left = 184
Height = 19
Top = 168
Width = 153
Width = 151
Caption = 'Force Bottom-Left Origin'
TabOrder = 18
end
@ -107,8 +106,8 @@ object frmFPVViewer: TfrmFPVViewer
Top = 40
Width = 96
Caption = 'Visualize'
OnClick = btnVisualizeClick
TabOrder = 1
OnClick = btnVisualizeClick
end
object spinScale: TFloatSpinEdit
Left = 72
@ -118,10 +117,9 @@ object frmFPVViewer: TfrmFPVViewer
DecimalPlaces = 6
Increment = 0.1
MaxValue = 100
MinValue = 0
OnChange = spinScaleChange
TabOrder = 2
Value = 1
OnChange = spinScaleChange
end
object Label1: TLabel
Left = 8
@ -137,8 +135,8 @@ object frmFPVViewer: TfrmFPVViewer
Top = 40
Width = 128
Caption = 'View DXF Tokens'
OnClick = btnViewDXFTokensClick
TabOrder = 3
OnClick = btnViewDXFTokensClick
end
object buttonAutoFitView: TButton
Left = 112
@ -146,8 +144,8 @@ object frmFPVViewer: TfrmFPVViewer
Top = 40
Width = 96
Caption = 'Auto Fit View'
OnClick = buttonAutoFitViewClick
TabOrder = 4
OnClick = buttonAutoFitViewClick
end
object buttonConvertToSVG: TButton
Left = 360
@ -155,8 +153,8 @@ object frmFPVViewer: TfrmFPVViewer
Top = 40
Width = 120
Caption = 'Convert to SVG'
OnClick = buttonConvertToSVGClick
TabOrder = 5
OnClick = buttonConvertToSVGClick
end
object btnContourLines: TButton
Left = 256
@ -164,8 +162,8 @@ object frmFPVViewer: TfrmFPVViewer
Top = 97
Width = 224
Caption = 'Generate Contour Lines'
OnClick = btnContourLinesClick
TabOrder = 6
OnClick = btnContourLinesClick
end
object Label2: TLabel
Left = 8
@ -183,8 +181,8 @@ object frmFPVViewer: TfrmFPVViewer
Increment = 100
MaxValue = 1000
MinValue = -1000
OnChange = spinAdjustYChange
TabOrder = 7
OnChange = spinAdjustYChange
end
object spinAdjustX: TSpinEdit
Left = 232
@ -194,8 +192,8 @@ object frmFPVViewer: TfrmFPVViewer
Increment = 50
MaxValue = 1000
MinValue = -1000
OnChange = spinAdjustXChange
TabOrder = 8
OnChange = spinAdjustXChange
end
object Label3: TLabel
Left = 160
@ -211,8 +209,8 @@ object frmFPVViewer: TfrmFPVViewer
Top = 70
Width = 168
Caption = 'View FPVectorial Tokens'
OnClick = buttonViewFPVTokensClick
TabOrder = 9
OnClick = buttonViewFPVTokensClick
end
object Label4: TLabel
Left = 9
@ -273,7 +271,7 @@ object frmFPVViewer: TfrmFPVViewer
Left = 9
Height = 19
Top = 152
Width = 153
Width = 151
Caption = 'Force white background?'
TabOrder = 11
end
@ -283,8 +281,8 @@ object frmFPVViewer: TfrmFPVViewer
Top = 153
Width = 107
Caption = 'View Debug Info'
OnClick = buttonViewDebugInfoClick
TabOrder = 12
OnClick = buttonViewDebugInfoClick
end
object buttonPrint: TButton
Left = 416
@ -292,8 +290,8 @@ object frmFPVViewer: TfrmFPVViewer
Top = 8
Width = 59
Caption = 'Print'
OnClick = buttonPrintClick
TabOrder = 13
OnClick = buttonPrintClick
end
object buttonAdjust: TButton
Left = 344
@ -301,14 +299,14 @@ object frmFPVViewer: TfrmFPVViewer
Top = 8
Width = 56
Caption = 'Adjust'
OnClick = buttonAdjustClick
TabOrder = 14
OnClick = buttonAdjustClick
end
object checkShowPage: TCheckBox
Left = 184
Height = 19
Top = 152
Width = 78
Width = 76
Caption = 'Show Page'
TabOrder = 15
end
@ -318,14 +316,14 @@ object frmFPVViewer: TfrmFPVViewer
Top = 153
Width = 64
Caption = 'Auto Fit'
OnClick = buttonAutoFitClick
TabOrder = 16
OnClick = buttonAutoFitClick
end
object checkboxSVGviaRSVG: TCheckBox
Left = 9
Height = 19
Top = 168
Width = 147
Width = 145
Caption = 'SVG Rendering via RSVG'
TabOrder = 17
end

View File

@ -560,7 +560,7 @@ begin
FVec.ReaderSettings.HelperToolPath := ExtractFilePath(paramstr(0))+'rsvg\rsvg-convert.exe';
{$endif}
if checkboxForceBottomLeftOrigin.Checked then
FVec.ReaderSettings.VecReaderFlags := [vrfSVG_UseBottomLeftCoords]
FVec.ReaderSettings.VecReaderFlags := [vrf_UseBottomLeftCoords]
else
FVec.ReaderSettings.VecReaderFlags := [];
if checkboxSVGviaRSVG.Checked then

View File

@ -1,19 +1,18 @@
<?xml version="1.0" encoding="UTF-8"?>
<CONFIG>
<ProjectOptions>
<Version Value="9"/>
<Version Value="12"/>
<General>
<Flags>
<CompatibilityMode Value="True"/>
</Flags>
<SessionStorage Value="InProjectDir"/>
<MainUnit Value="0"/>
<ResourceType Value="res"/>
<UseXPManifest Value="True"/>
</General>
<i18n>
<EnableI18N LFM="False"/>
</i18n>
<VersionInfo>
<StringTable ProductVersion=""/>
</VersionInfo>
<BuildModes Count="5">
<Item1 Name="default" Default="True"/>
<Item2 Name="win32-console">
@ -98,20 +97,20 @@
</Linking>
</CompilerOptions>
</Item5>
<SharedMatrixOptions Count="2">
<SharedMatrixOptions Count="3">
<Item1 ID="669514139583" Modes="qt" Type="IDEMacro" MacroName="LCLWidgetType" Value="qt"/>
<Item2 ID="166328276776" Modes="cocoa" Type="IDEMacro" MacroName="LCLWidgetType" Value="cocoa"/>
<Item3 ID="574418906724" Modes="default" Value="-gw3"/>
</SharedMatrixOptions>
</BuildModes>
<PublishOptions>
<Version Value="2"/>
<IncludeFileFilter Value="*.(pas|pp|inc|lfm|lpr|lrs|lpi|lpk|sh|xml)"/>
<ExcludeFileFilter Value="*.(bak|ppu|o|so);*~;backup"/>
</PublishOptions>
<RunParams>
<local>
<FormatVersion Value="1"/>
</local>
<FormatVersion Value="2"/>
<Modes Count="1">
<Mode0 Name="default"/>
</Modes>
</RunParams>
<RequiredPackages Count="4">
<Item1>
@ -139,7 +138,6 @@
<ComponentName Value="frmFPVViewer"/>
<HasResources Value="True"/>
<ResourceBaseClass Value="Form"/>
<UnitName Value="fpvv_mainform"/>
</Unit1>
<Unit2>
<Filename Value="dxftokentotree.pas"/>
@ -165,6 +163,9 @@
<UnitOutputDirectory Value="lib/$(TargetCPU)-$(TargetOS)"/>
</SearchPaths>
<Linking>
<Debugging>
<DebugInfoType Value="dsDwarf3"/>
</Debugging>
<Options>
<Win32>
<GraphicApplication Value="True"/>

View File

@ -13,6 +13,7 @@ uses
{$R *.res}
begin
Application.Title:='';
Application.Initialize;
Application.CreateForm(TfrmFPVViewer, frmFPVViewer);
Application.Run;

View File

@ -65,13 +65,6 @@
<string>sans-serif</string>
</edit>
</match>
<alias>
<family>sans-serif</family>
<prefer>
<family>segoe ui</family>
<family>tahoma</family>
</prefer>
</alias>
<!--
Load local system customization file
-->