-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathForm7.frm
267 lines (258 loc) · 7.43 KB
/
Form7.frm
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
VERSION 5.00
Begin VB.Form Form7
Appearance = 0 'Flat
BackColor = &H80000005&
BorderStyle = 4 'Fixed ToolWindow
Caption = "Text editor"
ClientHeight = 3615
ClientLeft = 45
ClientTop = 285
ClientWidth = 2385
LinkTopic = "Form7"
MaxButton = 0 'False
MinButton = 0 'False
ScaleHeight = 3615
ScaleWidth = 2385
ShowInTaskbar = 0 'False
StartUpPosition = 3 'Windows Default
Begin VB.PictureBox Picture3
Appearance = 0 'Flat
BackColor = &H80000018&
ForeColor = &H80000008&
Height = 3615
Left = 0
ScaleHeight = 3585
ScaleWidth = 2355
TabIndex = 0
Top = 0
Width = 2380
Begin VB.PictureBox Picture4
BackColor = &H00000000&
Height = 255
Left = 60
ScaleHeight = 195
ScaleWidth = 555
TabIndex = 12
Top = 3240
Width = 615
End
Begin VB.ComboBox Combo3
BackColor = &H00FFFFFF&
Height = 315
Left = 1560
TabIndex = 11
Top = 2400
Width = 735
End
Begin VB.OptionButton Option1
Height = 375
Index = 0
Left = 60
Picture = "Form7.frx":0000
Style = 1 'Graphical
TabIndex = 10
Top = 2760
Width = 375
End
Begin VB.ComboBox Combo2
Appearance = 0 'Flat
BackColor = &H00FFFFFF&
Height = 315
Left = 60
TabIndex = 9
Text = "Arial"
Top = 2400
Width = 1455
End
Begin VB.TextBox Text1
Height = 1695
Left = 60
MultiLine = -1 'True
ScrollBars = 2 'Vertical
TabIndex = 8
Top = 600
Width = 2235
End
Begin VB.PictureBox Picture5
BackColor = &H00000000&
Height = 255
Left = 1680
ScaleHeight = 195
ScaleWidth = 555
TabIndex = 7
Top = 3240
Width = 615
End
Begin VB.OptionButton Option1
Height = 375
Index = 2
Left = 420
Picture = "Form7.frx":03FA
Style = 1 'Graphical
TabIndex = 6
Top = 2760
Width = 375
End
Begin VB.OptionButton Option1
Height = 375
Index = 1
Left = 780
Picture = "Form7.frx":0644
Style = 1 'Graphical
TabIndex = 5
Top = 2760
Width = 375
End
Begin VB.CheckBox Check1
Height = 375
Left = 1200
Picture = "Form7.frx":088E
Style = 1 'Graphical
TabIndex = 4
Top = 2760
Width = 375
End
Begin VB.CheckBox Check2
Height = 375
Left = 1560
Picture = "Form7.frx":0A5C
Style = 1 'Graphical
TabIndex = 3
Top = 2760
Width = 375
End
Begin VB.CheckBox Check3
Height = 375
Left = 1920
Picture = "Form7.frx":0CAE
Style = 1 'Graphical
TabIndex = 2
Top = 2760
Width = 375
End
Begin VB.CheckBox Check4
Caption = "Opaque"
Height = 255
Left = 600
Style = 1 'Graphical
TabIndex = 1
Top = 3240
Width = 1095
End
Begin VB.Label Label4
AutoSize = -1 'True
BackStyle = 0 'Transparent
Caption = "Write your text here."
Height = 195
Left = 120
TabIndex = 14
Top = 360
Width = 1425
End
Begin VB.Label Label3
BackColor = &H00800000&
Caption = " Text editing"
BeginProperty Font
Name = "MS Sans Serif"
Size = 8.25
Charset = 0
Weight = 400
Underline = -1 'True
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
ForeColor = &H00FFFFFF&
Height = 255
Left = 0
TabIndex = 13
Top = 0
Width = 2415
End
End
End
Attribute VB_Name = "Form7"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Private Sub Check4_Click()
On Error Resume Next
Form1.Label1(Text1.Tag).BackStyle = Check4.Value
End Sub
Private Sub Form_Load()
On Error Resume Next
Dim i As Integer
For i = 0 To Screen.FontCount - 1
Form7.Combo2.AddItem Screen.Fonts(i)
Next i
For i = 1 To 120
Form7.Combo3.AddItem i
Next i
End Sub
Private Sub Picture5_Click()
On Error GoTo er
MDI.CommonDialog1.ShowColor
Picture5.BackColor = MDI.CommonDialog1.Color
Form1.Label1(Text1.Tag).BackColor = Picture5.BackColor
Exit Sub
er:
If Err.Number <> 32755 Then
MsgBox Err.Description
End If
End Sub
Private Sub Picture4_Click()
On Error GoTo er
MDI.CommonDialog1.ShowColor
Picture4.BackColor = MDI.CommonDialog1.Color
Form1.Label1(Text1.Tag).ForeColor = Picture4.BackColor
Exit Sub
er:
If Err.Number <> 32755 Then
MsgBox Err.Description
End If
End Sub
Private Sub Combo2_Click()
On Error Resume Next
Form1.Label1(Text1.Tag).FontName = Combo2.Text
changes = True
End Sub
Private Sub Combo3_Click()
On Error Resume Next
Form1.Label1(Text1.Tag).FontSize = Combo3.Text
changes = True
End Sub
Private Sub Combo4_Click()
On Error Resume Next
Form1.Shape1(Picture7.Tag).BorderStyle = Combo4.ListIndex
End Sub
Private Sub Check1_Click()
On Error Resume Next
Form1.Label1(Text1.Tag).FontBold = (Check1.Value <> 0)
End Sub
Private Sub Check2_Click()
On Error Resume Next
Form1.Label1(Text1.Tag).FontItalic = (Check2.Value <> 0)
End Sub
Private Sub Check3_Click()
On Error Resume Next
Form1.Label1(Text1.Tag).FontUnderline = (Check3.Value <> 0)
changes = True
End Sub
Private Sub Option1_Click(Index As Integer)
On Error Resume Next
For i = 0 To 2
If Option1(i).Value = True Then
Form1.Label1(Text1.Tag).Alignment = i
End If
Next i
End Sub
Private Sub Text1_Change()
On Error Resume Next
Form1.Label1(Text1.Tag).Caption = Text1.Text
changes = True
If Text1.ForeColor = vbWhite Then
Text1.BackColor = vblack
Else
Text1.BackColor = vbWhite
End If
End Sub