changeset 398 | 155310ec83aa |
parent 382 | 2a46018227a1 |
child 406 | a519e0d547f6 |
397:be1357e3bf7f | 398:155310ec83aa |
---|---|
10 hereby transferred. |
10 hereby transferred. |
11 " |
11 " |
12 |
12 |
13 |
13 |
14 |
14 |
15 ApplicationModel subclass:#MenuEditor |
15 ToolApplicationModel subclass:#MenuEditor |
16 instanceVariableNames:'isModified specClass specCanvas helpCanvas tabSelection aspects |
16 instanceVariableNames:'isModified specClass specCanvas helpCanvas tabSelection aspects |
17 slices didInstall' |
17 slices didInstall' |
18 classVariableNames:'' |
18 classVariableNames:'' |
19 poolDictionaries:'' |
19 poolDictionaries:'' |
20 category:'Interface-UIPainter' |
20 category:'Interface-UIPainter' |
21 ! |
21 ! |
22 |
22 |
23 Object subclass:#Item |
23 Object subclass:#Item |
24 instanceVariableNames:'activeHelpKey enabled label value nameKey indication shortcutKey |
24 instanceVariableNames:'activeHelpKey enabled label value nameKey indication shortcutKey |
25 accessCharaterPos retriever icon iconAndLabel submenuChannel |
25 accessCharaterPos retriever icon iconAndLabel submenuChannel |
26 argument' |
26 argument translateLabel isButton' |
27 classVariableNames:'' |
27 classVariableNames:'' |
28 poolDictionaries:'' |
28 poolDictionaries:'' |
29 privateIn:MenuEditor |
29 privateIn:MenuEditor |
30 ! |
30 ! |
31 |
31 |
68 UIHelpTool |
68 UIHelpTool |
69 UISpecificationTool |
69 UISpecificationTool |
70 SelectionInTreeView |
70 SelectionInTreeView |
71 |
71 |
72 [author:] |
72 [author:] |
73 Claus Atzkern |
73 Claus Atzkern, Thomas Zwick |
74 " |
74 " |
75 |
75 |
76 ! ! |
76 ! ! |
77 |
77 |
78 !MenuEditor class methodsFor:'code generation'! |
78 !MenuEditor class methodsFor:'code generation'! |
119 " |
119 " |
120 |
120 |
121 ^ super helpSpec addPairsFrom:#( |
121 ^ super helpSpec addPairsFrom:#( |
122 |
122 |
123 #accessCharaterPos |
123 #accessCharaterPos |
124 'the index of the access character position into the textual label (optional).' |
124 'The index of the access character position |
125 into the textual label (optional).' |
|
125 |
126 |
126 #argument |
127 #argument |
127 'an argument passed to the value method, if the value selector is a one- or two-arg selector (i.e. ends with '':''). The argument is passed as a string.' |
128 'An argument passed to the value method, if the value |
129 selector is a one- or two-arg selector (i.e. ends with '':''). |
|
130 The argument is passed as a string.' |
|
128 |
131 |
129 #enbled |
132 #enbled |
130 'This enabled field specifies the name of the aspect (-method or binding) in your application, which returns a valueHolder holding a boolean, a block which evaluates to either true or false, a selector which returns either true or false or simply true or false.\ The value, true or false, specifies whether the respective field can be selected, a value of true, or not, a value of false.' |
133 'This enabled field specifies the name of the aspect (-method or binding) |
134 in your application, which returns a value holder holding a boolean, |
|
135 a block which evaluates to either true or false, a selector which returns |
|
136 either true or false or simply true or false. The value, true or false, |
|
137 specifies whether the respective field can be selected, a value of true, |
|
138 or not, a value of false.' |
|
131 |
139 |
132 #icon |
140 #icon |
133 'selector which returns the bitmap to be displayed.' |
141 'Selector which returns an image to be displayed.' |
134 |
142 |
135 #iconAndLabel |
143 #iconAndLabel |
136 'boolean flag to specify that both the bitmap and textual label shall be shown.' |
144 'Boolean flag to specify that both image and textual label shall be shown.' |
137 |
145 |
138 #indication |
146 #indication |
139 'This indication field specifies the name of the aspect (-method or binding) in your application, a valueHolder holding a boolean, a block which evaluates to either true or false, a selector which returns either true or false or simply true or false.\ The value, true or false, specifies whether the shown indicator is switched on or off.' |
147 'This indication field specifies the name of the aspect (-method or binding) |
148 in your application, a value holder holding a boolean, a block which evaluates |
|
149 to either true or false, a selector which returns either true or false or |
|
150 simply true or false. The value, true or false, specifies whether the shown |
|
151 indicator is switched on or off.' |
|
140 |
152 |
141 #label |
153 #label |
142 'the label of the item. If the ''retriever/icon'' is set, and returns a bitmap image, the bitmap is used as the displayed label. Dependent on the state of the ''Icon & Label'' flag, both the bitmap and the label are shown.' |
154 'The label of the item. If the ''retriever/selector'' is set, |
155 and returns an image, the image is used as the displayed label. |
|
156 Dependent on the state of the ''Image & Label'' flag, both |
|
157 the image and the label are shown.' |
|
143 |
158 |
144 #menuSelector |
159 #menuSelector |
145 'the name of the selector under which the generated menu should be installed and is accessable.' |
160 'The name of the selector under which the generated |
161 menu should be installed and is accessable.' |
|
146 |
162 |
147 #nameKey |
163 #nameKey |
148 'a unique identifier of the item (optional)' |
164 'An unique identifier of the item (optional)' |
149 |
165 |
150 #retriever |
166 #retriever |
151 'the name of the class, which implements the bitmap selector. This selector is specified by ''icon''. If no class is given, the current application should implement the specified bitmap selector.' |
167 'The name of the class, which implements the image selector. |
168 This selector is specified by ''selector''. If no class is given, |
|
169 the current application should implement the specified image selector.' |
|
152 |
170 |
153 #seperatorList |
171 #seperatorList |
154 'the list of valid separators' |
172 'The list of valid separators' |
155 |
173 |
156 #shortcutKey |
174 #shortcutKey |
157 'the key to be pressed, to select the menu item from the keyboard (accelerator key).' |
175 'The key to be pressed, to select the menu item from the keyboard (accelerator key).' |
158 |
176 |
159 #submenuChannel |
177 #submenuChannel |
160 'a value holder, which provides the submenu (Menu) to be opened if the item is selected. Useful if the items submenu is to be changed dynamically.' |
178 'A value holder, which provides the submenu (Menu) to be opened |
179 if the item is selected. Useful if the items submenu is to be |
|
180 changed dynamically.' |
|
161 |
181 |
162 #value |
182 #value |
163 'An action which can be either a block or a selector.\ Depending on the number of arguments to the action, the action will be called with the respective arguments. There can either zero, one or two arguments. The first argument to the action is the argument derived from the argument field and the second argument the selected item.' |
183 'An action which can be either a block or a selector. Depending on the number |
184 of arguments to the action, the action will be called with the respective arguments. |
|
185 There can either zero, one or two arguments. The first argument to the action is the |
|
186 argument derived from the argument field and the second argument the selected item.' |
|
164 |
187 |
165 ) |
188 ) |
166 ! ! |
189 ! ! |
167 |
190 |
168 !MenuEditor class methodsFor:'icons'! |
191 !MenuEditor class methodsFor:'icons'! |
169 |
192 |
170 iconCreateItem |
193 iconCreateItem |
171 ^ Painter imageItem |
194 ^ Painter menuItemImage |
172 |
195 |
173 ! |
196 ! |
174 |
197 |
175 iconCreateLink |
198 iconCreateLink |
176 ^ Painter imageMenuLink |
199 ^ Painter linkSubmenuImage |
177 |
200 |
178 ! |
201 ! |
179 |
202 |
180 iconCreateMenu |
203 iconCreateMenu |
181 ^ Painter imageMenu |
204 ^ Painter closedSubmenuImage |
182 |
|
183 "Modified: 28.7.1997 / 10:02:21 / cg" |
|
184 ! |
205 ! |
185 |
206 |
186 iconCreateSep |
207 iconCreateSep |
187 ^ Painter imageSeparator |
208 ^ Painter menuSeparatorImage |
188 |
209 |
189 ! |
210 ! |
190 |
211 |
191 iconUnknown |
212 iconUnknown |
192 "returns an image used for picked items containing an image |
213 "returns an image used for picked items containing an image |
217 ^ |
238 ^ |
218 |
239 |
219 #(#FullSpec |
240 #(#FullSpec |
220 #'window:' |
241 #'window:' |
221 #(#WindowSpec |
242 #(#WindowSpec |
222 #'name:' 'ClassAndMethodSpec' |
243 #'name:' 'MenuEditor' |
223 #'layout:' #(#LayoutFrame 0 0.0 0 0.0 0 1.0 0 1.0) |
244 #'layout:' #(#LayoutFrame 197 0 172 0 552 0 258 0) |
224 #'label:' 'Painter' |
245 #'label:' 'MenuEditor' |
225 #'bounds:' #(#Rectangle 0 0 391 170) |
246 #'min:' #(#Point 10 10) |
247 #'max:' #(#Point 1152 900) |
|
248 #'bounds:' #(#Rectangle 197 172 553 259) |
|
249 #'usePreferredExtent:' false |
|
226 ) |
250 ) |
227 #'component:' |
251 #'component:' |
228 #(#SpecCollection |
252 #(#SpecCollection |
229 #'collection:' |
253 #'collection:' |
230 #( |
254 #( |
231 #(#LabelSpec |
255 #(#LabelSpec |
232 #'name:' 'classLabel' |
256 #'name:' 'classLabel' |
233 #'layout:' #(#AlignmentOrigin 45 0.11 51 0 1 0.5) |
257 #'layout:' #(#LayoutFrame 0 0.0 4 0 150 0 21 0) |
234 #'label:' 'class:' |
258 #'label:' 'Class for menu code:' |
235 #'adjust:' #right |
259 #'adjust:' #right |
236 #'resizeForLabel:' true |
260 #'resizeForLabel:' true |
237 ) |
261 ) |
238 #(#LabelSpec |
262 #(#LabelSpec |
239 #'name:' 'selectorLabel' |
263 #'name:' 'selectorLabel' |
240 #'layout:' #(#AlignmentOrigin 45 0.11 74 0 1 0.5) |
264 #'layout:' #(#LayoutFrame 0 0.0 29 0 150 0 46 0) |
241 #'label:' 'selector:' |
265 #'label:' 'Selector for menu code:' |
242 #'adjust:' #right |
266 #'adjust:' #right |
243 #'resizeForLabel:' true |
267 #'resizeForLabel:' true |
244 ) |
268 ) |
245 #(#InputFieldSpec |
269 #(#InputFieldSpec |
246 #'name:' 'methodNameField' |
270 #'name:' 'methodNameField' |
247 #'layout:' #(#LayoutFrame 47 0.11 64 0 0 1.0 86 0) |
271 #'layout:' #(#LayoutFrame 155 0 27 0 0 1.0 49 0) |
248 #'tabable:' true |
272 #'tabable:' true |
249 #'model:' #methodNameChannel |
273 #'model:' #methodNameChannel |
250 ) |
274 ) |
251 #(#LabelSpec |
|
252 #'name:' 'boxLabel' |
|
253 #'layout:' #(#Point 5 10) |
|
254 #'label:' 'class & selector for code:' |
|
255 #'adjust:' #left |
|
256 #'resizeForLabel:' true |
|
257 ) |
|
258 #(#InputFieldSpec |
275 #(#InputFieldSpec |
259 #'name:' 'classNameField' |
276 #'name:' 'classNameField' |
260 #'layout:' #(#LayoutFrame 47 0.11 39 0 0 1.0 61 0) |
277 #'layout:' #(#LayoutFrame 155 0 2 0 0 1.0 24 0) |
261 #'tabable:' true |
278 #'tabable:' true |
262 #'model:' #classNameChannel |
279 #'model:' #classNameChannel |
263 ) |
280 ) |
264 #(#HorizontalPanelViewSpec |
281 #(#HorizontalPanelViewSpec |
265 #'name:' 'commitPanel' |
282 #'name:' 'commitPanel' |
266 #'layout:' #(#LayoutFrame 0 0.0 -24 1.0 0 1.0 0 1.0) |
283 #'layout:' #(#LayoutFrame 10 0.0 -29 1.0 -10 1.0 -5 1.0) |
267 #'component:' |
284 #'component:' |
268 #(#SpecCollection |
285 #(#SpecCollection |
269 #'collection:' |
286 #'collection:' |
270 #( |
287 #( |
271 #(#ActionButtonSpec |
288 #(#ActionButtonSpec |
272 #'name:' 'button1' |
289 #'name:' 'button1' |
273 #'label:' 'cancel' |
290 #'label:' 'cancel' |
274 #'tabable:' true |
291 #'tabable:' true |
275 #'model:' #cancel |
292 #'model:' #cancel |
276 #'extent:' #(#Point 191 24) |
293 #'extent:' #(#Point 163 24) |
277 ) |
294 ) |
278 #(#ActionButtonSpec |
295 #(#ActionButtonSpec |
279 #'name:' 'button2' |
296 #'name:' 'button2' |
280 #'label:' 'ok' |
297 #'label:' 'ok' |
281 #'tabable:' true |
298 #'tabable:' true |
299 #'model:' #accept |
|
282 #'isDefault:' true |
300 #'isDefault:' true |
283 #'model:' #accept |
301 #'extent:' #(#Point 164 24) |
284 #'extent:' #(#Point 191 24) |
|
285 ) |
302 ) |
286 ) |
303 ) |
287 ) |
304 ) |
288 #'horizontalLayout:' #fitSpace |
305 #'horizontalLayout:' #fitSpace |
289 #'verticalLayout:' #fit |
306 #'verticalLayout:' #fit |
291 #'verticalSpace:' 3 |
308 #'verticalSpace:' 3 |
292 ) |
309 ) |
293 ) |
310 ) |
294 ) |
311 ) |
295 ) |
312 ) |
296 |
|
297 "Modified: 28.7.1997 / 15:40:15 / cg" |
|
298 ! |
313 ! |
299 |
314 |
300 classDefineSpec |
315 classDefineSpec |
301 "this window spec was automatically generated by the ST/X UIPainter" |
316 "this window spec was automatically generated by the ST/X UIPainter" |
302 |
317 |
313 ^ |
328 ^ |
314 |
329 |
315 #(#FullSpec |
330 #(#FullSpec |
316 #'window:' |
331 #'window:' |
317 #(#WindowSpec |
332 #(#WindowSpec |
318 #'name:' 'ClassDefineSpec' |
333 #'name:' 'MenuEditor' |
319 #'layout:' #(#LayoutFrame 0 0.0 0 0.0 0 1.0 0 1.0) |
334 #'layout:' #(#LayoutFrame 197 0 172 0 443 0 265 0) |
320 #'label:' 'Painter' |
335 #'label:' 'MenuEditor' |
321 #'bounds:' #(#Rectangle 0 0 383 128) |
336 #'min:' #(#Point 10 10) |
337 #'max:' #(#Point 1152 900) |
|
338 #'bounds:' #(#Rectangle 197 172 444 266) |
|
339 #'usePreferredExtent:' false |
|
322 ) |
340 ) |
323 #'component:' |
341 #'component:' |
324 #(#SpecCollection |
342 #(#SpecCollection |
325 #'collection:' |
343 #'collection:' |
326 #( |
344 #( |
327 #(#LabelSpec |
345 #(#LabelSpec |
328 #'name:' 'classLabel' |
|
329 #'layout:' #(#AlignmentOrigin 45 0.11 51 0 1 0.5) |
|
330 #'label:' 'class:' |
|
331 #'adjust:' #right |
|
332 #'resizeForLabel:' true |
|
333 ) |
|
334 #(#LabelSpec |
|
335 #'name:' 'boxLabel' |
346 #'name:' 'boxLabel' |
336 #'layout:' #(#Point 5 10) |
347 #'layout:' #(#LayoutFrame 0 0.0 4 0 0 1.0 24 0) |
337 #'label:' 'class for code:' |
348 #'label:' 'Class for menu spec:' |
338 #'adjust:' #left |
349 #'adjust:' #left |
339 #'resizeForLabel:' true |
350 #'resizeForLabel:' true |
340 ) |
351 ) |
341 #(#InputFieldSpec |
352 #(#InputFieldSpec |
342 #'name:' 'classNameField' |
353 #'name:' 'classNameField' |
343 #'layout:' #(#LayoutFrame 47 0.11 39 0 0 1.0 61 0) |
354 #'layout:' #(#LayoutFrame 0 0.0 27 0 0 1.0 49 0) |
344 #'tabable:' true |
355 #'tabable:' true |
345 #'model:' #classNameChannel |
356 #'model:' #classNameChannel |
346 ) |
357 ) |
347 #(#HorizontalPanelViewSpec |
358 #(#HorizontalPanelViewSpec |
348 #'name:' 'commitPanel' |
359 #'name:' 'commitPanel' |
349 #'layout:' #(#LayoutFrame 0 0.0 -24 1.0 0 1.0 0 1.0) |
360 #'layout:' #(#LayoutFrame 10 0.0 -29 1.0 -10 1.0 -5 1.0) |
350 #'component:' |
361 #'component:' |
351 #(#SpecCollection |
362 #(#SpecCollection |
352 #'collection:' |
363 #'collection:' |
353 #( |
364 #( |
354 #(#ActionButtonSpec |
365 #(#ActionButtonSpec |
355 #'name:' 'button1' |
366 #'name:' 'button1' |
356 #'label:' 'cancel' |
367 #'label:' 'Cancel' |
357 #'tabable:' true |
368 #'tabable:' true |
358 #'model:' #cancel |
369 #'model:' #cancel |
359 #'extent:' #(#Point 187 24) |
370 #'extent:' #(#Point 109 24) |
360 ) |
371 ) |
361 #(#ActionButtonSpec |
372 #(#ActionButtonSpec |
362 #'name:' 'button2' |
373 #'name:' 'button2' |
363 #'label:' 'ok' |
374 #'label:' 'OK' |
364 #'tabable:' true |
375 #'tabable:' true |
376 #'model:' #accept |
|
365 #'isDefault:' true |
377 #'isDefault:' true |
366 #'model:' #accept |
378 #'extent:' #(#Point 109 24) |
367 #'extent:' #(#Point 187 24) |
|
368 ) |
379 ) |
369 ) |
380 ) |
370 ) |
381 ) |
371 #'horizontalLayout:' #fitSpace |
382 #'horizontalLayout:' #fitSpace |
372 #'verticalLayout:' #fit |
383 #'verticalLayout:' #fit |
374 #'verticalSpace:' 3 |
385 #'verticalSpace:' 3 |
375 ) |
386 ) |
376 ) |
387 ) |
377 ) |
388 ) |
378 ) |
389 ) |
379 |
390 ! |
380 "Modified: 28.7.1997 / 15:40:39 / cg" |
391 |
381 ! |
392 menu |
382 |
|
383 menuButtons |
|
384 "this window spec was automatically generated by the ST/X MenuEditor" |
393 "this window spec was automatically generated by the ST/X MenuEditor" |
385 |
394 |
386 "do not manually edit this - the builder may not be able to |
395 "do not manually edit this - the builder may not be able to |
387 handle the specification if its corrupted." |
396 handle the specification if its corrupted." |
388 |
397 |
389 " |
398 " |
390 MenuEditor new openOnClass:MenuEditor andSelector:#menuButtons |
399 MenuEditor new openOnClass:MenuEditor andSelector:#menu |
391 (Menu new fromLiteralArrayEncoding:(MenuEditor menuButtons)) startUp |
400 (Menu new fromLiteralArrayEncoding:(MenuEditor menu)) startUp |
392 " |
401 " |
393 |
402 |
394 <resource: #menu> |
403 <resource: #menu> |
395 |
404 |
396 ^ |
405 ^ |
397 |
406 |
398 #(#Menu |
407 #(#Menu |
399 |
408 |
400 #( |
409 #( |
401 #(#MenuItem |
410 #(#MenuItem |
402 #'label:' 'createMenu' |
411 #'label:' 'About' |
403 #'value:' #doCreateMenu |
412 #'accessCharacterPosition:' 1 |
404 #'enabled:' #hasAnySingleSelection |
413 #'labelImage:' #(#ResourceRetriever nil #icon) |
405 #'labelImage:' |
414 #'submenuChannel:' #menuAbout |
406 #(#ResourceRetriever |
415 ) |
407 #MenuEditor #iconCreateMenu |
416 #(#MenuItem |
408 ) |
417 #'label:' 'File' |
409 ) |
418 #'translateLabel:' true |
410 #(#MenuItem |
419 #'value:' #file |
411 #'label:' 'createLink' |
420 #'accessCharacterPosition:' 1 |
412 #'value:' #doCreateLink |
|
413 #'enabled:' #hasAnySingleSelection |
|
414 #'labelImage:' |
|
415 #(#ResourceRetriever |
|
416 #MenuEditor #iconCreateLink |
|
417 ) |
|
418 ) |
|
419 #(#MenuItem |
|
420 #'label:' 'createItem' |
|
421 #'value:' #doCreateItem |
|
422 #'enabled:' #hasAnySingleSelection |
|
423 #'labelImage:' |
|
424 #(#ResourceRetriever |
|
425 #MenuEditor #iconCreateItem |
|
426 ) |
|
427 ) |
|
428 #(#MenuItem |
|
429 #'label:' 'createSeparator' |
|
430 #'value:' #doCreateSep |
|
431 #'enabled:' #hasAnySingleSelection |
|
432 #'labelImage:' |
|
433 #(#ResourceRetriever |
|
434 #MenuEditor #iconCreateSep |
|
435 ) |
|
436 ) |
|
437 #(#MenuItem |
|
438 #'label:' '' |
|
439 ) |
|
440 #(#MenuItem |
|
441 #'label:' 'stepUp' |
|
442 #'value:' #doStepUp |
|
443 #'enabled:' #enabledStepOver |
|
444 #'labelImage:' |
|
445 #(#ResourceRetriever |
|
446 #UIPainter #iconStepUp |
|
447 ) |
|
448 ) |
|
449 #(#MenuItem |
|
450 #'label:' 'stepDown' |
|
451 #'value:' #doStepDown |
|
452 #'enabled:' #enabledStepOver |
|
453 #'labelImage:' |
|
454 #(#ResourceRetriever |
|
455 #UIPainter #iconStepDown |
|
456 ) |
|
457 ) |
|
458 #(#MenuItem |
|
459 #'label:' 'stepIn' |
|
460 #'value:' #doStepIn |
|
461 #'enabled:' #enabledStepIn |
|
462 #'labelImage:' |
|
463 #(#ResourceRetriever |
|
464 #UIPainter #iconStepIn |
|
465 ) |
|
466 ) |
|
467 #(#MenuItem |
|
468 #'label:' 'stepOut' |
|
469 #'value:' #doStepOut |
|
470 #'enabled:' #enabledStepOut |
|
471 #'labelImage:' |
|
472 #(#ResourceRetriever |
|
473 #UIPainter #iconStepOut |
|
474 ) |
|
475 ) |
|
476 ) nil |
|
477 nil |
|
478 ) |
|
479 ! |
|
480 |
|
481 menuDefaultLink |
|
482 "this window spec was automatically generated by the ST/X MenuEditor" |
|
483 |
|
484 "do not manually edit this - the builder may not be able to |
|
485 handle the specification if its corrupted." |
|
486 |
|
487 " |
|
488 MenuEditor new openOnClass:MenuEditor andSelector:#menuDefaultLink |
|
489 (Menu new fromLiteralArrayEncoding:(MenuEditor menuDefaultLink)) startUp |
|
490 " |
|
491 |
|
492 <resource: #menu> |
|
493 |
|
494 ^ |
|
495 |
|
496 #(#Menu |
|
497 |
|
498 #( |
|
499 #(#MenuItem |
|
500 #'label:' '!! derives from application !!' |
|
501 ) |
|
502 ) nil |
|
503 nil |
|
504 ) |
|
505 ! |
|
506 |
|
507 menuPainter |
|
508 "this window spec was automatically generated by the ST/X MenuEditor" |
|
509 |
|
510 "do not manually edit this - the builder may not be able to |
|
511 handle the specification if its corrupted." |
|
512 |
|
513 " |
|
514 MenuEditor new openOnClass:MenuEditor andSelector:#menuPainter |
|
515 (Menu new fromLiteralArrayEncoding:(MenuEditor menuPainter)) startUp |
|
516 " |
|
517 |
|
518 <resource: #menu> |
|
519 |
|
520 ^ |
|
521 |
|
522 #(#Menu |
|
523 |
|
524 #( |
|
525 #(#MenuItem |
|
526 #'label:' 'copy' |
|
527 #'value:' #doCopy |
|
528 #'enabled:' #hasValidSelection |
|
529 #'shortcutKeyCharacter:' #Copy |
|
530 ) |
|
531 #(#MenuItem |
|
532 #'label:' 'cut' |
|
533 #'value:' #doCut |
|
534 #'enabled:' #hasValidSelection |
|
535 #'shortcutKeyCharacter:' #Cut |
|
536 ) |
|
537 #(#MenuItem |
|
538 #'label:' 'paste' |
|
539 #'value:' #doPaste |
|
540 #'enabled:' #hasAnySingleSelection |
|
541 #'shortcutKeyCharacter:' #Paste |
|
542 ) |
|
543 #(#MenuItem |
|
544 #'label:' '-' |
|
545 ) |
|
546 #(#MenuItem |
|
547 #'label:' 'create' |
|
548 #'enabled:' #hasAnySingleSelection |
|
549 #'submenu:' |
421 #'submenu:' |
550 #(#Menu |
422 #(#Menu |
551 |
423 |
552 #( |
424 #( |
553 #(#MenuItem |
425 #(#MenuItem |
554 #'label:' 'submenu static' |
426 #'label:' 'New' |
555 #'value:' #doCreateMenu |
|
556 #'labelImage:' |
|
557 #(#ResourceRetriever |
|
558 #MenuEditor #iconCreateMenu |
|
559 'submenu static' |
|
560 ) |
|
561 ) |
|
562 #(#MenuItem |
|
563 #'label:' 'submenu dynamic' |
|
564 #'value:' #doCreateLink |
|
565 #'labelImage:' |
|
566 #(#ResourceRetriever |
|
567 #MenuEditor #iconCreateLink |
|
568 'submenu dynamic' |
|
569 ) |
|
570 ) |
|
571 #(#MenuItem |
|
572 #'label:' '-' |
|
573 ) |
|
574 #(#MenuItem |
|
575 #'label:' 'item' |
|
576 #'value:' #doCreateItem |
|
577 #'labelImage:' |
|
578 #(#ResourceRetriever |
|
579 #MenuEditor #iconCreateItem |
|
580 'item' |
|
581 ) |
|
582 ) |
|
583 #(#MenuItem |
|
584 #'label:' 'separator' |
|
585 #'value:' #doCreateSep |
|
586 #'labelImage:' |
|
587 #(#ResourceRetriever |
|
588 #MenuEditor #iconCreateSep |
|
589 'separator' |
|
590 ) |
|
591 ) |
|
592 ) nil |
|
593 nil |
|
594 ) |
|
595 ) |
|
596 ) nil |
|
597 nil |
|
598 ) |
|
599 ! |
|
600 |
|
601 menuPullDown |
|
602 "this window spec was automatically generated by the ST/X MenuEditor" |
|
603 |
|
604 "do not manually edit this - the builder may not be able to |
|
605 handle the specification if its corrupted." |
|
606 |
|
607 " |
|
608 MenuEditor new openOnClass:MenuEditor andSelector:#menuPullDown |
|
609 (Menu new fromLiteralArrayEncoding:(MenuEditor menuPullDown)) startUp |
|
610 " |
|
611 |
|
612 <resource: #menu> |
|
613 |
|
614 ^ |
|
615 |
|
616 #(#Menu |
|
617 |
|
618 #( |
|
619 #(#MenuItem |
|
620 #'label:' 'file' |
|
621 #'value:' #file |
|
622 #'submenu:' |
|
623 #(#Menu |
|
624 |
|
625 #( |
|
626 #(#MenuItem |
|
627 #'label:' 'new' |
|
628 #'value:' #doNew |
427 #'value:' #doNew |
629 ) |
428 ) |
630 #(#MenuItem |
429 #(#MenuItem |
631 #'label:' 'from class ...' |
430 #'label:' 'Load From Class...' |
431 #'translateLabel:' true |
|
632 #'value:' #doFromClass |
432 #'value:' #doFromClass |
633 #'enabled:' #isStandAlone |
|
634 ) |
|
635 #(#MenuItem |
|
636 #'label:' 'pick a menu' |
|
637 #'value:' #doPickAMenu |
|
638 #'enabled:' #isStandAlone |
|
639 ) |
|
640 #(#MenuItem |
|
641 #'label:' '=' |
|
642 ) |
|
643 #(#MenuItem |
|
644 #'label:' 'quit' |
|
645 #'value:' #closeRequest |
|
646 ) |
|
647 ) nil |
|
648 nil |
|
649 ) |
|
650 ) |
|
651 #(#MenuItem |
|
652 #'label:' 'edit' |
|
653 #'submenu:' |
|
654 #(#Menu |
|
655 |
|
656 #( |
|
657 #(#MenuItem |
|
658 #'label:' 'cut' |
|
659 #'value:' #doCut |
|
660 ) |
|
661 #(#MenuItem |
|
662 #'label:' '=' |
|
663 ) |
|
664 #(#MenuItem |
|
665 #'label:' 'create submenu static' |
|
666 #'value:' #doCreateMenu |
|
667 ) |
|
668 #(#MenuItem |
|
669 #'label:' 'create summenu dynamic' |
|
670 #'value:' #doCreateLink |
|
671 ) |
|
672 #(#MenuItem |
|
673 #'label:' '-' |
|
674 ) |
|
675 #(#MenuItem |
|
676 #'label:' 'create item' |
|
677 #'value:' #doCreateItem |
|
678 ) |
|
679 #(#MenuItem |
|
680 #'label:' 'create separator' |
|
681 #'value:' #doCreateSep |
|
682 ) |
|
683 ) nil |
|
684 nil |
|
685 ) |
|
686 ) |
|
687 #(#MenuItem |
|
688 #'label:' 'code' |
|
689 #'value:' #code |
|
690 #'submenu:' |
|
691 #(#Menu |
|
692 |
|
693 #( |
|
694 #(#MenuItem |
|
695 #'label:' 'class' |
|
696 #'value:' #doDefineClass |
|
697 #'enabled:' #isStandAlone |
433 #'enabled:' #isStandAlone |
698 ) |
434 ) |
699 #(#MenuItem |
435 #(#MenuItem |
700 #'label:' '-' |
436 #'label:' '-' |
701 ) |
437 ) |
702 #(#MenuItem |
438 #(#MenuItem |
703 #'label:' 'install menu spec.' |
439 #'label:' 'Pick A Menu' |
440 #'value:' #doPickAMenu |
|
441 #'enabled:' #isStandAlone |
|
442 ) |
|
443 #(#MenuItem |
|
444 #'label:' '-' |
|
445 ) |
|
446 #(#MenuItem |
|
447 #'label:' 'Save' |
|
704 #'value:' #doInstallSpec |
448 #'value:' #doInstallSpec |
705 ) |
449 ) |
706 #(#MenuItem |
450 #(#MenuItem |
707 #'label:' 'install help spec.' |
451 #'label:' 'Save Help Spec' |
708 #'value:' #doInstallHelp |
452 #'value:' #doInstallHelp |
709 #'enabled:' #isStandAlone |
453 #'enabled:' #isStandAlone |
710 ) |
454 ) |
711 #(#MenuItem |
455 #(#MenuItem |
712 #'label:' '=' |
456 #'label:' '-' |
713 ) |
457 ) |
714 #(#MenuItem |
458 #(#MenuItem |
715 #'label:' 'browse application' |
459 #'label:' 'Define Class...' |
460 #'value:' #doDefineClass |
|
461 #'enabled:' #isStandAlone |
|
462 ) |
|
463 #(#MenuItem |
|
464 #'label:' 'Browse Application Class' |
|
716 #'value:' #doBrowseAppClass |
465 #'value:' #doBrowseAppClass |
466 ) |
|
467 #(#MenuItem |
|
468 #'label:' '-' |
|
469 ) |
|
470 #(#MenuItem |
|
471 #'label:' 'Exit' |
|
472 #'translateLabel:' true |
|
473 #'value:' #closeRequest |
|
717 ) |
474 ) |
718 ) nil |
475 ) nil |
719 nil |
476 nil |
720 ) |
477 ) |
721 ) |
478 ) |
722 #(#MenuItem |
479 #(#MenuItem |
723 #'label:' 'test' |
480 #'label:' 'Edit' |
481 #'submenuChannel:' #menuPainter |
|
482 ) |
|
483 #(#MenuItem |
|
484 #'label:' 'Test' |
|
485 #'accessCharacterPosition:' 1 |
|
724 #'submenuChannel:' #submenuTest |
486 #'submenuChannel:' #submenuTest |
487 ) |
|
488 #(#MenuItem |
|
489 #'label:' 'History' |
|
490 #'accessCharacterPosition:' 1 |
|
491 #'submenuChannel:' #menuHistory |
|
492 ) |
|
493 #(#MenuItem |
|
494 #'label:' 'Help' |
|
495 #'accessCharacterPosition:' 1 |
|
496 #'submenuChannel:' #menuHelp |
|
725 ) |
497 ) |
726 ) nil |
498 ) nil |
727 nil |
499 nil |
728 ) |
500 ) |
729 |
501 ! |
730 "Modified: 28.7.1997 / 18:12:10 / cg" |
502 |
503 menuDefaultLink |
|
504 "this window spec was automatically generated by the ST/X MenuEditor" |
|
505 |
|
506 "do not manually edit this - the builder may not be able to |
|
507 handle the specification if its corrupted." |
|
508 |
|
509 " |
|
510 MenuEditor new openOnClass:MenuEditor andSelector:#menuDefaultLink |
|
511 (Menu new fromLiteralArrayEncoding:(MenuEditor menuDefaultLink)) startUp |
|
512 " |
|
513 |
|
514 <resource: #menu> |
|
515 |
|
516 ^ |
|
517 |
|
518 #(#Menu |
|
519 |
|
520 #( |
|
521 #(#MenuItem |
|
522 #'label:' '!! derives from application !!' |
|
523 ) |
|
524 ) nil |
|
525 nil |
|
526 ) |
|
527 ! |
|
528 |
|
529 menuPainter |
|
530 "this window spec was automatically generated by the ST/X MenuEditor" |
|
531 |
|
532 "do not manually edit this - the builder may not be able to |
|
533 handle the specification if its corrupted." |
|
534 |
|
535 " |
|
536 MenuEditor new openOnClass:MenuEditor andSelector:#menuPainter |
|
537 (Menu new fromLiteralArrayEncoding:(MenuEditor menuPainter)) startUp |
|
538 " |
|
539 |
|
540 <resource: #menu> |
|
541 |
|
542 ^ |
|
543 |
|
544 #(#Menu |
|
545 |
|
546 #( |
|
547 #(#MenuItem |
|
548 #'label:' 'Cut' |
|
549 #'value:' #doCut |
|
550 #'enabled:' #hasValidSelection |
|
551 #'shortcutKeyCharacter:' #Cut |
|
552 ) |
|
553 #(#MenuItem |
|
554 #'label:' 'Copy' |
|
555 #'value:' #doCopy |
|
556 #'enabled:' #hasValidSelection |
|
557 #'shortcutKeyCharacter:' #Copy |
|
558 ) |
|
559 #(#MenuItem |
|
560 #'label:' 'Paste' |
|
561 #'value:' #doPaste |
|
562 #'enabled:' #hasAnySingleSelection |
|
563 #'shortcutKeyCharacter:' #Paste |
|
564 ) |
|
565 #(#MenuItem |
|
566 #'label:' '=' |
|
567 ) |
|
568 #(#MenuItem |
|
569 #'label:' 'Create Item' |
|
570 #'value:' #doCreateItem |
|
571 #'labelImage:' #(#ResourceRetriever #MenuEditor #iconCreateItem 'Create Item') |
|
572 ) |
|
573 #(#MenuItem |
|
574 #'label:' 'Create Separator' |
|
575 #'value:' #doCreateSep |
|
576 #'labelImage:' #(#ResourceRetriever #MenuEditor #iconCreateSep 'Create Separator') |
|
577 ) |
|
578 #(#MenuItem |
|
579 #'label:' '-' |
|
580 ) |
|
581 #(#MenuItem |
|
582 #'label:' 'Create Submenu Static' |
|
583 #'value:' #doCreateMenu |
|
584 #'labelImage:' #(#ResourceRetriever #MenuEditor #iconCreateMenu 'Create Submenu Static') |
|
585 ) |
|
586 #(#MenuItem |
|
587 #'label:' 'Create Submenu Dynamic' |
|
588 #'value:' #doCreateLink |
|
589 #'labelImage:' #(#ResourceRetriever #MenuEditor #iconCreateLink 'Create Submenu Dynamic') |
|
590 ) |
|
591 ) nil |
|
592 nil |
|
593 ) |
|
594 ! |
|
595 |
|
596 menuToolbar |
|
597 "this window spec was automatically generated by the ST/X MenuEditor" |
|
598 |
|
599 "do not manually edit this - the builder may not be able to |
|
600 handle the specification if its corrupted." |
|
601 |
|
602 " |
|
603 MenuEditor new openOnClass:MenuEditor andSelector:#menuToolbar |
|
604 (Menu new fromLiteralArrayEncoding:(MenuEditor menuToolbar)) startUp |
|
605 " |
|
606 |
|
607 <resource: #menu> |
|
608 |
|
609 ^ |
|
610 |
|
611 #(#Menu |
|
612 |
|
613 #( |
|
614 #(#MenuItem |
|
615 #'label:' 'New' |
|
616 #'isButton:' true |
|
617 #'value:' #doNew |
|
618 #'labelImage:' #(#ResourceRetriever nil #newIcon) |
|
619 ) |
|
620 #(#MenuItem |
|
621 #'label:' 'Load' |
|
622 #'isButton:' true |
|
623 #'value:' #doFromClass |
|
624 #'labelImage:' #(#ResourceRetriever nil #loadIcon) |
|
625 ) |
|
626 #(#MenuItem |
|
627 #'label:' 'Save' |
|
628 #'isButton:' true |
|
629 #'value:' #doInstallSpec |
|
630 #'labelImage:' #(#ResourceRetriever nil #saveIcon) |
|
631 ) |
|
632 #(#MenuItem |
|
633 #'label:' '-' |
|
634 ) |
|
635 #(#MenuItem |
|
636 #'label:' 'createItem' |
|
637 #'isButton:' true |
|
638 #'value:' #doCreateItem |
|
639 #'enabled:' #hasAnySingleSelection |
|
640 #'labelImage:' #(#ResourceRetriever nil #iconCreateItem) |
|
641 ) |
|
642 #(#MenuItem |
|
643 #'label:' 'createSeparator' |
|
644 #'isButton:' true |
|
645 #'value:' #doCreateSep |
|
646 #'enabled:' #hasAnySingleSelection |
|
647 #'labelImage:' #(#ResourceRetriever nil #iconCreateSep) |
|
648 ) |
|
649 #(#MenuItem |
|
650 #'label:' '-' |
|
651 ) |
|
652 #(#MenuItem |
|
653 #'label:' 'createMenu' |
|
654 #'isButton:' true |
|
655 #'value:' #doCreateMenu |
|
656 #'enabled:' #hasAnySingleSelection |
|
657 #'labelImage:' #(#ResourceRetriever nil #iconCreateMenu) |
|
658 ) |
|
659 #(#MenuItem |
|
660 #'label:' 'createLink' |
|
661 #'isButton:' true |
|
662 #'value:' #doCreateLink |
|
663 #'enabled:' #hasAnySingleSelection |
|
664 #'labelImage:' #(#ResourceRetriever nil #iconCreateLink) |
|
665 ) |
|
666 #(#MenuItem |
|
667 #'label:' '-' |
|
668 ) |
|
669 #(#MenuItem |
|
670 #'label:' 'stepUp' |
|
671 #'isButton:' true |
|
672 #'value:' #doStepUp |
|
673 #'enabled:' #enabledStepOver |
|
674 #'labelImage:' #(#ResourceRetriever nil #upIcon) |
|
675 ) |
|
676 #(#MenuItem |
|
677 #'label:' 'stepDown' |
|
678 #'isButton:' true |
|
679 #'value:' #doStepDown |
|
680 #'enabled:' #enabledStepOver |
|
681 #'labelImage:' #(#ResourceRetriever nil #downIcon) |
|
682 ) |
|
683 #(#MenuItem |
|
684 #'label:' 'stepIn' |
|
685 #'isButton:' true |
|
686 #'value:' #doStepIn |
|
687 #'enabled:' #enabledStepIn |
|
688 #'labelImage:' #(#ResourceRetriever nil #downRightIcon) |
|
689 ) |
|
690 #(#MenuItem |
|
691 #'label:' 'stepOut' |
|
692 #'isButton:' true |
|
693 #'value:' #doStepOut |
|
694 #'enabled:' #enabledStepOut |
|
695 #'labelImage:' #(#ResourceRetriever nil #leftDownIcon) |
|
696 ) |
|
697 ) nil |
|
698 nil |
|
699 ) |
|
731 ! |
700 ! |
732 |
701 |
733 windowSpec |
702 windowSpec |
734 "this window spec was automatically generated by the ST/X UIPainter" |
703 "this window spec was automatically generated by the ST/X UIPainter" |
735 |
704 |
747 ^ |
716 ^ |
748 |
717 |
749 #(#FullSpec |
718 #(#FullSpec |
750 #'window:' |
719 #'window:' |
751 #(#WindowSpec |
720 #(#WindowSpec |
752 #'name:' 'MenuEditor' |
721 #'name:' 'Menu Builder' |
753 #'layout:' #(#LayoutFrame 0 0.0 0 0.0 0 1.0 0 1.0) |
722 #'layout:' #(#LayoutFrame 102 0 166 0 681 0 549 0) |
754 #'label:' 'Menu Builder' |
723 #'label:' 'Menu Builder' |
755 #'bounds:' #(#Rectangle 0 0 580 384) |
724 #'min:' #(#Point 10 10) |
725 #'max:' #(#Point 1152 900) |
|
726 #'bounds:' #(#Rectangle 102 166 682 550) |
|
727 #'menu:' #menu |
|
728 #'usePreferredExtent:' false |
|
756 ) |
729 ) |
757 #'component:' |
730 #'component:' |
758 #(#SpecCollection |
731 #(#SpecCollection |
759 #'collection:' |
732 #'collection:' |
760 #( |
733 #( |
761 #(#ArbitraryComponentSpec |
734 #(#MenuPanelSpec |
762 #'name:' 'painterView' |
735 #'name:' 'menuToolbarView' |
763 #'layout:' #(#LayoutFrame 0 0.0 57 0 0 0.5 0 1.0) |
736 #'layout:' #(#LayoutFrame 0 0.0 0 0 0 1.0 34 0) |
764 #'menu:' #menuPainter |
737 #'menu:' #menuToolbar |
765 #'hasHorizontalScrollBar:' true |
738 #'showSeparatingLines:' true |
766 #'hasVerticalScrollBar:' true |
739 ) |
767 #'component:' #painter |
740 #(#VariableHorizontalPanelSpec |
768 #'hasBorder:' false |
741 #'name:' 'variableHorizontalPanel1' |
769 ) |
742 #'layout:' #(#LayoutFrame 0 0.0 36 0.0 0 1.0 -22 1.0) |
770 #(#NoteBookViewSpec |
|
771 #'name:' 'specificationView' |
|
772 #'layout:' #(#LayoutFrame 0 0.5 0 0.0 0 1.0 -25 1.0) |
|
773 #'tabable:' true |
|
774 #'menu:' #tabList |
|
775 #'model:' #tabModel |
|
776 #'tabWidget:' #Window |
|
777 #'useIndex:' true |
|
778 #'canvas:' #noteBookView |
|
779 ) |
|
780 #(#HorizontalPanelViewSpec |
|
781 #'name:' 'confirmationPanel' |
|
782 #'layout:' #(#LayoutFrame 0 0.5 -24 1.0 0 1.0 0 1.0) |
|
783 #'component:' |
743 #'component:' |
784 #(#SpecCollection |
744 #(#SpecCollection |
785 #'collection:' |
745 #'collection:' |
786 #( |
746 #( |
787 #(#ActionButtonSpec |
747 #(#ArbitraryComponentSpec |
788 #'name:' 'cancelButton' |
748 #'name:' 'painterView' |
789 #'label:' 'cancel' |
749 #'menu:' #menuPainter |
790 #'model:' #cancel |
750 #'hasHorizontalScrollBar:' true |
791 #'enableChannel:' #modifiedChannel |
751 #'hasVerticalScrollBar:' true |
792 #'extent:' #(#Point 140 24) |
752 #'component:' #painter |
753 #'hasBorder:' false |
|
793 ) |
754 ) |
794 #(#ActionButtonSpec |
755 #(#ViewSpec |
795 #'name:' 'acceptButton' |
756 #'name:' 'view1' |
796 #'label:' 'ok' |
757 #'component:' |
797 #'model:' #accept |
758 #(#SpecCollection |
798 #'enableChannel:' #modifiedChannel |
759 #'collection:' |
799 #'extent:' #(#Point 141 24) |
760 #( |
761 #(#NoteBookViewSpec |
|
762 #'name:' 'specificationView' |
|
763 #'layout:' #(#LayoutFrame 1 0.0 0 0.0 0 1.0 -26 1.0) |
|
764 #'tabable:' true |
|
765 #'model:' #tabModel |
|
766 #'menu:' #tabList |
|
767 #'useIndex:' true |
|
768 #'canvas:' #noteBookView |
|
769 ) |
|
770 #(#HorizontalPanelViewSpec |
|
771 #'name:' 'confirmationPanel' |
|
772 #'layout:' #(#LayoutFrame 1 0.0 -24 1 0 1.0 0 1.0) |
|
773 #'component:' |
|
774 #(#SpecCollection |
|
775 #'collection:' |
|
776 #( |
|
777 #(#ActionButtonSpec |
|
778 #'name:' 'cancelButton' |
|
779 #'label:' 'Cancel' |
|
780 #'model:' #cancel |
|
781 #'enableChannel:' #modifiedChannel |
|
782 #'extent:' #(#Point 171 24) |
|
783 ) |
|
784 #(#ActionButtonSpec |
|
785 #'name:' 'acceptButton' |
|
786 #'label:' 'OK' |
|
787 #'model:' #accept |
|
788 #'enableChannel:' #modifiedChannel |
|
789 #'extent:' #(#Point 171 24) |
|
790 ) |
|
791 ) |
|
792 ) |
|
793 #'horizontalLayout:' #fitSpace |
|
794 #'verticalLayout:' #fit |
|
795 #'horizontalSpace:' 3 |
|
796 #'verticalSpace:' 3 |
|
797 ) |
|
798 ) |
|
799 ) |
|
800 #'level:' -1 |
|
800 ) |
801 ) |
801 ) |
802 ) |
802 ) |
803 ) |
803 #'horizontalLayout:' #fitSpace |
804 #'handles:' #(#Any 0.384483 1.0) |
804 #'verticalLayout:' #fit |
805 ) |
805 #'horizontalSpace:' 3 |
806 #(#LabelSpec |
806 #'verticalSpace:' 3 |
807 #'name:' 'infoLabel' |
807 ) |
808 #'layout:' #(#LayoutFrame 0 0.0 -22 1 -65 1.0 0 1.0) |
808 #(#MenuPanelSpec |
809 #'labelChannel:' #valueOfInfoLabel |
809 #'name:' 'pullDownMenu' |
810 #'level:' 1 |
810 #'layout:' #(#LayoutFrame 0 0.0 0 0.0 0 0.5 24 0) |
811 #'adjust:' #left |
811 #'tabable:' true |
812 ) |
812 #'menu:' #menuPullDown |
813 #(#LabelSpec |
813 ) |
814 #'name:' 'timeLabel' |
814 #(#MenuPanelSpec |
815 #'layout:' #(#LayoutFrame -65 1 -22 1 0 1.0 0 1.0) |
815 #'name:' 'menuPanel1' |
816 #'labelChannel:' #valueOfTimeLabel |
816 #'layout:' #(#LayoutFrame 0 0 28 0 0 0.5 53 0) |
817 #'level:' 1 |
817 #'menu:' #menuButtons |
818 #'adjust:' #right |
818 #'showSeparatingLines:' true |
|
819 ) |
819 ) |
820 ) |
820 ) |
821 ) |
821 ) |
822 ) |
822 ) |
823 ! ! |
823 ! ! |
826 |
826 |
827 slicesItem |
827 slicesItem |
828 ^#( |
828 ^#( |
829 (Basics basicsItemSpec) |
829 (Basics basicsItemSpec) |
830 (Details detailsEditSpec) |
830 (Details detailsEditSpec) |
831 (Misc miscEditSpec) |
831 (Image imageEditSpec) |
832 ) |
832 ) |
833 |
833 |
834 ! |
834 ! |
835 |
835 |
836 slicesLink |
836 slicesLink |
837 ^#( |
837 ^#( |
838 (Basics basicsLinkSpec) |
838 (Basics basicsLinkSpec) |
839 (Details detailsEditSpec) |
839 (Details detailsEditSpec) |
840 (Misc miscEditSpec) |
840 (Image imageEditSpec) |
841 ) |
841 ) |
842 |
842 |
843 ! |
843 ! |
844 |
844 |
845 slicesMenu |
845 slicesMenu |
846 ^#( |
846 ^#( |
847 (Basics basicsMenuSpec) |
847 (Basics basicsMenuSpec) |
848 (Details detailsEditSpec) |
848 (Details detailsEditSpec) |
849 (Misc miscEditSpec) |
849 (Image imageEditSpec) |
850 ) |
850 ) |
851 |
851 |
852 ! |
852 ! |
853 |
853 |
854 slicesRootMenu |
854 slicesRootMenu |
884 |
884 |
885 #(#FullSpec |
885 #(#FullSpec |
886 #'window:' |
886 #'window:' |
887 #(#WindowSpec |
887 #(#WindowSpec |
888 #'name:' 'unnamed canvas' |
888 #'name:' 'unnamed canvas' |
889 #'layout:' #(#LayoutFrame 377 0 282 0 643 0 600 0) |
889 #'layout:' #(#LayoutFrame 197 0 172 0 463 0 490 0) |
890 #'label:' 'unnamed canvas' |
890 #'label:' 'unnamed canvas' |
891 #'min:' #(#Point 10 10) |
891 #'min:' #(#Point 10 10) |
892 #'max:' #(#Point 1160 870) |
892 #'max:' #(#Point 1160 870) |
893 #'bounds:' #(#Rectangle 377 282 644 601) |
893 #'bounds:' #(#Rectangle 197 172 464 491) |
894 #'usePreferredExtent:' false |
894 #'usePreferredExtent:' false |
895 ) |
895 ) |
896 #'component:' |
896 #'component:' |
897 #(#SpecCollection |
897 #(#SpecCollection |
898 #'collection:' |
898 #'collection:' |
904 #'adjust:' #right |
904 #'adjust:' #right |
905 #'resizeForLabel:' true |
905 #'resizeForLabel:' true |
906 ) |
906 ) |
907 #(#InputFieldSpec |
907 #(#InputFieldSpec |
908 #'name:' 'nameKeyField' |
908 #'name:' 'nameKeyField' |
909 #'layout:' #(#LayoutFrame 91 0 15 0 0 1.0 37 0) |
909 #'layout:' #(#LayoutFrame 90 0 15 0 0 1.0 37 0) |
910 #'activeHelpKey:' #nameKey |
910 #'activeHelpKey:' #nameKey |
911 #'tabable:' true |
911 #'tabable:' true |
912 #'model:' #nameKey |
912 #'model:' #nameKey |
913 #'type:' #symbolOrNil |
913 #'type:' #symbolOrNil |
914 ) |
914 ) |
915 #(#LabelSpec |
915 #(#LabelSpec |
916 #'name:' 'labelLabel' |
916 #'name:' 'labelLabel' |
917 #'layout:' #(#AlignmentOrigin 87 0 53 0 1 0.5) |
917 #'layout:' #(#AlignmentOrigin 87 0 51 0 1 0.5) |
918 #'label:' 'Label' |
918 #'label:' 'Label:' |
919 #'adjust:' #right |
919 #'adjust:' #right |
920 #'resizeForLabel:' true |
920 #'resizeForLabel:' true |
921 ) |
921 ) |
922 #(#InputFieldSpec |
922 #(#InputFieldSpec |
923 #'name:' 'labelField' |
923 #'name:' 'labelField' |
924 #'layout:' #(#LayoutFrame 91 0 42 0 0 1.0 64 0) |
924 #'layout:' #(#LayoutFrame 90 0 40 0 0 1.0 62 0) |
925 #'activeHelpKey:' #label |
925 #'activeHelpKey:' #label |
926 #'tabable:' true |
926 #'tabable:' true |
927 #'model:' #label |
927 #'model:' #label |
928 ) |
928 ) |
929 #(#LabelSpec |
929 #(#LabelSpec |
933 #'adjust:' #right |
933 #'adjust:' #right |
934 #'resizeForLabel:' true |
934 #'resizeForLabel:' true |
935 ) |
935 ) |
936 #(#InputFieldSpec |
936 #(#InputFieldSpec |
937 #'name:' 'valueField' |
937 #'name:' 'valueField' |
938 #'layout:' #(#LayoutFrame 91 0 79 0 0 1.0 101 0) |
938 #'layout:' #(#LayoutFrame 90 0 79 0 0 1.0 101 0) |
939 #'activeHelpKey:' #value |
939 #'activeHelpKey:' #value |
940 #'tabable:' true |
940 #'tabable:' true |
941 #'model:' #value |
941 #'model:' #value |
942 #'type:' #symbolOrNil |
942 #'type:' #symbolOrNil |
943 ) |
943 ) |
944 #(#LabelSpec |
944 #(#LabelSpec |
945 #'name:' 'argumentLabel' |
945 #'name:' 'argumentLabel' |
946 #'layout:' #(#AlignmentOrigin 87 0 116 0 1 0.5) |
946 #'layout:' #(#AlignmentOrigin 87 0 115 0 1 0.5) |
947 #'label:' 'Argument:' |
947 #'label:' 'Argument:' |
948 #'adjust:' #right |
948 #'adjust:' #right |
949 #'resizeForLabel:' true |
949 #'resizeForLabel:' true |
950 ) |
950 ) |
951 #(#InputFieldSpec |
951 #(#InputFieldSpec |
952 #'name:' 'argumentField' |
952 #'name:' 'argumentField' |
953 #'layout:' #(#LayoutFrame 91 0 105 0 0 1.0 127 0) |
953 #'layout:' #(#LayoutFrame 90 0 104 0 0 1.0 126 0) |
954 #'activeHelpKey:' #argument |
954 #'activeHelpKey:' #argument |
955 #'tabable:' true |
955 #'tabable:' true |
956 #'model:' #argument |
956 #'model:' #argument |
957 #'type:' #string |
957 #'type:' #string |
958 ) |
958 ) |
959 #(#LabelSpec |
959 #(#LabelSpec |
960 #'name:' 'indicationLabel' |
960 #'name:' 'indicationLabel' |
961 #'layout:' #(#AlignmentOrigin 87 0 156 0 1 0.5) |
961 #'layout:' #(#AlignmentOrigin 87 0 155 0 1 0.5) |
962 #'label:' 'Indication:' |
962 #'label:' 'Indication:' |
963 #'adjust:' #right |
963 #'adjust:' #right |
964 #'resizeForLabel:' true |
964 #'resizeForLabel:' true |
965 ) |
965 ) |
966 #(#InputFieldSpec |
966 #(#InputFieldSpec |
967 #'name:' 'indicationField' |
967 #'name:' 'indicationField' |
968 #'layout:' #(#LayoutFrame 91 0 145 0 0 1.0 167 0) |
968 #'layout:' #(#LayoutFrame 90 0 144 0 0 1.0 166 0) |
969 #'activeHelpKey:' #indication |
969 #'activeHelpKey:' #indication |
970 #'tabable:' true |
970 #'tabable:' true |
971 #'model:' #indication |
971 #'model:' #indication |
972 #'type:' #symbolOrNil |
972 #'type:' #symbolOrNil |
973 ) |
|
974 #(#CheckBoxSpec |
|
975 #'name:' 'translateLabelCheckBox' |
|
976 #'layout:' #(#Point 20 192) |
|
977 #'activeHelpKey:' #translateLabel |
|
978 #'model:' #translateLabel |
|
979 #'label:' 'Translate Label' |
|
980 ) |
|
981 #(#CheckBoxSpec |
|
982 #'name:' 'isButtonCheckBox' |
|
983 #'layout:' #(#Point 20 221) |
|
984 #'activeHelpKey:' #translateLabel |
|
985 #'model:' #isButton |
|
986 #'label:' 'Is Button' |
|
973 ) |
987 ) |
974 ) |
988 ) |
975 ) |
989 ) |
976 ) |
990 ) |
977 ! |
991 ! |
993 |
1007 |
994 #(#FullSpec |
1008 #(#FullSpec |
995 #'window:' |
1009 #'window:' |
996 #(#WindowSpec |
1010 #(#WindowSpec |
997 #'name:' 'unnamed canvas' |
1011 #'name:' 'unnamed canvas' |
998 #'layout:' #(#LayoutFrame 219 0 193 0 485 0 511 0) |
1012 #'layout:' #(#LayoutFrame 197 0 172 0 463 0 490 0) |
999 #'label:' 'unnamed canvas' |
1013 #'label:' 'unnamed canvas' |
1000 #'min:' #(#Point 10 10) |
1014 #'min:' #(#Point 10 10) |
1001 #'max:' #(#Point 1280 1024) |
1015 #'max:' #(#Point 1280 1024) |
1002 #'bounds:' #(#Rectangle 219 193 486 512) |
1016 #'bounds:' #(#Rectangle 197 172 464 491) |
1003 #'usePreferredExtent:' false |
1017 #'usePreferredExtent:' false |
1004 ) |
1018 ) |
1005 #'component:' |
1019 #'component:' |
1006 #(#SpecCollection |
1020 #(#SpecCollection |
1007 #'collection:' |
1021 #'collection:' |
1014 #'adjust:' #right |
1028 #'adjust:' #right |
1015 #'resizeForLabel:' true |
1029 #'resizeForLabel:' true |
1016 ) |
1030 ) |
1017 #(#InputFieldSpec |
1031 #(#InputFieldSpec |
1018 #'name:' 'nameKeyField' |
1032 #'name:' 'nameKeyField' |
1019 #'layout:' #(#LayoutFrame 91 0 15 0 0 1.0 37 0) |
1033 #'layout:' #(#LayoutFrame 90 0 15 0 0 1.0 37 0) |
1020 #'activeHelpKey:' #nameKey |
1034 #'activeHelpKey:' #nameKey |
1021 #'tabable:' true |
1035 #'tabable:' true |
1022 #'model:' #nameKey |
1036 #'model:' #nameKey |
1023 #'type:' #symbolOrNil |
1037 #'type:' #symbolOrNil |
1024 ) |
1038 ) |
1025 #(#LabelSpec |
1039 #(#LabelSpec |
1026 #'name:' 'labelLabel' |
1040 #'name:' 'labelLabel' |
1027 #'layout:' #(#AlignmentOrigin 87 0 53 0 1 0.5) |
1041 #'layout:' #(#AlignmentOrigin 87 0 51 0 1 0.5) |
1028 #'label:' 'Label' |
1042 #'label:' 'Label:' |
1029 #'resizeForLabel:' true |
1043 #'resizeForLabel:' true |
1030 ) |
1044 ) |
1031 #(#InputFieldSpec |
1045 #(#InputFieldSpec |
1032 #'name:' 'labelField' |
1046 #'name:' 'labelField' |
1033 #'layout:' #(#LayoutFrame 91 0 42 0 0 1.0 64 0) |
1047 #'layout:' #(#LayoutFrame 90 0 40 0 0 1.0 62 0) |
1034 #'activeHelpKey:' #label |
1048 #'activeHelpKey:' #label |
1035 #'tabable:' true |
1049 #'tabable:' true |
1036 #'model:' #label |
1050 #'model:' #label |
1037 ) |
1051 ) |
1038 #(#InputFieldSpec |
1052 #(#InputFieldSpec |
1039 #'name:' 'menuField' |
1053 #'name:' 'menuField' |
1040 #'layout:' #(#LayoutFrame 91 0 69 0 0 1.0 91 0) |
1054 #'layout:' #(#LayoutFrame 90 0 65 0 0 1.0 87 0) |
1041 #'activeHelpKey:' #submenuChannel |
1055 #'activeHelpKey:' #submenuChannel |
1042 #'tabable:' true |
1056 #'tabable:' true |
1043 #'model:' #submenuChannel |
1057 #'model:' #submenuChannel |
1044 #'type:' #symbolOrNil |
1058 #'type:' #symbolOrNil |
1045 ) |
1059 ) |
1046 #(#LabelSpec |
1060 #(#LabelSpec |
1047 #'name:' 'menuLabel' |
1061 #'name:' 'menuLabel' |
1048 #'layout:' #(#AlignmentOrigin 87 0 80 0 1 0.5) |
1062 #'layout:' #(#AlignmentOrigin 87 0 76 0 1 0.5) |
1049 #'label:' 'Menu:' |
1063 #'label:' 'Menu:' |
1050 #'resizeForLabel:' true |
1064 #'resizeForLabel:' true |
1051 ) |
1065 ) |
1052 ) |
1066 ) |
1053 ) |
1067 ) |
1071 |
1085 |
1072 #(#FullSpec |
1086 #(#FullSpec |
1073 #'window:' |
1087 #'window:' |
1074 #(#WindowSpec |
1088 #(#WindowSpec |
1075 #'name:' 'unnamed canvas' |
1089 #'name:' 'unnamed canvas' |
1076 #'layout:' #(#LayoutFrame 219 0 193 0 485 0 511 0) |
1090 #'layout:' #(#LayoutFrame 197 0 172 0 463 0 490 0) |
1077 #'label:' 'unnamed canvas' |
1091 #'label:' 'unnamed canvas' |
1078 #'min:' #(#Point 10 10) |
1092 #'min:' #(#Point 10 10) |
1079 #'max:' #(#Point 1280 1024) |
1093 #'max:' #(#Point 1280 1024) |
1080 #'bounds:' #(#Rectangle 219 193 486 512) |
1094 #'bounds:' #(#Rectangle 197 172 464 491) |
1081 #'usePreferredExtent:' false |
1095 #'usePreferredExtent:' false |
1082 ) |
1096 ) |
1083 #'component:' |
1097 #'component:' |
1084 #(#SpecCollection |
1098 #(#SpecCollection |
1085 #'collection:' |
1099 #'collection:' |
1091 #'adjust:' #right |
1105 #'adjust:' #right |
1092 #'resizeForLabel:' true |
1106 #'resizeForLabel:' true |
1093 ) |
1107 ) |
1094 #(#InputFieldSpec |
1108 #(#InputFieldSpec |
1095 #'name:' 'nameKeyField' |
1109 #'name:' 'nameKeyField' |
1096 #'layout:' #(#LayoutFrame 91 0 15 0 0 1.0 37 0) |
1110 #'layout:' #(#LayoutFrame 90 0 15 0 0 1.0 37 0) |
1097 #'activeHelpKey:' #nameKey |
1111 #'activeHelpKey:' #nameKey |
1098 #'tabable:' true |
1112 #'tabable:' true |
1099 #'model:' #nameKey |
1113 #'model:' #nameKey |
1100 #'type:' #symbolOrNil |
1114 #'type:' #symbolOrNil |
1101 ) |
1115 ) |
1102 #(#LabelSpec |
1116 #(#LabelSpec |
1103 #'name:' 'labelLabel' |
1117 #'name:' 'labelLabel' |
1104 #'layout:' #(#AlignmentOrigin 87 0 53 0 1 0.5) |
1118 #'layout:' #(#AlignmentOrigin 87 0 51 0 1 0.5) |
1105 #'label:' 'Label' |
1119 #'label:' 'Label:' |
1106 #'adjust:' #right |
1120 #'adjust:' #right |
1107 #'resizeForLabel:' true |
1121 #'resizeForLabel:' true |
1108 ) |
1122 ) |
1109 #(#InputFieldSpec |
1123 #(#InputFieldSpec |
1110 #'name:' 'labelField' |
1124 #'name:' 'labelField' |
1111 #'layout:' #(#LayoutFrame 91 0 42 0 0 1.0 64 0) |
1125 #'layout:' #(#LayoutFrame 90 0 40 0 0 1.0 62 0) |
1112 #'activeHelpKey:' #label |
1126 #'activeHelpKey:' #label |
1113 #'tabable:' true |
1127 #'tabable:' true |
1114 #'model:' #label |
1128 #'model:' #label |
1129 ) |
|
1130 #(#CheckBoxSpec |
|
1131 #'name:' 'translateLabelCheckBox' |
|
1132 #'layout:' #(#Point 20 100) |
|
1133 #'activeHelpKey:' #translateLabel |
|
1134 #'model:' #translateLabel |
|
1135 #'label:' 'Translate Label' |
|
1115 ) |
1136 ) |
1116 ) |
1137 ) |
1117 ) |
1138 ) |
1118 ) |
1139 ) |
1119 ! |
1140 ! |
1135 |
1156 |
1136 #(#FullSpec |
1157 #(#FullSpec |
1137 #'window:' |
1158 #'window:' |
1138 #(#WindowSpec |
1159 #(#WindowSpec |
1139 #'name:' 'unnamed canvas' |
1160 #'name:' 'unnamed canvas' |
1140 #'layout:' #(#LayoutFrame 219 0 193 0 485 0 511 0) |
1161 #'layout:' #(#LayoutFrame 197 0 172 0 463 0 490 0) |
1141 #'label:' 'unnamed canvas' |
1162 #'label:' 'unnamed canvas' |
1142 #'min:' #(#Point 10 10) |
1163 #'min:' #(#Point 10 10) |
1143 #'max:' #(#Point 1280 1024) |
1164 #'max:' #(#Point 1280 1024) |
1144 #'bounds:' #(#Rectangle 219 193 486 512) |
1165 #'bounds:' #(#Rectangle 197 172 464 491) |
1145 #'usePreferredExtent:' false |
1166 #'usePreferredExtent:' false |
1146 ) |
1167 ) |
1147 #'component:' |
1168 #'component:' |
1148 #(#SpecCollection |
1169 #(#SpecCollection |
1149 #'collection:' |
1170 #'collection:' |
1150 #( |
1171 #( |
1151 #(#LabelSpec |
1172 #(#LabelSpec |
1152 #'name:' 'selectorLabel' |
1173 #'name:' 'selectorLabel' |
1153 #'layout:' #(#AlignmentOrigin 78 0 53 0 1 0.5) |
1174 #'layout:' #(#AlignmentOrigin 87 0 26 0 1 0.5) |
1154 #'label:' 'Selector:' |
1175 #'label:' 'Selector:' |
1155 #'adjust:' #right |
1176 #'adjust:' #right |
1156 #'resizeForLabel:' true |
1177 #'resizeForLabel:' true |
1157 ) |
1178 ) |
1158 #(#InputFieldSpec |
1179 #(#InputFieldSpec |
1159 #'name:' 'selectorField' |
1180 #'name:' 'selectorField' |
1160 #'layout:' #(#LayoutFrame 82 0 42 0 0 1.0 64 0) |
1181 #'layout:' #(#LayoutFrame 90 0 15 0 0 1.0 37 0) |
1161 #'activeHelpKey:' #menuSelector |
1182 #'activeHelpKey:' #menuSelector |
1162 #'tabable:' true |
1183 #'tabable:' true |
1163 #'model:' #label |
1184 #'model:' #label |
1164 ) |
1185 ) |
1165 ) |
1186 ) |
1184 |
1205 |
1185 #(#FullSpec |
1206 #(#FullSpec |
1186 #'window:' |
1207 #'window:' |
1187 #(#WindowSpec |
1208 #(#WindowSpec |
1188 #'name:' 'unnamed canvas' |
1209 #'name:' 'unnamed canvas' |
1189 #'layout:' #(#LayoutFrame 219 0 193 0 485 0 511 0) |
1210 #'layout:' #(#LayoutFrame 197 0 172 0 463 0 490 0) |
1190 #'label:' 'unnamed canvas' |
1211 #'label:' 'unnamed canvas' |
1191 #'min:' #(#Point 10 10) |
1212 #'min:' #(#Point 10 10) |
1192 #'max:' #(#Point 1160 870) |
1213 #'max:' #(#Point 1160 870) |
1193 #'bounds:' #(#Rectangle 219 193 486 512) |
1214 #'bounds:' #(#Rectangle 197 172 464 491) |
1194 #'usePreferredExtent:' false |
1215 #'usePreferredExtent:' false |
1195 ) |
1216 ) |
1196 #'component:' |
1217 #'component:' |
1197 #(#SpecCollection |
1218 #(#SpecCollection |
1198 #'collection:' |
1219 #'collection:' |
1199 #( |
1220 #( |
1200 #(#LabelSpec |
1221 #(#LabelSpec |
1201 #'name:' 'separatorLabel' |
1222 #'name:' 'separatorLabel' |
1202 #'layout:' #(#AlignmentOrigin 127 0 22 0 1 0.5) |
1223 #'layout:' #(#AlignmentOrigin 127 0 26 0 1 0.5) |
1203 #'label:' 'Separator Type:' |
1224 #'label:' 'Separator Type:' |
1204 #'adjust:' #right |
1225 #'adjust:' #right |
1205 #'resizeForLabel:' true |
1226 #'resizeForLabel:' true |
1206 ) |
1227 ) |
1207 #(#ComboListSpec |
1228 #(#ComboListSpec |
1208 #'name:' 'seperatorList' |
1229 #'name:' 'seperatorList' |
1209 #'layout:' #(#LayoutFrame 132 0 11 0 0 1.0 33 0) |
1230 #'layout:' #(#LayoutFrame 132 0 15 0 0 1.0 37 0) |
1210 #'activeHelpKey:' #seperatorList |
1231 #'activeHelpKey:' #seperatorList |
1211 #'model:' #seperatorSelection |
1232 #'model:' #seperatorSelection |
1212 #'useIndex:' true |
1233 #'useIndex:' true |
1213 ) |
1234 ) |
1214 ) |
1235 ) |
1233 |
1254 |
1234 #(#FullSpec |
1255 #(#FullSpec |
1235 #'window:' |
1256 #'window:' |
1236 #(#WindowSpec |
1257 #(#WindowSpec |
1237 #'name:' 'unnamed canvas' |
1258 #'name:' 'unnamed canvas' |
1238 #'layout:' #(#LayoutFrame 219 0 193 0 477 0 480 0) |
1259 #'layout:' #(#LayoutFrame 367 0 108 0 625 0 395 0) |
1239 #'label:' 'unnamed canvas' |
1260 #'label:' 'unnamed canvas' |
1240 #'min:' #(#Point 10 10) |
1261 #'min:' #(#Point 10 10) |
1241 #'max:' #(#Point 1280 1024) |
1262 #'max:' #(#Point 1280 1024) |
1242 #'bounds:' #(#Rectangle 219 193 478 481) |
1263 #'bounds:' #(#Rectangle 367 108 626 396) |
1243 #'usePreferredExtent:' false |
1264 #'usePreferredExtent:' false |
1244 ) |
1265 ) |
1245 #'component:' |
1266 #'component:' |
1246 #(#SpecCollection |
1267 #(#SpecCollection |
1247 #'collection:' |
1268 #'collection:' |
1248 #( |
1269 #( |
1249 #(#LabelSpec |
1270 #(#LabelSpec |
1250 #'name:' 'shortcutKeyLabel' |
1271 #'name:' 'shortcutKeyLabel' |
1251 #'layout:' #(#AlignmentOrigin 87 0 33 0 1 0.5) |
1272 #'layout:' #(#AlignmentOrigin 87 0 26 0 1 0.5) |
1252 #'label:' 'Accelerator:' |
1273 #'label:' 'Accelerator:' |
1253 #'adjust:' #right |
1274 #'adjust:' #right |
1254 #'resizeForLabel:' true |
1275 #'resizeForLabel:' true |
1255 ) |
1276 ) |
1256 #(#InputFieldSpec |
1277 #(#InputFieldSpec |
1257 #'name:' 'shortcutKeyField' |
1278 #'name:' 'shortcutKeyField' |
1258 #'layout:' #(#LayoutFrame 91 0 22 0 0 1.0 44 0) |
1279 #'layout:' #(#LayoutFrame 90 0 15 0 0 1.0 37 0) |
1259 #'activeHelpKey:' #shortcutKey |
1280 #'activeHelpKey:' #shortcutKey |
1260 #'tabable:' true |
1281 #'tabable:' true |
1261 #'model:' #shortcutKey |
1282 #'model:' #shortcutKey |
1262 #'type:' #symbolOrNil |
1283 #'type:' #symbolOrNil |
1263 ) |
1284 ) |
1264 #(#LabelSpec |
1285 #(#LabelSpec |
1265 #'name:' 'enabledLabel' |
1286 #'name:' 'enabledLabel' |
1266 #'layout:' #(#AlignmentOrigin 87 0 59 0 1 0.5) |
1287 #'layout:' #(#AlignmentOrigin 87 0 51 0 1 0.5) |
1267 #'label:' 'Enabled:' |
1288 #'label:' 'Enabled:' |
1268 #'adjust:' #right |
1289 #'adjust:' #right |
1269 #'resizeForLabel:' true |
1290 #'resizeForLabel:' true |
1270 ) |
1291 ) |
1271 #(#InputFieldSpec |
1292 #(#InputFieldSpec |
1272 #'name:' 'enabledField' |
1293 #'name:' 'enabledField' |
1273 #'layout:' #(#LayoutFrame 91 0 48 0 0 1.0 70 0) |
1294 #'layout:' #(#LayoutFrame 90 0 40 0 0 1.0 62 0) |
1274 #'activeHelpKey:' #enbled |
1295 #'activeHelpKey:' #enbled |
1275 #'tabable:' true |
1296 #'tabable:' true |
1276 #'model:' #enabled |
1297 #'model:' #enabled |
1277 #'type:' #symbolOrNil |
1298 #'type:' #symbolOrNil |
1278 ) |
1299 ) |
1279 #(#LabelSpec |
1300 #(#LabelSpec |
1280 #'name:' 'accessCharLabel' |
1301 #'name:' 'accessCharLabel' |
1281 #'layout:' #(#AlignmentOrigin 211 0 127 0 1 0.5) |
1302 #'layout:' #(#AlignmentOrigin 171 0 90 0 1 0.5) |
1282 #'label:' 'Access Character Position:' |
1303 #'label:' 'Access Character Position:' |
1283 #'adjust:' #right |
1304 #'adjust:' #right |
1284 #'resizeForLabel:' true |
1305 #'resizeForLabel:' true |
1285 ) |
1306 ) |
1286 #(#InputFieldSpec |
1307 #(#InputFieldSpec |
1287 #'name:' 'accessCharField' |
1308 #'name:' 'accessCharField' |
1288 #'layout:' #(#LayoutFrame 215 0 116 0 0 1.0 138 0) |
1309 #'layout:' #(#LayoutFrame 177 0 79 0 0 1.0 101 0) |
1289 #'activeHelpKey:' #accessCharaterPos |
1310 #'activeHelpKey:' #accessCharaterPos |
1290 #'tabable:' true |
1311 #'tabable:' true |
1291 #'model:' #accessCharaterPos |
1312 #'model:' #accessCharaterPos |
1292 #'type:' #numberOrNil |
1313 #'type:' #numberOrNil |
1293 ) |
1314 ) |
1294 ) |
1315 ) |
1295 ) |
1316 ) |
1296 ) |
1317 ) |
1297 ! |
1318 ! |
1298 |
1319 |
1299 miscEditSpec |
1320 imageEditSpec |
1300 "this window spec was automatically generated by the ST/X UIPainter" |
1321 "this window spec was automatically generated by the ST/X UIPainter" |
1301 |
1322 |
1302 "do not manually edit this - the painter/builder may not be able to |
1323 "do not manually edit this - the painter/builder may not be able to |
1303 handle the specification if its corrupted." |
1324 handle the specification if its corrupted." |
1304 |
1325 |
1305 " |
1326 " |
1306 UIPainter new openOnClass:MenuEditor andSelector:#miscEditSpec |
1327 UIPainter new openOnClass:MenuEditor andSelector:#imageEditSpec |
1307 MenuEditor new openInterface:#miscEditSpec |
1328 MenuEditor new openInterface:#imageEditSpec |
1308 " |
1329 " |
1309 |
1330 |
1310 <resource: #canvas> |
1331 <resource: #canvas> |
1311 |
1332 |
1312 ^ |
1333 ^ |
1313 |
1334 |
1314 #(#FullSpec |
1335 #(#FullSpec |
1315 #'window:' |
1336 #'window:' |
1316 #(#WindowSpec |
1337 #(#WindowSpec |
1317 #'name:' 'unnamed canvas' |
1338 #'name:' 'unnamed canvas' |
1318 #'layout:' #(#LayoutFrame 441 0 301 0 685 0 442 0) |
1339 #'layout:' #(#LayoutFrame 197 0 172 0 441 0 313 0) |
1319 #'label:' 'unnamed canvas' |
1340 #'label:' 'unnamed canvas' |
1320 #'min:' #(#Point 10 10) |
1341 #'min:' #(#Point 10 10) |
1321 #'max:' #(#Point 1280 1024) |
1342 #'max:' #(#Point 1280 1024) |
1322 #'bounds:' #(#Rectangle 441 301 686 443) |
1343 #'bounds:' #(#Rectangle 197 172 442 314) |
1323 #'usePreferredExtent:' false |
1344 #'usePreferredExtent:' false |
1324 ) |
1345 ) |
1325 #'component:' |
1346 #'component:' |
1326 #(#SpecCollection |
1347 #(#SpecCollection |
1327 #'collection:' |
1348 #'collection:' |
1328 #( |
1349 #( |
1329 #(#LabelSpec |
1350 #(#LabelSpec |
1330 #'name:' 'retrieverLabel' |
1351 #'name:' 'retrieverLabel' |
1331 #'layout:' #(#AlignmentOrigin 77 0 26 0 1 0.5) |
1352 #'layout:' #(#AlignmentOrigin 87 0 26 0 1 0.5) |
1332 #'label:' 'Retriever:' |
1353 #'label:' 'Retriever:' |
1333 #'adjust:' #right |
1354 #'adjust:' #right |
1334 #'resizeForLabel:' true |
1355 #'resizeForLabel:' true |
1335 ) |
1356 ) |
1336 #(#InputFieldSpec |
1357 #(#InputFieldSpec |
1337 #'name:' 'retrieverField' |
1358 #'name:' 'retrieverField' |
1338 #'layout:' #(#LayoutFrame 81 0 15 0 0 1.0 37 0) |
1359 #'layout:' #(#LayoutFrame 90 0 15 0 0 1.0 37 0) |
1339 #'activeHelpKey:' #retriever |
1360 #'activeHelpKey:' #retriever |
1340 #'tabable:' true |
1361 #'tabable:' true |
1341 #'model:' #retriever |
1362 #'model:' #retriever |
1342 #'type:' #symbolOrNil |
1363 #'type:' #symbolOrNil |
1343 ) |
1364 ) |
1344 #(#LabelSpec |
1365 #(#LabelSpec |
1345 #'name:' 'iconLabel' |
1366 #'name:' 'iconLabel' |
1346 #'layout:' #(#AlignmentOrigin 77 0 50 0 1 0.5) |
1367 #'layout:' #(#AlignmentOrigin 87 0 51 0 1 0.5) |
1347 #'label:' 'Icon:' |
1368 #'label:' 'Selector:' |
1348 #'adjust:' #right |
1369 #'adjust:' #right |
1349 #'resizeForLabel:' true |
1370 #'resizeForLabel:' true |
1350 ) |
1371 ) |
1351 #(#InputFieldSpec |
1372 #(#InputFieldSpec |
1352 #'name:' 'iconField' |
1373 #'name:' 'iconField' |
1353 #'layout:' #(#LayoutFrame 81 0 39 0 0 1.0 61 0) |
1374 #'layout:' #(#LayoutFrame 90 0 40 0 0 1.0 62 0) |
1354 #'activeHelpKey:' #icon |
1375 #'activeHelpKey:' #icon |
1355 #'tabable:' true |
1376 #'tabable:' true |
1356 #'model:' #icon |
1377 #'model:' #icon |
1357 #'type:' #symbolOrNil |
1378 #'type:' #symbolOrNil |
1358 ) |
1379 ) |
1359 #(#CheckBoxSpec |
1380 #(#CheckBoxSpec |
1360 #'name:' 'iconAndLabel' |
1381 #'name:' 'iconAndLabel' |
1361 #'layout:' #(#LayoutOrigin 15 0 103 0) |
1382 #'layout:' #(#LayoutOrigin 20 0 104 0) |
1362 #'activeHelpKey:' #iconAndLabel |
1383 #'activeHelpKey:' #iconAndLabel |
1363 #'tabable:' true |
1384 #'tabable:' true |
1364 #'model:' #iconAndLabel |
1385 #'model:' #iconAndLabel |
1365 #'label:' 'Icon & Label' |
1386 #'label:' 'Image & Label' |
1366 ) |
1387 ) |
1367 #(#ActionButtonSpec |
1388 #(#ActionButtonSpec |
1368 #'name:' 'imageEditorButton' |
1389 #'name:' 'imageEditorButton' |
1369 #'layout:' #(#LayoutFrame 81 0 65 0 0 1 87 0) |
1390 #'layout:' #(#LayoutFrame 90 0 66 0 0 1 90 0) |
1370 #'label:' 'Image Editor' |
1391 #'label:' 'Image Editor' |
1371 #'model:' #doEditImage |
1392 #'model:' #doEditImage |
1372 ) |
1393 ) |
1373 ) |
1394 ) |
1374 ) |
1395 ) |
1389 |
1410 |
1390 ! ! |
1411 ! ! |
1391 |
1412 |
1392 !MenuEditor methodsFor:'accessing'! |
1413 !MenuEditor methodsFor:'accessing'! |
1393 |
1414 |
1415 isModified: aBoolean |
|
1416 |
|
1417 isModified := aBoolean |
|
1418 ! |
|
1419 |
|
1394 menuDefaultLink |
1420 menuDefaultLink |
1395 ^ self class menuDefaultLink |
1421 ^ self class menuDefaultLink |
1396 ! |
1422 ! |
1397 |
1423 |
1398 selectorName |
1424 selectorName |
1429 self helpTool dictionary:aDictionary. |
1455 self helpTool dictionary:aDictionary. |
1430 ! ! |
1456 ! ! |
1431 |
1457 |
1432 !MenuEditor methodsFor:'accessing menu'! |
1458 !MenuEditor methodsFor:'accessing menu'! |
1433 |
1459 |
1460 menu |
|
1461 "this window spec was automatically generated by the UI Builder" |
|
1462 |
|
1463 ^ self class menu |
|
1464 |
|
1465 |
|
1466 ! |
|
1467 |
|
1434 menuButtons |
1468 menuButtons |
1435 "this window spec was automatically generated by the ST/X MenuEditor" |
1469 "this window spec was automatically generated by the ST/X MenuEditor" |
1436 |
1470 |
1437 ^ self class menuButtons |
1471 ^ self class menuButtons |
1438 |
1472 |
1449 |
1483 |
1450 menuPullDown |
1484 menuPullDown |
1451 "this window spec was automatically generated by the ST/X MenuEditor" |
1485 "this window spec was automatically generated by the ST/X MenuEditor" |
1452 |
1486 |
1453 ^ self class menuPullDown |
1487 ^ self class menuPullDown |
1488 |
|
1489 |
|
1490 ! |
|
1491 |
|
1492 menuToolbar |
|
1493 "this window spec was automatically generated by the UI Builder" |
|
1494 |
|
1495 ^ self class menuToolbar |
|
1454 |
1496 |
1455 |
1497 |
1456 ! ! |
1498 ! ! |
1457 |
1499 |
1458 !MenuEditor methodsFor:'actions'! |
1500 !MenuEditor methodsFor:'actions'! |
1784 |
1826 |
1785 (self isStandAlone and:[oldClass ~= newClass]) ifTrue:[ |
1827 (self isStandAlone and:[oldClass ~= newClass]) ifTrue:[ |
1786 self helpTool helpSpecFrom:newClass |
1828 self helpTool helpSpecFrom:newClass |
1787 ]. |
1829 ]. |
1788 self painter buildFrom:newClass andSelector:aSelector. |
1830 self painter buildFrom:newClass andSelector:aSelector. |
1831 |
|
1832 aClass notNil & aSelector notNil |
|
1833 ifTrue: |
|
1834 [ |
|
1835 |className message| |
|
1836 aClass isClass ifTrue: [className := aClass name]. |
|
1837 aClass isString ifTrue: [className := aClass]. |
|
1838 message := className, ' ', aSelector. |
|
1839 self addToHistory: message -> #loadFromMessage:. |
|
1840 self valueOfInfoLabel value: className, ' << ', aSelector |
|
1841 ]. |
|
1842 |
|
1843 |
|
1844 ! |
|
1845 |
|
1846 checkModified |
|
1847 "check menu modification |
|
1848 " |
|
1849 isModified |
|
1850 ifTrue: |
|
1851 [ |
|
1852 ((YesNoBox title:'Menu was modified!!') |
|
1853 noText:'Cancel'; |
|
1854 yesText:'Waste it and proceed'; |
|
1855 showAtPointer; |
|
1856 accepted) ifFalse: [^false]. |
|
1857 isModified := false |
|
1858 ]. |
|
1859 ^true |
|
1860 |
|
1861 |
|
1789 ! |
1862 ! |
1790 |
1863 |
1791 closeRequest |
1864 closeRequest |
1792 "close request |
1865 "close request |
1793 " |
1866 " |
1794 isModified ifTrue:[ |
1867 self checkModified ifTrue: [super closeRequest] |
1795 (self confirm:'quit without without saving your modifications ?') ifFalse:[ |
|
1796 ^ self |
|
1797 ] |
|
1798 ]. |
|
1799 super closeRequest. |
|
1800 |
1868 |
1801 |
1869 |
1802 |
1870 |
1803 |
1871 |
1804 |
1872 |
1820 submenuChannel |
1888 submenuChannel |
1821 enabled |
1889 enabled |
1822 value |
1890 value |
1823 nameKey |
1891 nameKey |
1824 indication |
1892 indication |
1893 translateLabel |
|
1894 isButton |
|
1825 shortcutKey |
1895 shortcutKey |
1826 retriever |
1896 retriever |
1827 iconAndLabel |
1897 iconAndLabel |
1828 icon |
1898 icon |
1829 |
1899 |
1835 aspects at:#seperatorSelection put:(holder := SelectionInList new). |
1905 aspects at:#seperatorSelection put:(holder := SelectionInList new). |
1836 holder list:(Item separatorList). |
1906 holder list:(Item separatorList). |
1837 holder addDependent:self. |
1907 holder addDependent:self. |
1838 |
1908 |
1839 |
1909 |
1910 ! |
|
1911 |
|
1912 loadFromMessage: aMessage |
|
1913 |
|
1914 self checkModified ifTrue: |
|
1915 [ |
|
1916 |readStream aClass aSelector| |
|
1917 readStream := aMessage readStream. |
|
1918 aClass := Smalltalk at: (readStream upTo: $ ) asSymbol. |
|
1919 aSelector := readStream upToEnd asSymbol. |
|
1920 self buildFrom: aClass andSelector: aSelector. |
|
1921 self painter selection: nil |
|
1922 ] |
|
1840 ! |
1923 ! |
1841 |
1924 |
1842 openModalOnClass:aClass andSelector:aSelector |
1925 openModalOnClass:aClass andSelector:aSelector |
1843 specClass := Association key:aClass value:aSelector. |
1926 specClass := Association key:aClass value:aSelector. |
1844 super openInterfaceModal. |
1927 super openInterfaceModal. |
1883 cls := self resolveName:(self specClass). |
1966 cls := self resolveName:(self specClass). |
1884 |
1967 |
1885 cls notNil ifTrue:[ |
1968 cls notNil ifTrue:[ |
1886 SystemBrowser openInClass:cls class selector:(self painter selectorName) |
1969 SystemBrowser openInClass:cls class selector:(self painter selectorName) |
1887 ] ifFalse:[ |
1970 ] ifFalse:[ |
1888 self information:'no valid class defined'. |
1971 self information:'No valid class defined!!'. |
1889 ] |
1972 ] |
1890 ! |
1973 ! |
1891 |
1974 |
1892 doDefineClass |
1975 doDefineClass |
1893 |
1976 |
1899 |
1982 |
1900 ! |
1983 ! |
1901 |
1984 |
1902 doEditImage |
1985 doEditImage |
1903 |
1986 |
1904 ImageEditor open loadFromMessage: ((aspects at:#retriever) value ? specClass ? '') , ' ', ((aspects at:#icon) value ? '') |
1987 |cls resourceClass resourceSelector imageResourceMessage readStream| |
1988 |
|
1989 cls := self resolveName:(self specClass). |
|
1990 cls isNil ifTrue:[ |
|
1991 ^ self information:'No valid class defined!!'. |
|
1992 ]. |
|
1993 (aspects at:#retriever) value size > 0 |
|
1994 ifTrue: [resourceClass := (aspects at:#retriever) value] |
|
1995 ifFalse: [resourceClass := cls]. |
|
1996 (aspects at:#icon) value size > 0 |
|
1997 ifTrue: [resourceSelector := (aspects at:#icon) value] |
|
1998 ifFalse: [resourceSelector := #stxIcon]. |
|
1999 imageResourceMessage := ImageEditor openModalOnClass: resourceClass andSelector: resourceSelector. |
|
2000 readStream := imageResourceMessage readStream. |
|
2001 resourceClass := (readStream upTo: $ ) asSymbol. |
|
2002 resourceSelector := readStream upToEnd asSymbol. |
|
2003 resourceClass size > 0 ifTrue: [(aspects at:#retriever) value: resourceClass]. |
|
2004 resourceSelector size > 0 ifTrue: [(aspects at:#icon) value: resourceSelector]. |
|
2005 |
|
2006 (aspects at:#retriever) value = specClass |
|
2007 ifTrue: |
|
2008 [ |
|
2009 (aspects at:#retriever) value: nil |
|
2010 ] |
|
2011 |
|
1905 ! |
2012 ! |
1906 |
2013 |
1907 doFromClass |
2014 doFromClass |
1908 |
2015 |
1909 aspects at:#classNameChannel put:(self specClass asValue). |
2016 aspects at:#classNameChannel put:(self specClass asValue). |
1927 |cls selector painter menu spec mthd category code| |
2034 |cls selector painter menu spec mthd category code| |
1928 |
2035 |
1929 cls := self resolveName:(self specClass). |
2036 cls := self resolveName:(self specClass). |
1930 |
2037 |
1931 cls isNil ifTrue:[ |
2038 cls isNil ifTrue:[ |
1932 ^ self information:'no valid class defined'. |
2039 ^ self information:'No valid class defined!!'. |
1933 ]. |
2040 ]. |
1934 painter := self painter. |
2041 painter := self painter. |
1935 selector := painter selectorName. |
2042 selector := painter selectorName. |
1936 menu := painter asMenu. |
2043 menu := painter asMenu. |
1937 |
2044 |
1938 menu isNil ifTrue:[ |
2045 menu isNil ifTrue:[ |
1939 ^ self information:'no menu defined' |
2046 ^ self information:'No menu defined.' |
1940 ]. |
2047 ]. |
1941 menu := menu literalArrayEncoding. |
2048 menu := menu literalArrayEncoding. |
1942 spec := WriteStream on:String new. |
2049 spec := WriteStream on:String new. |
1943 UISpecification prettyPrintSpecArray:menu on:spec indent:5. |
2050 UISpecification prettyPrintSpecArray:menu on:spec indent:5. |
1944 spec := spec contents. |
2051 spec := spec contents. |
1986 isModified := false. |
2093 isModified := false. |
1987 |
2094 |
1988 ! |
2095 ! |
1989 |
2096 |
1990 doNew |
2097 doNew |
2098 |
|
1991 self buildFrom:nil andSelector:(self painter selectorName) |
2099 self buildFrom:nil andSelector:(self painter selectorName) |
1992 ! |
2100 ! |
1993 |
2101 |
1994 doPickAMenu |
2102 doPickAMenu |
1995 |
2103 |
2007 ! |
2115 ! |
2008 |
2116 |
2009 doStepDown |
2117 doStepDown |
2010 "move selected child after next child |
2118 "move selected child after next child |
2011 " |
2119 " |
2012 self painter selectedNodeChangeSequenceOrder:1 |
2120 self painter selectedNodeChangeSequenceOrder:1. |
2121 isModified := true. |
|
2122 |
|
2123 |
|
2124 |
|
2125 |
|
2013 ! |
2126 ! |
2014 |
2127 |
2015 doStepIn |
2128 doStepIn |
2016 self painter selectedNodeBecomeChildOfNext |
2129 "move selected child into next parent node |
2130 " |
|
2131 self painter selectedNodeBecomeChildOfNext. |
|
2132 isModified := true. |
|
2133 |
|
2134 |
|
2135 |
|
2136 |
|
2017 |
2137 |
2018 ! |
2138 ! |
2019 |
2139 |
2020 doStepOut |
2140 doStepOut |
2021 self painter selectedNodeBecomeSisterOfParent |
2141 "move selected child out from parent node |
2142 " |
|
2143 self painter selectedNodeBecomeSisterOfParent. |
|
2144 isModified := true. |
|
2022 ! |
2145 ! |
2023 |
2146 |
2024 doStepUp |
2147 doStepUp |
2025 "move selected child after next child |
2148 "move selected child before previous child |
2026 " |
2149 " |
2027 self painter selectedNodeChangeSequenceOrder:-1 |
2150 self painter selectedNodeChangeSequenceOrder:-1. |
2151 isModified := true. |
|
2028 ! ! |
2152 ! ! |
2029 |
2153 |
2030 !MenuEditor methodsFor:'values'! |
2154 !MenuEditor methodsFor:'values'! |
2031 |
2155 |
2032 painter |
2156 painter |
2131 " |
2255 " |
2132 |item rcv| |
2256 |item rcv| |
2133 |
2257 |
2134 item := MenuItem labeled:label. |
2258 item := MenuItem labeled:label. |
2135 |
2259 |
2136 self isSeparator ifFalse:[ |
2260 self isSeparator ifFalse:[ |
2137 item activeHelpKey:activeHelpKey. |
2261 item activeHelpKey:activeHelpKey. |
2138 item enabled:enabled. |
2262 item enabled:enabled. |
2139 item accessCharacterPosition:accessCharaterPos. |
2263 item accessCharacterPosition:accessCharaterPos. |
2140 item argument:argument. |
2264 item argument:argument. |
2141 item submenuChannel:submenuChannel. |
2265 item submenuChannel:submenuChannel. |
2142 item nameKey:nameKey. |
2266 item nameKey:nameKey. |
2143 item shortcutKeyCharacter:shortcutKey. |
2267 item shortcutKeyCharacter:shortcutKey. |
2144 item value:value. |
2268 item value:value. |
2145 item indication:indication. |
2269 item indication:indication. |
2270 item translateLabel: translateLabel. |
|
2271 item isButton: isButton. |
|
2146 |
2272 |
2147 icon notNil ifTrue:[ |
2273 icon notNil ifTrue:[ |
2148 rcv := ResourceRetriever new. |
2274 rcv := ResourceRetriever new. |
2149 rcv className:retriever. |
2275 rcv className:retriever. |
2150 rcv selector:icon. |
2276 rcv selector:icon. |
2173 nameKey := (aspects at:#nameKey) value. |
2299 nameKey := (aspects at:#nameKey) value. |
2174 indication := (aspects at:#indication) value. |
2300 indication := (aspects at:#indication) value. |
2175 shortcutKey := (aspects at:#shortcutKey) value. |
2301 shortcutKey := (aspects at:#shortcutKey) value. |
2176 accessCharaterPos := (aspects at:#accessCharaterPos) value. |
2302 accessCharaterPos := (aspects at:#accessCharaterPos) value. |
2177 argument := (aspects at:#argument) value. |
2303 argument := (aspects at:#argument) value. |
2304 translateLabel := (aspects at:#translateLabel) value. |
|
2305 isButton := (aspects at:#isButton) value. |
|
2178 |
2306 |
2179 argument isString ifTrue:[ |
2307 argument isString ifTrue:[ |
2180 argument size > 1 ifTrue:[ |
2308 argument size > 1 ifTrue:[ |
2181 (argument at:1) == $# ifTrue:[ |
2309 (argument at:1) == $# ifTrue:[ |
2182 argument := (argument copyFrom:2) asSymbol |
2310 argument := (argument copyFrom:2) asSymbol |
2214 nameKey := anItem nameKey. |
2342 nameKey := anItem nameKey. |
2215 shortcutKey := anItem shortcutKeyCharacter. |
2343 shortcutKey := anItem shortcutKeyCharacter. |
2216 accessCharaterPos := anItem accessCharacterPosition. |
2344 accessCharaterPos := anItem accessCharacterPosition. |
2217 argument := anItem argument. |
2345 argument := anItem argument. |
2218 submenuChannel := anItem submenuChannel. |
2346 submenuChannel := anItem submenuChannel. |
2347 translateLabel := anItem translateLabel. |
|
2348 isButton := anItem isButton. |
|
2219 |
2349 |
2220 ( ((rtv := anItem adornment) notNil) |
2350 ( ((rtv := anItem adornment) notNil) |
2221 and:[(rtv := rtv labelImage) isKindOf:ResourceRetriever] |
2351 and:[(rtv := rtv labelImage) isKindOf:ResourceRetriever] |
2222 ) ifTrue:[ |
2352 ) ifTrue:[ |
2223 retriever := rtv className. |
2353 retriever := rtv className. |
2241 (aspects at:#value) value:value. |
2371 (aspects at:#value) value:value. |
2242 (aspects at:#nameKey) value:nameKey. |
2372 (aspects at:#nameKey) value:nameKey. |
2243 (aspects at:#indication) value:indication. |
2373 (aspects at:#indication) value:indication. |
2244 (aspects at:#shortcutKey) value:shortcutKey. |
2374 (aspects at:#shortcutKey) value:shortcutKey. |
2245 (aspects at:#accessCharaterPos) value:accessCharaterPos. |
2375 (aspects at:#accessCharaterPos) value:accessCharaterPos. |
2376 (aspects at:#translateLabel) value:translateLabel. |
|
2377 (aspects at:#isButton) value:isButton. |
|
2246 |
2378 |
2247 argument isSymbol ifTrue:[ |
2379 argument isSymbol ifTrue:[ |
2248 (aspects at:#argument) value:'#', argument |
2380 (aspects at:#argument) value:'#', argument |
2249 ] ifFalse:[ |
2381 ] ifFalse:[ |
2250 (aspects at:#argument) value:argument. |
2382 (aspects at:#argument) value:argument. |
2262 "returns true if item is a seperator |
2394 "returns true if item is a seperator |
2263 " |
2395 " |
2264 ^ self separatorType notNil |
2396 ^ self separatorType notNil |
2265 ! ! |
2397 ! ! |
2266 |
2398 |
2267 !MenuEditor::Painter class methodsFor:'constants'! |
|
2268 |
|
2269 imageItem |
|
2270 ^ self images at:#item |
|
2271 ! |
|
2272 |
|
2273 imageMenu |
|
2274 ^ self images at:#menuOpen |
|
2275 ! |
|
2276 |
|
2277 imageMenuLink |
|
2278 ^ self images at:#menuLink |
|
2279 |
|
2280 ! |
|
2281 |
|
2282 imageSeparator |
|
2283 ^ self images at:#separator |
|
2284 |
|
2285 ! |
|
2286 |
|
2287 images |
|
2288 "returns an IdentityDictionary containing a list of images and keys used |
|
2289 " |
|
2290 <resource: #fileImage> |
|
2291 |
|
2292 |image| |
|
2293 |
|
2294 Images notNil ifTrue:[ |
|
2295 ^ Images |
|
2296 ]. |
|
2297 |
|
2298 Images := IdentityDictionary new. |
|
2299 |
|
2300 #( |
|
2301 (#item 'ui_menuitem.xpm') |
|
2302 (#menuClosed 'ui_submenu.xpm') |
|
2303 (#menuOpen 'ui_submenu_open.xpm') |
|
2304 (#menuLink 'ui_submenulink.xpm') |
|
2305 (#separator 'ui_menusep.xpm') |
|
2306 |
|
2307 ) do:[:el | |
|
2308 image := Image fromFile:( el last ). |
|
2309 Images at:(el first) put:image. |
|
2310 ]. |
|
2311 |
|
2312 ^ Images |
|
2313 |
|
2314 |
|
2315 |
|
2316 ! ! |
|
2317 |
|
2318 !MenuEditor::Painter class methodsFor:'defaults'! |
2399 !MenuEditor::Painter class methodsFor:'defaults'! |
2319 |
2400 |
2320 defaultMenuMessage |
2401 defaultMenuMessage |
2321 "This message is the default yo be sent to the menuHolder to get a menu |
2402 "This message is the default yo be sent to the menuHolder to get a menu |
2322 " |
2403 " |
2340 Claus Atzkern |
2421 Claus Atzkern |
2341 " |
2422 " |
2342 |
2423 |
2343 |
2424 |
2344 ! ! |
2425 ! ! |
2426 |
|
2427 !MenuEditor::Painter class methodsFor:'resources'! |
|
2428 |
|
2429 closedSubmenuImage |
|
2430 "ImageEditor openOnClass:self andSelector:#closedSubmenuImage" |
|
2431 |
|
2432 <resource: #image> |
|
2433 ^(Depth2Image new) width: 22; height: 22; photometric:(#palette); bitsPerSample:(#(2 )); samplesPerPixel:(1); bits:(#[0 0 0 0 0 0 21 85 85 85 85 128 26 170 170 170 170 192 26 170 170 170 170 192 31 255 255 255 255 199 16 0 0 0 0 192 21 85 85 85 85 204 26 170 170 170 170 192 26 170 170 170 170 192 31 255 255 255 255 200 16 0 0 0 0 192 21 85 85 85 85 192 26 170 170 170 170 192 26 170 170 170 170 207 31 255 255 255 255 192 16 0 0 0 0 192 21 85 85 85 85 192 26 170 170 170 170 192 26 170 170 170 170 192 47 255 255 255 255 192 0 0 0 0 0 0 0 0 0 0 0 0]) ; colorMap:(((Array new:4) at:1 put:((Color black)); at:2 put:((Color white)); at:3 put:((Color grey:66.9978)); at:4 put:((Color grey:49.9962)); yourself)); mask:((Depth1Image new) width: 22; height: 22; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(#[255 255 252 255 255 252 255 255 252 255 255 252 255 255 252 255 255 252 255 255 252 255 255 252 255 255 252 255 255 252 255 255 252 255 255 252 255 255 252 255 255 252 255 255 252 255 255 252 255 255 252 255 255 252 255 255 252 255 255 252 255 255 252 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0]) ; yourself); yourself! |
|
2434 |
|
2435 images |
|
2436 "returns an IdentityDictionary containing a list of images and keys used |
|
2437 " |
|
2438 ^ Images ? |
|
2439 (Images := IdentityDictionary new |
|
2440 at: #menuItemImage put: self menuItemImage; |
|
2441 at: #openedSubmenuImage put: self openedSubmenuImage; |
|
2442 at: #closedSubmenuImage put: self closedSubmenuImage; |
|
2443 at: #linkSubmenuImage put: self linkSubmenuImage; |
|
2444 at: #menuSeparatorImage put: self menuSeparatorImage; |
|
2445 yourself) |
|
2446 |
|
2447 |
|
2448 |
|
2449 ! |
|
2450 |
|
2451 linkSubmenuImage |
|
2452 "ImageEditor openOnClass:self andSelector:#linkSubmenuImage" |
|
2453 |
|
2454 <resource: #image> |
|
2455 ^(Depth4Image new) width: 22; height: 22; photometric:(#palette); bitsPerSample:(#(4 )); samplesPerPixel:(1); bits:(#[0 0 0 0 0 0 0 0 0 0 0 1 17 17 17 17 17 17 17 17 17 32 1 34 34 34 34 34 34 34 34 34 240 1 34 34 34 34 34 34 34 34 34 240 1 255 255 255 255 255 255 255 255 255 240 1 0 0 0 0 0 0 0 0 0 240 1 3 51 51 1 17 17 17 17 17 240 1 3 51 51 48 34 34 34 34 34 240 1 3 51 51 51 2 34 34 34 34 240 1 3 51 51 51 48 255 255 255 255 240 1 0 0 0 51 51 0 0 0 0 240 1 17 17 17 3 51 48 16 48 17 240 1 34 34 34 32 51 51 0 51 2 240 1 34 34 34 34 3 51 51 51 48 240 1 255 255 255 255 240 51 51 51 51 0 1 0 0 0 0 0 3 51 51 48 240 1 17 17 17 17 17 16 0 51 1 240 1 34 34 34 34 34 34 32 48 34 240 1 34 34 34 34 34 34 32 2 34 240 2 255 255 255 255 255 255 255 255 255 240 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0]) ; colorMap:((OrderedCollection new add:(Color black); add:(Color white); add:(Color grey:66.9978); add:(Color red:100.0 green:0.0 blue:0.0); add:(Color red:0.0 green:100.0 blue:0.0); add:(Color red:0.0 green:0.0 blue:100.0); add:(Color red:0.0 green:100.0 blue:100.0); add:(Color red:100.0 green:100.0 blue:0.0); add:(Color red:100.0 green:0.0 blue:100.0); add:(Color red:49.9962 green:0.0 blue:0.0); add:(Color red:0.0 green:49.9962 blue:0.0); add:(Color red:0.0 green:0.0 blue:49.9962); add:(Color red:0.0 green:49.9962 blue:49.9962); add:(Color red:49.9962 green:49.9962 blue:0.0); add:(Color red:49.9962 green:0.0 blue:49.9962); add:(Color grey:49.9962); yourself)); mask:((Depth1Image new) width: 22; height: 22; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(#[255 255 252 255 255 252 255 255 252 255 255 252 255 255 252 255 255 252 255 255 252 255 255 252 255 255 252 255 255 252 255 255 252 255 255 252 255 255 252 255 255 252 255 255 252 255 255 252 255 255 252 255 255 252 255 255 252 255 255 252 255 255 252 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0]) ; yourself); yourself! |
|
2456 |
|
2457 menuItemImage |
|
2458 "ImageEditor openOnClass:self andSelector:#menuItemImage" |
|
2459 |
|
2460 <resource: #image> |
|
2461 ^(Depth2Image new) width: 22; height: 22; photometric:(#palette); bitsPerSample:(#(2 )); samplesPerPixel:(1); bits:(#[85 85 85 85 85 81 85 85 85 85 85 80 85 85 85 85 85 95 85 85 85 85 85 80 85 85 85 85 85 80 0 0 0 0 0 0 21 85 85 85 85 129 26 170 170 170 170 200 27 175 235 235 174 192 27 171 171 171 254 192 27 171 171 235 174 192 27 171 171 171 174 192 27 171 171 235 174 192 26 170 170 170 170 196 47 255 255 255 255 193 0 0 0 0 0 0 85 85 85 85 85 80 85 85 85 85 85 88 85 85 85 85 85 80 85 85 85 85 85 80 85 85 85 85 85 80 85 85 85 85 85 88]) ; colorMap:(((Array new:4) at:1 put:((Color black)); at:2 put:((Color white)); at:3 put:((Color grey:66.9978)); at:4 put:((Color grey:49.9977)); yourself)); mask:((Depth1Image new) width: 22; height: 22; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(#[0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 255 255 252 255 255 252 255 255 252 255 255 252 255 255 252 255 255 252 255 255 252 255 255 252 255 255 252 255 255 252 255 255 252 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0]) ; yourself); yourself! |
|
2462 |
|
2463 menuSeparatorImage |
|
2464 "ImageEditor openOnClass:self andSelector:#menuSeparatorImage" |
|
2465 |
|
2466 <resource: #image> |
|
2467 ^(Depth2Image new) width: 22; height: 22; photometric:(#palette); bitsPerSample:(#(2 )); samplesPerPixel:(1); bits:(#[85 85 85 85 85 82 85 85 85 85 85 80 85 85 85 85 85 80 85 85 85 85 85 80 85 85 85 85 85 80 0 0 0 0 0 0 21 85 85 85 85 128 26 170 170 170 170 196 26 170 170 170 170 195 27 255 255 255 250 192 27 0 0 0 6 192 26 85 85 85 86 200 26 170 170 170 170 192 26 170 170 170 170 192 47 255 255 255 255 206 0 0 0 0 0 8 85 85 85 85 85 80 85 85 85 85 85 80 85 85 85 85 85 87 85 85 85 85 85 88 85 85 85 85 85 80 85 85 85 85 85 80]) ; colorMap:(((Array new:4) at:1 put:((Color black)); at:2 put:((Color white)); at:3 put:((Color grey:66.9978)); at:4 put:((Color grey:49.9977)); yourself)); mask:((Depth1Image new) width: 22; height: 22; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(#[0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 255 255 252 255 255 252 255 255 252 255 255 252 255 255 252 255 255 252 255 255 252 255 255 252 255 255 252 255 255 252 255 255 252 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0]) ; yourself); yourself! |
|
2468 |
|
2469 openedSubmenuImage |
|
2470 "ImageEditor openOnClass:self andSelector:#openedSubmenuImage" |
|
2471 |
|
2472 <resource: #image> |
|
2473 ^(Depth2Image new) width: 22; height: 22; photometric:(#palette); bitsPerSample:(#(2 )); samplesPerPixel:(1); bits:(#[0 0 0 0 0 13 21 85 85 85 85 128 26 170 170 170 170 192 26 170 170 170 170 192 31 255 255 255 255 192 16 0 0 0 0 192 21 85 85 85 85 192 26 170 170 170 170 200 26 170 170 170 170 192 31 255 255 255 255 192 16 0 0 0 0 192 21 85 85 85 85 200 26 170 170 170 170 192 26 170 170 170 170 200 31 255 255 255 255 192 16 0 0 0 0 192 21 85 85 85 85 192 26 170 170 170 170 192 26 170 170 170 170 192 47 255 255 255 255 192 0 0 0 0 0 0 0 0 0 0 0 0]) ; colorMap:(((Array new:4) at:1 put:((Color black)); at:2 put:((Color white)); at:3 put:((Color grey:66.9978)); at:4 put:((Color grey:49.9962)); yourself)); mask:((Depth1Image new) width: 22; height: 22; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(#[255 255 252 255 255 252 255 255 252 255 255 252 255 255 252 255 255 252 255 255 252 255 255 252 255 255 252 255 255 252 255 255 252 255 255 252 255 255 252 255 255 252 255 255 252 255 255 252 255 255 252 255 255 252 255 255 252 255 255 252 255 255 252 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0]) ; yourself); yourself! ! |
|
2345 |
2474 |
2346 !MenuEditor::Painter methodsFor:'accessing'! |
2475 !MenuEditor::Painter methodsFor:'accessing'! |
2347 |
2476 |
2348 selectorName |
2477 selectorName |
2349 ^ (listOfNodes first contents label) asSymbol |
2478 ^ (listOfNodes first contents label) asSymbol |
2495 |
2624 |
2496 aNode hasChildren ifFalse:[ |
2625 aNode hasChildren ifFalse:[ |
2497 item := aNode contents. |
2626 item := aNode contents. |
2498 |
2627 |
2499 item submenuChannel notNil ifTrue:[ |
2628 item submenuChannel notNil ifTrue:[ |
2500 ^ images at:#menuLink |
2629 ^ images at:#linkSubmenuImage |
2501 ]. |
2630 ]. |
2502 |
2631 |
2503 item isSeparator ifTrue:[ |
2632 item isSeparator ifTrue:[ |
2504 ^ images at:#separator |
2633 ^ images at:#menuSeparatorImage |
2505 ]. |
2634 ]. |
2506 ^ images at:#item |
2635 ^ images at:#menuItemImage |
2507 ]. |
2636 ]. |
2508 |
2637 |
2509 aNode isExpandable ifTrue:[ |
2638 aNode isExpandable ifTrue:[ |
2510 ^ images at:#menuClosed |
2639 ^ images at:#closedSubmenuImage |
2511 ]. |
2640 ]. |
2512 ^ images at:#menuOpen |
2641 ^ images at:#openedSubmenuImage |
2513 ! ! |
2642 ! ! |
2514 |
2643 |
2515 !MenuEditor::Painter methodsFor:'event handling'! |
2644 !MenuEditor::Painter methodsFor:'event handling'! |
2516 |
2645 |
2517 keyPress:key x:x y:y |
2646 keyPress:key x:x y:y |
2562 ! ! |
2691 ! ! |
2563 |
2692 |
2564 !MenuEditor::Painter methodsFor:'menus'! |
2693 !MenuEditor::Painter methodsFor:'menus'! |
2565 |
2694 |
2566 doCopy |
2695 doCopy |
2696 |
|
2567 self hasSelection ifTrue:[ |
2697 self hasSelection ifTrue:[ |
2568 CopyBuffer := OrderedCollection new. |
2698 CopyBuffer := OrderedCollection new. |
2569 self selectionDo:[:i| CopyBuffer add:((listOfNodes at:i) copy)] |
2699 self selectionDo:[:i| CopyBuffer add:((listOfNodes at:i) copy)] |
2570 ] |
2700 ] |
2571 ! |
2701 ! |
2572 |
2702 |
2573 doCreateItem |
2703 doCreateItem |
2704 |
|
2574 self addElement:(self nodeLabel:'undefined') |
2705 self addElement:(self nodeLabel:'undefined') |
2706 |
|
2575 ! |
2707 ! |
2576 |
2708 |
2577 doCreateLink |
2709 doCreateLink |
2578 |node item| |
2710 |node item| |
2579 |
2711 |
2580 node := self nodeLabel:'undefined'. |
2712 node := self nodeLabel:'undefined'. |
2581 item := node contents. |
2713 item := node contents. |
2582 item submenuChannel:#menuDefaultLink. |
2714 item submenuChannel:#menuDefaultLink. |
2583 self addElement:node |
2715 self addElement:node. |
2584 |
2716 self setModified. |
2585 |
2717 |
2586 |
2718 |
2587 ! |
2719 ! |
2588 |
2720 |
2589 doCreateMenu |
2721 doCreateMenu |
2722 |
|
2590 |node| |
2723 |node| |
2591 |
|
2592 node := self nodeLabel:'undefined'. |
2724 node := self nodeLabel:'undefined'. |
2593 node add:(self nodeLabel:'undefined'). |
2725 node add:(self nodeLabel:'undefined'). |
2594 self addElement:node |
2726 self addElement:node |
2595 |
|
2596 ! |
2727 ! |
2597 |
2728 |
2598 doCreateSep |
2729 doCreateSep |
2730 |
|
2599 self addElement:(self nodeLabel:nil) |
2731 self addElement:(self nodeLabel:nil) |
2600 |
|
2601 ! |
2732 ! |
2602 |
2733 |
2603 doCut |
2734 doCut |
2735 |
|
2604 self doCopy. |
2736 self doCopy. |
2605 self selectedNodesRemove. |
2737 self selectedNodesRemove. |
2738 self setModified. |
|
2739 |
|
2740 |
|
2606 ! |
2741 ! |
2607 |
2742 |
2608 doPaste |
2743 doPaste |
2609 |
2744 |
2610 (CopyBuffer notNil and:[self selectedNode notNil]) ifTrue:[ |
2745 (CopyBuffer notNil and:[self selectedNode notNil]) ifTrue:[ |
2615 !MenuEditor::Painter methodsFor:'private'! |
2750 !MenuEditor::Painter methodsFor:'private'! |
2616 |
2751 |
2617 addElement:something |
2752 addElement:something |
2618 "add something after selection |
2753 "add something after selection |
2619 " |
2754 " |
2620 self selectedNodeAdd:something |
2755 self selectedNodeAdd:something. |
2756 self setModified. |
|
2621 ! |
2757 ! |
2622 |
2758 |
2623 nodeLabel:aLabel |
2759 nodeLabel:aLabel |
2624 ^ TreeItem name:aLabel contents:(MenuEditor::Item new label:aLabel). |
2760 ^ TreeItem name:aLabel contents:(MenuEditor::Item new label:aLabel). |
2761 ! |
|
2762 |
|
2763 setModified |
|
2764 |
|
2765 self topView application isModified: true |
|
2625 ! ! |
2766 ! ! |
2626 |
2767 |
2627 !MenuEditor::Painter methodsFor:'selection'! |
2768 !MenuEditor::Painter methodsFor:'selection'! |
2628 |
2769 |
2629 selectedNodeChanged |
2770 selectedNodeChanged |