/
MainForm.lfm
548 lines (548 loc) · 15.5 KB
/
MainForm.lfm
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
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
object Form1: TForm1
Left = 640
Height = 878
Top = 392
Width = 1112
Caption = 'Image Knife'
ClientHeight = 844
ClientWidth = 1112
Color = clBtnFace
DesignTimePPI = 168
Font.CharSet = GREEK_CHARSET
Font.Color = clWindowText
Font.Height = -16
Font.Name = 'Tahoma'
Menu = MainMenu1
OnCreate = FormCreate
OnDestroy = FormDestroy
LCLVersion = '1.8.0.6'
object Splitter1: TSplitter
Left = 185
Height = 736
Top = 65
Width = 3
end
object Panel2: TPanel
Left = 0
Height = 736
Top = 65
Width = 185
Align = alLeft
ClientHeight = 736
ClientWidth = 185
TabOrder = 2
object Splitter2: TSplitter
Cursor = crVSplit
Left = 1
Height = 3
Top = 249
Width = 183
Align = alTop
ResizeAnchor = akTop
end
object TreeView1: TTreeView
Left = 1
Height = 248
Top = 1
Width = 183
Align = alTop
Indent = 19
PopupMenu = popSlice
RightClickSelect = True
RowSelect = True
TabOrder = 0
OnChange = TreeView1Change
OnEdited = TreeView1Edited
Options = [tvoAutoItemHeight, tvoHideSelection, tvoKeepCollapsedNodes, tvoRightClickSelect, tvoRowSelect, tvoShowButtons, tvoShowLines, tvoShowRoot, tvoToolTips, tvoThemedDraw]
end
object Memo1: TMemo
Left = 30
Height = 73
Top = 310
Width = 129
Lines.Strings = (
'Memo1'
)
TabOrder = 1
Visible = False
end
object Panel3: TPanel
Left = 1
Height = 483
Top = 252
Width = 183
Align = alClient
ClientHeight = 483
ClientWidth = 183
TabOrder = 2
object Label1: TLabel
Left = 22
Height = 19
Top = 30
Width = 38
Caption = 'Color'
ParentColor = False
end
object lblSingleColor: TLabel
Left = 54
Height = 17
Top = 30
Width = 31
AutoSize = False
Color = clWhite
ParentColor = False
Transparent = False
end
object btnPickSingleColor: TSpeedButton
Left = 86
Height = 22
Hint = 'Pick from image'
Top = 30
Width = 23
Flat = True
Glyph.Data = {
76010000424D7601000000000000760000002800000020000000100000000100
04000000000000010000120B0000120B00001000000000000000000000000000
800000800000008080008000000080008000808000007F7F7F00BFBFBF000000
FF0000FF000000FFFF00FF000000FF00FF00FFFF0000FFFFFF00559999999995
5555557777777775F5555559999999505555555777777757FFF5555555555550
0955555555555FF7775F55555555995501955555555577557F75555555555555
01995555555555557F5755555555555501905555555555557F57555555555555
0F905555555555557FF75555555555500005555555555557777555555555550F
F05555555555557F57F5555555555008F05555555555F775F755555555570000
05555555555775577555555555700007555555555F755F775555555570000755
55555555775F77555555555700075555555555F75F7755555555570007555555
5555577F77555555555500075555555555557777555555555555
}
NumGlyphs = 2
ShowHint = True
ParentShowHint = False
end
object Label3: TLabel
Left = 6
Height = 19
Top = 86
Width = 47
Caption = 'VAlign'
ParentColor = False
end
object chkSingleColor: TCheckBox
Left = 6
Height = 33
Top = 6
Width = 120
Caption = 'Single Color'
OnClick = chkSingleColorClick
TabOrder = 0
end
object chkBackground: TCheckBox
Left = 6
Height = 33
Top = 62
Width = 192
Caption = 'Render as background'
OnClick = chkBackgroundClick
TabOrder = 1
end
object cmbVAlign: TComboBox
Left = 38
Height = 21
Top = 86
Width = 121
ItemHeight = 19
Items.Strings = (
''
'top'
'bottom'
'middle'
)
OnChange = cmbVAlignChange
Style = csDropDownList
TabOrder = 2
end
object btnRefreshWidth: TBitBtn
Left = 140
Height = 25
Hint = 'Refresh Width'
Top = 6
Width = 33
Glyph.Data = {
76010000424D7601000000000000760000002800000020000000100000000100
04000000000000010000120B0000120B00001000000000000000000000000000
800000800000008080008000000080008000808000007F7F7F00BFBFBF000000
FF0000FF000000FFFF00FF000000FF00FF00FFFF0000FFFFFF00555555550555
555555555555F55555555505555B0555570555F55557F55555F55B50555B0555
7B55575F5557F555575555B5055B5557B5555575F55755557555555B5550005B
55555557555FFF575555555555BBB0055555555555777FF5555555555BBBBB00
55555555577777FF55555000BBBBBBB050005FFF7777777F5FFFBBB5BBBBBBB0
BBB577757777777F77755555BBBBBBB55555555577777775555555555BBBBB55
55555555577777555555555705BBB55505555555F5777555F555557B5555055B
505555575555F5575F5557B5555B0555B50555755557F55575F55B55555B0555
5B5557555557F55557555555555B555555555555555755555555
}
ModalResult = 1
NumGlyphs = 2
OnClick = btnRefreshWidthClick
ParentShowHint = False
ShowHint = True
TabOrder = 3
end
object StringGrid1: TStringGrid
Left = 0
Height = 120
Top = 118
Width = 185
ColCount = 2
DefaultColWidth = 80
DefaultRowHeight = 16
FixedRows = 0
Options = [goFixedVertLine, goFixedHorzLine, goVertLine, goHorzLine, goEditing]
TabOrder = 4
TitleFont.CharSet = GREEK_CHARSET
TitleFont.Color = clWindowText
TitleFont.Height = -28
TitleFont.Name = 'Tahoma'
OnSetEditText = StringGrid1SetEditText
end
end
end
object StatusBar1: TStatusBar
Left = 0
Height = 43
Top = 801
Width = 1112
Panels = <>
end
object Panel1: TPanel
Left = 0
Height = 41
Top = 0
Width = 1112
Align = alTop
ClientHeight = 41
ClientWidth = 1112
ParentShowHint = False
ShowHint = True
TabOrder = 0
object btnExport: TSpeedButton
Left = 86
Height = 22
Hint = 'Export'
Top = 6
Width = 23
Glyph.Data = {
76010000424D7601000000000000760000002800000020000000100000000100
04000000000000010000130B0000130B00001000000000000000000000000000
800000800000008080008000000080008000808000007F7F7F00BFBFBF000000
FF0000FF000000FFFF00FF000000FF00FF00FFFF0000FFFFFF00333333330070
7700333333337777777733333333008088003333333377F73377333333330088
88003333333377FFFF7733333333000000003FFFFFFF77777777000000000000
000077777777777777770FFFFFFF0FFFFFF07F3333337F3333370FFFFFFF0FFF
FFF07F3FF3FF7FFFFFF70F00F0080CCC9CC07F773773777777770FFFFFFFF039
99337F3FFFF3F7F777F30F0000F0F09999937F7777373777777F0FFFFFFFF999
99997F3FF3FFF77777770F00F000003999337F773777773777F30FFFF0FF0339
99337F3FF7F3733777F30F08F0F0337999337F7737F73F7777330FFFF0039999
93337FFFF7737777733300000033333333337777773333333333
}
NumGlyphs = 2
OnClick = mnuFileExportClick
end
object SpeedButton3: TSpeedButton
Left = 6
Height = 22
Hint = 'New'
Top = 6
Width = 23
Glyph.Data = {
76010000424D7601000000000000760000002800000020000000100000000100
04000000000000010000130B0000130B00001000000000000000000000000000
800000800000008080008000000080008000808000007F7F7F00BFBFBF000000
FF0000FF000000FFFF00FF000000FF00FF00FFFF0000FFFFFF0033333333B333
333B33FF33337F3333F73BB3777BB7777BB3377FFFF77FFFF77333B000000000
0B3333777777777777333330FFFFFFFF07333337F33333337F333330FFFFFFFF
07333337F33333337F333330FFFFFFFF07333337F33333337F333330FFFFFFFF
07333FF7F33333337FFFBBB0FFFFFFFF0BB37777F3333333777F3BB0FFFFFFFF
0BBB3777F3333FFF77773330FFFF000003333337F333777773333330FFFF0FF0
33333337F3337F37F3333330FFFF0F0B33333337F3337F77FF333330FFFF003B
B3333337FFFF77377FF333B000000333BB33337777777F3377FF3BB3333BB333
3BB33773333773333773B333333B3333333B7333333733333337
}
NumGlyphs = 2
OnClick = mnuFileNewClick
end
object SpeedButton4: TSpeedButton
Left = 30
Height = 22
Hint = 'Open'
Top = 6
Width = 23
Glyph.Data = {
76010000424D7601000000000000760000002800000020000000100000000100
04000000000000010000120B0000120B00001000000000000000000000000000
800000800000008080008000000080008000808000007F7F7F00BFBFBF000000
FF0000FF000000FFFF00FF000000FF00FF00FFFF0000FFFFFF00555555555555
5555555555555555555555555555555555555555555555555555555555555555
555555555555555555555555555555555555555FFFFFFFFFF555550000000000
55555577777777775F55500B8B8B8B8B05555775F555555575F550F0B8B8B8B8
B05557F75F555555575F50BF0B8B8B8B8B0557F575FFFFFFFF7F50FBF0000000
000557F557777777777550BFBFBFBFB0555557F555555557F55550FBFBFBFBF0
555557F555555FF7555550BFBFBF00055555575F555577755555550BFBF05555
55555575FFF75555555555700007555555555557777555555555555555555555
5555555555555555555555555555555555555555555555555555
}
NumGlyphs = 2
OnClick = mnuFileOpenClick
end
object SpeedButton5: TSpeedButton
Left = 54
Height = 22
Hint = 'Save'
Top = 6
Width = 23
Glyph.Data = {
76010000424D7601000000000000760000002800000020000000100000000100
04000000000000010000120B0000120B00001000000000000000000000000000
800000800000008080008000000080008000808000007F7F7F00BFBFBF000000
FF0000FF000000FFFF00FF000000FF00FF00FFFF0000FFFFFF00333333333333
333333FFFFFFFFFFFFF33000077777770033377777777777773F000007888888
00037F3337F3FF37F37F00000780088800037F3337F77F37F37F000007800888
00037F3337F77FF7F37F00000788888800037F3337777777337F000000000000
00037F3FFFFFFFFFFF7F00000000000000037F77777777777F7F000FFFFFFFFF
00037F7F333333337F7F000FFFFFFFFF00037F7F333333337F7F000FFFFFFFFF
00037F7F333333337F7F000FFFFFFFFF00037F7F333333337F7F000FFFFFFFFF
00037F7F333333337F7F000FFFFFFFFF07037F7F33333333777F000FFFFFFFFF
0003737FFFFFFFFF7F7330099999999900333777777777777733
}
NumGlyphs = 2
OnClick = mnuFileSaveClick
end
object btnAutoName: TButton
Left = 342
Height = 25
Top = 6
Width = 118
Caption = 'Auto Name'
OnClick = btnAutoNameClick
TabOrder = 0
end
object tbCompression: TTrackBar
Left = 660
Height = 25
Hint = 'png compression level'
Top = 6
Width = 81
Max = 9
Position = 0
ParentShowHint = False
ShowHint = True
TabOrder = 1
end
object btnScan1: TButton
Left = 118
Height = 29
Top = 6
Width = 223
Caption = 'Scan For Single Color Areas'
OnClick = btnScan1Click
TabOrder = 2
end
end
object ScrollBox1: TScrollBox
Left = 188
Height = 736
Top = 65
Width = 924
HorzScrollBar.Page = 559
VertScrollBar.Page = 537
Align = alClient
ClientHeight = 732
ClientWidth = 920
TabOrder = 3
object PaintBox1: TPaintBox
Left = 0
Height = 537
Top = 0
Width = 559
OnMouseMove = PaintBox1MouseMove
OnMouseUp = PaintBox1MouseUp
OnPaint = PaintBox1Paint
end
end
object Panel4: TPanel
Left = 0
Height = 24
Top = 41
Width = 1112
Align = alTop
ClientHeight = 24
ClientWidth = 1112
ParentShowHint = False
ShowHint = True
TabOrder = 4
object btnSelector: TSpeedButton
Left = 6
Height = 23
Hint = 'Select'
Top = 0
Width = 45
Caption = 'Select'
Down = True
Flat = True
GroupIndex = 1
OnClick = btnSelectorClick
end
object SpeedButton1: TSpeedButton
Left = 180
Height = 23
Top = 0
Width = 106
Caption = 'Horizontal line'
Flat = True
GroupIndex = 1
OnClick = SpeedButton1Click
end
object SpeedButton2: TSpeedButton
Left = 300
Height = 23
Top = 0
Width = 86
Caption = 'Vertical line'
Flat = True
GroupIndex = 1
OnClick = SpeedButton2Click
end
object btnSelectParents: TSpeedButton
Left = 62
Height = 23
Hint = 'Select Parents'
Top = 0
Width = 102
Caption = 'Select Parents'
Flat = True
GroupIndex = 1
OnClick = btnSelectParentsClick
end
object btnGroup: TSpeedButton
Left = 540
Height = 23
Hint = 'Group Continuous Rects'
Top = 0
Width = 116
Caption = 'Group Selection'
Flat = True
OnClick = btnGroupClick
end
object chkAcross: TCheckBox
Left = 400
Height = 33
Top = 0
Width = 115
Caption = 'Slice across'
TabOrder = 0
end
end
object OpenPictureDialog1: TOpenPictureDialog
Options = [ofHideReadOnly, ofPathMustExist, ofFileMustExist, ofEnableSizing]
left = 120
top = 192
end
object SaveDialog1: TSaveDialog
DefaultExt = '.html'
Filter = 'HTML Files|*.html'
Options = [ofOverwritePrompt, ofHideReadOnly, ofEnableSizing]
left = 88
top = 192
end
object MainMenu1: TMainMenu
left = 120
top = 224
object mnuFile: TMenuItem
Caption = '&File'
object mnuFileNew: TMenuItem
Caption = 'New...'
ShortCut = 16462
OnClick = mnuFileNewClick
end
object mnuFileOpen: TMenuItem
Caption = 'Open...'
ShortCut = 16463
OnClick = mnuFileOpenClick
end
object mnuFileSave: TMenuItem
Caption = 'Save'
ShortCut = 16467
OnClick = mnuFileSaveClick
end
object mnuFileSaveAs: TMenuItem
Caption = 'Save As...'
OnClick = mnuFileSaveAsClick
end
object mnuFileClose: TMenuItem
Caption = 'Close'
ShortCut = 16471
end
object N1: TMenuItem
Caption = '-'
end
object mnuFileExport: TMenuItem
Caption = 'Export...'
OnClick = mnuFileExportClick
end
object N2: TMenuItem
Caption = '-'
end
object mnuFileExit: TMenuItem
Caption = 'Exit'
ShortCut = 16472
OnClick = mnuFileExitClick
end
end
object mnuView: TMenuItem
Caption = 'View'
object mnuViewRefresh: TMenuItem
Caption = 'Refresh'
ShortCut = 116
OnClick = mnuViewRefreshClick
end
object N3: TMenuItem
Caption = '-'
end
object mnuViewZoomIn: TMenuItem
Caption = 'Zoom In'
ShortCut = 16571
OnClick = mnuViewZoomInClick
end
object mnuViewZoomOut: TMenuItem
Caption = 'Zoom Out'
ShortCut = 16573
OnClick = mnuViewZoomOutClick
end
object mnuViewZoomNormal: TMenuItem
Caption = '1:1'
ShortCut = 49230
OnClick = mnuViewZoomNormalClick
end
end
end
object saveKnife: TSaveDialog
DefaultExt = '.xml'
Filter = 'Image knife document|*.xml'
Options = [ofOverwritePrompt, ofHideReadOnly, ofEnableSizing]
left = 24
top = 224
end
object openKnife: TOpenDialog
DefaultExt = '.xml'
Filter = 'Image knife document|*.xml'
Options = [ofHideReadOnly, ofPathMustExist, ofFileMustExist, ofEnableSizing]
left = 56
top = 224
end
object popSlice: TPopupMenu
left = 88
top = 224
object Deleteslice1: TMenuItem
Caption = 'Delete slice'
end
end
end