Skip to content

Commit d9f3d58

Browse files
authored
Merge pull request #187 from ReinierNL/update_demo32
Updates for demo 32
2 parents 5c40983 + aec4c07 commit d9f3d58

File tree

2 files changed

+53
-44
lines changed

2 files changed

+53
-44
lines changed

Demos/Demo32/Demo32.dproj

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -57,23 +57,25 @@
5757
</PropertyGroup>
5858
<PropertyGroup Condition="'$(Base_Win32)'!=''">
5959
<VerInfo_IncludeVerInfo>true</VerInfo_IncludeVerInfo>
60-
<Icon_MainIcon>Demo32_Icon.ico</Icon_MainIcon>
60+
<Icon_MainIcon>$(BDS)\bin\delphi_PROJECTICON.ico</Icon_MainIcon>
6161
<DCC_Namespace>System.Win;Data.Win;Datasnap.Win;Web.Win;Soap.Win;Xml.Win;Bde;$(DCC_Namespace)</DCC_Namespace>
6262
<VerInfo_Locale>1033</VerInfo_Locale>
6363
<Manifest_File>$(BDS)\bin\default_app.manifest</Manifest_File>
6464
<AppEnableRuntimeThemes>true</AppEnableRuntimeThemes>
6565
<UWP_DelphiLogo44>$(BDS)\bin\Artwork\Windows\UWP\delphi_UwpDefault_44.png</UWP_DelphiLogo44>
6666
<UWP_DelphiLogo150>$(BDS)\bin\Artwork\Windows\UWP\delphi_UwpDefault_150.png</UWP_DelphiLogo150>
67+
<AppDPIAwarenessMode>PerMonitorV2</AppDPIAwarenessMode>
6768
</PropertyGroup>
6869
<PropertyGroup Condition="'$(Base_Win64)'!=''">
6970
<DCC_Namespace>System.Win;Data.Win;Datasnap.Win;Web.Win;Soap.Win;Xml.Win;$(DCC_Namespace)</DCC_Namespace>
7071
<Manifest_File>$(BDS)\bin\default_app.manifest</Manifest_File>
7172
<VerInfo_IncludeVerInfo>true</VerInfo_IncludeVerInfo>
7273
<VerInfo_Locale>1033</VerInfo_Locale>
73-
<Icon_MainIcon>Demo32_Icon.ico</Icon_MainIcon>
74+
<Icon_MainIcon>$(BDS)\bin\delphi_PROJECTICON.ico</Icon_MainIcon>
7475
<AppEnableRuntimeThemes>true</AppEnableRuntimeThemes>
7576
<UWP_DelphiLogo44>$(BDS)\bin\Artwork\Windows\UWP\delphi_UwpDefault_44.png</UWP_DelphiLogo44>
7677
<UWP_DelphiLogo150>$(BDS)\bin\Artwork\Windows\UWP\delphi_UwpDefault_150.png</UWP_DelphiLogo150>
78+
<AppDPIAwarenessMode>PerMonitorV2</AppDPIAwarenessMode>
7779
</PropertyGroup>
7880
<PropertyGroup Condition="'$(Cfg_1)'!=''">
7981
<DCC_LocalDebugSymbols>false</DCC_LocalDebugSymbols>
@@ -88,7 +90,6 @@
8890
<BT_BuildType>Debug</BT_BuildType>
8991
</PropertyGroup>
9092
<PropertyGroup Condition="'$(Cfg_2_Win64)'!=''">
91-
<Icon_MainIcon>$(BDS)\bin\delphi_PROJECTICON.ico</Icon_MainIcon>
9293
<VerInfo_Locale>1033</VerInfo_Locale>
9394
<VerInfo_IncludeVerInfo>true</VerInfo_IncludeVerInfo>
9495
<BT_BuildType>Debug</BT_BuildType>
@@ -153,10 +154,7 @@
153154
<VersionInfoKeys Name="ProductVersion">1.0.0.0</VersionInfoKeys>
154155
<VersionInfoKeys Name="Comments"/>
155156
</VersionInfoKeys>
156-
<Excluded_Packages>
157-
<Excluded_Packages Name="$(BDSBIN)\dcloffice2k210.bpl">Microsoft Office 2000 Sample Automation Server Wrapper Components</Excluded_Packages>
158-
<Excluded_Packages Name="$(BDSBIN)\dclofficexp210.bpl">Microsoft Office XP Sample Automation Server Wrapper Components</Excluded_Packages>
159-
</Excluded_Packages>
157+
<Excluded_Packages/>
160158
</Delphi.Personality>
161159
<Platforms>
162160
<Platform value="Win32">True</Platform>

Demos/Demo32/Unit1.dfm

Lines changed: 48 additions & 37 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ object Form1: TForm1
1616
OldCreateOrder = True
1717
Visible = True
1818
PixelsPerInch = 96
19-
TextHeight = 11
19+
TextHeight = 13
2020
object Splitter1: TSplitter
2121
Left = 0
2222
Top = 169
@@ -32,6 +32,12 @@ object Form1: TForm1
3232
Width = 576
3333
Height = 170
3434
Align = alClient
35+
Font.Charset = DEFAULT_CHARSET
36+
Font.Color = clWindowText
37+
Font.Height = -13
38+
Font.Name = 'Consolas'
39+
Font.Pitch = fpVariable
40+
Font.Style = []
3541
Lines.Strings = (
3642
'import spam'
3743
''
@@ -40,46 +46,46 @@ object Form1: TForm1
4046
' Self.OffsetBy(v, v)'
4147
''
4248
'p = spam.Point(2, 5)'
43-
'print p, type(p)'
49+
'print (p, type(p))'
4450
'p.OffsetBy( 3, 3 )'
45-
'print p.x, p.y'
46-
'print "Name =", p.Name'
51+
'print (p.x, p.y)'
52+
'print ("Name =", p.Name)'
4753
'p.Name = '#39'Hello world!'#39
48-
'print "Name =", p.Name'
54+
'print ("Name =", p.Name)'
4955
''
50-
'p = spam.Point(2, 5) '
51-
'print p, type(p)'
56+
'p = spam.Point(2, 5)'
57+
'print (p, type(p))'
5258
'p.OffsetBy( 3, 3 )'
53-
'print p.x, p.y'
59+
'print (p.x, p.y)'
5460
''
5561
'# create a subtype instance'
5662
'p = MyPoint(2, 5)'
57-
'print p, type(p)'
63+
'print (p, type(p))'
5864
'p.OffsetBy( 3, 3 )'
59-
'print p.x, p.y'
65+
'print (p.x, p.y)'
6066
'p.Foo( 4 )'
61-
'print p.x, p.y'
62-
'print dir(spam)'
63-
'print spam.Point'
64-
'print "p = ", p, " --> ",'
67+
'print (p.x, p.y)'
68+
'print (dir(spam))'
69+
'print (spam.Point)'
70+
'print ("p = ", p, " --> ",)'
6571
'if type(p) is spam.Point:'
66-
' print "p is a Point"'
72+
' print ("p is a Point")'
6773
'else:'
68-
' print "p is not a point"'
74+
' print ("p is not a point")'
6975
'p = 2'
70-
'print "p = ", p, " --> ",'
76+
'print ("p = ", p, " --> ",)'
7177
'if type(p) is spam.Point:'
72-
' print "p is a Point"'
78+
' print ("p is a Point")'
7379
'else:'
74-
' print "p is not a point"'
80+
' print ("p is not a point")'
7581
''
76-
'# You can raise error from a Python script to !'
82+
'# You can raise errors from a Python script too !'
7783

78-
'print "---------------------------------------------------------' +
79-
'---------"'
80-
'print "Errors in a Python script"'
84+
'print ("--------------------------------------------------------' +
85+
'----------")'
86+
'print ("Errors in a Python script")'
8187
'try:'
82-
' raise spam.EBadPoint, "this is a test !"'
88+
' raise spam.EBadPoint("this is a test !")'
8389
'except:'
8490
' pass'
8591
''
@@ -90,19 +96,21 @@ object Form1: TForm1
9096
' err.c = 3'
9197
' raise err'
9298

93-
'except spam.PointError, what: #it shows you that you can interce' +
94-
'pt a parent class'
95-
' print "Catched an error dirived from PointError"'
99+
'except spam.PointError as what: # this shows that you can interc' +
100+
'ept a parent class'
101+
' print ("Caught an error derived from PointError")'
96102

97-
' print "Error class = ", what.__class__, " a =", what.a, " ' +
98-
' b =", what.b, " c =", what.c'
103+
' print ("Error class = ", what.__class__, " a =", what.a, "' +
104+
' b =", what.b, " c =", what.c)'
99105
''
100-
'if p == spam.Point(2, 5): '
101-
' print "Equal"'
106+
'if p == spam.Point(2, 5):'
107+
' print ("Equal")'
102108
'else:'
103-
' print "Not equal"')
104-
ScrollBars = ssVertical
109+
' print ("Not equal")')
110+
ParentFont = False
111+
ScrollBars = ssBoth
105112
TabOrder = 0
113+
WordWrap = False
106114
end
107115
object Panel1: TPanel
108116
Left = 0
@@ -128,14 +136,17 @@ object Form1: TForm1
128136
Width = 576
129137
Height = 169
130138
Align = alTop
139+
Font.Charset = DEFAULT_CHARSET
140+
Font.Color = clWindowText
141+
Font.Height = -13
142+
Font.Name = 'Consolas'
143+
Font.Pitch = fpVariable
144+
Font.Style = []
145+
ParentFont = False
131146
ScrollBars = ssBoth
132147
TabOrder = 2
133148
end
134149
object PythonEngine1: TPythonEngine
135-
DllName = 'python27.dll'
136-
APIVersion = 1013
137-
RegVersion = '2.7'
138-
UseLastKnownVersion = False
139150
IO = PythonGUIInputOutput1
140151
Left = 32
141152
Top = 16

0 commit comments

Comments
 (0)