author | Claus Gittinger <cg@exept.de> |
Fri, 01 Nov 2019 05:52:26 +0100 | |
changeset 19248 | 525d8b42574e |
parent 19216 | fd6f6d647048 |
child 19391 | e0e0f6428e4d |
permissions | -rw-r--r-- |
19248 | 1 |
"{ Encoding: utf8 }" |
2 |
||
5140 | 3 |
" |
4 |
COPYRIGHT (c) 2001 by eXept Software AG |
|
5 |
All Rights Reserved |
|
6 |
||
7 |
This software is furnished under a license and may be used |
|
8 |
only in accordance with the terms of that license and with the |
|
9 |
inclusion of the above copyright notice. This software may not |
|
10 |
be provided or otherwise made available to, or used by, any |
|
11 |
other person. No title to or ownership of the software is |
|
12 |
hereby transferred. |
|
13 |
" |
|
3154 | 14 |
"{ Package: 'stx:libtool' }" |
15 |
||
15234
e00c67bae495
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15046
diff
changeset
|
16 |
"{ NameSpace: Smalltalk }" |
e00c67bae495
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15046
diff
changeset
|
17 |
|
5303 | 18 |
MultiViewToolApplication subclass:#WorkspaceApplication |
9300
07364a10a823
syntax to choose from is fetched via ProgramminLanguage list;
Claus Gittinger <cg@exept.de>
parents:
9166
diff
changeset
|
19 |
instanceVariableNames:'autoDefineVariables syntaxHolder poolsConsideredInDoIts |
9695 | 20 |
smalltalkMenuEnabledHolder clipBoardWatcherProcess |
9735 | 21 |
fetchClipboardLines cursorLineHolder cursorColHolder |
13852 | 22 |
modeLabelHolder toolBarView namespaceHolder |
15817
f6046130309e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15816
diff
changeset
|
23 |
canChangeLanguageHolder cursorLineAndColumnInfoHolder |
18055 | 24 |
cursorLineAndColumnLabelHolder autoFetchSelectionHolder' |
13917
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
25 |
classVariableNames:'LastFilterBlockString LastProcessingBlockString |
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
26 |
LastGeneratorBlockString LastTeaWaitTime DefaultToolBarVisible |
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
27 |
ClipBoardFetchingInstance LastLanguage MyWorkspaceOpened |
16260 | 28 |
LastNamespace LastSnippetFilename' |
8315 | 29 |
poolDictionaries:'' |
30 |
category:'Interface-Smalltalk' |
|
3154 | 31 |
! |
32 |
||
3191 | 33 |
!WorkspaceApplication class methodsFor:'documentation'! |
34 |
||
5140 | 35 |
copyright |
36 |
" |
|
37 |
COPYRIGHT (c) 2001 by eXept Software AG |
|
38 |
All Rights Reserved |
|
39 |
||
40 |
This software is furnished under a license and may be used |
|
41 |
only in accordance with the terms of that license and with the |
|
42 |
inclusion of the above copyright notice. This software may not |
|
43 |
be provided or otherwise made available to, or used by, any |
|
44 |
other person. No title to or ownership of the software is |
|
45 |
hereby transferred. |
|
46 |
" |
|
47 |
! |
|
48 |
||
3191 | 49 |
documentation |
50 |
" |
|
51 |
A simple wrapper around a WorkSpace-View, adding a pullDown menu. |
|
52 |
||
53 |
[author:] |
|
54 |
Claus Gittinger |
|
55 |
" |
|
56 |
! ! |
|
3154 | 57 |
|
7825 | 58 |
!WorkspaceApplication class methodsFor:'defaults'! |
59 |
||
15833
b058e6078d5a
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15817
diff
changeset
|
60 |
default |
b058e6078d5a
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15817
diff
changeset
|
61 |
"a place where the default workspaceApplication could be hooked in; |
b058e6078d5a
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15817
diff
changeset
|
62 |
see SystemBrowser default and FileBrowser default on the intention..." |
b058e6078d5a
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15817
diff
changeset
|
63 |
|
b058e6078d5a
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15817
diff
changeset
|
64 |
^ self |
b058e6078d5a
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15817
diff
changeset
|
65 |
! |
b058e6078d5a
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15817
diff
changeset
|
66 |
|
8499 | 67 |
defaultEditToolbarVisible |
68 |
^ UserPreferences current editToolbarVisibleInWorkspace |
|
69 |
||
70 |
"Created: / 14-07-2007 / 16:42:50 / cg" |
|
71 |
! |
|
72 |
||
7825 | 73 |
defaultInfoVisible |
74 |
^ UserPreferences current infoVisibleInWorkspace |
|
75 |
||
76 |
"Created: / 14-07-2007 / 16:43:21 / cg" |
|
77 |
! |
|
78 |
||
10169 | 79 |
defaultMyWorkspaceDotWspFile |
10568 | 80 |
|stxFolder f | |
81 |
||
82 |
stxFolder := Filename homeDirectory / '.smalltalk'. |
|
83 |
f := stxFolder / 'MyWorkspace.wsp'. |
|
10169 | 84 |
f exists ifFalse:[ |
10568 | 85 |
stxFolder makeDirectory. |
86 |
||
10169 | 87 |
f writingFileDo:[:s| |
88 |
'MyWorkspace.wsp' asFilename exists ifTrue:[ |
|
89 |
s nextPutAll:('MyWorkspace.wsp' asFilename contentsAsString) |
|
90 |
] ifFalse:[ |
|
91 |
s nextPutLine: '"This is your personal workspace..."'. |
|
92 |
s nextPutLine: '"Edit and save as ', f pathName , '"'. |
|
10568 | 93 |
|
94 |
'MyWorkspaceSample.wsp' asFilename exists ifTrue:[ |
|
95 |
s nextPutAll:('MyWorkspaceSample.wsp' asFilename contentsAsString) |
|
96 |
] |
|
12393 | 97 |
]. |
98 |
s syncData. |
|
99 |
]. |
|
10169 | 100 |
]. |
101 |
^f |
|
102 |
||
103 |
"Created: / 21-06-2011 / 08:45:11 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
10317 | 104 |
"Modified: / 14-07-2011 / 13:08:30 / Administrator" |
10568 | 105 |
"Modified: / 10-08-2011 / 21:40:31 / cg" |
10169 | 106 |
! |
107 |
||
7825 | 108 |
defaultToolbarVisible |
109 |
^ UserPreferences current toolbarVisibleInWorkspace |
|
110 |
||
111 |
"Created: / 14-07-2007 / 16:42:50 / cg" |
|
8486 | 112 |
! |
113 |
||
17054 | 114 |
filterTemplate |
115 |
^ |
|
116 |
'"/ general text filter; |
|
117 |
"/ the following block should evaluate to true for all lines |
|
118 |
"/ you want to KEEP. |
|
119 |
"/ Lines for which the block returns false, will be removed. |
|
120 |
"/ Beginner warning: Smalltalk know-how is useful here. |
|
121 |
||
122 |
[:line :lineNr :previousLine :nextLine| |
|
123 |
"/ any condition on line. |
|
124 |
"/ Notice, that line might be a Text object (i.e. non-string), |
|
125 |
"/ so you may want to use ''line string''. |
|
126 |
"/ |
|
127 |
"/ Useful queries on the line are: |
|
128 |
"/ - size the length of the line |
|
129 |
"/ - hasChangeOfEmphasis any bold, italic etc. |
|
130 |
"/ - startsWith:someString |
|
131 |
"/ - endsWith:someString |
|
132 |
"/ - includesString:someString |
|
133 |
"/ - pattern match: |
|
134 |
||
135 |
"/ example filters |
|
136 |
"/ |
|
137 |
"/ -------- removes all empty lines --------------- |
|
138 |
"/ |
|
139 |
"/ line size > 0 |
|
140 |
||
141 |
"/ -------- removes all lines which do not end with some suffix ---------- |
|
142 |
"/ |
|
143 |
"/ (line asLowercase endsWith:''foo'') not |
|
144 |
||
145 |
"/ -------- removes duplicates ---------- |
|
146 |
"/ |
|
147 |
"/ (line = nextLine) not |
|
148 |
||
17055 | 149 |
"/ -------- keep lines which start with some suffix ---------- |
150 |
"/ |
|
151 |
"/ (line asLowercase startsWith:''foo'') |
|
152 |
||
153 |
"/ -------- keep lines which include some substring ---------- |
|
154 |
"/ |
|
155 |
"/ (line asLowercase includesString:''foo'') |
|
156 |
||
17054 | 157 |
"/ dummy filter (keeps all lines) |
158 |
"/ |
|
159 |
true |
|
160 |
] |
|
161 |
'. |
|
162 |
! |
|
163 |
||
164 |
generatorTemplate |
|
165 |
^ |
|
166 |
'"/ general text generator; |
|
167 |
"/ the following block is called with a write stream argument |
|
168 |
"/ and the generated text is inserted at the current cursor position |
|
169 |
"/ or replaces the current selection. |
|
170 |
"/ Beginner warning: Smalltalk know-how is useful here. |
|
171 |
||
172 |
[:outputStream :selectedText | |
|
173 |
"/ example generators |
|
174 |
||
175 |
"/ -------- generates N empty lines --------------- |
|
176 |
"/ |
|
177 |
"/ |n| |
|
178 |
"/ n := Dialog requestNumber:''how many empty lines:''. |
|
179 |
"/ n timesRepeat:[ outputStream nextPutLine:'''' ]. |
|
180 |
||
181 |
"/ -------- generates a table of binary numbers |
|
182 |
"/ |
|
183 |
"/ |n| |
|
184 |
"/ n := Dialog requestNumber:''how many numbers:''. |
|
185 |
"/ 1 to:n do:[:i | outputStream nextPutLine:(i raisedTo:i) printString ]. |
|
186 |
] |
|
187 |
' |
|
188 |
! |
|
189 |
||
190 |
textProcessorTemplate |
|
191 |
^ |
|
192 |
'"/ general text processor; |
|
193 |
"/ the following block should evaluate to a new line, |
|
194 |
"/ given the original line as argument. |
|
195 |
"/ Beginner warning: Smalltalk know-how is useful here. |
|
196 |
||
197 |
[:line | |
|
198 |
"/ any processing on line. |
|
199 |
"/ Notice, that line might be a Text object (i.e. non-string), |
|
200 |
"/ |
|
201 |
"/ Useful operations on the line are: |
|
202 |
"/ - '' .... '' , concatenation of any prefix/suffix |
|
203 |
"/ - leftPaddedTo:size padding |
|
204 |
"/ - rightPaddedTo:size padding |
|
205 |
"/ - copyTo:(size min:N) |
|
206 |
"/ - asUppercase |
|
207 |
"/ - asLowercase |
|
208 |
"/ - withoutSeparators remove whiteSpace |
|
209 |
"/ - asCollectionOfWords words |
|
210 |
||
211 |
"/ makes everything bold |
|
212 |
"/ |
|
213 |
"/ line allBold |
|
214 |
||
215 |
"/ first word only |
|
216 |
"/ |
|
217 |
"/ line withoutSeparators asCollectionOfWords first |
|
218 |
||
219 |
"/ dummy filter (keeps all lines as-is) |
|
220 |
"/ |
|
221 |
line |
|
222 |
] |
|
223 |
' |
|
224 |
! |
|
225 |
||
8486 | 226 |
webServiceLinkName |
227 |
^ '/workspace' |
|
7825 | 228 |
! ! |
229 |
||
8708 | 230 |
!WorkspaceApplication class methodsFor:'help specs'! |
231 |
||
17881 | 232 |
helpSpec |
8708 | 233 |
<resource: #help> |
234 |
||
17881 | 235 |
^ super helpSpec addPairsFrom:#( |
8708 | 236 |
|
12479 | 237 |
#editCopy |
238 |
'Copy the selected text to the clipboard' |
|
239 |
||
240 |
#editCut |
|
241 |
'Cut the selected text to the clipboard' |
|
242 |
||
243 |
#editDelete |
|
244 |
'Delete the selected text' |
|
245 |
||
10169 | 246 |
#addTerminal |
10277 | 247 |
'Add a tab with an embedded console-terminal' |
248 |
||
249 |
#addTerminalWindows |
|
18554
1a0789b603da
#UI_ENHANCEMENT by cgexept.de
Claus Gittinger <cg@exept.de>
parents:
18553
diff
changeset
|
250 |
'Add a tab with an embedded console-terminal\(Windows users: ignore the no-echo bug, please)' |
10169 | 251 |
|
15816
64d953f953a1
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15737
diff
changeset
|
252 |
#lineAndColumnLabel |
64d953f953a1
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15737
diff
changeset
|
253 |
'The text-cursor''s line and column number' |
64d953f953a1
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15737
diff
changeset
|
254 |
|
9695 | 255 |
#columnLabel |
256 |
'The text-cursor''s column number' |
|
257 |
||
258 |
#lineLabel |
|
13643
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
259 |
'The text-cursor''s line number. Double-click to change' |
9695 | 260 |
|
261 |
#modeLabel |
|
18846 | 262 |
'The editing mode (insert vs. overwrite).\Right-click to change' |
9695 | 263 |
|
8708 | 264 |
#editRedo |
8709 | 265 |
'Redo' |
8708 | 266 |
|
267 |
#doIndent |
|
13643
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
268 |
'Indent (shift right)' |
8708 | 269 |
|
270 |
#doUndent |
|
13643
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
271 |
'Undent (shift left)' |
8708 | 272 |
|
9676 | 273 |
#languageSelection |
15737
5f5dd0d93690
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15608
diff
changeset
|
274 |
'Syntax for doits, syntax checks and coloring. Right-click for menu to change' |
13643
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
275 |
|
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
276 |
#namespaceSelection |
15737
5f5dd0d93690
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15608
diff
changeset
|
277 |
'Namespace for doits. Right-click for menu to change' |
9676 | 278 |
|
10169 | 279 |
#menuSave |
280 |
'Save the page''s contents in the original file' |
|
281 |
||
282 |
#menuSaveAs |
|
283 |
'Ask for a file and save the page''s contents there' |
|
14837
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
284 |
|
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
285 |
#snippedPaste |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
286 |
'Paste the selected snippet''s text into the text' |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
287 |
|
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
288 |
#snippedDefine |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
289 |
'Add the above definition to the list of snippets' |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
290 |
|
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
291 |
#snippedRemove |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
292 |
'Remove the above selected snippet from the list of snippets' |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
293 |
|
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
294 |
#snippedKey |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
295 |
'The key of the snippet. This is the abbreviation you will have to type before pressing Shift-Space' |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
296 |
|
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
297 |
#snippedList |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
298 |
'The list of defined snippets.' |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
299 |
|
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
300 |
#snippedText |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
301 |
'The text of the snippet. This is the text that will be inserted when pressing Shift-Space' |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
302 |
|
8708 | 303 |
) |
9676 | 304 |
|
10277 | 305 |
"Modified: / 08-07-2011 / 08:29:51 / cg" |
18846 | 306 |
"Modified: / 26-06-2019 / 22:21:20 / Claus Gittinger" |
8708 | 307 |
! ! |
308 |
||
7931 | 309 |
!WorkspaceApplication class methodsFor:'interface specs'! |
310 |
||
14830
ae72eee69f1c
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14818
diff
changeset
|
311 |
manageSnippetsDialogSpec |
7931 | 312 |
"This resource specification was automatically generated |
313 |
by the UIPainter of ST/X." |
|
314 |
||
315 |
"Do not manually edit this!! If it is corrupted, |
|
316 |
the UIPainter may not be able to read the specification." |
|
317 |
||
318 |
" |
|
14830
ae72eee69f1c
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14818
diff
changeset
|
319 |
UIPainter new openOnClass:WorkspaceApplication andSelector:#manageSnippetsDialogSpec |
ae72eee69f1c
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14818
diff
changeset
|
320 |
WorkspaceApplication new openInterface:#manageSnippetsDialogSpec |
7931 | 321 |
" |
322 |
||
323 |
<resource: #canvas> |
|
324 |
||
325 |
^ |
|
14837
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
326 |
#(FullSpec |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
327 |
name: manageSnippetsDialogSpec |
17743 | 328 |
uuid: '74513a6c-c5a3-11e7-82f7-c42c033b4871' |
14837
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
329 |
window: |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
330 |
(WindowSpec |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
331 |
label: 'Manage Snippets' |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
332 |
name: 'Manage Snippets' |
17743 | 333 |
uuid: '625f25a8-c5a3-11e7-82f7-c42c033b4871' |
14837
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
334 |
min: (Point 10 10) |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
335 |
bounds: (Rectangle 0 0 379 590) |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
336 |
menu: manageSnippetDialogMenuSpec |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
337 |
) |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
338 |
component: |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
339 |
(SpecCollection |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
340 |
collection: ( |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
341 |
(LabelSpec |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
342 |
label: 'Snippet:' |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
343 |
name: 'Label1' |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
344 |
layout: (LayoutFrame 0 0 0 0 0 1 30 0) |
17743 | 345 |
uuid: '625f28f0-c5a3-11e7-82f7-c42c033b4871' |
14837
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
346 |
translateLabel: true |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
347 |
adjust: left |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
348 |
) |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
349 |
(VariableVerticalPanelSpec |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
350 |
name: 'VariableVerticalPanel1' |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
351 |
layout: (LayoutFrame 0 0 30 0 0 1 -80 1) |
17743 | 352 |
uuid: '625f2bac-c5a3-11e7-82f7-c42c033b4871' |
14837
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
353 |
component: |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
354 |
(SpecCollection |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
355 |
collection: ( |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
356 |
(SequenceViewSpec |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
357 |
name: 'List1' |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
358 |
activeHelpKey: snippedList |
17743 | 359 |
uuid: '625f2e04-c5a3-11e7-82f7-c42c033b4871' |
14837
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
360 |
model: selectedSnippet |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
361 |
hasHorizontalScrollBar: true |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
362 |
hasVerticalScrollBar: true |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
363 |
useIndex: true |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
364 |
sequenceList: listOfSnippets |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
365 |
) |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
366 |
(ViewSpec |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
367 |
name: 'Box1' |
17743 | 368 |
uuid: '625f3138-c5a3-11e7-82f7-c42c033b4871' |
14837
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
369 |
component: |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
370 |
(SpecCollection |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
371 |
collection: ( |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
372 |
(TextEditorSpec |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
373 |
name: 'TextEditor1' |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
374 |
layout: (LayoutFrame 0 0 30 0 0 1 0 1) |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
375 |
activeHelpKey: snippedText |
17743 | 376 |
uuid: '625f32b4-c5a3-11e7-82f7-c42c033b4871' |
14837
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
377 |
model: selectedSnippetsText |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
378 |
hasHorizontalScrollBar: true |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
379 |
hasVerticalScrollBar: true |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
380 |
acceptChannel: snippetTextAcceptHolder |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
381 |
modifiedChannel: snippetTextModified |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
382 |
hasKeyboardFocusInitially: false |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
383 |
viewClassName: '' |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
384 |
) |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
385 |
(LabelSpec |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
386 |
label: 'Snippet Key:' |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
387 |
name: 'Label2' |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
388 |
layout: (LayoutFrame 0 0 2 0 100 0 28 0) |
17743 | 389 |
uuid: '625f35ca-c5a3-11e7-82f7-c42c033b4871' |
14837
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
390 |
translateLabel: true |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
391 |
adjust: left |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
392 |
) |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
393 |
(InputFieldSpec |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
394 |
name: 'EntryField1' |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
395 |
layout: (LayoutFrame 100 0.0 2 0 0 1.0 28 0) |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
396 |
activeHelpKey: snippedKey |
17743 | 397 |
uuid: '625f37aa-c5a3-11e7-82f7-c42c033b4871' |
14837
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
398 |
model: selectedSnippetsKeyHolder |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
399 |
immediateAccept: true |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
400 |
acceptOnReturn: true |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
401 |
acceptOnTab: true |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
402 |
acceptOnPointerLeave: true |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
403 |
) |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
404 |
) |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
405 |
|
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
406 |
) |
7931 | 407 |
) |
14837
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
408 |
) |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
409 |
|
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
410 |
) |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
411 |
handles: (Any 0.5 1.0) |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
412 |
) |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
413 |
(HorizontalPanelViewSpec |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
414 |
name: 'ButtonPanel' |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
415 |
layout: (LayoutFrame 0 0 -70 1 0 1 -40 1) |
17743 | 416 |
uuid: '625f3b38-c5a3-11e7-82f7-c42c033b4871' |
14837
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
417 |
horizontalLayout: center |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
418 |
verticalLayout: center |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
419 |
horizontalSpace: 3 |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
420 |
verticalSpace: 3 |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
421 |
component: |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
422 |
(SpecCollection |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
423 |
collection: ( |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
424 |
(ActionButtonSpec |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
425 |
label: 'Define' |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
426 |
name: 'DefineButton' |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
427 |
activeHelpKey: snippedDefine |
17743 | 428 |
uuid: '625f3d90-c5a3-11e7-82f7-c42c033b4871' |
14837
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
429 |
translateLabel: true |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
430 |
model: defineSelectedSnippet |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
431 |
enableChannel: defineEnabled |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
432 |
extent: (Point 125 22) |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
433 |
) |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
434 |
(ActionButtonSpec |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
435 |
label: 'Remove' |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
436 |
name: 'RemoveButton' |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
437 |
activeHelpKey: snippedRemove |
17743 | 438 |
uuid: '625f402e-c5a3-11e7-82f7-c42c033b4871' |
14837
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
439 |
translateLabel: true |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
440 |
model: removeSelectedSnippet |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
441 |
enableChannel: removeEnabled |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
442 |
extent: (Point 125 22) |
8286 | 443 |
) |
14837
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
444 |
(ActionButtonSpec |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
445 |
label: 'Paste' |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
446 |
name: 'PasteButton' |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
447 |
activeHelpKey: snippedPaste |
17743 | 448 |
uuid: '625f4222-c5a3-11e7-82f7-c42c033b4871' |
14837
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
449 |
translateLabel: true |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
450 |
model: pasteSelectedSnippet |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
451 |
enableChannel: pasteEnabled |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
452 |
extent: (Point 125 22) |
7931 | 453 |
) |
14837
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
454 |
) |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
455 |
|
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
456 |
) |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
457 |
) |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
458 |
(DividerSpec |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
459 |
name: 'Separator1' |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
460 |
layout: (LayoutFrame 0 0.0 557 0 0 1.0 561 0) |
17743 | 461 |
uuid: '625f443e-c5a3-11e7-82f7-c42c033b4871' |
7931 | 462 |
) |
14837
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
463 |
(HorizontalPanelViewSpec |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
464 |
name: 'CloseButtonPanel' |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
465 |
layout: (LayoutFrame 0 0 -30 1 0 1 0 1) |
17743 | 466 |
uuid: '625f4600-c5a3-11e7-82f7-c42c033b4871' |
14837
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
467 |
horizontalLayout: fitSpace |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
468 |
verticalLayout: center |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
469 |
horizontalSpace: 3 |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
470 |
verticalSpace: 3 |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
471 |
reverseOrderIfOKAtLeft: true |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
472 |
component: |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
473 |
(SpecCollection |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
474 |
collection: ( |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
475 |
(ActionButtonSpec |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
476 |
label: 'Close' |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
477 |
name: 'Button1' |
17743 | 478 |
uuid: '625f47c2-c5a3-11e7-82f7-c42c033b4871' |
14837
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
479 |
translateLabel: true |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
480 |
model: cancel |
17743 | 481 |
extent: (Point 371 22) |
14837
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
482 |
) |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
483 |
) |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
484 |
|
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
485 |
) |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
486 |
) |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
487 |
) |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
488 |
|
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
489 |
) |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
490 |
) |
9381 | 491 |
! |
492 |
||
10169 | 493 |
toolBarSpec |
494 |
"This resource specification was automatically generated |
|
495 |
by the UIPainter of ST/X." |
|
496 |
||
497 |
"Do not manually edit this!! If it is corrupted, |
|
498 |
the UIPainter may not be able to read the specification." |
|
499 |
||
500 |
" |
|
501 |
UIPainter new openOnClass:WorkspaceApplication andSelector:#toolBarSpec |
|
502 |
WorkspaceApplication new openInterface:#toolBarSpec |
|
503 |
" |
|
504 |
||
505 |
<resource: #canvas> |
|
506 |
||
507 |
^ |
|
17743 | 508 |
#(FullSpec |
509 |
name: toolBarSpec |
|
510 |
uuid: '5fe89e08-c5a3-11e7-82f7-c42c033b4871' |
|
511 |
window: |
|
512 |
(WindowSpec |
|
513 |
label: 'Toolbar' |
|
514 |
name: 'Toolbar' |
|
515 |
uuid: '5fe8a2fe-c5a3-11e7-82f7-c42c033b4871' |
|
516 |
min: (Point 10 10) |
|
517 |
bounds: (Rectangle 0 0 728 48) |
|
518 |
) |
|
519 |
component: |
|
520 |
(SpecCollection |
|
521 |
collection: ( |
|
522 |
(MenuPanelSpec |
|
523 |
name: 'ToolBarMenu' |
|
524 |
layout: (LayoutFrame 0 0 0 0 0 1 0 1) |
|
525 |
uuid: '5fe8a6be-c5a3-11e7-82f7-c42c033b4871' |
|
526 |
level: 0 |
|
527 |
visibilityChannel: toolBarVisibleHolder |
|
528 |
menu: toolBarMenu |
|
529 |
textDefault: true |
|
10169 | 530 |
) |
17743 | 531 |
) |
532 |
||
533 |
) |
|
534 |
) |
|
10169 | 535 |
! |
536 |
||
9381 | 537 |
windowSpec |
538 |
"This resource specification was automatically generated |
|
539 |
by the UIPainter of ST/X." |
|
540 |
||
541 |
"Do not manually edit this!! If it is corrupted, |
|
542 |
the UIPainter may not be able to read the specification." |
|
543 |
||
544 |
" |
|
545 |
UIPainter new openOnClass:WorkspaceApplication andSelector:#windowSpec |
|
546 |
WorkspaceApplication new openInterface:#windowSpec |
|
547 |
WorkspaceApplication open |
|
548 |
" |
|
549 |
||
550 |
<resource: #canvas> |
|
551 |
||
552 |
^ |
|
15890 | 553 |
#(FullSpec |
554 |
name: windowSpec |
|
17743 | 555 |
uuid: '99c04dd0-c5a1-11e7-82f7-c42c033b4871' |
15890 | 556 |
window: |
557 |
(WindowSpec |
|
558 |
label: 'Workspace' |
|
559 |
name: 'Workspace' |
|
17743 | 560 |
uuid: '99c05262-c5a1-11e7-82f7-c42c033b4871' |
15890 | 561 |
min: (Point 10 10) |
562 |
bounds: (Rectangle 0 0 640 480) |
|
563 |
menu: mainMenu |
|
564 |
) |
|
565 |
component: |
|
566 |
(SpecCollection |
|
567 |
collection: ( |
|
568 |
(ViewSpec |
|
569 |
name: 'ToolBar' |
|
570 |
layout: (LayoutFrame 0 0 0 0 0 1 32 0) |
|
17743 | 571 |
uuid: '99c055e6-c5a1-11e7-82f7-c42c033b4871' |
15890 | 572 |
level: #'application.toolbarLevel' |
573 |
visibilityChannel: toolBarVisibleHolder |
|
574 |
component: |
|
575 |
(SpecCollection |
|
576 |
collection: ( |
|
577 |
(ActionButtonSpec |
|
578 |
label: 'hideToolBarIcon' |
|
579 |
name: 'HideToolBarButton' |
|
580 |
layout: (LayoutFrame 0 0 0 0 13 0 0 1) |
|
581 |
activeHelpKey: hideToolBar |
|
17743 | 582 |
uuid: '99c05834-c5a1-11e7-82f7-c42c033b4871' |
15890 | 583 |
hasCharacterOrientedLabel: false |
584 |
translateLabel: true |
|
585 |
model: hideToolbar |
|
586 |
postBuildCallback: hideToolBarButtonCreated: |
|
587 |
) |
|
588 |
(NonScrollableArbitraryComponentSpec |
|
589 |
name: 'ToolBarView' |
|
590 |
layout: (LayoutFrame 13 0.0 0 0.0 0 1.0 0 1.0) |
|
17743 | 591 |
uuid: '99c05ba4-c5a1-11e7-82f7-c42c033b4871' |
15890 | 592 |
visibilityChannel: toolBarVisibleHolder |
593 |
component: toolBarView |
|
9381 | 594 |
) |
15890 | 595 |
) |
596 |
||
597 |
) |
|
598 |
) |
|
599 |
(ViewSpec |
|
600 |
name: 'EditToolBar' |
|
601 |
layout: (LayoutFrame 0 0 32 0 0 1 64 0) |
|
17743 | 602 |
uuid: '99c05eba-c5a1-11e7-82f7-c42c033b4871' |
15890 | 603 |
visibilityChannel: editToolBarVisibleHolder |
604 |
component: |
|
605 |
(SpecCollection |
|
606 |
collection: ( |
|
607 |
(ActionButtonSpec |
|
608 |
label: 'hideToolBarIcon' |
|
609 |
name: 'HideEditToolBarButton' |
|
610 |
layout: (LayoutFrame 0 0 0 0 13 0 0 1) |
|
611 |
activeHelpKey: hideEditToolBar |
|
17743 | 612 |
uuid: '99c06040-c5a1-11e7-82f7-c42c033b4871' |
15890 | 613 |
hasCharacterOrientedLabel: false |
614 |
translateLabel: true |
|
615 |
model: hideEditToolbar |
|
616 |
postBuildCallback: hideToolBarButtonCreated: |
|
617 |
) |
|
618 |
(MenuPanelSpec |
|
619 |
name: 'EditToolBar1' |
|
620 |
layout: (LayoutFrame 13 0.0 0 0.0 0 1.0 0 1.0) |
|
17743 | 621 |
uuid: '99c06284-c5a1-11e7-82f7-c42c033b4871' |
15890 | 622 |
visibilityChannel: editToolBarVisibleHolder |
623 |
menu: editToolBarMenu |
|
624 |
textDefault: true |
|
9381 | 625 |
) |
15890 | 626 |
) |
627 |
||
628 |
) |
|
9381 | 629 |
) |
15890 | 630 |
(NoteBookViewSpec |
631 |
name: 'NoteBook' |
|
632 |
layout: (LayoutFrame 0 0.0 0 0.0 0 1.0 -26 1.0) |
|
17743 | 633 |
uuid: '99c064f0-c5a1-11e7-82f7-c42c033b4871' |
15890 | 634 |
model: selectedWorkspaceIndexHolder |
635 |
menu: tabList |
|
636 |
useIndex: true |
|
637 |
accessTabMenuAction: tabMenuAt: |
|
638 |
translateLabel: true |
|
639 |
destroyTabAction: destroyTab: |
|
640 |
canvas: workspaceHolder |
|
641 |
canvasInset: 0 |
|
642 |
keepCanvasAlive: true |
|
643 |
tabLevel: 1 |
|
644 |
) |
|
645 |
(UISubSpecification |
|
646 |
name: 'infoBarSubSpec' |
|
647 |
layout: (LayoutFrame 0 0.0 -26 1 -16 1.0 0 1.0) |
|
17743 | 648 |
uuid: '99c0682e-c5a1-11e7-82f7-c42c033b4871' |
15890 | 649 |
level: #'infobar.level' |
650 |
visibilityChannel: infoVisibleHolder |
|
651 |
majorKey: WorkspaceApplication |
|
652 |
minorKey: windowSpecForInfoBar |
|
653 |
keepSpaceForOSXResizeHandleH: true |
|
654 |
) |
|
655 |
) |
|
656 |
||
657 |
) |
|
658 |
) |
|
9381 | 659 |
! |
660 |
||
661 |
windowSpecForInfoBar |
|
662 |
"This resource specification was automatically generated |
|
663 |
by the UIPainter of ST/X." |
|
664 |
||
665 |
"Do not manually edit this!! If it is corrupted, |
|
666 |
the UIPainter may not be able to read the specification." |
|
667 |
||
668 |
" |
|
669 |
UIPainter new openOnClass:WorkspaceApplication andSelector:#windowSpecForInfoBar |
|
670 |
WorkspaceApplication new openInterface:#windowSpecForInfoBar |
|
671 |
" |
|
672 |
||
673 |
<resource: #canvas> |
|
674 |
||
675 |
^ |
|
13643
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
676 |
#(FullSpec |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
677 |
name: windowSpecForInfoBar |
17743 | 678 |
uuid: '5d3254b0-c5a3-11e7-82f7-c42c033b4871' |
13643
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
679 |
window: |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
680 |
(WindowSpec |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
681 |
label: 'Info Bar' |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
682 |
name: 'Info Bar' |
17743 | 683 |
uuid: '5d3258ca-c5a3-11e7-82f7-c42c033b4871' |
13643
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
684 |
bounds: (Rectangle 0 0 473 30) |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
685 |
) |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
686 |
component: |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
687 |
(SpecCollection |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
688 |
collection: ( |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
689 |
(ViewSpec |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
690 |
name: 'infoView' |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
691 |
layout: (LayoutFrame 0 0.0 0 0.0 0 1.0 0 1.0) |
17743 | 692 |
uuid: '5d325ba4-c5a3-11e7-82f7-c42c033b4871' |
13643
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
693 |
component: |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
694 |
(SpecCollection |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
695 |
collection: ( |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
696 |
(LabelSpec |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
697 |
name: 'infoLabel' |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
698 |
layout: (LayoutFrame 0 0.0 0 0.0 -220 1.0 0 1.0) |
17743 | 699 |
uuid: '5d325d98-c5a3-11e7-82f7-c42c033b4871' |
13643
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
700 |
level: -1 |
15816
64d953f953a1
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15737
diff
changeset
|
701 |
translateLabel: true |
13643
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
702 |
labelChannel: infoLabelHolder |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
703 |
resizeForLabel: false |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
704 |
adjust: left |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
705 |
) |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
706 |
(LabelSpec |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
707 |
name: 'namespaceInfoLabelHolder' |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
708 |
layout: (LayoutFrame -220 1.0 0 0.0 -136 1.0 0 1.0) |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
709 |
activeHelpKey: namespaceSelection |
17743 | 710 |
uuid: '5d325ffa-c5a3-11e7-82f7-c42c033b4871' |
13643
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
711 |
level: -1 |
15816
64d953f953a1
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15737
diff
changeset
|
712 |
translateLabel: true |
13643
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
713 |
labelChannel: namespaceInfoLabelHolder |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
714 |
resizeForLabel: false |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
715 |
adjust: left |
14635
bed940a94253
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14594
diff
changeset
|
716 |
menu: namespaceInfoLabelMenuHolder |
9381 | 717 |
) |
13643
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
718 |
(LabelSpec |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
719 |
name: 'LanguageLabel' |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
720 |
layout: (LayoutFrame -136 1.0 0 0.0 -65 1.0 0 1.0) |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
721 |
activeHelpKey: languageSelection |
17743 | 722 |
uuid: '5d3261bc-c5a3-11e7-82f7-c42c033b4871' |
13643
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
723 |
level: -1 |
15816
64d953f953a1
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15737
diff
changeset
|
724 |
translateLabel: true |
13643
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
725 |
labelChannel: languageInfoLabelHolder |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
726 |
resizeForLabel: false |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
727 |
adjust: left |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
728 |
menu: languageInfoLabelMenu |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
729 |
) |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
730 |
(LabelSpec |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
731 |
name: 'ModeLabel' |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
732 |
layout: (LayoutFrame -65 1 0 0.0 -50 1 0 1.0) |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
733 |
activeHelpKey: modeLabel |
17743 | 734 |
uuid: '5d32636a-c5a3-11e7-82f7-c42c033b4871' |
13643
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
735 |
level: -1 |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
736 |
translateLabel: true |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
737 |
labelChannel: modeLabelHolder |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
738 |
postBuildCallback: postBuildEditModeInfoLabel: |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
739 |
) |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
740 |
(LabelSpec |
15816
64d953f953a1
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15737
diff
changeset
|
741 |
name: 'CursorLineAndColLabel' |
64d953f953a1
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15737
diff
changeset
|
742 |
layout: (LayoutFrame -50 1 0 0.0 0 1 0 1.0) |
64d953f953a1
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15737
diff
changeset
|
743 |
activeHelpKey: lineAndColumnLabel |
17743 | 744 |
uuid: '5d326522-c5a3-11e7-82f7-c42c033b4871' |
13643
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
745 |
level: -1 |
17743 | 746 |
translateLabel: true |
15817
f6046130309e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15816
diff
changeset
|
747 |
labelChannel: cursorLineAndColumnLabelHolder |
15816
64d953f953a1
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15737
diff
changeset
|
748 |
adjust: left |
13643
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
749 |
) |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
750 |
) |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
751 |
|
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
752 |
) |
9381 | 753 |
) |
13643
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
754 |
) |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
755 |
|
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
756 |
) |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
757 |
) |
7931 | 758 |
! ! |
759 |
||
3154 | 760 |
!WorkspaceApplication class methodsFor:'menu specs'! |
761 |
||
10169 | 762 |
bufferAddMenuSlice |
763 |
"This resource specification was automatically generated |
|
764 |
by the MenuEditor of ST/X." |
|
765 |
||
766 |
"Do not manually edit this!! If it is corrupted, |
|
767 |
the MenuEditor may not be able to read the specification." |
|
768 |
||
13852 | 769 |
|
10169 | 770 |
" |
771 |
MenuEditor new openOnClass:WorkspaceApplication andSelector:#bufferAddMenuSlice |
|
772 |
(Menu new fromLiteralArrayEncoding:(WorkspaceApplication bufferAddMenuSlice)) startUp |
|
773 |
" |
|
774 |
||
775 |
<resource: #menu> |
|
776 |
||
13852 | 777 |
^ |
10169 | 778 |
#(Menu |
13852 | 779 |
( |
780 |
(MenuItem |
|
781 |
label: 'Terminal' |
|
782 |
itemValue: addTerminal |
|
783 |
translateLabel: true |
|
784 |
) |
|
785 |
(MenuItem |
|
786 |
label: 'Web Browser' |
|
787 |
itemValue: addWebBrowser |
|
788 |
translateLabel: true |
|
789 |
isVisible: isWebBrowserAvailable |
|
790 |
) |
|
791 |
(MenuItem |
|
792 |
enabled: isSQLWorkspaceAvailable |
|
793 |
label: 'SQL Workspace' |
|
794 |
itemValue: addSQLWorkspace |
|
795 |
translateLabel: true |
|
796 |
) |
|
797 |
(MenuItem |
|
798 |
label: 'Tea Timer' |
|
799 |
itemValue: addTeaTimer |
|
800 |
translateLabel: true |
|
801 |
) |
|
802 |
(MenuItem |
|
12032
37dea732aec1
changed: #bufferAddMenuSlice
Claus Gittinger <cg@exept.de>
parents:
12028
diff
changeset
|
803 |
label: 'Stopwatch' |
13852 | 804 |
itemValue: addStopWatch |
805 |
translateLabel: true |
|
806 |
) |
|
807 |
) |
|
808 |
nil |
|
809 |
nil |
|
10169 | 810 |
) |
811 |
! |
|
812 |
||
7865
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
813 |
bufferMenu |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
814 |
"This resource specification was automatically generated |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
815 |
by the MenuEditor of ST/X." |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
816 |
|
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
817 |
"Do not manually edit this!! If it is corrupted, |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
818 |
the MenuEditor may not be able to read the specification." |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
819 |
|
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
820 |
" |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
821 |
MenuEditor new openOnClass:WorkspaceApplication andSelector:#bufferMenu |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
822 |
(Menu new fromLiteralArrayEncoding:(WorkspaceApplication bufferMenu)) startUp |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
823 |
" |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
824 |
|
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
825 |
<resource: #menu> |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
826 |
|
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
827 |
^ |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
828 |
#(Menu |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
829 |
( |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
830 |
(MenuItem |
18395 | 831 |
label: 'Add Page' |
7865
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
832 |
itemValue: addWorkspace |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
833 |
translateLabel: true |
10169 | 834 |
shortcutKey: Ctrlt |
7865
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
835 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
836 |
(MenuItem |
18395 | 837 |
label: 'Add Page with same Contents' |
17719 | 838 |
itemValue: addWorkspaceWithSameContents |
839 |
translateLabel: true |
|
840 |
) |
|
841 |
(MenuItem |
|
8111 | 842 |
label: '-' |
843 |
isVisible: thisIsASmalltalkWorkspace |
|
844 |
) |
|
845 |
(MenuItem |
|
18395 | 846 |
label: 'Add Page on MyWorkspace' |
7865
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
847 |
itemValue: addMyWorkspace |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
848 |
translateLabel: true |
7866 | 849 |
isVisible: thisIsASmalltalkWorkspace |
7865
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
850 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
851 |
(MenuItem |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
852 |
enabled: anyWorkspaceVariableIsDefined |
18395 | 853 |
label: 'Add Page on Workspace Variables' |
7865
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
854 |
itemValue: addWorkspaceVariableInspector |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
855 |
translateLabel: true |
7866 | 856 |
isVisible: thisIsASmalltalkWorkspace |
7865
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
857 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
858 |
(MenuItem |
18395 | 859 |
label: 'Add Page on Global Variables' |
7865
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
860 |
itemValue: addGlobalVariableInspector |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
861 |
translateLabel: true |
7866 | 862 |
isVisible: thisIsASmalltalkWorkspace |
7865
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
863 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
864 |
(MenuItem |
18395 | 865 |
label: 'Add Page on Namespace...' |
7865
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
866 |
itemValue: addNamespaceInspector |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
867 |
translateLabel: true |
7866 | 868 |
isVisible: thisIsASmalltalkWorkspace |
7865
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
869 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
870 |
(MenuItem |
18395 | 871 |
label: 'Add Page on SharedPool...' |
7944
3d185d0ca8e9
sharedPool inspection support
Claus Gittinger <cg@exept.de>
parents:
7931
diff
changeset
|
872 |
itemValue: addSharedPoolInspector |
3d185d0ca8e9
sharedPool inspection support
Claus Gittinger <cg@exept.de>
parents:
7931
diff
changeset
|
873 |
translateLabel: true |
3d185d0ca8e9
sharedPool inspection support
Claus Gittinger <cg@exept.de>
parents:
7931
diff
changeset
|
874 |
isVisible: thisIsASmalltalkWorkspace |
3d185d0ca8e9
sharedPool inspection support
Claus Gittinger <cg@exept.de>
parents:
7931
diff
changeset
|
875 |
) |
3d185d0ca8e9
sharedPool inspection support
Claus Gittinger <cg@exept.de>
parents:
7931
diff
changeset
|
876 |
(MenuItem |
18395 | 877 |
label: 'Add Page on Class Variables' |
7865
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
878 |
itemValue: addClassVariableInspector |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
879 |
translateLabel: true |
7866 | 880 |
isVisible: thisIsASmalltalkWorkspace |
7865
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
881 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
882 |
(MenuItem |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
883 |
label: '-' |
7866 | 884 |
isVisible: thisIsASmalltalkWorkspace |
7865
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
885 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
886 |
(MenuItem |
18395 | 887 |
label: 'Add Evaluation Page' |
7865
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
888 |
itemValue: addEvaluationWorkspace |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
889 |
translateLabel: true |
7866 | 890 |
isVisible: thisIsASmalltalkWorkspace |
7865
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
891 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
892 |
(MenuItem |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
893 |
label: '-' |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
894 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
895 |
(MenuItem |
10169 | 896 |
label: 'Menu Slice' |
8111 | 897 |
translateLabel: true |
10169 | 898 |
submenuChannel: bufferAddMenuSlice |
899 |
isMenuSlice: true |
|
8111 | 900 |
) |
901 |
(MenuItem |
|
902 |
label: '-' |
|
903 |
) |
|
904 |
(MenuItem |
|
7865
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
905 |
label: 'Rename...' |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
906 |
itemValue: renameWorkspace |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
907 |
translateLabel: true |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
908 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
909 |
(MenuItem |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
910 |
label: '-' |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
911 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
912 |
(MenuItem |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
913 |
enabled: canRemoveWorkspace |
18395 | 914 |
label: 'Remove Page' |
7865
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
915 |
itemValue: removeWorkspace |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
916 |
translateLabel: true |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
917 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
918 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
919 |
nil |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
920 |
nil |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
921 |
) |
17719 | 922 |
|
923 |
"Modified: / 22-10-2017 / 20:38:32 / cg" |
|
18395 | 924 |
"Modified: / 21-09-2018 / 10:57:30 / Claus Gittinger" |
7865
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
925 |
! |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
926 |
|
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
927 |
editMenu |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
928 |
"This resource specification was automatically generated |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
929 |
by the MenuEditor of ST/X." |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
930 |
|
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
931 |
"Do not manually edit this!! If it is corrupted, |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
932 |
the MenuEditor may not be able to read the specification." |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
933 |
|
11481
d0a2a73ed69d
added: #selectedWorkspaceIsTextView
Stefan Vogel <sv@exept.de>
parents:
11480
diff
changeset
|
934 |
|
7865
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
935 |
" |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
936 |
MenuEditor new openOnClass:WorkspaceApplication andSelector:#editMenu |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
937 |
(Menu new fromLiteralArrayEncoding:(WorkspaceApplication editMenu)) startUp |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
938 |
" |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
939 |
|
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
940 |
<resource: #menu> |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
941 |
|
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
942 |
^ |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
943 |
#(Menu |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
944 |
( |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
945 |
(MenuItem |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
946 |
enabled: hasSelectionInActiveWorkspace |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
947 |
label: 'Cut' |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
948 |
itemValue: cutSelection |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
949 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
950 |
(MenuItem |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
951 |
enabled: hasSelectionInActiveWorkspace |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
952 |
label: 'Copy' |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
953 |
itemValue: copySelection |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
954 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
955 |
(MenuItem |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
956 |
label: 'Paste' |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
957 |
itemValue: paste |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
958 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
959 |
(MenuItem |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
960 |
enabled: hasHistory |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
961 |
label: 'Paste Last' |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
962 |
itemValue: pasteLastDoIt |
8492 | 963 |
isVisible: thisIsASmalltalkWorkspace |
7865
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
964 |
submenuChannel: pasteRecentDoItMenu |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
965 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
966 |
(MenuItem |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
967 |
label: '-' |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
968 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
969 |
(MenuItem |
11481
d0a2a73ed69d
added: #selectedWorkspaceIsTextView
Stefan Vogel <sv@exept.de>
parents:
11480
diff
changeset
|
970 |
enabled: hasSelectionInActiveWorkspace |
13500 | 971 |
label: 'Copy as Snippet...' |
14830
ae72eee69f1c
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14818
diff
changeset
|
972 |
itemValue: addSelectionToSnippets |
7931 | 973 |
) |
974 |
(MenuItem |
|
11481
d0a2a73ed69d
added: #selectedWorkspaceIsTextView
Stefan Vogel <sv@exept.de>
parents:
11480
diff
changeset
|
975 |
enabled: selectedWorkspaceIsTextView |
13500 | 976 |
label: 'Paste Snippet...' |
14830
ae72eee69f1c
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14818
diff
changeset
|
977 |
itemValue: pasteSnippet |
7931 | 978 |
) |
979 |
(MenuItem |
|
11481
d0a2a73ed69d
added: #selectedWorkspaceIsTextView
Stefan Vogel <sv@exept.de>
parents:
11480
diff
changeset
|
980 |
enabled: selectedWorkspaceIsTextView |
13500 | 981 |
label: 'Manage Snippets...' |
14830
ae72eee69f1c
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14818
diff
changeset
|
982 |
itemValue: manageSnippets |
7931 | 983 |
) |
984 |
(MenuItem |
|
985 |
label: '-' |
|
986 |
) |
|
987 |
(MenuItem |
|
7865
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
988 |
label: 'Select All' |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
989 |
itemValue: selectAll |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
990 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
991 |
(MenuItem |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
992 |
label: '-' |
8134
e2d9bc2a289e
smalltalk functions only in smalltalks workspace
Claus Gittinger <cg@exept.de>
parents:
8133
diff
changeset
|
993 |
isVisible: thisIsASmalltalkWorkspace |
7865
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
994 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
995 |
(MenuItem |
11481
d0a2a73ed69d
added: #selectedWorkspaceIsTextView
Stefan Vogel <sv@exept.de>
parents:
11480
diff
changeset
|
996 |
enabled: selectedWorkspaceIsTextView |
7865
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
997 |
label: 'Filter Text...' |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
998 |
itemValue: filterText |
8134
e2d9bc2a289e
smalltalk functions only in smalltalks workspace
Claus Gittinger <cg@exept.de>
parents:
8133
diff
changeset
|
999 |
isVisible: thisIsASmalltalkWorkspace |
7865
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1000 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1001 |
(MenuItem |
11481
d0a2a73ed69d
added: #selectedWorkspaceIsTextView
Stefan Vogel <sv@exept.de>
parents:
11480
diff
changeset
|
1002 |
enabled: selectedWorkspaceIsTextView |
7865
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1003 |
label: 'Process Text...' |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1004 |
itemValue: processText |
8134
e2d9bc2a289e
smalltalk functions only in smalltalks workspace
Claus Gittinger <cg@exept.de>
parents:
8133
diff
changeset
|
1005 |
isVisible: thisIsASmalltalkWorkspace |
7865
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1006 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1007 |
(MenuItem |
13917
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
1008 |
label: 'Generate Text...' |
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
1009 |
itemValue: generateText |
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
1010 |
) |
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
1011 |
(MenuItem |
11496 | 1012 |
label: 'Compare Text Against...' |
1013 |
itemValue: compareTextAgainst |
|
1014 |
) |
|
1015 |
(MenuItem |
|
7865
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1016 |
label: '-' |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1017 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1018 |
(MenuItem |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1019 |
label: 'Services' |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1020 |
submenu: |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1021 |
(Menu |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1022 |
( |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1023 |
(MenuItem |
18055 | 1024 |
isVisible: autoFetchSelectionMenuItemVisible |
9632 | 1025 |
label: 'Autofetch Selection' |
11627 | 1026 |
hideMenuOnActivated: false |
18055 | 1027 |
indication: autoFetchSelectionHolder |
9632 | 1028 |
) |
1029 |
(MenuItem |
|
18055 | 1030 |
isVisible: autoFetchSelectionMenuItemVisible |
11627 | 1031 |
enabled: autoFetchSelection |
1032 |
label: 'Insert as Line (Append CR)' |
|
1033 |
hideMenuOnActivated: false |
|
9735 | 1034 |
indication: autoFetchSelectionLines |
1035 |
) |
|
1036 |
(MenuItem |
|
9632 | 1037 |
label: '-' |
18055 | 1038 |
isVisible: thisIsASmalltalkWorkspaceAndAutoFetchMenuItemVisible |
9632 | 1039 |
) |
1040 |
(MenuItem |
|
7865
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1041 |
enabled: hasSelectionInActiveWorkspace |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1042 |
label: 'Google Spell' |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1043 |
itemValue: googleSpellingSuggestion |
7876 | 1044 |
isVisible: thisIsASmalltalkWorkspace |
7865
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1045 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1046 |
(MenuItem |
11481
d0a2a73ed69d
added: #selectedWorkspaceIsTextView
Stefan Vogel <sv@exept.de>
parents:
11480
diff
changeset
|
1047 |
enabled: hasSelectionInActiveWorkspace |
9632 | 1048 |
label: 'Translate (babelFish)' |
7876 | 1049 |
isVisible: thisIsASmalltalkWorkspace |
7865
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1050 |
submenu: |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1051 |
(Menu |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1052 |
( |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1053 |
(MenuItem |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1054 |
enabled: hasSelectionInActiveWorkspace |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1055 |
label: 'English -> German' |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1056 |
itemValue: babelFishTranslate: |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1057 |
argument: 'en_de' |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1058 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1059 |
(MenuItem |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1060 |
enabled: hasSelectionInActiveWorkspace |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1061 |
label: 'English -> French' |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1062 |
itemValue: babelFishTranslate: |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1063 |
argument: 'en_fr' |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1064 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1065 |
(MenuItem |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1066 |
enabled: hasSelectionInActiveWorkspace |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1067 |
label: 'English -> Spanish' |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1068 |
itemValue: babelFishTranslate: |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1069 |
argument: 'en_es' |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1070 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1071 |
(MenuItem |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1072 |
enabled: hasSelectionInActiveWorkspace |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1073 |
label: 'English -> Portuguese' |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1074 |
itemValue: babelFishTranslate: |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1075 |
argument: 'en_pt' |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1076 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1077 |
(MenuItem |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1078 |
label: '-' |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1079 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1080 |
(MenuItem |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1081 |
enabled: hasSelectionInActiveWorkspace |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1082 |
label: 'German -> English' |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1083 |
itemValue: babelFishTranslate: |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1084 |
argument: 'de_en' |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1085 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1086 |
(MenuItem |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1087 |
enabled: hasSelectionInActiveWorkspace |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1088 |
label: 'French -> English' |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1089 |
itemValue: babelFishTranslate: |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1090 |
argument: 'fr_en' |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1091 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1092 |
(MenuItem |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1093 |
enabled: hasSelectionInActiveWorkspace |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1094 |
label: 'Spanish -> English' |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1095 |
itemValue: babelFishTranslate: |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1096 |
argument: 'es_en' |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1097 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1098 |
(MenuItem |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1099 |
enabled: hasSelectionInActiveWorkspace |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1100 |
label: 'Portuguese -> English' |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1101 |
itemValue: babelFishTranslate: |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1102 |
argument: 'pt_en' |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1103 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1104 |
(MenuItem |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1105 |
enabled: hasSelectionInActiveWorkspace |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1106 |
label: 'Russian -> English' |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1107 |
itemValue: babelFishTranslate: |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1108 |
argument: 'ru_en' |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1109 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1110 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1111 |
nil |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1112 |
nil |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1113 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1114 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1115 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1116 |
nil |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1117 |
nil |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1118 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1119 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1120 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1121 |
nil |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1122 |
nil |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1123 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1124 |
! |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1125 |
|
9695 | 1126 |
editModeInfoLabelMenu |
1127 |
"This resource specification was automatically generated |
|
1128 |
by the MenuEditor of ST/X." |
|
1129 |
||
1130 |
"Do not manually edit this!! If it is corrupted, |
|
1131 |
the MenuEditor may not be able to read the specification." |
|
1132 |
||
1133 |
" |
|
1134 |
MenuEditor new openOnClass:Tools::NewSystemBrowser andSelector:#editModeInfoLabelMenu |
|
1135 |
(Menu new fromLiteralArrayEncoding:(Tools::NewSystemBrowser editModeInfoLabelMenu)) startUp |
|
1136 |
" |
|
1137 |
||
1138 |
<resource: #menu> |
|
1139 |
||
1140 |
^ |
|
1141 |
#(Menu |
|
1142 |
( |
|
1143 |
(MenuItem |
|
1144 |
label: 'Insert' |
|
1145 |
itemValue: editModeInsert |
|
1146 |
translateLabel: true |
|
1147 |
) |
|
1148 |
(MenuItem |
|
1149 |
label: 'Overwrite' |
|
1150 |
itemValue: editModeOverwrite |
|
1151 |
translateLabel: true |
|
1152 |
) |
|
1153 |
(MenuItem |
|
1154 |
label: 'Insert Selecting' |
|
1155 |
itemValue: editModeInsertAndSelect |
|
1156 |
translateLabel: true |
|
1157 |
) |
|
1158 |
) |
|
1159 |
nil |
|
1160 |
nil |
|
1161 |
) |
|
1162 |
||
1163 |
"Created: / 22-01-2011 / 11:50:05 / cg" |
|
1164 |
! |
|
1165 |
||
8499 | 1166 |
editToolBarMenu |
1167 |
"This resource specification was automatically generated |
|
1168 |
by the MenuEditor of ST/X." |
|
1169 |
||
1170 |
"Do not manually edit this!! If it is corrupted, |
|
1171 |
the MenuEditor may not be able to read the specification." |
|
1172 |
||
1173 |
" |
|
1174 |
MenuEditor new openOnClass:WorkspaceApplication andSelector:#editToolBarMenu |
|
1175 |
(Menu new fromLiteralArrayEncoding:(WorkspaceApplication editToolBarMenu)) startUp |
|
1176 |
" |
|
1177 |
||
1178 |
<resource: #menu> |
|
1179 |
||
1180 |
^ |
|
1181 |
#(Menu |
|
1182 |
( |
|
1183 |
(MenuItem |
|
8506 | 1184 |
activeHelpKey: editCut |
8499 | 1185 |
label: 'Cut' |
1186 |
itemValue: cutSelection |
|
1187 |
translateLabel: true |
|
8508 | 1188 |
labelImage: (ResourceRetriever ToolbarIconLibrary cut16x16Icon) |
8499 | 1189 |
isButton: true |
1190 |
) |
|
1191 |
(MenuItem |
|
8506 | 1192 |
activeHelpKey: editCopy |
8499 | 1193 |
label: 'Copy' |
1194 |
itemValue: copySelection |
|
1195 |
translateLabel: true |
|
1196 |
labelImage: (ResourceRetriever ToolbarIconLibrary copy16x16Icon) |
|
1197 |
isButton: true |
|
1198 |
) |
|
1199 |
(MenuItem |
|
8506 | 1200 |
activeHelpKey: editPaste |
8499 | 1201 |
label: 'Paste' |
1202 |
itemValue: paste |
|
1203 |
translateLabel: true |
|
1204 |
labelImage: (ResourceRetriever ToolbarIconLibrary paste16x16Icon) |
|
1205 |
isButton: true |
|
1206 |
) |
|
1207 |
(MenuItem |
|
1208 |
label: '-' |
|
1209 |
) |
|
1210 |
(MenuItem |
|
8508 | 1211 |
activeHelpKey: editUndo |
1212 |
label: 'Undo' |
|
1213 |
itemValue: undo |
|
1214 |
translateLabel: true |
|
1215 |
labelImage: (ResourceRetriever ToolbarIconLibrary undo16x16Icon) |
|
1216 |
isButton: true |
|
1217 |
) |
|
1218 |
(MenuItem |
|
1219 |
activeHelpKey: editRedo |
|
1220 |
label: 'Redo' |
|
1221 |
itemValue: redo |
|
1222 |
translateLabel: true |
|
1223 |
labelImage: (ResourceRetriever ToolbarIconLibrary redo16x16Icon) |
|
1224 |
isButton: true |
|
1225 |
) |
|
1226 |
(MenuItem |
|
1227 |
label: '-' |
|
1228 |
) |
|
1229 |
(MenuItem |
|
8506 | 1230 |
activeHelpKey: editSearch |
8499 | 1231 |
label: 'Search' |
1232 |
itemValue: search |
|
1233 |
translateLabel: true |
|
1234 |
labelImage: (ResourceRetriever ToolbarIconLibrary search16x16Icon) |
|
1235 |
isButton: true |
|
1236 |
) |
|
1237 |
(MenuItem |
|
1238 |
label: '-' |
|
1239 |
) |
|
1240 |
(MenuItem |
|
8508 | 1241 |
activeHelpKey: doUndent |
1242 |
label: 'Undent' |
|
1243 |
itemValue: undent |
|
1244 |
translateLabel: true |
|
1245 |
isButton: true |
|
1246 |
labelImage: (ResourceRetriever ToolbarIconLibrary undent16x16Icon) |
|
1247 |
) |
|
1248 |
(MenuItem |
|
8506 | 1249 |
activeHelpKey: doIndent |
8499 | 1250 |
label: 'Indent' |
1251 |
itemValue: indent |
|
1252 |
translateLabel: true |
|
1253 |
isButton: true |
|
1254 |
labelImage: (ResourceRetriever ToolbarIconLibrary indent16x16Icon) |
|
1255 |
) |
|
1256 |
) |
|
1257 |
nil |
|
1258 |
nil |
|
1259 |
) |
|
1260 |
! |
|
1261 |
||
8342 | 1262 |
executionMenu |
1263 |
"This resource specification was automatically generated |
|
1264 |
by the MenuEditor of ST/X." |
|
1265 |
||
1266 |
"Do not manually edit this!! If it is corrupted, |
|
1267 |
the MenuEditor may not be able to read the specification." |
|
1268 |
||
11483
5f545a7d153a
fixed language related valueholder handling
Claus Gittinger <cg@exept.de>
parents:
11481
diff
changeset
|
1269 |
|
8342 | 1270 |
" |
8492 | 1271 |
MenuEditor new openOnClass:WorkspaceApplication andSelector:#executionMenu |
1272 |
(Menu new fromLiteralArrayEncoding:(WorkspaceApplication executionMenu)) startUp |
|
8342 | 1273 |
" |
1274 |
||
1275 |
<resource: #menu> |
|
1276 |
||
1277 |
^ |
|
1278 |
#(Menu |
|
1279 |
( |
|
1280 |
(MenuItem |
|
1281 |
enabled: hasHistory |
|
1282 |
label: 'Redo Last' |
|
1283 |
itemValue: redoLastDoIt |
|
1284 |
submenuChannel: redoRecentDoItMenu |
|
1285 |
) |
|
1286 |
(MenuItem |
|
1287 |
label: '-' |
|
1288 |
) |
|
1289 |
(MenuItem |
|
1290 |
enabled: hasSelectionInActiveWorkspace |
|
1291 |
label: 'DoIt' |
|
1292 |
itemValue: doIt |
|
1293 |
) |
|
1294 |
(MenuItem |
|
17199 | 1295 |
enabled: hasSelectionInActiveWorkspaceAndEditorIsNotReadonly |
8342 | 1296 |
label: 'PrintIt' |
1297 |
itemValue: printIt |
|
1298 |
) |
|
1299 |
(MenuItem |
|
1300 |
enabled: hasSelectionInActiveWorkspace |
|
1301 |
label: 'InspectIt' |
|
1302 |
itemValue: inspectIt |
|
1303 |
) |
|
1304 |
(MenuItem |
|
1305 |
label: '-' |
|
1306 |
) |
|
1307 |
(MenuItem |
|
1308 |
enabled: hasSelectionInActiveWorkspace |
|
11483
5f545a7d153a
fixed language related valueholder handling
Claus Gittinger <cg@exept.de>
parents:
11481
diff
changeset
|
1309 |
label: 'TimeIt' |
5f545a7d153a
fixed language related valueholder handling
Claus Gittinger <cg@exept.de>
parents:
11481
diff
changeset
|
1310 |
itemValue: timeIt |
5f545a7d153a
fixed language related valueholder handling
Claus Gittinger <cg@exept.de>
parents:
11481
diff
changeset
|
1311 |
) |
5f545a7d153a
fixed language related valueholder handling
Claus Gittinger <cg@exept.de>
parents:
11481
diff
changeset
|
1312 |
(MenuItem |
5f545a7d153a
fixed language related valueholder handling
Claus Gittinger <cg@exept.de>
parents:
11481
diff
changeset
|
1313 |
enabled: hasSelectionInActiveWorkspace |
12028 | 1314 |
label: 'SpyOnIt (Transcript)' |
11483
5f545a7d153a
fixed language related valueholder handling
Claus Gittinger <cg@exept.de>
parents:
11481
diff
changeset
|
1315 |
itemValue: spyOnIt |
12028 | 1316 |
) |
1317 |
(MenuItem |
|
1318 |
enabled: hasSelectionInActiveWorkspace |
|
1319 |
label: 'ProfileIt (Visual)' |
|
1320 |
itemValue: profileIt |
|
11483
5f545a7d153a
fixed language related valueholder handling
Claus Gittinger <cg@exept.de>
parents:
11481
diff
changeset
|
1321 |
) |
5f545a7d153a
fixed language related valueholder handling
Claus Gittinger <cg@exept.de>
parents:
11481
diff
changeset
|
1322 |
(MenuItem |
5f545a7d153a
fixed language related valueholder handling
Claus Gittinger <cg@exept.de>
parents:
11481
diff
changeset
|
1323 |
label: '-' |
5f545a7d153a
fixed language related valueholder handling
Claus Gittinger <cg@exept.de>
parents:
11481
diff
changeset
|
1324 |
) |
5f545a7d153a
fixed language related valueholder handling
Claus Gittinger <cg@exept.de>
parents:
11481
diff
changeset
|
1325 |
(MenuItem |
5f545a7d153a
fixed language related valueholder handling
Claus Gittinger <cg@exept.de>
parents:
11481
diff
changeset
|
1326 |
enabled: hasSelectionInActiveWorkspace |
8342 | 1327 |
label: 'Browse Class' |
1328 |
itemValue: browseIt |
|
1329 |
) |
|
1330 |
(MenuItem |
|
1331 |
enabled: hasSelectionInActiveWorkspace |
|
1332 |
label: 'Browse Implementors of It' |
|
1333 |
itemValue: browseImplementorsOfIt |
|
1334 |
) |
|
1335 |
(MenuItem |
|
1336 |
enabled: hasSelectionInActiveWorkspace |
|
1337 |
label: 'Browse References to It' |
|
1338 |
itemValue: browseReferencesToIt |
|
1339 |
) |
|
1340 |
) |
|
1341 |
nil |
|
1342 |
nil |
|
1343 |
) |
|
1344 |
! |
|
1345 |
||
7865
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1346 |
fileMenu |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1347 |
"This resource specification was automatically generated |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1348 |
by the MenuEditor of ST/X." |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1349 |
|
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1350 |
"Do not manually edit this!! If it is corrupted, |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1351 |
the MenuEditor may not be able to read the specification." |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1352 |
|
13852 | 1353 |
|
7865
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1354 |
" |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1355 |
MenuEditor new openOnClass:WorkspaceApplication andSelector:#fileMenu |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1356 |
(Menu new fromLiteralArrayEncoding:(WorkspaceApplication fileMenu)) startUp |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1357 |
" |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1358 |
|
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1359 |
<resource: #menu> |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1360 |
|
13852 | 1361 |
^ |
7865
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1362 |
#(Menu |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1363 |
( |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1364 |
(MenuItem |
13852 | 1365 |
label: 'Connect...' |
1366 |
itemValue: menuSQLConnect |
|
1367 |
translateLabel: true |
|
1368 |
isVisible: isSQLWorkspaceSelected |
|
1369 |
) |
|
1370 |
(MenuItem |
|
1371 |
label: '-' |
|
1372 |
isVisible: isSQLWorkspaceSelected |
|
1373 |
) |
|
1374 |
(MenuItem |
|
7865
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1375 |
label: 'New Workspace' |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1376 |
itemValue: newWorkspace |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1377 |
translateLabel: true |
10169 | 1378 |
shortcutKey: Ctrln |
1379 |
) |
|
1380 |
(MenuItem |
|
1381 |
label: 'New Tab' |
|
1382 |
itemValue: addWorkspace |
|
1383 |
translateLabel: true |
|
1384 |
isVisible: false |
|
1385 |
shortcutKey: Ctrlt |
|
7865
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1386 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1387 |
(MenuItem |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1388 |
label: 'New SystemWorkspace' |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1389 |
itemValue: newSystemWorkspace |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1390 |
translateLabel: true |
7866 | 1391 |
isVisible: thisIsASmalltalkWorkspace |
7865
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1392 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1393 |
(MenuItem |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1394 |
label: 'New EvaluationWorkspace' |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1395 |
itemValue: newEvaluationWorkspace |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1396 |
translateLabel: true |
7866 | 1397 |
isVisible: thisIsASmalltalkWorkspace |
7865
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1398 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1399 |
(MenuItem |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1400 |
label: '-' |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1401 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1402 |
(MenuItem |
13852 | 1403 |
label: 'Open File...' |
7865
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1404 |
itemValue: menuLoad |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1405 |
translateLabel: true |
10169 | 1406 |
shortcutKey: Ctrlo |
7865
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1407 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1408 |
(MenuItem |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1409 |
label: '-' |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1410 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1411 |
(MenuItem |
10169 | 1412 |
label: 'Save' |
1413 |
itemValue: menuSave |
|
1414 |
translateLabel: true |
|
1415 |
shortcutKey: Ctrls |
|
1416 |
) |
|
1417 |
(MenuItem |
|
7865
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1418 |
label: 'Save As...' |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1419 |
itemValue: menuSaveAs |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1420 |
translateLabel: true |
10169 | 1421 |
shortcutKey: SaveAs |
7865
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1422 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1423 |
(MenuItem |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1424 |
enabled: hasMultipleBuffersHolder |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1425 |
label: 'Save all As...' |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1426 |
itemValue: menuSaveAllAs |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1427 |
translateLabel: true |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1428 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1429 |
(MenuItem |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1430 |
label: '-' |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1431 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1432 |
(MenuItem |
8529
8d2391313df2
disable print item, if there is nothing to print
Claus Gittinger <cg@exept.de>
parents:
8508
diff
changeset
|
1433 |
enabled: hasTextInActiveWorkspace |
7865
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1434 |
label: 'Print...' |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1435 |
itemValue: menuPrint |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1436 |
translateLabel: true |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1437 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1438 |
(MenuItem |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1439 |
label: '-' |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1440 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1441 |
(MenuItem |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1442 |
label: 'Exit' |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1443 |
itemValue: closeRequest |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1444 |
translateLabel: true |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1445 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1446 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1447 |
nil |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1448 |
nil |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1449 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1450 |
! |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1451 |
|
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1452 |
helpMenu |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1453 |
"This resource specification was automatically generated |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1454 |
by the MenuEditor of ST/X." |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1455 |
|
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1456 |
"Do not manually edit this!! If it is corrupted, |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1457 |
the MenuEditor may not be able to read the specification." |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1458 |
|
13581
75759c16ab7f
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13500
diff
changeset
|
1459 |
|
7865
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1460 |
" |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1461 |
MenuEditor new openOnClass:WorkspaceApplication andSelector:#helpMenu |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1462 |
(Menu new fromLiteralArrayEncoding:(WorkspaceApplication helpMenu)) startUp |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1463 |
" |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1464 |
|
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1465 |
<resource: #menu> |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1466 |
|
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1467 |
^ |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1468 |
#(Menu |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1469 |
( |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1470 |
(MenuItem |
15384
196b596fa7e3
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15294
diff
changeset
|
1471 |
label: 'Workspace Documentation' |
7865
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1472 |
itemValue: openDocumentation |
13581
75759c16ab7f
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13500
diff
changeset
|
1473 |
) |
75759c16ab7f
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13500
diff
changeset
|
1474 |
(MenuItem |
75759c16ab7f
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13500
diff
changeset
|
1475 |
label: 'Editing Text' |
75759c16ab7f
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13500
diff
changeset
|
1476 |
itemValue: openEditingDocumentation |
7865
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1477 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1478 |
(MenuItem |
8315 | 1479 |
label: 'Documentation on Smalltalk/X' |
1480 |
itemValue: openSTXDocumentation |
|
1481 |
) |
|
1482 |
(MenuItem |
|
7865
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1483 |
label: '-' |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1484 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1485 |
(MenuItem |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1486 |
label: 'About this Application...' |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1487 |
itemValue: openAboutThisApplication |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1488 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1489 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1490 |
nil |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1491 |
nil |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1492 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1493 |
! |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1494 |
|
9676 | 1495 |
languageInfoLabelMenu |
1496 |
"This resource specification was automatically generated |
|
1497 |
by the MenuEditor of ST/X." |
|
1498 |
||
1499 |
"Do not manually edit this!! If it is corrupted, |
|
1500 |
the MenuEditor may not be able to read the specification." |
|
1501 |
||
1502 |
" |
|
1503 |
MenuEditor new openOnClass:WorkspaceApplication andSelector:#workspaceMenu |
|
1504 |
(Menu new fromLiteralArrayEncoding:(WorkspaceApplication workspaceMenu)) startUp |
|
1505 |
" |
|
1506 |
||
1507 |
<resource: #menu> |
|
1508 |
||
1509 |
^ |
|
1510 |
#(Menu |
|
1511 |
( |
|
1512 |
(MenuItem |
|
1513 |
label: 'Language List Slice' |
|
1514 |
translateLabel: true |
|
1515 |
submenuChannel: languageListMenuSlice |
|
1516 |
isMenuSlice: true |
|
1517 |
) |
|
1518 |
) |
|
1519 |
nil |
|
1520 |
nil |
|
1521 |
) |
|
1522 |
||
1523 |
"Created: / 24-12-2010 / 02:03:59 / cg" |
|
1524 |
! |
|
1525 |
||
3154 | 1526 |
mainMenu |
1527 |
"This resource specification was automatically generated |
|
1528 |
by the MenuEditor of ST/X." |
|
1529 |
||
1530 |
"Do not manually edit this!! If it is corrupted, |
|
1531 |
the MenuEditor may not be able to read the specification." |
|
1532 |
||
13413
1e726d57eeca
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
12942
diff
changeset
|
1533 |
|
3154 | 1534 |
" |
1535 |
MenuEditor new openOnClass:WorkspaceApplication andSelector:#mainMenu |
|
1536 |
(Menu new fromLiteralArrayEncoding:(WorkspaceApplication mainMenu)) startUp |
|
1537 |
" |
|
1538 |
||
1539 |
<resource: #menu> |
|
1540 |
||
1541 |
^ |
|
5852 | 1542 |
#(Menu |
1543 |
( |
|
1544 |
(MenuItem |
|
1545 |
label: 'File' |
|
7865
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1546 |
submenuChannel: fileMenu |
3154 | 1547 |
) |
5852 | 1548 |
(MenuItem |
18395 | 1549 |
label: 'Pages' |
8147 | 1550 |
submenuChannel: bufferMenu |
1551 |
) |
|
1552 |
(MenuItem |
|
8146 | 1553 |
label: 'Edit' |
1554 |
submenuChannel: editMenu |
|
1555 |
) |
|
1556 |
(MenuItem |
|
7651 | 1557 |
label: 'View' |
1558 |
submenuChannel: viewMenu |
|
1559 |
) |
|
1560 |
(MenuItem |
|
10169 | 1561 |
label: 'Bookmarks' |
1562 |
submenuChannel: bookmarkMenu |
|
1563 |
) |
|
1564 |
(MenuItem |
|
8501 | 1565 |
label: 'Execute' |
10169 | 1566 |
isVisible: executeMenuVisible |
8501 | 1567 |
submenuChannel: executionMenu |
1568 |
) |
|
1569 |
(MenuItem |
|
5852 | 1570 |
label: 'Workspace' |
8501 | 1571 |
isVisible: thisIsASmalltalkWorkspace |
7865
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1572 |
submenuChannel: workspaceMenu |
3722 | 1573 |
) |
5852 | 1574 |
(MenuItem |
9300
07364a10a823
syntax to choose from is fetched via ProgramminLanguage list;
Claus Gittinger <cg@exept.de>
parents:
9166
diff
changeset
|
1575 |
enabled: smalltalkMenuEnabledHolder |
5852 | 1576 |
label: 'Smalltalk' |
8501 | 1577 |
isVisible: thisIsASmalltalkWorkspace |
7865
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1578 |
submenuChannel: smalltalkMenu |
3154 | 1579 |
) |
5852 | 1580 |
(MenuItem |
7461
605ae97c85db
support '?' as help (for now: controlled by resources)
Claus Gittinger <cg@exept.de>
parents:
7441
diff
changeset
|
1581 |
label: 'MENU_Help' |
7865
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1582 |
submenuChannel: helpMenu |
3154 | 1583 |
) |
1584 |
) |
|
1585 |
nil |
|
1586 |
nil |
|
1587 |
) |
|
18395 | 1588 |
|
1589 |
"Modified: / 21-09-2018 / 10:56:17 / Claus Gittinger" |
|
7865
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1590 |
! |
7831 | 1591 |
|
14837
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1592 |
manageSnippetDialogMenuSpec |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1593 |
"This resource specification was automatically generated |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1594 |
by the MenuEditor of ST/X." |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1595 |
|
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1596 |
"Do not manually edit this!! If it is corrupted, |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1597 |
the MenuEditor may not be able to read the specification." |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1598 |
|
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1599 |
|
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1600 |
" |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1601 |
MenuEditor new openOnClass:WorkspaceApplication andSelector:#manageSnippetDialogMenuSpec |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1602 |
(Menu new fromLiteralArrayEncoding:(WorkspaceApplication manageSnippetDialogMenuSpec)) startUp |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1603 |
" |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1604 |
|
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1605 |
<resource: #menu> |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1606 |
|
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1607 |
^ |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1608 |
#(Menu |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1609 |
( |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1610 |
(MenuItem |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1611 |
label: 'File' |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1612 |
submenu: |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1613 |
(Menu |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1614 |
( |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1615 |
(MenuItem |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1616 |
label: 'Open Snippet File...' |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1617 |
itemValue: menuOpenSnippetFile |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1618 |
) |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1619 |
(MenuItem |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1620 |
label: '-' |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1621 |
) |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1622 |
(MenuItem |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1623 |
label: 'Save As Snipped File...' |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1624 |
itemValue: menuSaveSnippetFileAs |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1625 |
) |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1626 |
(MenuItem |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1627 |
label: '-' |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1628 |
) |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1629 |
(MenuItem |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1630 |
label: 'Close' |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1631 |
itemValue: closeSnippetDialog |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1632 |
) |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1633 |
) |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1634 |
nil |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1635 |
nil |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1636 |
) |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1637 |
) |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1638 |
(MenuItem |
15392
5d9d4650b23f
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15384
diff
changeset
|
1639 |
label: 'MENU_Help' |
14837
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1640 |
startGroup: conditionalRight |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1641 |
submenu: |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1642 |
(Menu |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1643 |
( |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1644 |
(MenuItem |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1645 |
label: 'Documentation' |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1646 |
itemValue: openSnippetDocumentation |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1647 |
) |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1648 |
(MenuItem |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1649 |
label: '-' |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1650 |
) |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1651 |
(MenuItem |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1652 |
label: 'About this Application...' |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1653 |
itemValue: openAboutThisApplication |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1654 |
) |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1655 |
) |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1656 |
nil |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1657 |
nil |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1658 |
) |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1659 |
) |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1660 |
) |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1661 |
nil |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1662 |
nil |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1663 |
) |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1664 |
! |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
1665 |
|
7865
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1666 |
smalltalkMenu |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1667 |
"This resource specification was automatically generated |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1668 |
by the MenuEditor of ST/X." |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1669 |
|
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1670 |
"Do not manually edit this!! If it is corrupted, |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1671 |
the MenuEditor may not be able to read the specification." |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1672 |
|
11481
d0a2a73ed69d
added: #selectedWorkspaceIsTextView
Stefan Vogel <sv@exept.de>
parents:
11480
diff
changeset
|
1673 |
|
7865
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1674 |
" |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1675 |
MenuEditor new openOnClass:WorkspaceApplication andSelector:#smalltalkMenu |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1676 |
(Menu new fromLiteralArrayEncoding:(WorkspaceApplication smalltalkMenu)) startUp |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1677 |
" |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1678 |
|
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1679 |
<resource: #menu> |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1680 |
|
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1681 |
^ |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1682 |
#(Menu |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1683 |
( |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1684 |
(MenuItem |
11481
d0a2a73ed69d
added: #selectedWorkspaceIsTextView
Stefan Vogel <sv@exept.de>
parents:
11480
diff
changeset
|
1685 |
enabled: hasSelectionInActiveWorkspace |
7865
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1686 |
label: 'FileIn Text' |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1687 |
itemValue: fileInText |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1688 |
translateLabel: true |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1689 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1690 |
(MenuItem |
11481
d0a2a73ed69d
added: #selectedWorkspaceIsTextView
Stefan Vogel <sv@exept.de>
parents:
11480
diff
changeset
|
1691 |
enabled: hasSelectionInActiveWorkspace |
7865
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1692 |
label: 'ChangeList on Text' |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1693 |
itemValue: changesBrowserOnText |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1694 |
translateLabel: true |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1695 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1696 |
(MenuItem |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1697 |
label: '-' |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1698 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1699 |
(MenuItem |
11481
d0a2a73ed69d
added: #selectedWorkspaceIsTextView
Stefan Vogel <sv@exept.de>
parents:
11480
diff
changeset
|
1700 |
enabled: selectedWorkspaceIsTextView |
7865
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1701 |
label: 'Add Global Variable...' |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1702 |
itemValue: addGlobalVariable |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1703 |
translateLabel: true |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1704 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1705 |
(MenuItem |
11481
d0a2a73ed69d
added: #selectedWorkspaceIsTextView
Stefan Vogel <sv@exept.de>
parents:
11480
diff
changeset
|
1706 |
enabled: selectedWorkspaceIsTextView |
7865
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1707 |
label: 'Remove Global Variable...' |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1708 |
itemValue: removeGlobalVariable |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1709 |
translateLabel: true |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1710 |
) |
8342 | 1711 |
(MenuItem |
1712 |
label: '-' |
|
1713 |
) |
|
1714 |
(MenuItem |
|
11481
d0a2a73ed69d
added: #selectedWorkspaceIsTextView
Stefan Vogel <sv@exept.de>
parents:
11480
diff
changeset
|
1715 |
enabled: selectedWorkspaceIsTextView |
8342 | 1716 |
label: 'Add SharedPool...' |
1717 |
itemValue: addSharedPool |
|
1718 |
translateLabel: true |
|
1719 |
) |
|
1720 |
(MenuItem |
|
11481
d0a2a73ed69d
added: #selectedWorkspaceIsTextView
Stefan Vogel <sv@exept.de>
parents:
11480
diff
changeset
|
1721 |
enabled: selectedWorkspaceIsTextView |
8342 | 1722 |
label: 'Remove SharedPool...' |
1723 |
itemValue: removeSharedPool |
|
1724 |
translateLabel: true |
|
1725 |
) |
|
7865
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1726 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1727 |
nil |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1728 |
nil |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1729 |
) |
7658 | 1730 |
! |
1731 |
||
1732 |
toolBarMenu |
|
1733 |
"This resource specification was automatically generated |
|
1734 |
by the MenuEditor of ST/X." |
|
1735 |
||
1736 |
"Do not manually edit this!! If it is corrupted, |
|
1737 |
the MenuEditor may not be able to read the specification." |
|
1738 |
||
14060
fef6bc962708
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13949
diff
changeset
|
1739 |
|
7658 | 1740 |
" |
1741 |
MenuEditor new openOnClass:WorkspaceApplication andSelector:#toolBarMenu |
|
1742 |
(Menu new fromLiteralArrayEncoding:(WorkspaceApplication toolBarMenu)) startUp |
|
1743 |
" |
|
1744 |
||
1745 |
<resource: #menu> |
|
1746 |
||
1747 |
^ |
|
1748 |
#(Menu |
|
1749 |
( |
|
1750 |
(MenuItem |
|
1751 |
label: '' |
|
1752 |
) |
|
1753 |
(MenuItem |
|
18396 | 1754 |
label: 'Add Page' |
7658 | 1755 |
itemValue: addWorkspace |
1756 |
isButton: true |
|
1757 |
labelImage: (ResourceRetriever ToolbarIconLibrary addBufferIcon) |
|
1758 |
) |
|
1759 |
(MenuItem |
|
1760 |
label: '-' |
|
1761 |
) |
|
1762 |
(MenuItem |
|
10169 | 1763 |
activeHelpKey: menuSaveOrSaveAs |
1764 |
label: 'Save Text' |
|
1765 |
itemValue: menuSave |
|
7658 | 1766 |
isButton: true |
11612 | 1767 |
labelImage: (ResourceRetriever ToolbarIconLibrary saveToFileIcon) |
7658 | 1768 |
) |
1769 |
(MenuItem |
|
8226 | 1770 |
label: '-' |
13728
01b72a80639e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13690
diff
changeset
|
1771 |
isVisible: doItMenuButtonVisible |
7658 | 1772 |
) |
1773 |
(MenuItem |
|
10169 | 1774 |
activeHelpKey: #'help_doIt' |
7658 | 1775 |
label: 'DoIt' |
1776 |
itemValue: doIt |
|
7789 | 1777 |
isButton: true |
13728
01b72a80639e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13690
diff
changeset
|
1778 |
isVisible: doItMenuButtonVisible |
8226 | 1779 |
labelImage: (ResourceRetriever ToolbarIconLibrary doItIcon) |
1780 |
) |
|
1781 |
(MenuItem |
|
10169 | 1782 |
activeHelpKey: #'help_printIt' |
8226 | 1783 |
label: 'PrintIt' |
1784 |
itemValue: printIt |
|
1785 |
isButton: true |
|
13728
01b72a80639e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13690
diff
changeset
|
1786 |
isVisible: printItMenuButtonVisible |
8226 | 1787 |
labelImage: (ResourceRetriever ToolbarIconLibrary printItIcon) |
7658 | 1788 |
) |
1789 |
(MenuItem |
|
10169 | 1790 |
activeHelpKey: #'help_inspectIt' |
7658 | 1791 |
label: 'InspectIt' |
1792 |
itemValue: inspectIt |
|
7789 | 1793 |
isButton: true |
13728
01b72a80639e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13690
diff
changeset
|
1794 |
isVisible: inspectItMenuButtonVisible |
8226 | 1795 |
labelImage: (ResourceRetriever ToolbarIconLibrary inspectItIcon) |
1796 |
) |
|
1797 |
(MenuItem |
|
10169 | 1798 |
activeHelpKey: #'help_browseIt' |
8226 | 1799 |
label: 'BrowseIt' |
1800 |
itemValue: browseIt |
|
1801 |
isButton: true |
|
13728
01b72a80639e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13690
diff
changeset
|
1802 |
isVisible: browseItMenuButtonVisible |
8226 | 1803 |
labelImage: (ResourceRetriever ToolbarIconLibrary browseItIcon) |
7658 | 1804 |
) |
10169 | 1805 |
(MenuItem |
14060
fef6bc962708
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13949
diff
changeset
|
1806 |
activeHelpKey: #'help_profileIt' |
fef6bc962708
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13949
diff
changeset
|
1807 |
label: 'ProfileIt' |
fef6bc962708
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13949
diff
changeset
|
1808 |
itemValue: profileIt |
fef6bc962708
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13949
diff
changeset
|
1809 |
isButton: true |
fef6bc962708
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13949
diff
changeset
|
1810 |
isVisible: profileItMenuButtonVisible |
fef6bc962708
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13949
diff
changeset
|
1811 |
labelImage: (ResourceRetriever ToolbarIconLibrary profileItIcon) |
fef6bc962708
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13949
diff
changeset
|
1812 |
) |
fef6bc962708
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13949
diff
changeset
|
1813 |
(MenuItem |
10169 | 1814 |
activeHelpKey: addTerminal |
1815 |
label: 'Web Browser' |
|
1816 |
itemValue: addWebBrowser |
|
1817 |
isButton: true |
|
1818 |
startGroup: right |
|
1819 |
isVisible: isWebBrowserAvailable |
|
1820 |
labelImage: (ResourceRetriever ToolbarIconLibrary webKit22x22) |
|
1821 |
) |
|
1822 |
(MenuItem |
|
1823 |
activeHelpKey: addTerminal |
|
1824 |
label: 'Terminal' |
|
1825 |
itemValue: addTerminal |
|
1826 |
isButton: true |
|
1827 |
startGroup: right |
|
1828 |
labelImage: (ResourceRetriever ToolbarIconLibrary shellTerminalIcon) |
|
1829 |
) |
|
7658 | 1830 |
) |
1831 |
nil |
|
1832 |
nil |
|
1833 |
) |
|
18396 | 1834 |
|
1835 |
"Modified: / 21-09-2018 / 11:06:00 / Claus Gittinger" |
|
7865
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1836 |
! |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1837 |
|
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1838 |
workspaceMenu |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1839 |
"This resource specification was automatically generated |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1840 |
by the MenuEditor of ST/X." |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1841 |
|
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1842 |
"Do not manually edit this!! If it is corrupted, |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1843 |
the MenuEditor may not be able to read the specification." |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1844 |
|
11481
d0a2a73ed69d
added: #selectedWorkspaceIsTextView
Stefan Vogel <sv@exept.de>
parents:
11480
diff
changeset
|
1845 |
|
7865
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1846 |
" |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1847 |
MenuEditor new openOnClass:WorkspaceApplication andSelector:#workspaceMenu |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1848 |
(Menu new fromLiteralArrayEncoding:(WorkspaceApplication workspaceMenu)) startUp |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1849 |
" |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1850 |
|
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1851 |
<resource: #menu> |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1852 |
|
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1853 |
^ |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1854 |
#(Menu |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1855 |
( |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1856 |
(MenuItem |
13643
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
1857 |
label: 'Language List Slice' |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
1858 |
submenuChannel: languageListMenuSlice |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
1859 |
isMenuSlice: true |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
1860 |
) |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
1861 |
(MenuItem |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
1862 |
label: '-' |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
1863 |
) |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
1864 |
(MenuItem |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
1865 |
label: 'Namespace for DoIt' |
14635
bed940a94253
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14594
diff
changeset
|
1866 |
submenuChannel: namespaceInfoLabelMenuHolder |
13643
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
1867 |
) |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
1868 |
(MenuItem |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
1869 |
label: '-' |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
1870 |
) |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
1871 |
(MenuItem |
11481
d0a2a73ed69d
added: #selectedWorkspaceIsTextView
Stefan Vogel <sv@exept.de>
parents:
11480
diff
changeset
|
1872 |
enabled: selectedWorkspaceIsTextView |
7865
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1873 |
label: 'Add Workspace Variable...' |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1874 |
itemValue: addWorkspaceVariable |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1875 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1876 |
(MenuItem |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1877 |
enabled: anyWorkspaceVariableIsDefined |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1878 |
label: 'Remove Workspace Variable...' |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1879 |
itemValue: removeWorkspaceVariable |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1880 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1881 |
(MenuItem |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1882 |
enabled: anyWorkspaceVariableIsDefined |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1883 |
label: 'Remove all Workspace Variables...' |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1884 |
itemValue: removeAllWorkspaceVariables |
10169 | 1885 |
) |
1886 |
(MenuItem |
|
1887 |
label: '-' |
|
1888 |
) |
|
1889 |
(MenuItem |
|
7865
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1890 |
enabled: anyWorkspaceVariableIsDefined |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1891 |
label: 'Inspect Workspace Variables' |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1892 |
itemValue: inspectWorkspaceVariables |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1893 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1894 |
(MenuItem |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1895 |
label: '-' |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1896 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1897 |
(MenuItem |
11799 | 1898 |
label: 'Autodefine Variables' |
7865
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1899 |
submenu: |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1900 |
(Menu |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1901 |
( |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1902 |
(MenuItem |
11799 | 1903 |
label: 'As Workspace Variable' |
7865
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1904 |
hideMenuOnActivated: false |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1905 |
choice: autoDefineVariables |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1906 |
choiceValue: workspace |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1907 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1908 |
(MenuItem |
11799 | 1909 |
label: 'As DoIt Variable' |
7865
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1910 |
hideMenuOnActivated: false |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1911 |
choice: autoDefineVariables |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1912 |
choiceValue: doIt |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1913 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1914 |
(MenuItem |
11799 | 1915 |
label: '-' |
1916 |
) |
|
1917 |
(MenuItem |
|
1918 |
label: 'Do not Autodefine' |
|
7865
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1919 |
hideMenuOnActivated: false |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1920 |
choice: autoDefineVariables |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1921 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1922 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1923 |
nil |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1924 |
nil |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1925 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1926 |
) |
13413
1e726d57eeca
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
12942
diff
changeset
|
1927 |
(MenuItem |
1e726d57eeca
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
12942
diff
changeset
|
1928 |
label: '-' |
1e726d57eeca
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
12942
diff
changeset
|
1929 |
) |
1e726d57eeca
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
12942
diff
changeset
|
1930 |
(MenuItem |
1e726d57eeca
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
12942
diff
changeset
|
1931 |
label: 'Terminate Processes Forked Here' |
1e726d57eeca
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
12942
diff
changeset
|
1932 |
itemValue: terminateBackgroundProcesses |
1e726d57eeca
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
12942
diff
changeset
|
1933 |
) |
7865
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1934 |
) |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1935 |
nil |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1936 |
nil |
ae5b649724dd
separated submenus into separate specs (for easier customization in subclasses)
Claus Gittinger <cg@exept.de>
parents:
7853
diff
changeset
|
1937 |
) |
3154 | 1938 |
! ! |
1939 |
||
10169 | 1940 |
!WorkspaceApplication class methodsFor:'private'! |
1941 |
||
1942 |
createWorkspaceView |
|
13585
3e4d51ef27a2
Refactoring after moving codeAspect to EditTextView.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13581
diff
changeset
|
1943 |
| view | |
3e4d51ef27a2
Refactoring after moving codeAspect to EditTextView.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13581
diff
changeset
|
1944 |
|
3e4d51ef27a2
Refactoring after moving codeAspect to EditTextView.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13581
diff
changeset
|
1945 |
view := (UserPreferences current useCodeView2In:#Workspace) |
15294
4bd3f000c743
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15273
diff
changeset
|
1946 |
ifTrue:[Tools::CodeView2 new] |
4bd3f000c743
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15273
diff
changeset
|
1947 |
ifFalse:[HVScrollableView for:Workspace]. |
13585
3e4d51ef27a2
Refactoring after moving codeAspect to EditTextView.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13581
diff
changeset
|
1948 |
^ view |
3e4d51ef27a2
Refactoring after moving codeAspect to EditTextView.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13581
diff
changeset
|
1949 |
|
3e4d51ef27a2
Refactoring after moving codeAspect to EditTextView.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13581
diff
changeset
|
1950 |
"Modified: / 27-09-2013 / 10:23:56 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
10169 | 1951 |
! ! |
1952 |
||
3332 | 1953 |
!WorkspaceApplication class methodsFor:'special startup'! |
1954 |
||
7403
73712386ea82
menu: open/add evaluation workspace
Claus Gittinger <cg@exept.de>
parents:
6865
diff
changeset
|
1955 |
openEvaluationWorkspace |
11728
eb5cf1a80189
comment/format in: #openEvaluationWorkspace
Stefan Vogel <sv@exept.de>
parents:
11725
diff
changeset
|
1956 |
|wsApp needRemove| |
7403
73712386ea82
menu: open/add evaluation workspace
Claus Gittinger <cg@exept.de>
parents:
6865
diff
changeset
|
1957 |
|
73712386ea82
menu: open/add evaluation workspace
Claus Gittinger <cg@exept.de>
parents:
6865
diff
changeset
|
1958 |
needRemove := true. |
73712386ea82
menu: open/add evaluation workspace
Claus Gittinger <cg@exept.de>
parents:
6865
diff
changeset
|
1959 |
|
73712386ea82
menu: open/add evaluation workspace
Claus Gittinger <cg@exept.de>
parents:
6865
diff
changeset
|
1960 |
wsApp := self new. |
73712386ea82
menu: open/add evaluation workspace
Claus Gittinger <cg@exept.de>
parents:
6865
diff
changeset
|
1961 |
wsApp allButOpen. |
73712386ea82
menu: open/add evaluation workspace
Claus Gittinger <cg@exept.de>
parents:
6865
diff
changeset
|
1962 |
wsApp window extent:400@500. |
73712386ea82
menu: open/add evaluation workspace
Claus Gittinger <cg@exept.de>
parents:
6865
diff
changeset
|
1963 |
|
73712386ea82
menu: open/add evaluation workspace
Claus Gittinger <cg@exept.de>
parents:
6865
diff
changeset
|
1964 |
wsApp addEvaluationWorkspace. |
73712386ea82
menu: open/add evaluation workspace
Claus Gittinger <cg@exept.de>
parents:
6865
diff
changeset
|
1965 |
wsApp removeWorkspace:1. |
73712386ea82
menu: open/add evaluation workspace
Claus Gittinger <cg@exept.de>
parents:
6865
diff
changeset
|
1966 |
wsApp renameWorkspace:1 to:'Evaluator'. |
73712386ea82
menu: open/add evaluation workspace
Claus Gittinger <cg@exept.de>
parents:
6865
diff
changeset
|
1967 |
|
73712386ea82
menu: open/add evaluation workspace
Claus Gittinger <cg@exept.de>
parents:
6865
diff
changeset
|
1968 |
wsApp openWindow. |
73712386ea82
menu: open/add evaluation workspace
Claus Gittinger <cg@exept.de>
parents:
6865
diff
changeset
|
1969 |
wsApp selectedWorkspaceIndexHolder value:1. |
7849
e3e01db99dd9
open methods return the just created ws
Claus Gittinger <cg@exept.de>
parents:
7848
diff
changeset
|
1970 |
^ wsApp |
7403
73712386ea82
menu: open/add evaluation workspace
Claus Gittinger <cg@exept.de>
parents:
6865
diff
changeset
|
1971 |
|
73712386ea82
menu: open/add evaluation workspace
Claus Gittinger <cg@exept.de>
parents:
6865
diff
changeset
|
1972 |
" |
73712386ea82
menu: open/add evaluation workspace
Claus Gittinger <cg@exept.de>
parents:
6865
diff
changeset
|
1973 |
self openEvaluationWorkspace |
73712386ea82
menu: open/add evaluation workspace
Claus Gittinger <cg@exept.de>
parents:
6865
diff
changeset
|
1974 |
" |
73712386ea82
menu: open/add evaluation workspace
Claus Gittinger <cg@exept.de>
parents:
6865
diff
changeset
|
1975 |
|
73712386ea82
menu: open/add evaluation workspace
Claus Gittinger <cg@exept.de>
parents:
6865
diff
changeset
|
1976 |
"Created: / 13-10-2006 / 12:14:13 / cg" |
7849
e3e01db99dd9
open methods return the just created ws
Claus Gittinger <cg@exept.de>
parents:
7848
diff
changeset
|
1977 |
"Modified: / 25-09-2007 / 21:00:45 / cg" |
7403
73712386ea82
menu: open/add evaluation workspace
Claus Gittinger <cg@exept.de>
parents:
6865
diff
changeset
|
1978 |
! |
73712386ea82
menu: open/add evaluation workspace
Claus Gittinger <cg@exept.de>
parents:
6865
diff
changeset
|
1979 |
|
9085 | 1980 |
openForSinglePageDoing:aBlock |
1981 |
|wsApp needRemove| |
|
1982 |
||
1983 |
needRemove := true. |
|
1984 |
||
1985 |
wsApp := self new. |
|
1986 |
wsApp allButOpen. |
|
1987 |
||
1988 |
(wsApp builder componentAt:'NoteBook') destroyTabAction:nil. |
|
1989 |
||
1990 |
wsApp window height:500. |
|
1991 |
||
1992 |
aBlock value:wsApp. |
|
1993 |
wsApp removeWorkspace:1. "/ the original Workspace |
|
1994 |
"/ wsApp renameWorkspace:1 to:'LICENCE README'. |
|
1995 |
||
1996 |
wsApp openWindow. |
|
1997 |
wsApp selectedWorkspaceIndexHolder value:1. |
|
1998 |
^ wsApp |
|
1999 |
||
2000 |
" |
|
2001 |
self openWithGlobalsInspector |
|
2002 |
" |
|
2003 |
! |
|
2004 |
||
8317 | 2005 |
openMyWorkspace |
15608
0f4b14944011
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15409
diff
changeset
|
2006 |
|ws| |
0f4b14944011
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15409
diff
changeset
|
2007 |
|
17035 | 2008 |
"/ openMyWorkspace_new leads to an error in root /, which we don't understand... |
15608
0f4b14944011
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15409
diff
changeset
|
2009 |
ws := self openMyWorkspace_new. |
12699 | 2010 |
"/ self openMyWorkspace_old. |
2011 |
MyWorkspaceOpened := true. |
|
15608
0f4b14944011
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15409
diff
changeset
|
2012 |
^ ws |
10318 | 2013 |
|
2014 |
" |
|
10562 | 2015 |
WorkspaceApplication openMyWorkspace |
10318 | 2016 |
" |
2017 |
||
2018 |
"Modified: / 21-06-2011 / 08:58:28 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
2019 |
"Modified: / 14-07-2011 / 13:12:04 / Administrator" |
|
10562 | 2020 |
"Modified (comment): / 09-08-2011 / 22:59:13 / cg" |
10318 | 2021 |
! |
2022 |
||
2023 |
openMyWorkspace_new |
|
10730
23c04d952143
much faster startup in openMyWorkspace_new
Claus Gittinger <cg@exept.de>
parents:
10602
diff
changeset
|
2024 |
"open showing tabs for ALL bookmarked workspace files" |
23c04d952143
much faster startup in openMyWorkspace_new
Claus Gittinger <cg@exept.de>
parents:
10602
diff
changeset
|
2025 |
|
23c04d952143
much faster startup in openMyWorkspace_new
Claus Gittinger <cg@exept.de>
parents:
10602
diff
changeset
|
2026 |
|workspace| |
23c04d952143
much faster startup in openMyWorkspace_new
Claus Gittinger <cg@exept.de>
parents:
10602
diff
changeset
|
2027 |
|
23c04d952143
much faster startup in openMyWorkspace_new
Claus Gittinger <cg@exept.de>
parents:
10602
diff
changeset
|
2028 |
"/ workspace := self openWith: nil. |
23c04d952143
much faster startup in openMyWorkspace_new
Claus Gittinger <cg@exept.de>
parents:
10602
diff
changeset
|
2029 |
"/ workspace enqueueDelayedAction:[ |
23c04d952143
much faster startup in openMyWorkspace_new
Claus Gittinger <cg@exept.de>
parents:
10602
diff
changeset
|
2030 |
"/ Error handle:[:ex | |
23c04d952143
much faster startup in openMyWorkspace_new
Claus Gittinger <cg@exept.de>
parents:
10602
diff
changeset
|
2031 |
"/ "/ no time to debug that stuff now... |
23c04d952143
much faster startup in openMyWorkspace_new
Claus Gittinger <cg@exept.de>
parents:
10602
diff
changeset
|
2032 |
"/ Dialog information:'Error in bookmark handling: ',ex description |
23c04d952143
much faster startup in openMyWorkspace_new
Claus Gittinger <cg@exept.de>
parents:
10602
diff
changeset
|
2033 |
"/ ] do:[ |
23c04d952143
much faster startup in openMyWorkspace_new
Claus Gittinger <cg@exept.de>
parents:
10602
diff
changeset
|
2034 |
"/ BookmarkList forWorkspace myWorkspaces do:[:bookmark| |
23c04d952143
much faster startup in openMyWorkspace_new
Claus Gittinger <cg@exept.de>
parents:
10602
diff
changeset
|
2035 |
"/ workspace switchToBookmarkEntry: bookmark |
23c04d952143
much faster startup in openMyWorkspace_new
Claus Gittinger <cg@exept.de>
parents:
10602
diff
changeset
|
2036 |
"/ ]. |
23c04d952143
much faster startup in openMyWorkspace_new
Claus Gittinger <cg@exept.de>
parents:
10602
diff
changeset
|
2037 |
"/ |
23c04d952143
much faster startup in openMyWorkspace_new
Claus Gittinger <cg@exept.de>
parents:
10602
diff
changeset
|
2038 |
"/ |
23c04d952143
much faster startup in openMyWorkspace_new
Claus Gittinger <cg@exept.de>
parents:
10602
diff
changeset
|
2039 |
"/ |
23c04d952143
much faster startup in openMyWorkspace_new
Claus Gittinger <cg@exept.de>
parents:
10602
diff
changeset
|
2040 |
"/ ]. |
23c04d952143
much faster startup in openMyWorkspace_new
Claus Gittinger <cg@exept.de>
parents:
10602
diff
changeset
|
2041 |
"/ workspace selectedWorkspaceIndexHolder value: 1. |
23c04d952143
much faster startup in openMyWorkspace_new
Claus Gittinger <cg@exept.de>
parents:
10602
diff
changeset
|
2042 |
"/ ]. |
23c04d952143
much faster startup in openMyWorkspace_new
Claus Gittinger <cg@exept.de>
parents:
10602
diff
changeset
|
2043 |
|
23c04d952143
much faster startup in openMyWorkspace_new
Claus Gittinger <cg@exept.de>
parents:
10602
diff
changeset
|
2044 |
workspace := self new. |
23c04d952143
much faster startup in openMyWorkspace_new
Claus Gittinger <cg@exept.de>
parents:
10602
diff
changeset
|
2045 |
workspace allButOpen. |
11483
5f545a7d153a
fixed language related valueholder handling
Claus Gittinger <cg@exept.de>
parents:
11481
diff
changeset
|
2046 |
workspace initialSyntax:SmalltalkLanguage instance. |
10730
23c04d952143
much faster startup in openMyWorkspace_new
Claus Gittinger <cg@exept.de>
parents:
10602
diff
changeset
|
2047 |
|
23c04d952143
much faster startup in openMyWorkspace_new
Claus Gittinger <cg@exept.de>
parents:
10602
diff
changeset
|
2048 |
Error handle:[:ex | |
23c04d952143
much faster startup in openMyWorkspace_new
Claus Gittinger <cg@exept.de>
parents:
10602
diff
changeset
|
2049 |
ex reject. |
23c04d952143
much faster startup in openMyWorkspace_new
Claus Gittinger <cg@exept.de>
parents:
10602
diff
changeset
|
2050 |
"/ no time to debug that stuff now... |
23c04d952143
much faster startup in openMyWorkspace_new
Claus Gittinger <cg@exept.de>
parents:
10602
diff
changeset
|
2051 |
Dialog information:'Error in bookmark handling: ',ex description |
23c04d952143
much faster startup in openMyWorkspace_new
Claus Gittinger <cg@exept.de>
parents:
10602
diff
changeset
|
2052 |
] do:[ |
23c04d952143
much faster startup in openMyWorkspace_new
Claus Gittinger <cg@exept.de>
parents:
10602
diff
changeset
|
2053 |
BookmarkList forWorkspace myWorkspaces do:[:bookmark| |
23c04d952143
much faster startup in openMyWorkspace_new
Claus Gittinger <cg@exept.de>
parents:
10602
diff
changeset
|
2054 |
workspace switchToBookmarkEntry: bookmark |
10169 | 2055 |
]. |
2056 |
]. |
|
10730
23c04d952143
much faster startup in openMyWorkspace_new
Claus Gittinger <cg@exept.de>
parents:
10602
diff
changeset
|
2057 |
workspace selectedWorkspaceIndexHolder value: 1. |
23c04d952143
much faster startup in openMyWorkspace_new
Claus Gittinger <cg@exept.de>
parents:
10602
diff
changeset
|
2058 |
workspace openWindow. |
15608
0f4b14944011
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15409
diff
changeset
|
2059 |
^ workspace |
10169 | 2060 |
|
2061 |
" |
|
10730
23c04d952143
much faster startup in openMyWorkspace_new
Claus Gittinger <cg@exept.de>
parents:
10602
diff
changeset
|
2062 |
WorkspaceApplication openMyWorkspace |
10169 | 2063 |
" |
2064 |
||
2065 |
"Modified: / 21-06-2011 / 08:58:28 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
10318 | 2066 |
"Created: / 14-07-2011 / 13:11:32 / Administrator" |
11483
5f545a7d153a
fixed language related valueholder handling
Claus Gittinger <cg@exept.de>
parents:
11481
diff
changeset
|
2067 |
"Modified: / 26-04-2012 / 12:45:50 / cg" |
10169 | 2068 |
! |
2069 |
||
2070 |
openMyWorkspace_old |
|
10730
23c04d952143
much faster startup in openMyWorkspace_new
Claus Gittinger <cg@exept.de>
parents:
10602
diff
changeset
|
2071 |
"open showing the single file: MyWorkspace.wsp" |
23c04d952143
much faster startup in openMyWorkspace_new
Claus Gittinger <cg@exept.de>
parents:
10602
diff
changeset
|
2072 |
|
15608
0f4b14944011
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15409
diff
changeset
|
2073 |
^ self openOnFile:'MyWorkspace.wsp' |
8317 | 2074 |
|
2075 |
" |
|
2076 |
self openMyWorkspace. |
|
2077 |
" |
|
10169 | 2078 |
|
2079 |
"Created: / 21-06-2011 / 08:51:01 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
10730
23c04d952143
much faster startup in openMyWorkspace_new
Claus Gittinger <cg@exept.de>
parents:
10602
diff
changeset
|
2080 |
"Modified (comment): / 28-09-2011 / 07:48:07 / cg" |
8317 | 2081 |
! |
2082 |
||
6022 | 2083 |
openOnFile:aFilename |
2084 |
"launch a new workspace on the contents of some file" |
|
2085 |
||
2086 |
|ws| |
|
2087 |
||
2088 |
ws := self openWith:nil. |
|
8369 | 2089 |
|
2090 |
"/ let the ws load the file - instead of the caller. |
|
2091 |
"/ so the error dialog is shown in its context, |
|
2092 |
"/ and the caller (Launcher) is not blocked. |
|
2093 |
ws enqueueDelayedAction:[ws loadFile:aFilename]. |
|
2094 |
"/ ws loadFile:aFilename. |
|
6022 | 2095 |
^ ws |
2096 |
||
2097 |
" |
|
2098 |
WorkspaceApplication openOnFile:'Makefile' |
|
2099 |
" |
|
2100 |
! |
|
2101 |
||
3332 | 2102 |
openSystemWorkspace |
14747 | 2103 |
^ self new openSystemWorkspace. |
3332 | 2104 |
|
2105 |
" |
|
7850 | 2106 |
|ws b| |
2107 |
ws := self openSystemWorkspace. |
|
7853 | 2108 |
ws addMyWorkspace. |
2109 |
ws selectedWorkspaceIndexHolder value:(ws workspaces size). |
|
2110 |
ws selectedWorkspace contents:'Tools::NewSystemBrowser open'; selectAll. |
|
7850 | 2111 |
ws selectedWorkspace |
7851 | 2112 |
add:(b := Button label:'DoIt' action:[ws doIt. b destroy]) |
3332 | 2113 |
" |
7853 | 2114 |
" |
2115 |
|ws b| |
|
2116 |
ws := self new. |
|
2117 |
ws open. |
|
2118 |
ws selectedWorkspace contents:'Tools::NewSystemBrowser open'; selectAll. |
|
2119 |
" |
|
7612
42b1c57c6cc7
Private.wsp and MyWorkspace.wsp
Claus Gittinger <cg@exept.de>
parents:
7544
diff
changeset
|
2120 |
|
10169 | 2121 |
"Modified: / 14-02-2010 / 23:02:59 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
2122 |
"Modified: / 05-07-2011 / 15:34:40 / cg" |
|
4542 | 2123 |
! |
2124 |
||
2125 |
openWith:initialText |
|
15046
0441bc4caefc
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14837
diff
changeset
|
2126 |
"launch a new workspace with some initial contents. |
0441bc4caefc
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14837
diff
changeset
|
2127 |
The workspace will be opened in smalltalk syntax mode" |
4542 | 2128 |
|
13852 | 2129 |
^ self openWith:initialText selected:false |
5098 | 2130 |
|
2131 |
" |
|
13852 | 2132 |
WorkspaceApplication openWith:'Transcript showCR:''hello world''' |
5098 | 2133 |
" |
2134 |
! |
|
2135 |
||
2136 |
openWith:initialText selected:selectedBoolean |
|
15046
0441bc4caefc
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14837
diff
changeset
|
2137 |
"launch a new workspace with some initial contents. |
0441bc4caefc
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14837
diff
changeset
|
2138 |
The workspace will be opened in smalltalk syntax mode" |
5098 | 2139 |
|
13852 | 2140 |
|workspace| |
2141 |
||
2142 |
workspace := self new. |
|
2143 |
workspace open. |
|
2144 |
workspace selectedWorkspace contents:initialText selected:selectedBoolean. |
|
2145 |
^ workspace |
|
12639
6a0a5bf99236
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
12479
diff
changeset
|
2146 |
|
6a0a5bf99236
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
12479
diff
changeset
|
2147 |
" |
13852 | 2148 |
WorkspaceApplication openWith:'Transcript showCR:''hello world''' |
12639
6a0a5bf99236
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
12479
diff
changeset
|
2149 |
" |
6a0a5bf99236
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
12479
diff
changeset
|
2150 |
! |
6a0a5bf99236
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
12479
diff
changeset
|
2151 |
|
6a0a5bf99236
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
12479
diff
changeset
|
2152 |
openWith:initialText selected:selectedBoolean title:titleString |
15046
0441bc4caefc
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14837
diff
changeset
|
2153 |
"launch a new workspace with some initial contents. |
0441bc4caefc
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14837
diff
changeset
|
2154 |
The workspace will be opened in smalltalk syntax mode" |
12639
6a0a5bf99236
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
12479
diff
changeset
|
2155 |
|
4542 | 2156 |
|workspace| |
2157 |
||
2158 |
workspace := self new. |
|
2159 |
workspace open. |
|
12639
6a0a5bf99236
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
12479
diff
changeset
|
2160 |
titleString notNil ifTrue:[workspace setLabel:titleString]. |
5098 | 2161 |
workspace selectedWorkspace contents:initialText selected:selectedBoolean. |
4542 | 2162 |
^ workspace |
2163 |
||
2164 |
" |
|
12639
6a0a5bf99236
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
12479
diff
changeset
|
2165 |
WorkspaceApplication |
6a0a5bf99236
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
12479
diff
changeset
|
2166 |
openWith:'Transcript showCR:''hello world''' |
6a0a5bf99236
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
12479
diff
changeset
|
2167 |
selected:false |
6a0a5bf99236
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
12479
diff
changeset
|
2168 |
title:'hello' |
4542 | 2169 |
" |
9085 | 2170 |
! |
2171 |
||
2172 |
openWithGlobalsInspector |
|
2173 |
"open a workspaceApp with a single initial pane, showing global variables. |
|
2174 |
Same as Smalltalk inspect, but looks nicer..." |
|
2175 |
||
2176 |
^ self openForSinglePageDoing:[:wsApp | wsApp addNamespaceInspectorFor:Smalltalk] |
|
2177 |
||
2178 |
" |
|
2179 |
self openWithGlobalsInspector |
|
2180 |
" |
|
2181 |
! |
|
2182 |
||
15046
0441bc4caefc
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14837
diff
changeset
|
2183 |
openWithText:initialText |
0441bc4caefc
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14837
diff
changeset
|
2184 |
"like openWith, but will set the language to 'text', so it is not incorrectly syntax highlighted" |
0441bc4caefc
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14837
diff
changeset
|
2185 |
|
0441bc4caefc
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14837
diff
changeset
|
2186 |
|ws| |
0441bc4caefc
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14837
diff
changeset
|
2187 |
|
0441bc4caefc
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14837
diff
changeset
|
2188 |
ws := self openWith:initialText selected:false. |
0441bc4caefc
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14837
diff
changeset
|
2189 |
ws syntax:nil. |
0441bc4caefc
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14837
diff
changeset
|
2190 |
^ ws. |
0441bc4caefc
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14837
diff
changeset
|
2191 |
|
0441bc4caefc
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14837
diff
changeset
|
2192 |
" |
0441bc4caefc
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14837
diff
changeset
|
2193 |
WorkspaceApplication openWithText:'foo 1 2 3 4' |
0441bc4caefc
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14837
diff
changeset
|
2194 |
" |
0441bc4caefc
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14837
diff
changeset
|
2195 |
! |
0441bc4caefc
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14837
diff
changeset
|
2196 |
|
9085 | 2197 |
openWithWorkspaceVariableInspector |
2198 |
"open a workspaceApp with a single initial pane, showing workspace variables. |
|
2199 |
Same as Workspace workspaceVariables inspect, but looks nicer..." |
|
2200 |
||
2201 |
^ self openForSinglePageDoing:[:wsApp | wsApp addWorkspaceVariableInspector] |
|
2202 |
||
2203 |
" |
|
2204 |
self openWithWorkspaceVariableInspector |
|
2205 |
" |
|
3332 | 2206 |
! ! |
2207 |
||
10169 | 2208 |
!WorkspaceApplication class methodsFor:'startup'! |
2209 |
||
2210 |
open |
|
2211 |
"/ the very first open opens a MyWorkspace |
|
2212 |
||
2213 |
(MyWorkspaceOpened == true) ifTrue:[ |
|
15608
0f4b14944011
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15409
diff
changeset
|
2214 |
^ self openRegularWorkspace |
10169 | 2215 |
] ifFalse:[ |
15608
0f4b14944011
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15409
diff
changeset
|
2216 |
^ self openMyWorkspace |
10169 | 2217 |
]. |
2218 |
||
2219 |
" |
|
2220 |
MyWorkspaceOpened := nil. |
|
2221 |
WorkspaceApplication open. |
|
2222 |
" |
|
2223 |
||
2224 |
"Created: / 21-06-2011 / 09:03:29 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
2225 |
"Modified (comment): / 05-07-2011 / 15:23:53 / cg" |
|
15234
e00c67bae495
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15046
diff
changeset
|
2226 |
! |
e00c67bae495
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15046
diff
changeset
|
2227 |
|
e00c67bae495
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15046
diff
changeset
|
2228 |
openRegularWorkspace |
e00c67bae495
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15046
diff
changeset
|
2229 |
"/ always open a normal MyWorkspace |
e00c67bae495
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15046
diff
changeset
|
2230 |
|
15608
0f4b14944011
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15409
diff
changeset
|
2231 |
^ super open |
15234
e00c67bae495
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15046
diff
changeset
|
2232 |
|
e00c67bae495
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15046
diff
changeset
|
2233 |
" |
e00c67bae495
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15046
diff
changeset
|
2234 |
MyWorkspaceOpened := nil. |
e00c67bae495
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15046
diff
changeset
|
2235 |
WorkspaceApplication open. |
e00c67bae495
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15046
diff
changeset
|
2236 |
" |
10169 | 2237 |
! ! |
2238 |
||
3193 | 2239 |
!WorkspaceApplication methodsFor:'aspects'! |
2240 |
||
4474 | 2241 |
autoDefineVariables |
2242 |
autoDefineVariables isNil ifTrue:[ |
|
2243 |
autoDefineVariables := ValueHolder new. |
|
2244 |
(UserPreferences current autoDefineWorkspaceVariables) ifTrue:[ |
|
5547
65af7af97085
initial value of #autoDefine was not set correctly
Claus Gittinger <cg@exept.de>
parents:
5490
diff
changeset
|
2245 |
autoDefineVariables value:#workspace. |
9381 | 2246 |
] ifFalse:[ |
2247 |
autoDefineVariables value:#doIt. |
|
4474 | 2248 |
]. |
2249 |
autoDefineVariables onChangeSend:#autoDefineVariablesChanged to:self. |
|
2250 |
]. |
|
2251 |
^ autoDefineVariables. |
|
2252 |
! |
|
2253 |
||
18055 | 2254 |
autoFetchSelectionHolder |
2255 |
autoFetchSelectionHolder isNil ifTrue:[ |
|
2256 |
autoFetchSelectionHolder := ValueHolder with:false. |
|
2257 |
autoFetchSelectionHolder onChangeEvaluate:[self autoFetchSelection:autoFetchSelectionHolder value]. |
|
2258 |
]. |
|
2259 |
^ autoFetchSelectionHolder |
|
2260 |
! |
|
2261 |
||
2262 |
autoFetchSelectionMenuItemVisible |
|
2263 |
^ false |
|
2264 |
! |
|
2265 |
||
10169 | 2266 |
bookmarks |
2267 |
|ws app| |
|
2268 |
||
2269 |
ws := self selectedWorkspace scrolledView. |
|
2270 |
ws isTextView ifTrue:[ |
|
2271 |
^ BookmarkList forWorkspace |
|
2272 |
]. |
|
11725
0b626c2b4b2d
Avoid #isKindOf: where possible
Stefan Vogel <sv@exept.de>
parents:
11713
diff
changeset
|
2273 |
(ws isApplicationSubView) ifTrue:[ |
10169 | 2274 |
app := ws application. |
2275 |
(app respondsTo:#bookmarks) ifTrue:[ |
|
2276 |
^ app bookmarks |
|
2277 |
]. |
|
2278 |
(app respondsTo:#bookmarkListHolder) ifTrue:[ |
|
2279 |
^ app bookmarkListHolder value |
|
2280 |
]. |
|
2281 |
]. |
|
2282 |
^ BookmarkList new. |
|
2283 |
||
2284 |
"Created: / 20-06-2011 / 22:23:03 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
2285 |
"Modified: / 21-06-2011 / 08:13:09 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
2286 |
"Modified (format): / 05-07-2011 / 14:21:10 / cg" |
|
2287 |
! |
|
2288 |
||
8226 | 2289 |
browseItMenuButtonVisibile |
13728
01b72a80639e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13690
diff
changeset
|
2290 |
"/ typo in previous version |
01b72a80639e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13690
diff
changeset
|
2291 |
^ self browseItMenuButtonVisible |
01b72a80639e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13690
diff
changeset
|
2292 |
|
01b72a80639e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13690
diff
changeset
|
2293 |
"Modified: / 17-12-2013 / 16:34:59 / cg" |
01b72a80639e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13690
diff
changeset
|
2294 |
! |
01b72a80639e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13690
diff
changeset
|
2295 |
|
01b72a80639e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13690
diff
changeset
|
2296 |
browseItMenuButtonVisible |
8226 | 2297 |
^ self thisIsASmalltalkWorkspace |
13728
01b72a80639e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13690
diff
changeset
|
2298 |
|
01b72a80639e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13690
diff
changeset
|
2299 |
"Created: / 17-12-2013 / 16:34:04 / cg" |
8226 | 2300 |
! |
2301 |
||
13852 | 2302 |
canChangeLanguageHolder |
2303 |
"return/create the 'canChangeLanguageHolder' value holder (automatically generated)" |
|
2304 |
||
2305 |
canChangeLanguageHolder isNil ifTrue:[ |
|
2306 |
canChangeLanguageHolder := ValueHolder with: true. |
|
2307 |
]. |
|
2308 |
^ canChangeLanguageHolder |
|
2309 |
||
2310 |
"Modified: / 10-05-2012 / 23:43:45 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
2311 |
! |
|
2312 |
||
2313 |
canChangeLanguageHolder:something |
|
2314 |
"set the 'canChangeLanguageHolder' value holder (automatically generated)" |
|
2315 |
||
2316 |
canChangeLanguageHolder := something. |
|
2317 |
! |
|
2318 |
||
9695 | 2319 |
cursorColHolder |
2320 |
cursorColHolder isNil ifTrue:[ |
|
15273
a6606b8ea2f6
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15234
diff
changeset
|
2321 |
cursorColHolder := IndirectValue for:(ValueHolder with:1) |
9695 | 2322 |
]. |
2323 |
^ cursorColHolder |
|
2324 |
||
2325 |
"Created: / 22-01-2011 / 11:36:00 / cg" |
|
2326 |
! |
|
2327 |
||
2328 |
cursorColLabelHolder |
|
2329 |
^ BlockValue |
|
2330 |
with:[:v | v isNil ifTrue:[''] ifFalse:[v printString]] |
|
2331 |
argument:self cursorColHolder. |
|
2332 |
||
2333 |
"Created: / 22-01-2011 / 11:36:08 / cg" |
|
2334 |
! |
|
2335 |
||
15817
f6046130309e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15816
diff
changeset
|
2336 |
cursorLineAndColumnLabelHolder |
f6046130309e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15816
diff
changeset
|
2337 |
cursorLineAndColumnLabelHolder isNil ifTrue:[ |
f6046130309e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15816
diff
changeset
|
2338 |
cursorLineAndColumnLabelHolder := IndirectValue for:(ValueHolder with:1) |
15816
64d953f953a1
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15737
diff
changeset
|
2339 |
]. |
15817
f6046130309e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15816
diff
changeset
|
2340 |
^ cursorLineAndColumnLabelHolder |
15816
64d953f953a1
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15737
diff
changeset
|
2341 |
! |
64d953f953a1
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15737
diff
changeset
|
2342 |
|
9695 | 2343 |
cursorLineHolder |
2344 |
cursorLineHolder isNil ifTrue:[ |
|
15273
a6606b8ea2f6
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15234
diff
changeset
|
2345 |
cursorLineHolder := IndirectValue for:(ValueHolder with:1) |
9695 | 2346 |
]. |
2347 |
^ cursorLineHolder |
|
2348 |
||
2349 |
"Created: / 22-01-2011 / 11:35:22 / cg" |
|
2350 |
! |
|
2351 |
||
2352 |
cursorLineLabelHolder |
|
2353 |
^ BlockValue |
|
2354 |
with:[:v | v isNil ifTrue:[''] ifFalse:[v printString]] |
|
2355 |
argument:self cursorLineHolder. |
|
2356 |
||
2357 |
"Modified: / 22-01-2011 / 11:42:56 / cg" |
|
2358 |
! |
|
2359 |
||
8133
8b09d048b345
doIt button only in smalltalks workspace
Claus Gittinger <cg@exept.de>
parents:
8111
diff
changeset
|
2360 |
doItMenuButtonVisibile |
13728
01b72a80639e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13690
diff
changeset
|
2361 |
"/ typo in previous version |
01b72a80639e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13690
diff
changeset
|
2362 |
^ self doItMenuButtonVisible |
01b72a80639e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13690
diff
changeset
|
2363 |
|
01b72a80639e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13690
diff
changeset
|
2364 |
"Modified: / 17-12-2013 / 16:35:05 / cg" |
01b72a80639e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13690
diff
changeset
|
2365 |
! |
01b72a80639e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13690
diff
changeset
|
2366 |
|
01b72a80639e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13690
diff
changeset
|
2367 |
doItMenuButtonVisible |
8133
8b09d048b345
doIt button only in smalltalks workspace
Claus Gittinger <cg@exept.de>
parents:
8111
diff
changeset
|
2368 |
^ self thisIsASmalltalkWorkspace |
13728
01b72a80639e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13690
diff
changeset
|
2369 |
|
01b72a80639e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13690
diff
changeset
|
2370 |
"Created: / 17-12-2013 / 16:34:10 / cg" |
8133
8b09d048b345
doIt button only in smalltalks workspace
Claus Gittinger <cg@exept.de>
parents:
8111
diff
changeset
|
2371 |
! |
8b09d048b345
doIt button only in smalltalks workspace
Claus Gittinger <cg@exept.de>
parents:
8111
diff
changeset
|
2372 |
|
4136 | 2373 |
hasHistory |
11481
d0a2a73ed69d
added: #selectedWorkspaceIsTextView
Stefan Vogel <sv@exept.de>
parents:
11480
diff
changeset
|
2374 |
^ Workspace doItHistory notEmptyOrNil. |
5852 | 2375 |
! |
2376 |
||
9381 | 2377 |
hasInfoLabel |
2378 |
^ true |
|
2379 |
! |
|
2380 |
||
8133
8b09d048b345
doIt button only in smalltalks workspace
Claus Gittinger <cg@exept.de>
parents:
8111
diff
changeset
|
2381 |
inspectItMenuButtonVisibile |
13728
01b72a80639e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13690
diff
changeset
|
2382 |
"/ typo in previous version |
01b72a80639e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13690
diff
changeset
|
2383 |
^ self inspectItMenuButtonVisible |
01b72a80639e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13690
diff
changeset
|
2384 |
|
01b72a80639e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13690
diff
changeset
|
2385 |
"Modified: / 17-12-2013 / 16:35:17 / cg" |
01b72a80639e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13690
diff
changeset
|
2386 |
! |
01b72a80639e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13690
diff
changeset
|
2387 |
|
01b72a80639e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13690
diff
changeset
|
2388 |
inspectItMenuButtonVisible |
8133
8b09d048b345
doIt button only in smalltalks workspace
Claus Gittinger <cg@exept.de>
parents:
8111
diff
changeset
|
2389 |
^ self thisIsASmalltalkWorkspace |
13728
01b72a80639e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13690
diff
changeset
|
2390 |
|
01b72a80639e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13690
diff
changeset
|
2391 |
"Created: / 17-12-2013 / 16:34:17 / cg" |
8133
8b09d048b345
doIt button only in smalltalks workspace
Claus Gittinger <cg@exept.de>
parents:
8111
diff
changeset
|
2392 |
! |
8b09d048b345
doIt button only in smalltalks workspace
Claus Gittinger <cg@exept.de>
parents:
8111
diff
changeset
|
2393 |
|
9381 | 2394 |
languageInfoLabelHolder |
2395 |
^ BlockValue |
|
11612 | 2396 |
with:[:syntax | |
2397 |
syntax notNil ifTrue:[ |
|
2398 |
"'Syntax: ',"syntax name |
|
2399 |
] ifFalse:[ |
|
11615
f9dfb7daa5e4
corrected switching languages between tabs
Claus Gittinger <cg@exept.de>
parents:
11612
diff
changeset
|
2400 |
'Text' |
11612 | 2401 |
] |
2402 |
] |
|
9381 | 2403 |
argument:self syntaxHolder |
11483
5f545a7d153a
fixed language related valueholder handling
Claus Gittinger <cg@exept.de>
parents:
11481
diff
changeset
|
2404 |
|
11615
f9dfb7daa5e4
corrected switching languages between tabs
Claus Gittinger <cg@exept.de>
parents:
11612
diff
changeset
|
2405 |
"Modified: / 19-07-2012 / 16:53:30 / cg" |
9381 | 2406 |
! |
2407 |
||
9695 | 2408 |
modeLabelHolder |
2409 |
modeLabelHolder isNil ifTrue:[ |
|
15273
a6606b8ea2f6
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15234
diff
changeset
|
2410 |
modeLabelHolder := IndirectValue for:(ValueHolder with:'I') |
9695 | 2411 |
]. |
2412 |
^ modeLabelHolder |
|
2413 |
||
2414 |
"Created: / 22-01-2011 / 11:37:25 / cg" |
|
2415 |
! |
|
2416 |
||
13643
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
2417 |
namespaceHolder |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
2418 |
namespaceHolder isNil ifTrue:[ |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
2419 |
namespaceHolder := self defaultNameSpaceForDoIts asValue. |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
2420 |
namespaceHolder onChangeSend:#setNameSpaceForDoIts to:self |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
2421 |
]. |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
2422 |
^ namespaceHolder |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
2423 |
! |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
2424 |
|
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
2425 |
namespaceInfoLabelHolder |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
2426 |
^ BlockValue |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
2427 |
with:[:ns | |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
2428 |
ns notNil ifTrue:[ |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
2429 |
ns name |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
2430 |
] ifFalse:[ |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
2431 |
'' |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
2432 |
] |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
2433 |
] |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
2434 |
argument:self namespaceHolder |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
2435 |
! |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
2436 |
|
8226 | 2437 |
printItMenuButtonVisibile |
13728
01b72a80639e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13690
diff
changeset
|
2438 |
"/ typo in previous version |
01b72a80639e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13690
diff
changeset
|
2439 |
^ self printItMenuButtonVisible |
01b72a80639e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13690
diff
changeset
|
2440 |
|
01b72a80639e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13690
diff
changeset
|
2441 |
"Modified: / 17-12-2013 / 16:35:11 / cg" |
01b72a80639e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13690
diff
changeset
|
2442 |
! |
01b72a80639e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13690
diff
changeset
|
2443 |
|
01b72a80639e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13690
diff
changeset
|
2444 |
printItMenuButtonVisible |
8226 | 2445 |
^ self thisIsASmalltalkWorkspace |
13728
01b72a80639e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13690
diff
changeset
|
2446 |
|
01b72a80639e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13690
diff
changeset
|
2447 |
"Created: / 17-12-2013 / 16:34:23 / cg" |
8226 | 2448 |
! |
2449 |
||
14060
fef6bc962708
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13949
diff
changeset
|
2450 |
profileItMenuButtonVisible |
fef6bc962708
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13949
diff
changeset
|
2451 |
^ self thisIsASmalltalkWorkspace |
fef6bc962708
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13949
diff
changeset
|
2452 |
|
fef6bc962708
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13949
diff
changeset
|
2453 |
"Created: / 17-12-2013 / 16:34:04 / cg" |
fef6bc962708
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13949
diff
changeset
|
2454 |
! |
fef6bc962708
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13949
diff
changeset
|
2455 |
|
10169 | 2456 |
setWindowLabel: label |
2457 |
||
2458 |
self setWindowLabel: label language: self syntaxHolder value |
|
2459 |
! |
|
2460 |
||
2461 |
setWindowLabel: label language: language |
|
11624 | 2462 |
|languageName| |
2463 |
||
2464 |
language notNil ifTrue:[ |
|
2465 |
languageName := ' - ', language name. |
|
2466 |
] ifFalse:[ |
|
2467 |
languageName := ''. |
|
2468 |
]. |
|
2469 |
self window label:label, ' - ' , languageName |
|
10169 | 2470 |
! |
2471 |
||
9300
07364a10a823
syntax to choose from is fetched via ProgramminLanguage list;
Claus Gittinger <cg@exept.de>
parents:
9166
diff
changeset
|
2472 |
smalltalkMenuEnabledHolder |
07364a10a823
syntax to choose from is fetched via ProgramminLanguage list;
Claus Gittinger <cg@exept.de>
parents:
9166
diff
changeset
|
2473 |
smalltalkMenuEnabledHolder isNil ifTrue:[ |
15273
a6606b8ea2f6
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15234
diff
changeset
|
2474 |
smalltalkMenuEnabledHolder := ValueHolder with:true. |
9300
07364a10a823
syntax to choose from is fetched via ProgramminLanguage list;
Claus Gittinger <cg@exept.de>
parents:
9166
diff
changeset
|
2475 |
]. |
07364a10a823
syntax to choose from is fetched via ProgramminLanguage list;
Claus Gittinger <cg@exept.de>
parents:
9166
diff
changeset
|
2476 |
^ smalltalkMenuEnabledHolder |
5852 | 2477 |
! |
2478 |
||
15046
0441bc4caefc
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14837
diff
changeset
|
2479 |
syntax:aProgrammingLanguageOrNil |
0441bc4caefc
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14837
diff
changeset
|
2480 |
"the argument must sth. like SmalltalkLanguage" |
0441bc4caefc
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14837
diff
changeset
|
2481 |
|
0441bc4caefc
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14837
diff
changeset
|
2482 |
self syntaxHolder value:aProgrammingLanguageOrNil |
0441bc4caefc
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14837
diff
changeset
|
2483 |
! |
0441bc4caefc
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14837
diff
changeset
|
2484 |
|
5852 | 2485 |
syntaxHolder |
2486 |
syntaxHolder isNil ifTrue:[ |
|
9341
aa3c5825ec98
refactored to allow redefinition of defaultSyntax
Claus Gittinger <cg@exept.de>
parents:
9304
diff
changeset
|
2487 |
syntaxHolder := self defaultEvaluatorSyntax asValue. |
5852 | 2488 |
syntaxHolder onChangeSend:#setCompilerForSyntax to:self |
2489 |
]. |
|
2490 |
^ syntaxHolder |
|
10169 | 2491 |
! |
2492 |
||
2493 |
toolBarView |
|
2494 |
||
2495 |
toolBarView isNil ifTrue:[ |
|
2496 |
toolBarView := SubCanvas new. |
|
2497 |
toolBarView level: 0. |
|
2498 |
toolBarView client: self spec: #toolBarSpec builder: builder. |
|
2499 |
]. |
|
2500 |
^toolBarView |
|
2501 |
||
2502 |
"Created: / 10-06-2011 / 22:52:54 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
2503 |
"Modified: / 11-06-2011 / 00:06:21 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
3193 | 2504 |
! ! |
2505 |
||
4358 | 2506 |
!WorkspaceApplication methodsFor:'aspects-queries'! |
3193 | 2507 |
|
3812 | 2508 |
anyWorkspaceVariableIsDefined |
6267 | 2509 |
^ Workspace anyWorkspaceVariableIsDefined |
2510 |
||
2511 |
"Modified: / 20-04-2005 / 11:57:59 / cg" |
|
10169 | 2512 |
! |
2513 |
||
2514 |
canAddBookmark |
|
2515 |
||
16259 | 2516 |
| ws | |
10169 | 2517 |
|
2518 |
ws := self selectedWorkspace scrolledView. |
|
16259 | 2519 |
ws isTextView ifFalse:[^ true]. |
2520 |
||
2521 |
^ ws defaultFileNameForFileDialog notNil. |
|
10169 | 2522 |
|
2523 |
"Created: / 20-06-2011 / 22:43:30 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
2524 |
! |
|
2525 |
||
13852 | 2526 |
isSQLWorkspaceAvailable |
2527 |
||
2528 |
^(Smalltalk at:#'SQL::WorkspacePage') notNil |
|
2529 |
||
2530 |
"Created: / 10-05-2012 / 18:49:34 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
2531 |
! |
|
2532 |
||
2533 |
isSQLWorkspaceSelected |
|
2534 |
||
2535 |
builder isNil ifTrue:[self createBuilder]. |
|
14168
f3b4d93f0481
class: WorkspaceApplication
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14060
diff
changeset
|
2536 |
^ builder bindings at: #isSQLWorkspaceSelected ifAbsentPut: [ |
13852 | 2537 |
BlockValue |
14168
f3b4d93f0481
class: WorkspaceApplication
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14060
diff
changeset
|
2538 |
with:[:ignored| |
f3b4d93f0481
class: WorkspaceApplication
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14060
diff
changeset
|
2539 |
self selectedWorkspaceApplication isKindOf: (Smalltalk at:#'SQL::WorkspacePage') |
f3b4d93f0481
class: WorkspaceApplication
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14060
diff
changeset
|
2540 |
] |
13852 | 2541 |
argument: self selectedWorkspaceIndexHolder |
2542 |
] |
|
2543 |
||
2544 |
"Created: / 11-05-2012 / 09:41:10 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
14168
f3b4d93f0481
class: WorkspaceApplication
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14060
diff
changeset
|
2545 |
"Modified: / 27-03-2014 / 16:38:14 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
13852 | 2546 |
! |
2547 |
||
10169 | 2548 |
isWebBrowserAvailable |
2549 |
||
2550 |
^(Smalltalk at:#WebKitView) notNil |
|
2551 |
||
2552 |
"Created: / 11-06-2011 / 00:30:59 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
11481
d0a2a73ed69d
added: #selectedWorkspaceIsTextView
Stefan Vogel <sv@exept.de>
parents:
11480
diff
changeset
|
2553 |
! |
d0a2a73ed69d
added: #selectedWorkspaceIsTextView
Stefan Vogel <sv@exept.de>
parents:
11480
diff
changeset
|
2554 |
|
d0a2a73ed69d
added: #selectedWorkspaceIsTextView
Stefan Vogel <sv@exept.de>
parents:
11480
diff
changeset
|
2555 |
selectedWorkspaceIsTextView |
d0a2a73ed69d
added: #selectedWorkspaceIsTextView
Stefan Vogel <sv@exept.de>
parents:
11480
diff
changeset
|
2556 |
^ self selectedWorkspacesTextView notNil |
3154 | 2557 |
! ! |
2558 |
||
9632 | 2559 |
!WorkspaceApplication methodsFor:'autofetch selection'! |
2560 |
||
2561 |
autoFetchSelection |
|
18055 | 2562 |
^ [ clipBoardWatcherProcess notNil ] |
9632 | 2563 |
|
2564 |
"Created: / 16-11-2010 / 14:55:39 / cg" |
|
2565 |
! |
|
2566 |
||
2567 |
autoFetchSelection:aBoolean |
|
14746 | 2568 |
Screen current isWindowsPlatform ifTrue:[ |
9632 | 2569 |
aBoolean ifTrue:[ |
2570 |
self startClipboardWatcher |
|
2571 |
] ifFalse:[ |
|
2572 |
self stopClipboardWatcher |
|
2573 |
]. |
|
2574 |
^ self. |
|
2575 |
]. |
|
2576 |
||
2577 |
aBoolean ifTrue:[ |
|
2578 |
self window windowGroup addPreEventHook:self. |
|
2579 |
device addSelectionHandler:self |
|
2580 |
] ifFalse:[ |
|
2581 |
self window windowGroup removePreEventHook:self. |
|
2582 |
device removeSelectionHandler:self |
|
2583 |
]. |
|
2584 |
||
2585 |
"Created: / 16-11-2010 / 14:34:15 / cg" |
|
2586 |
! |
|
2587 |
||
9735 | 2588 |
autoFetchSelectionLines |
2589 |
fetchClipboardLines isNil ifTrue:[ |
|
15273
a6606b8ea2f6
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15234
diff
changeset
|
2590 |
fetchClipboardLines := ValueHolder with:true |
9735 | 2591 |
]. |
2592 |
^ fetchClipboardLines |
|
2593 |
||
2594 |
"Created: / 04-02-2011 / 17:52:34 / cg" |
|
2595 |
! |
|
2596 |
||
9632 | 2597 |
itemFromClipboard |
2598 |
|text| |
|
2599 |
||
2600 |
text := self window getClipboardText. |
|
2601 |
(text notNil and:[text isString]) ifTrue:[ |
|
9735 | 2602 |
self autoFetchSelectionLines value ifTrue:[ |
2603 |
text := text , Character cr |
|
2604 |
]. |
|
9632 | 2605 |
self paste:text. |
2606 |
]. |
|
2607 |
||
2608 |
"Created: / 16-11-2010 / 14:44:26 / cg" |
|
9735 | 2609 |
"Modified: / 04-02-2011 / 17:53:46 / cg" |
9632 | 2610 |
! |
2611 |
||
18055 | 2612 |
selectionClear:foo |
18057 | 2613 |
"/ Transcript showCR:foo. |
18055 | 2614 |
! |
2615 |
||
9632 | 2616 |
startClipboardWatcher |
2617 |
clipBoardWatcherProcess isNil ifTrue:[ |
|
2618 |
ClipBoardFetchingInstance notNil ifTrue:[ |
|
2619 |
ClipBoardFetchingInstance stopClipboardWatcher |
|
2620 |
]. |
|
2621 |
clipBoardWatcherProcess := |
|
2622 |
[ |
|
2623 |
[true] whileTrue:[ |
|
2624 |
self waitForClipBoardToChange. |
|
2625 |
]. |
|
2626 |
] newProcess. |
|
2627 |
||
2628 |
clipBoardWatcherProcess resume. |
|
2629 |
ClipBoardFetchingInstance := self. |
|
2630 |
]. |
|
2631 |
||
2632 |
"Created: / 16-11-2010 / 14:35:55 / cg" |
|
2633 |
! |
|
2634 |
||
2635 |
stopClipboardWatcher |
|
2636 |
|p| |
|
2637 |
||
2638 |
(p := clipBoardWatcherProcess) notNil ifTrue:[ |
|
2639 |
ClipBoardFetchingInstance := nil. |
|
2640 |
clipBoardWatcherProcess := nil. |
|
2641 |
p terminate |
|
2642 |
]. |
|
2643 |
||
2644 |
"Created: / 16-11-2010 / 14:36:12 / cg" |
|
2645 |
! |
|
2646 |
||
2647 |
waitForClipBoardToChange |
|
2648 |
|prev| |
|
2649 |
||
2650 |
prev := self window getClipboardText. |
|
2651 |
[ |
|
2652 |
Delay waitForSeconds:0.2. |
|
2653 |
self window getClipboardText = prev |
|
2654 |
] whileTrue. |
|
2655 |
self itemFromClipboard. |
|
2656 |
||
2657 |
"Created: / 16-11-2010 / 14:44:05 / cg" |
|
2658 |
! ! |
|
2659 |
||
7474
f18ef25a1ca6
refactored to allow for standAlone multiTab editors
Claus Gittinger <cg@exept.de>
parents:
7461
diff
changeset
|
2660 |
!WorkspaceApplication methodsFor:'defaults'! |
f18ef25a1ca6
refactored to allow for standAlone multiTab editors
Claus Gittinger <cg@exept.de>
parents:
7461
diff
changeset
|
2661 |
|
9341
aa3c5825ec98
refactored to allow redefinition of defaultSyntax
Claus Gittinger <cg@exept.de>
parents:
9304
diff
changeset
|
2662 |
defaultEvaluatorSyntax |
9653 | 2663 |
LastLanguage notNil ifTrue:[^ LastLanguage]. |
9341
aa3c5825ec98
refactored to allow redefinition of defaultSyntax
Claus Gittinger <cg@exept.de>
parents:
9304
diff
changeset
|
2664 |
^ SmalltalkLanguage instance. |
9653 | 2665 |
|
2666 |
"Modified: / 01-12-2010 / 12:21:41 / cg" |
|
9341
aa3c5825ec98
refactored to allow redefinition of defaultSyntax
Claus Gittinger <cg@exept.de>
parents:
9304
diff
changeset
|
2667 |
! |
aa3c5825ec98
refactored to allow redefinition of defaultSyntax
Claus Gittinger <cg@exept.de>
parents:
9304
diff
changeset
|
2668 |
|
7474
f18ef25a1ca6
refactored to allow for standAlone multiTab editors
Claus Gittinger <cg@exept.de>
parents:
7461
diff
changeset
|
2669 |
defaultFileNameForLoad |
f18ef25a1ca6
refactored to allow for standAlone multiTab editors
Claus Gittinger <cg@exept.de>
parents:
7461
diff
changeset
|
2670 |
^ 'file.wsp' |
f18ef25a1ca6
refactored to allow for standAlone multiTab editors
Claus Gittinger <cg@exept.de>
parents:
7461
diff
changeset
|
2671 |
|
f18ef25a1ca6
refactored to allow for standAlone multiTab editors
Claus Gittinger <cg@exept.de>
parents:
7461
diff
changeset
|
2672 |
"Created: / 25-10-2006 / 14:56:10 / cg" |
f18ef25a1ca6
refactored to allow for standAlone multiTab editors
Claus Gittinger <cg@exept.de>
parents:
7461
diff
changeset
|
2673 |
! |
f18ef25a1ca6
refactored to allow for standAlone multiTab editors
Claus Gittinger <cg@exept.de>
parents:
7461
diff
changeset
|
2674 |
|
f18ef25a1ca6
refactored to allow for standAlone multiTab editors
Claus Gittinger <cg@exept.de>
parents:
7461
diff
changeset
|
2675 |
defaultFileNameForSave |
8324 | 2676 |
|ws| |
2677 |
||
9695 | 2678 |
ws := self selectedWorkspace scrolledView. |
8324 | 2679 |
ws isTextView ifFalse:[ |
2680 |
"/ eval-ws |
|
2681 |
^ super defaultFileNameForSave |
|
2682 |
]. |
|
2683 |
^ ws defaultFileNameForFileDialog ? super defaultFileNameForSave |
|
9695 | 2684 |
|
2685 |
"Modified: / 22-01-2011 / 12:01:27 / cg" |
|
7474
f18ef25a1ca6
refactored to allow for standAlone multiTab editors
Claus Gittinger <cg@exept.de>
parents:
7461
diff
changeset
|
2686 |
! |
f18ef25a1ca6
refactored to allow for standAlone multiTab editors
Claus Gittinger <cg@exept.de>
parents:
7461
diff
changeset
|
2687 |
|
f18ef25a1ca6
refactored to allow for standAlone multiTab editors
Claus Gittinger <cg@exept.de>
parents:
7461
diff
changeset
|
2688 |
defaultFileNameForSaveAll |
f18ef25a1ca6
refactored to allow for standAlone multiTab editors
Claus Gittinger <cg@exept.de>
parents:
7461
diff
changeset
|
2689 |
^ 'file.wsp' |
f18ef25a1ca6
refactored to allow for standAlone multiTab editors
Claus Gittinger <cg@exept.de>
parents:
7461
diff
changeset
|
2690 |
|
f18ef25a1ca6
refactored to allow for standAlone multiTab editors
Claus Gittinger <cg@exept.de>
parents:
7461
diff
changeset
|
2691 |
"Created: / 25-10-2006 / 14:56:04 / cg" |
f18ef25a1ca6
refactored to allow for standAlone multiTab editors
Claus Gittinger <cg@exept.de>
parents:
7461
diff
changeset
|
2692 |
! |
f18ef25a1ca6
refactored to allow for standAlone multiTab editors
Claus Gittinger <cg@exept.de>
parents:
7461
diff
changeset
|
2693 |
|
13643
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
2694 |
defaultNameSpaceForDoIts |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
2695 |
LastNamespace notNil ifTrue:[^ LastNamespace]. |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
2696 |
^ Smalltalk. |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
2697 |
! |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
2698 |
|
7474
f18ef25a1ca6
refactored to allow for standAlone multiTab editors
Claus Gittinger <cg@exept.de>
parents:
7461
diff
changeset
|
2699 |
defaultPatternLoad |
8032 | 2700 |
^ '*.wsp; *.txt; *.rc' |
7474
f18ef25a1ca6
refactored to allow for standAlone multiTab editors
Claus Gittinger <cg@exept.de>
parents:
7461
diff
changeset
|
2701 |
|
f18ef25a1ca6
refactored to allow for standAlone multiTab editors
Claus Gittinger <cg@exept.de>
parents:
7461
diff
changeset
|
2702 |
"Created: / 25-10-2006 / 14:57:25 / cg" |
7866 | 2703 |
! |
2704 |
||
9341
aa3c5825ec98
refactored to allow redefinition of defaultSyntax
Claus Gittinger <cg@exept.de>
parents:
9304
diff
changeset
|
2705 |
executeMenuVisible |
aa3c5825ec98
refactored to allow redefinition of defaultSyntax
Claus Gittinger <cg@exept.de>
parents:
9304
diff
changeset
|
2706 |
^ self thisIsASmalltalkWorkspace |
aa3c5825ec98
refactored to allow redefinition of defaultSyntax
Claus Gittinger <cg@exept.de>
parents:
9304
diff
changeset
|
2707 |
! |
aa3c5825ec98
refactored to allow redefinition of defaultSyntax
Claus Gittinger <cg@exept.de>
parents:
9304
diff
changeset
|
2708 |
|
7866 | 2709 |
thisIsASmalltalkWorkspace |
9300
07364a10a823
syntax to choose from is fetched via ProgramminLanguage list;
Claus Gittinger <cg@exept.de>
parents:
9166
diff
changeset
|
2710 |
"can be redefined in a subclass to disable smalltalk-specific menu items |
07364a10a823
syntax to choose from is fetched via ProgramminLanguage list;
Claus Gittinger <cg@exept.de>
parents:
9166
diff
changeset
|
2711 |
(expecco uses workspaces as scratchpads)" |
7866 | 2712 |
|
2713 |
^ true |
|
18055 | 2714 |
! |
2715 |
||
2716 |
thisIsASmalltalkWorkspaceAndAutoFetchMenuItemVisible |
|
2717 |
^ self thisIsASmalltalkWorkspace and:[self autoFetchSelectionMenuItemVisible] |
|
7474
f18ef25a1ca6
refactored to allow for standAlone multiTab editors
Claus Gittinger <cg@exept.de>
parents:
7461
diff
changeset
|
2718 |
! ! |
f18ef25a1ca6
refactored to allow for standAlone multiTab editors
Claus Gittinger <cg@exept.de>
parents:
7461
diff
changeset
|
2719 |
|
9372 | 2720 |
!WorkspaceApplication methodsFor:'drag & drop'! |
2721 |
||
2722 |
droppedFile:aFilename in:aComponent |
|
2723 |
"this is a notification from my textView component" |
|
2724 |
||
2725 |
self |
|
2726 |
renameWorkspace:(self selectedWorkspaceIndexHolder value) |
|
2727 |
to:aFilename asFilename baseName |
|
2728 |
! ! |
|
2729 |
||
10169 | 2730 |
!WorkspaceApplication methodsFor:'help'! |
2731 |
||
10220 | 2732 |
updateHelpSpec:aSpec |
2733 |
|file ws| |
|
10169 | 2734 |
|
17881 | 2735 |
"/ dynamically adjust the menuSave item's helpText |
10169 | 2736 |
ws := self selectedWorkspace scrolledView. |
2737 |
ws isTextView ifTrue:[ |
|
2738 |
file := ws defaultFileNameForFileDialog. |
|
2739 |
]. |
|
2740 |
||
10220 | 2741 |
aSpec |
10169 | 2742 |
at:#menuSaveOrSaveAs |
10220 | 2743 |
put:(file isNil ifTrue:[aSpec at:#menuSaveAs] ifFalse:[aSpec at:#menuSave]). |
2744 |
||
10277 | 2745 |
OperatingSystem isMSWINDOWSlike ifTrue:[ |
18553 | 2746 |
aSpec at:#addTerminal put:(aSpec at:#addTerminalWindows). |
10277 | 2747 |
|
2748 |
]. |
|
10220 | 2749 |
^ aSpec |
2750 |
||
2751 |
"Created: / 06-07-2011 / 16:32:13 / cg" |
|
18553 | 2752 |
"Modified (format): / 21-12-2018 / 09:59:08 / Claus Gittinger" |
10169 | 2753 |
! ! |
2754 |
||
19216 | 2755 |
!WorkspaceApplication methodsFor:'help specs'! |
2756 |
||
2757 |
helpSpec |
|
2758 |
"/ dynamically adjust the menuSave item's helpText |
|
2759 |
^ self updateHelpSpec:(super helpSpec) |
|
2760 |
||
2761 |
"Created: / 05-07-2011 / 15:42:25 / cg" |
|
2762 |
! ! |
|
2763 |
||
3154 | 2764 |
!WorkspaceApplication methodsFor:'initialization & release'! |
2765 |
||
2766 |
closeRequest |
|
6636 | 2767 |
"asks for permission before closing" |
2768 |
||
14818
c76a3a590773
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14804
diff
changeset
|
2769 |
(self askIfAnyModified:'Text in %1 was not saved. Close anyway ?' yesButton:'Close') ifFalse:[ |
3154 | 2770 |
^ self |
2771 |
]. |
|
2772 |
||
2773 |
^ super closeRequest |
|
9341
aa3c5825ec98
refactored to allow redefinition of defaultSyntax
Claus Gittinger <cg@exept.de>
parents:
9304
diff
changeset
|
2774 |
! |
aa3c5825ec98
refactored to allow redefinition of defaultSyntax
Claus Gittinger <cg@exept.de>
parents:
9304
diff
changeset
|
2775 |
|
11483
5f545a7d153a
fixed language related valueholder handling
Claus Gittinger <cg@exept.de>
parents:
11481
diff
changeset
|
2776 |
initialSyntax: aLanguage |
5f545a7d153a
fixed language related valueholder handling
Claus Gittinger <cg@exept.de>
parents:
11481
diff
changeset
|
2777 |
self syntaxHolder value: aLanguage. |
5f545a7d153a
fixed language related valueholder handling
Claus Gittinger <cg@exept.de>
parents:
11481
diff
changeset
|
2778 |
|
5f545a7d153a
fixed language related valueholder handling
Claus Gittinger <cg@exept.de>
parents:
11481
diff
changeset
|
2779 |
"Created: / 26-04-2012 / 12:26:48 / cg" |
5f545a7d153a
fixed language related valueholder handling
Claus Gittinger <cg@exept.de>
parents:
11481
diff
changeset
|
2780 |
! |
5f545a7d153a
fixed language related valueholder handling
Claus Gittinger <cg@exept.de>
parents:
11481
diff
changeset
|
2781 |
|
9695 | 2782 |
postBuildEditModeInfoLabel:aLabel |
2783 |
aLabel menuHolder:self; menuMessage:#editModeInfoLabelMenu. |
|
2784 |
||
2785 |
"Created: / 22-01-2011 / 11:32:57 / cg" |
|
2786 |
! |
|
2787 |
||
9341
aa3c5825ec98
refactored to allow redefinition of defaultSyntax
Claus Gittinger <cg@exept.de>
parents:
9304
diff
changeset
|
2788 |
postBuildWith:aBuilder |
aa3c5825ec98
refactored to allow redefinition of defaultSyntax
Claus Gittinger <cg@exept.de>
parents:
9304
diff
changeset
|
2789 |
super postBuildWith:aBuilder. |
9381 | 2790 |
self setCompilerForSyntax. |
2791 |
||
2792 |
self infoVisibilityChanged. "/ force geometry update |
|
2793 |
self autoDefineVariablesChanged. "/ force workspaceView update |
|
9695 | 2794 |
! |
2795 |
||
2796 |
postOpenWith:aBuilder |
|
2797 |
self windowGroup addPreEventHook:self. |
|
2798 |
super postOpenWith:aBuilder. |
|
2799 |
||
2800 |
"Created: / 22-01-2011 / 12:09:20 / cg" |
|
9746
d7c05875edc0
initial language setting fixed
Claus Gittinger <cg@exept.de>
parents:
9745
diff
changeset
|
2801 |
"Modified: / 08-02-2011 / 21:33:49 / cg" |
9695 | 2802 |
! |
2803 |
||
2804 |
processEvent:anEvent |
|
2805 |
"filter double click in line-label. |
|
2806 |
Return true, if I have eaten the event" |
|
2807 |
||
2808 |
anEvent isButtonMultiPressEvent ifTrue:[ |
|
2809 |
anEvent view name = 'CursorLineLabel' ifTrue:[ |
|
2810 |
self selectedWorkspace scrolledView gotoLine. |
|
2811 |
^ true |
|
2812 |
]. |
|
2813 |
]. |
|
2814 |
^ false |
|
2815 |
||
2816 |
"Created: / 22-01-2011 / 12:10:01 / cg" |
|
3154 | 2817 |
! ! |
2818 |
||
4359 | 2819 |
!WorkspaceApplication methodsFor:'menu-actions'! |
3154 | 2820 |
|
3752 | 2821 |
askForFilterBlock:message template:template rememberIn:nameOfClassVar |
2822 |
|filterBlockString filterBlock dialog textHolder classVarValue| |
|
2823 |
||
2824 |
classVarValue := self class classVarAt:nameOfClassVar ifAbsent:nil. |
|
2825 |
classVarValue isNil ifTrue:[ |
|
2826 |
self class classVarAt:nameOfClassVar put:template. |
|
2827 |
classVarValue := template. |
|
2828 |
]. |
|
2829 |
||
2830 |
textHolder := ValueHolder new. |
|
2831 |
dialog := Dialog |
|
2832 |
forRequestText:(resources string:message) |
|
13917
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
2833 |
editViewClass:CodeView |
3752 | 2834 |
lines:25 |
2835 |
columns:70 |
|
2836 |
initialAnswer:classVarValue |
|
2837 |
model:textHolder. |
|
2838 |
dialog addButton:(Button label:'Template' action:[textHolder value:template. textHolder changed:#value.]). |
|
2839 |
dialog open. |
|
2840 |
dialog accepted ifFalse:[^ nil]. |
|
2841 |
||
2842 |
filterBlockString := textHolder value. |
|
2843 |
self class classVarAt:nameOfClassVar put:filterBlockString. |
|
2844 |
||
2845 |
filterBlock := Parser evaluate:filterBlockString. |
|
2846 |
filterBlock isBlock ifFalse:[ |
|
13917
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
2847 |
self error:'bad input for block' mayProceed:true. |
3752 | 2848 |
^ nil |
2849 |
]. |
|
2850 |
||
2851 |
^ filterBlock |
|
2852 |
! |
|
2853 |
||
4474 | 2854 |
autoDefineVariablesChanged |
2855 |
|autoDefine| |
|
2856 |
||
2857 |
autoDefine := autoDefineVariables value. |
|
2858 |
UserPreferences current autoDefineWorkspaceVariables:(autoDefine == #workspace). |
|
2859 |
workspaces do:[:each | |
|
2860 |
each autoDefineVariables:autoDefine |
|
2861 |
]. |
|
2862 |
! |
|
2863 |
||
3198 | 2864 |
basicInspectIt |
2865 |
self inspectIt:true |
|
2866 |
! |
|
2867 |
||
3383
fb3b6909bd1a
+ browseReferencesToIt & browserImplementorsOfIt
Claus Gittinger <cg@exept.de>
parents:
3347
diff
changeset
|
2868 |
browseImplementorsOfIt |
fb3b6909bd1a
+ browseReferencesToIt & browserImplementorsOfIt
Claus Gittinger <cg@exept.de>
parents:
3347
diff
changeset
|
2869 |
self selectedWorkspacesTextView browseImplementorsOfIt |
fb3b6909bd1a
+ browseReferencesToIt & browserImplementorsOfIt
Claus Gittinger <cg@exept.de>
parents:
3347
diff
changeset
|
2870 |
! |
fb3b6909bd1a
+ browseReferencesToIt & browserImplementorsOfIt
Claus Gittinger <cg@exept.de>
parents:
3347
diff
changeset
|
2871 |
|
3154 | 2872 |
browseIt |
11481
d0a2a73ed69d
added: #selectedWorkspaceIsTextView
Stefan Vogel <sv@exept.de>
parents:
11480
diff
changeset
|
2873 |
|ws| |
d0a2a73ed69d
added: #selectedWorkspaceIsTextView
Stefan Vogel <sv@exept.de>
parents:
11480
diff
changeset
|
2874 |
|
d0a2a73ed69d
added: #selectedWorkspaceIsTextView
Stefan Vogel <sv@exept.de>
parents:
11480
diff
changeset
|
2875 |
ws := self selectedWorkspacesTextView. |
d0a2a73ed69d
added: #selectedWorkspaceIsTextView
Stefan Vogel <sv@exept.de>
parents:
11480
diff
changeset
|
2876 |
ws notNil ifTrue:[ |
d0a2a73ed69d
added: #selectedWorkspaceIsTextView
Stefan Vogel <sv@exept.de>
parents:
11480
diff
changeset
|
2877 |
ws browseIt |
d0a2a73ed69d
added: #selectedWorkspaceIsTextView
Stefan Vogel <sv@exept.de>
parents:
11480
diff
changeset
|
2878 |
] |
3154 | 2879 |
! |
2880 |
||
3383
fb3b6909bd1a
+ browseReferencesToIt & browserImplementorsOfIt
Claus Gittinger <cg@exept.de>
parents:
3347
diff
changeset
|
2881 |
browseReferencesToIt |
fb3b6909bd1a
+ browseReferencesToIt & browserImplementorsOfIt
Claus Gittinger <cg@exept.de>
parents:
3347
diff
changeset
|
2882 |
self selectedWorkspacesTextView browseReferencesToIt |
fb3b6909bd1a
+ browseReferencesToIt & browserImplementorsOfIt
Claus Gittinger <cg@exept.de>
parents:
3347
diff
changeset
|
2883 |
! |
fb3b6909bd1a
+ browseReferencesToIt & browserImplementorsOfIt
Claus Gittinger <cg@exept.de>
parents:
3347
diff
changeset
|
2884 |
|
4136 | 2885 |
clearHistory |
2886 |
Workspace clearDoItHistory |
|
2887 |
! |
|
2888 |
||
11496 | 2889 |
compareTextAgainst |
2890 |
|ws otherText thisText| |
|
2891 |
||
2892 |
ws := self selectedWorkspace scrolledView. |
|
2893 |
ws isTextView ifFalse:[ |
|
2894 |
^ self |
|
2895 |
]. |
|
2896 |
||
2897 |
ws hasSelection ifTrue:[ |
|
2898 |
thisText := ws selectionAsString. |
|
2899 |
] ifFalse:[ |
|
2900 |
thisText := ws contents asString. |
|
2901 |
]. |
|
2902 |
||
2903 |
otherText := Dialog requestText:'Paste other text below:'. |
|
2904 |
otherText isEmptyOrNil ifTrue:[^ self ]. |
|
2905 |
||
2906 |
DiffTextView |
|
2907 |
openOn: thisText label: 'Workspace' |
|
2908 |
and: otherText label: 'Other Text' |
|
2909 |
title: 'Comparing Workspace Contents' |
|
2910 |
||
2911 |
"Created: / 04-05-2012 / 15:35:32 / cg" |
|
2912 |
! |
|
2913 |
||
3154 | 2914 |
doIt |
11481
d0a2a73ed69d
added: #selectedWorkspaceIsTextView
Stefan Vogel <sv@exept.de>
parents:
11480
diff
changeset
|
2915 |
|ws| |
d0a2a73ed69d
added: #selectedWorkspaceIsTextView
Stefan Vogel <sv@exept.de>
parents:
11480
diff
changeset
|
2916 |
|
d0a2a73ed69d
added: #selectedWorkspaceIsTextView
Stefan Vogel <sv@exept.de>
parents:
11480
diff
changeset
|
2917 |
ws := self selectedWorkspacesTextView. |
d0a2a73ed69d
added: #selectedWorkspaceIsTextView
Stefan Vogel <sv@exept.de>
parents:
11480
diff
changeset
|
2918 |
ws notNil ifTrue:[ |
d0a2a73ed69d
added: #selectedWorkspaceIsTextView
Stefan Vogel <sv@exept.de>
parents:
11480
diff
changeset
|
2919 |
ws doIt |
d0a2a73ed69d
added: #selectedWorkspaceIsTextView
Stefan Vogel <sv@exept.de>
parents:
11480
diff
changeset
|
2920 |
] |
3154 | 2921 |
! |
2922 |
||
2923 |
inspectIt |
|
3198 | 2924 |
self inspectIt:false |
2925 |
! |
|
2926 |
||
4086
9f685ed7ad3f
autodefine workspace variables
Claus Gittinger <cg@exept.de>
parents:
4031
diff
changeset
|
2927 |
inspectIt:isBasicInspector |
9f685ed7ad3f
autodefine workspace variables
Claus Gittinger <cg@exept.de>
parents:
4031
diff
changeset
|
2928 |
|ws| |
3196 | 2929 |
|
3198 | 2930 |
ws := self selectedWorkspacesTextView. |
11481
d0a2a73ed69d
added: #selectedWorkspaceIsTextView
Stefan Vogel <sv@exept.de>
parents:
11480
diff
changeset
|
2931 |
ws isNil ifTrue:[ |
d0a2a73ed69d
added: #selectedWorkspaceIsTextView
Stefan Vogel <sv@exept.de>
parents:
11480
diff
changeset
|
2932 |
"there is none - i.e. it is a HTMLDocumentView" |
d0a2a73ed69d
added: #selectedWorkspaceIsTextView
Stefan Vogel <sv@exept.de>
parents:
11480
diff
changeset
|
2933 |
^ self. |
d0a2a73ed69d
added: #selectedWorkspaceIsTextView
Stefan Vogel <sv@exept.de>
parents:
11480
diff
changeset
|
2934 |
]. |
3196 | 2935 |
ws |
2936 |
do:(ws selection) |
|
2937 |
withValueDo:[:result | |
|
4096
1c393b3edbcd
Workspace-Variable inspector
Claus Gittinger <cg@exept.de>
parents:
4086
diff
changeset
|
2938 |
self addInspectorOn:result basic:isBasicInspector suppressPseudoSlots:false |
3196 | 2939 |
] |
2940 |
||
2941 |
"/ self selectedWorkspace inspectIt |
|
3154 | 2942 |
! |
2943 |
||
3812 | 2944 |
inspectWorkspaceVariables |
2945 |
|wsvars| |
|
2946 |
||
2947 |
wsvars := Workspace workspaceVariables. |
|
2948 |
wsvars size == 0 ifTrue:[ |
|
2949 |
Dialog information:'No Workspace Variables are defined'. |
|
2950 |
^ self |
|
2951 |
]. |
|
2952 |
wsvars inspect |
|
2953 |
! |
|
2954 |
||
10169 | 2955 |
loadFile:aFileName encoding:encodingSymbolOrNil label:label |
2956 |
||
2957 |
"This small hack allows programmers to have their own |
|
2958 |
MyWorkspace.wsp in their ~/.smalltalk directory" |
|
2959 |
||
2960 |
| f | |
|
2961 |
f := aFileName asFilename. |
|
2962 |
(f exists not and:[f isAbsolute not]) ifTrue:[ |
|
2963 |
f := Filename homeDirectory / '.smalltalk' / f pathName. |
|
2964 |
f exists ifFalse:[ |
|
2965 |
(aFileName = 'MyWorkspace.wsp') |
|
2966 |
ifTrue: |
|
2967 |
[| s| |
|
2968 |
s := f writeStream. |
|
2969 |
[s nextPutAll:'"Edit and save as ', f pathName , '"'] |
|
2970 |
ensure:[s close]] |
|
2971 |
ifFalse: |
|
2972 |
[f := aFileName asFilename] |
|
2973 |
]]. |
|
2974 |
^super loadFile:f pathName encoding:encodingSymbolOrNil label:label |
|
2975 |
||
2976 |
"Created: / 23-12-2009 / 10:13:49 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
2977 |
"Modified: / 11-02-2010 / 10:15:05 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
2978 |
! |
|
2979 |
||
14830
ae72eee69f1c
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14818
diff
changeset
|
2980 |
manageSnippets |
ae72eee69f1c
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14818
diff
changeset
|
2981 |
|bindings listOfSnippets removeAction pasteAction |
7931 | 2982 |
hasSelectionHolder removeEnabledHolder pasteEnabledHolder |
14837
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
2983 |
selectedSnippetHolder selectedSnippetsTextHolder selectedSnippetsKeyHolder |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
2984 |
selectedSnippetsName |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
2985 |
snippetsDictionary defineEnabledHolder defineAction |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
2986 |
snippetTextAcceptHolder snippetTextModifiedHolder |
16260 | 2987 |
loadFileAction saveFileAction| |
13500 | 2988 |
|
14830
ae72eee69f1c
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14818
diff
changeset
|
2989 |
snippetsDictionary := Workspace snippets. |
13500 | 2990 |
snippetsDictionary isEmptyOrNil ifTrue:[ |
2991 |
Dialog information:(resources string:'No Snippets to Manage'). |
|
7944
3d185d0ca8e9
sharedPool inspection support
Claus Gittinger <cg@exept.de>
parents:
7931
diff
changeset
|
2992 |
^ self. |
3d185d0ca8e9
sharedPool inspection support
Claus Gittinger <cg@exept.de>
parents:
7931
diff
changeset
|
2993 |
]. |
3d185d0ca8e9
sharedPool inspection support
Claus Gittinger <cg@exept.de>
parents:
7931
diff
changeset
|
2994 |
|
14830
ae72eee69f1c
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14818
diff
changeset
|
2995 |
listOfSnippets := List withAll:(snippetsDictionary keysSorted). |
15273
a6606b8ea2f6
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15234
diff
changeset
|
2996 |
selectedSnippetsTextHolder := ValueHolder with:''. |
a6606b8ea2f6
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15234
diff
changeset
|
2997 |
selectedSnippetsKeyHolder := ValueHolder with:''. |
13500 | 2998 |
|
2999 |
selectedSnippetHolder := nil asValue. |
|
14837
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3000 |
selectedSnippetHolder |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3001 |
onChangeEvaluate:[ |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3002 |
(selectedSnippetHolder value) isNil ifTrue:[ |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3003 |
selectedSnippetsName := nil. |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3004 |
selectedSnippetsTextHolder value:''. |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3005 |
selectedSnippetsKeyHolder value:nil. |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3006 |
] ifFalse:[ |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3007 |
selectedSnippetsName := listOfSnippets at:(selectedSnippetHolder value). |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3008 |
selectedSnippetsKeyHolder value:selectedSnippetsName. |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3009 |
selectedSnippetsTextHolder value:(snippetsDictionary at:selectedSnippetsName). |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3010 |
]. |
7931 | 3011 |
]. |
3012 |
||
18762 | 3013 |
hasSelectionHolder := BlockValue with:[:m | m notNil] argument:selectedSnippetHolder. |
7931 | 3014 |
removeEnabledHolder := hasSelectionHolder. |
3015 |
pasteEnabledHolder := hasSelectionHolder. |
|
14837
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3016 |
defineEnabledHolder := |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3017 |
BlockValue |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3018 |
with:[:key :text| |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3019 |
key notEmptyOrNil |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3020 |
and:[(snippetsDictionary includesKey:key) not |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3021 |
or:[ (snippetsDictionary at:key) ~= text]] |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3022 |
] |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3023 |
argument: selectedSnippetsKeyHolder argument: selectedSnippetsTextHolder. |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3024 |
|
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3025 |
removeAction := |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3026 |
[ |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3027 |
snippetsDictionary removeKey:selectedSnippetsName. |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3028 |
listOfSnippets remove:selectedSnippetsName. |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3029 |
]. |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3030 |
|
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3031 |
pasteAction := |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3032 |
[ |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3033 |
|text| |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3034 |
text := snippetsDictionary at:selectedSnippetsName. |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3035 |
self paste:text |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3036 |
]. |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3037 |
|
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3038 |
defineAction := |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3039 |
[ |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3040 |
|originalText newText key| |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3041 |
|
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3042 |
key := selectedSnippetsKeyHolder value. |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3043 |
key notEmptyOrNil ifTrue:[ |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3044 |
originalText := snippetsDictionary at:key ifAbsent:nil. "/ selectedSnippetsName. |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3045 |
newText := selectedSnippetsTextHolder value withoutTrailingSeparators. |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3046 |
originalText ~= newText ifTrue:[ |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3047 |
snippetsDictionary at: key put: newText. |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3048 |
snippetTextModifiedHolder value:false. |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3049 |
]. |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3050 |
]. |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3051 |
defineEnabledHolder recomputeValue. |
8286 | 3052 |
]. |
14837
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3053 |
|
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3054 |
loadFileAction := |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3055 |
[ |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3056 |
|file fileSnippets| |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3057 |
|
16260 | 3058 |
file := Dialog requestFileName:'Load Snippet Definition File' default:(LastSnippetFilename ? 'snippets.txt'). |
14837
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3059 |
file notEmptyOrNil ifTrue:[ |
16260 | 3060 |
LastSnippetFilename := file. |
14837
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3061 |
file asFilename readingFileDo:[:s | |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3062 |
fileSnippets := (Object readFrom:s onError:#()) decodeAsLiteralArray. |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3063 |
]. |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3064 |
fileSnippets notEmptyOrNil ifTrue:[ |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3065 |
snippetsDictionary declareAllFrom:fileSnippets. |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3066 |
listOfSnippets contents:(snippetsDictionary keysSorted). |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3067 |
selectedSnippetHolder value:nil. |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3068 |
selectedSnippetsTextHolder value:''. |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3069 |
selectedSnippetsKeyHolder value:''. |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3070 |
] |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3071 |
] |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3072 |
]. |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3073 |
|
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3074 |
saveFileAction := |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3075 |
[ |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3076 |
|file| |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3077 |
|
16260 | 3078 |
file := Dialog requestFileName:'Save Snippet Definition File' default:(LastSnippetFilename ? 'snippets.txt'). |
14837
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3079 |
file notEmptyOrNil ifTrue:[ |
16260 | 3080 |
LastSnippetFilename := file. |
14837
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3081 |
file asFilename writingFileDo:[:s | |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3082 |
s nextPutLine:'#( Dictionary'. |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3083 |
snippetsDictionary keys asSortedCollection do:[:k | |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3084 |
k storeOn:s. |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3085 |
s spaces:2. |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3086 |
(snippetsDictionary at:k) storeOn:s. |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3087 |
s cr. |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3088 |
]. |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3089 |
s nextPutLine:')'. |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3090 |
] |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3091 |
] |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3092 |
]. |
7931 | 3093 |
|
3094 |
bindings := IdentityDictionary new. |
|
14830
ae72eee69f1c
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14818
diff
changeset
|
3095 |
bindings at:#listOfSnippets put:listOfSnippets. |
ae72eee69f1c
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14818
diff
changeset
|
3096 |
bindings at:#selectedSnippet put:selectedSnippetHolder asValue. |
14837
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3097 |
bindings at:#selectedSnippetsKeyHolder put:selectedSnippetsKeyHolder. |
14830
ae72eee69f1c
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14818
diff
changeset
|
3098 |
bindings at:#selectedSnippetsText put:selectedSnippetsTextHolder. |
ae72eee69f1c
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14818
diff
changeset
|
3099 |
bindings at:#removeSelectedSnippet put:removeAction. |
ae72eee69f1c
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14818
diff
changeset
|
3100 |
bindings at:#pasteSelectedSnippet put:pasteAction. |
14837
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3101 |
bindings at:#defineSelectedSnippet put:defineAction. |
7931 | 3102 |
bindings at:#removeEnabled put:removeEnabledHolder. |
8286 | 3103 |
bindings at:#pasteEnabled put:pasteEnabledHolder. |
14837
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3104 |
bindings at:#defineEnabled put:defineEnabledHolder. |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3105 |
bindings at:#menuOpenSnippetFile put:loadFileAction. |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3106 |
bindings at:#menuSaveSnippetFileAs put:saveFileAction. |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3107 |
bindings at:#closeSnippetDialog put:[:a :menu | menu topView closeRequest]. |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3108 |
bindings at:#snippetTextAcceptHolder put:(snippetTextAcceptHolder := TriggerValue new). |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3109 |
bindings at:#snippetTextModified put:(snippetTextModifiedHolder := TriggerValue new). |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3110 |
bindings at:#openSnippetDocumentation put:[self halt. self openHTMLDocument: 'tools/misc/TOP.html#WORKSPACE']. |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3111 |
|
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3112 |
snippetTextModifiedHolder onChangeEvaluate:[snippetTextAcceptHolder value:true. defineEnabledHolder recomputeValue ]. |
d7de71154d37
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14830
diff
changeset
|
3113 |
selectedSnippetsKeyHolder onChangeEvaluate:[defineEnabledHolder recomputeValue ]. |
7931 | 3114 |
|
14830
ae72eee69f1c
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14818
diff
changeset
|
3115 |
self openDialogInterface:#manageSnippetsDialogSpec withBindings:bindings |
18762 | 3116 |
|
3117 |
"Modified: / 17-05-2019 / 15:59:10 / Stefan Vogel" |
|
7931 | 3118 |
! |
3119 |
||
13852 | 3120 |
menuSQLConnect |
3121 |
||
3122 |
self selectedWorkspaceApplication menuConnect |
|
3123 |
||
3124 |
"Created: / 11-05-2012 / 10:00:31 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
3125 |
! |
|
3126 |
||
10169 | 3127 |
menuSave |
10786
2499584c6260
changed: #menuSave (support for CodeView2 accept/cancel bar)
vrany
parents:
10730
diff
changeset
|
3128 |
|ws file| |
10169 | 3129 |
|
3130 |
ws := self selectedWorkspace scrolledView. |
|
3131 |
ws isTextView ifFalse:[ |
|
3132 |
self shouldImplement:'Functionality not yet implemented'. |
|
3133 |
]. |
|
3134 |
file := ws defaultFileNameForFileDialog. |
|
10786
2499584c6260
changed: #menuSave (support for CodeView2 accept/cancel bar)
vrany
parents:
10730
diff
changeset
|
3135 |
file |
2499584c6260
changed: #menuSave (support for CodeView2 accept/cancel bar)
vrany
parents:
10730
diff
changeset
|
3136 |
ifNil:[ |
2499584c6260
changed: #menuSave (support for CodeView2 accept/cancel bar)
vrany
parents:
10730
diff
changeset
|
3137 |
self menuSaveAs. |
2499584c6260
changed: #menuSave (support for CodeView2 accept/cancel bar)
vrany
parents:
10730
diff
changeset
|
3138 |
^ self |
2499584c6260
changed: #menuSave (support for CodeView2 accept/cancel bar)
vrany
parents:
10730
diff
changeset
|
3139 |
]. |
10169 | 3140 |
ws saveAs:file doAppend:false. |
10786
2499584c6260
changed: #menuSave (support for CodeView2 accept/cancel bar)
vrany
parents:
10730
diff
changeset
|
3141 |
ws isCodeView2 ifTrue:[ |
2499584c6260
changed: #menuSave (support for CodeView2 accept/cancel bar)
vrany
parents:
10730
diff
changeset
|
3142 |
ws beUnmodified |
2499584c6260
changed: #menuSave (support for CodeView2 accept/cancel bar)
vrany
parents:
10730
diff
changeset
|
3143 |
] |
10169 | 3144 |
|
3145 |
"Created: / 21-06-2011 / 11:42:22 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
3146 |
"Modified (format): / 05-07-2011 / 15:44:27 / cg" |
|
10786
2499584c6260
changed: #menuSave (support for CodeView2 accept/cancel bar)
vrany
parents:
10730
diff
changeset
|
3147 |
"Modified: / 08-10-2011 / 12:51:53 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
10169 | 3148 |
! |
3149 |
||
7403
73712386ea82
menu: open/add evaluation workspace
Claus Gittinger <cg@exept.de>
parents:
6865
diff
changeset
|
3150 |
newEvaluationWorkspace |
73712386ea82
menu: open/add evaluation workspace
Claus Gittinger <cg@exept.de>
parents:
6865
diff
changeset
|
3151 |
self class openEvaluationWorkspace |
73712386ea82
menu: open/add evaluation workspace
Claus Gittinger <cg@exept.de>
parents:
6865
diff
changeset
|
3152 |
|
73712386ea82
menu: open/add evaluation workspace
Claus Gittinger <cg@exept.de>
parents:
6865
diff
changeset
|
3153 |
"Created: / 13-10-2006 / 12:19:47 / cg" |
73712386ea82
menu: open/add evaluation workspace
Claus Gittinger <cg@exept.de>
parents:
6865
diff
changeset
|
3154 |
! |
73712386ea82
menu: open/add evaluation workspace
Claus Gittinger <cg@exept.de>
parents:
6865
diff
changeset
|
3155 |
|
3334 | 3156 |
newSystemWorkspace |
3157 |
self class openSystemWorkspace |
|
3158 |
! |
|
3159 |
||
3154 | 3160 |
openDocumentation |
3161 |
"opens the documentation file" |
|
19248 | 3162 |
"Called when <F1> is pressed" |
3154 | 3163 |
|
3164 |
self openHTMLDocument: 'tools/misc/TOP.html#WORKSPACE' |
|
3165 |
! |
|
3166 |
||
13581
75759c16ab7f
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13500
diff
changeset
|
3167 |
openEditingDocumentation |
75759c16ab7f
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13500
diff
changeset
|
3168 |
"opens the documentation file" |
75759c16ab7f
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13500
diff
changeset
|
3169 |
|
75759c16ab7f
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13500
diff
changeset
|
3170 |
self openHTMLDocument: 'tools/codeeditor.html' |
75759c16ab7f
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13500
diff
changeset
|
3171 |
! |
75759c16ab7f
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13500
diff
changeset
|
3172 |
|
4267 | 3173 |
pasteAndExecute:aString |
3174 |
self paste:aString. |
|
4136 | 3175 |
self printIt |
3176 |
! |
|
3177 |
||
14830
ae72eee69f1c
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14818
diff
changeset
|
3178 |
pasteSnippet |
13500 | 3179 |
|allSnippets snippetToPaste snippetsDictionary| |
3180 |
||
14830
ae72eee69f1c
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14818
diff
changeset
|
3181 |
snippetsDictionary := Workspace snippets. |
13500 | 3182 |
snippetsDictionary isEmptyOrNil ifTrue:[ |
3183 |
Dialog information:(resources string:'No Snippet to Paste'). |
|
7944
3d185d0ca8e9
sharedPool inspection support
Claus Gittinger <cg@exept.de>
parents:
7931
diff
changeset
|
3184 |
^ self. |
3d185d0ca8e9
sharedPool inspection support
Claus Gittinger <cg@exept.de>
parents:
7931
diff
changeset
|
3185 |
]. |
13500 | 3186 |
allSnippets := snippetsDictionary keysSorted. |
3187 |
||
3188 |
snippetToPaste := Dialog |
|
3189 |
choose:(resources string:'Paste Snippet:') |
|
3190 |
fromList:allSnippets |
|
7931 | 3191 |
lines:10. |
13500 | 3192 |
snippetToPaste isNil ifTrue:[ |
7931 | 3193 |
^ self |
3194 |
]. |
|
13500 | 3195 |
self paste:(snippetsDictionary at:snippetToPaste) withCRs. |
9616 | 3196 |
|
3197 |
"Modified: / 29-10-2010 / 10:21:29 / cg" |
|
7931 | 3198 |
! |
3199 |
||
3154 | 3200 |
printIt |
11481
d0a2a73ed69d
added: #selectedWorkspaceIsTextView
Stefan Vogel <sv@exept.de>
parents:
11480
diff
changeset
|
3201 |
|ws| |
d0a2a73ed69d
added: #selectedWorkspaceIsTextView
Stefan Vogel <sv@exept.de>
parents:
11480
diff
changeset
|
3202 |
|
d0a2a73ed69d
added: #selectedWorkspaceIsTextView
Stefan Vogel <sv@exept.de>
parents:
11480
diff
changeset
|
3203 |
ws := self selectedWorkspacesTextView. |
d0a2a73ed69d
added: #selectedWorkspaceIsTextView
Stefan Vogel <sv@exept.de>
parents:
11480
diff
changeset
|
3204 |
ws notNil ifTrue:[ |
d0a2a73ed69d
added: #selectedWorkspaceIsTextView
Stefan Vogel <sv@exept.de>
parents:
11480
diff
changeset
|
3205 |
ws printIt |
d0a2a73ed69d
added: #selectedWorkspaceIsTextView
Stefan Vogel <sv@exept.de>
parents:
11480
diff
changeset
|
3206 |
] |
3193 | 3207 |
! |
3208 |
||
12028 | 3209 |
profileIt |
3210 |
self selectedWorkspacesTextView profileIt |
|
3211 |
! |
|
3212 |
||
4136 | 3213 |
redoLastDoIt |
4267 | 3214 |
|s| |
4136 | 3215 |
|
4267 | 3216 |
s := self lastDoItsString. |
3217 |
s notNil ifTrue:[ |
|
3218 |
self pasteAndExecute:s |
|
3219 |
] |
|
4136 | 3220 |
! |
3221 |
||
3722 | 3222 |
removeAllWorkspaceVariables |
5846 | 3223 |
(Dialog confirm:(resources string:'Do you really want to remove all Workspace Variables ?')) |
3722 | 3224 |
ifTrue:[ |
3225 |
Workspace removeAllWorkspaceVariables |
|
3226 |
]. |
|
3227 |
! |
|
3228 |
||
4284 | 3229 |
removeGlobalVariable |
3230 |
|name nameKey selection value| |
|
3231 |
||
3232 |
selection := self selectedWorkspacesTextView selection ? ''. |
|
3233 |
||
3234 |
name := Dialog |
|
3235 |
request:'Remove Global Variable:' |
|
3236 |
initialAnswer:(selection asString string) |
|
3237 |
okLabel:'Remove' |
|
3238 |
title:'Remove Global'. |
|
3239 |
||
3240 |
name size == 0 ifTrue:[^ self]. |
|
3241 |
nameKey := name asSymbolIfInterned. |
|
3242 |
nameKey isNil ifTrue:[^ self]. |
|
3243 |
||
3244 |
(Smalltalk includesKey:nameKey) ifFalse:[ |
|
3245 |
self warn:('No such Global Binding: ''%1''.' bindWith:name). |
|
3246 |
^ self. |
|
3247 |
]. |
|
3248 |
||
3249 |
value := Smalltalk at:nameKey. |
|
3250 |
value notNil ifTrue:[ |
|
3251 |
(self confirm:('Global ''%1'' is currently bound to %2\\Remove Binding ?' bindWith:name with:value) withCRs) |
|
3252 |
ifFalse:[ |
|
3253 |
^ self. |
|
3254 |
]. |
|
3255 |
]. |
|
3256 |
Smalltalk at:nameKey put:nil. |
|
3257 |
Smalltalk removeKey:nameKey |
|
3258 |
! |
|
3259 |
||
7931 | 3260 |
removeSharedPool |
3261 |
|poolToRemove| |
|
3262 |
||
3263 |
poolsConsideredInDoIts isEmptyOrNil ifTrue:[ |
|
3264 |
Dialog information:'No pools have been added yet'. |
|
3265 |
^ self. |
|
3266 |
]. |
|
3267 |
||
3268 |
poolToRemove := Dialog |
|
3269 |
choose:'Pool to Remove (No longer known in doIt-Evaluations):' |
|
3270 |
fromList:(poolsConsideredInDoIts asOrderedCollection sort) |
|
3271 |
lines:10. |
|
3272 |
||
3273 |
poolToRemove isNil ifTrue:[ |
|
3274 |
^ self |
|
3275 |
]. |
|
3276 |
poolsConsideredInDoIts remove:poolToRemove. |
|
11481
d0a2a73ed69d
added: #selectedWorkspaceIsTextView
Stefan Vogel <sv@exept.de>
parents:
11480
diff
changeset
|
3277 |
workspaces do:[:eachWs | |
d0a2a73ed69d
added: #selectedWorkspaceIsTextView
Stefan Vogel <sv@exept.de>
parents:
11480
diff
changeset
|
3278 |
|ws| |
d0a2a73ed69d
added: #selectedWorkspaceIsTextView
Stefan Vogel <sv@exept.de>
parents:
11480
diff
changeset
|
3279 |
ws := self workspaceViewOfView:eachWs. |
d0a2a73ed69d
added: #selectedWorkspaceIsTextView
Stefan Vogel <sv@exept.de>
parents:
11480
diff
changeset
|
3280 |
ws notNil ifTrue:[ |
d0a2a73ed69d
added: #selectedWorkspaceIsTextView
Stefan Vogel <sv@exept.de>
parents:
11480
diff
changeset
|
3281 |
ws poolsConsideredInDoIts:poolsConsideredInDoIts. |
d0a2a73ed69d
added: #selectedWorkspaceIsTextView
Stefan Vogel <sv@exept.de>
parents:
11480
diff
changeset
|
3282 |
]. |
7931 | 3283 |
]. |
3284 |
||
3285 |
"Modified: / 24-11-2006 / 12:44:16 / cg" |
|
3286 |
! |
|
3287 |
||
3722 | 3288 |
removeWorkspaceVariable |
6266 | 3289 |
|name selection wsVarNames| |
3812 | 3290 |
|
6266 | 3291 |
wsVarNames := Workspace workspaceVariableNames. |
3292 |
wsVarNames isEmpty ifTrue:[ |
|
3812 | 3293 |
Dialog information:'No Workspace Variables are defined'. |
3294 |
^ self |
|
3295 |
]. |
|
3722 | 3296 |
|
3297 |
selection := self selectedWorkspacesTextView selection ? ''. |
|
3298 |
||
3299 |
name := Dialog |
|
3300 |
request:'Variable to remove:' |
|
3301 |
initialAnswer:(selection asString string) |
|
3302 |
okLabel:'Remove' |
|
3303 |
title:'Enter Variable Name' |
|
6266 | 3304 |
list:(wsVarNames asOrderedCollection sort). |
3305 |
name isEmptyOrNil ifTrue:[ |
|
3722 | 3306 |
^ self |
3307 |
]. |
|
3308 |
Workspace removeWorkspaceVariable:name. |
|
6266 | 3309 |
|
3310 |
"Modified: / 20-04-2005 / 11:56:28 / cg" |
|
3722 | 3311 |
! |
3312 |
||
10169 | 3313 |
renameWorkspace:wsIndex to:newName |
3314 |
|tabList| |
|
3315 |
||
3316 |
tabList := self tabList. |
|
3317 |
tabList notEmpty ifTrue:[ |
|
3318 |
tabList at:wsIndex put:newName. |
|
3319 |
]. |
|
3320 |
wsIndex == self selectedWorkspaceIndexHolder value ifTrue:[ |
|
3321 |
self setWindowLabel: newName. |
|
3322 |
]. |
|
3323 |
! |
|
3324 |
||
9746
d7c05875edc0
initial language setting fixed
Claus Gittinger <cg@exept.de>
parents:
9745
diff
changeset
|
3325 |
setCompilerForSyntax |
11811
41a4ebfe2da2
changed: #setCompilerForSyntax
Claus Gittinger <cg@exept.de>
parents:
11799
diff
changeset
|
3326 |
|selectedWorkspace ws| |
11654
7ac01328f0ef
changed: #setCompilerForSyntax
Claus Gittinger <cg@exept.de>
parents:
11627
diff
changeset
|
3327 |
|
7ac01328f0ef
changed: #setCompilerForSyntax
Claus Gittinger <cg@exept.de>
parents:
11627
diff
changeset
|
3328 |
(selectedWorkspace := self selectedWorkspace) notNil ifTrue:[ |
11811
41a4ebfe2da2
changed: #setCompilerForSyntax
Claus Gittinger <cg@exept.de>
parents:
11799
diff
changeset
|
3329 |
(ws := self workspaceViewOfView:selectedWorkspace) notNil ifTrue:[ |
41a4ebfe2da2
changed: #setCompilerForSyntax
Claus Gittinger <cg@exept.de>
parents:
11799
diff
changeset
|
3330 |
self setCompilerForSyntaxIn:ws. |
41a4ebfe2da2
changed: #setCompilerForSyntax
Claus Gittinger <cg@exept.de>
parents:
11799
diff
changeset
|
3331 |
] |
11654
7ac01328f0ef
changed: #setCompilerForSyntax
Claus Gittinger <cg@exept.de>
parents:
11627
diff
changeset
|
3332 |
]. |
7ac01328f0ef
changed: #setCompilerForSyntax
Claus Gittinger <cg@exept.de>
parents:
11627
diff
changeset
|
3333 |
|
11811
41a4ebfe2da2
changed: #setCompilerForSyntax
Claus Gittinger <cg@exept.de>
parents:
11799
diff
changeset
|
3334 |
"Modified: / 26-09-2012 / 11:55:59 / cg" |
9746
d7c05875edc0
initial language setting fixed
Claus Gittinger <cg@exept.de>
parents:
9745
diff
changeset
|
3335 |
! |
d7c05875edc0
initial language setting fixed
Claus Gittinger <cg@exept.de>
parents:
9745
diff
changeset
|
3336 |
|
d7c05875edc0
initial language setting fixed
Claus Gittinger <cg@exept.de>
parents:
9745
diff
changeset
|
3337 |
setCompilerForSyntaxIn:aWorkspace |
11826 | 3338 |
|compilerClass language| |
9746
d7c05875edc0
initial language setting fixed
Claus Gittinger <cg@exept.de>
parents:
9745
diff
changeset
|
3339 |
|
d7c05875edc0
initial language setting fixed
Claus Gittinger <cg@exept.de>
parents:
9745
diff
changeset
|
3340 |
language := self syntaxHolder value. |
d7c05875edc0
initial language setting fixed
Claus Gittinger <cg@exept.de>
parents:
9745
diff
changeset
|
3341 |
language isSymbol ifTrue:[ |
d7c05875edc0
initial language setting fixed
Claus Gittinger <cg@exept.de>
parents:
9745
diff
changeset
|
3342 |
language := ProgrammingLanguage named:language |
d7c05875edc0
initial language setting fixed
Claus Gittinger <cg@exept.de>
parents:
9745
diff
changeset
|
3343 |
]. |
11612 | 3344 |
language isNil ifTrue:[ |
11826 | 3345 |
compilerClass := nil |
11612 | 3346 |
] ifFalse:[ |
17719 | 3347 |
"/ compilerClass := (language evaluatorClass "self compilerClassForSyntaxName:syntax"). |
17720 | 3348 |
compilerClass := (language compilerClass ? language evaluatorClass "self compilerClassForSyntaxName:syntax"). |
11612 | 3349 |
]. |
11826 | 3350 |
[ |
3351 |
"/ could be a non-text view (VT100Terminal) |
|
3352 |
aWorkspace compilerClass:compilerClass. |
|
13581
75759c16ab7f
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13500
diff
changeset
|
3353 |
aWorkspace editedLanguage:language. |
11826 | 3354 |
] on:MessageNotUnderstood do:[]. |
3355 |
||
11612 | 3356 |
self smalltalkMenuEnabledHolder value:(language notNil and:[language isSmalltalk]). |
9746
d7c05875edc0
initial language setting fixed
Claus Gittinger <cg@exept.de>
parents:
9745
diff
changeset
|
3357 |
|
d7c05875edc0
initial language setting fixed
Claus Gittinger <cg@exept.de>
parents:
9745
diff
changeset
|
3358 |
"Created: / 08-02-2011 / 21:32:39 / cg" |
10602 | 3359 |
"Modified: / 17-08-2011 / 08:47:09 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
17720 | 3360 |
"Modified: / 22-10-2017 / 21:06:53 / cg" |
9746
d7c05875edc0
initial language setting fixed
Claus Gittinger <cg@exept.de>
parents:
9745
diff
changeset
|
3361 |
! |
d7c05875edc0
initial language setting fixed
Claus Gittinger <cg@exept.de>
parents:
9745
diff
changeset
|
3362 |
|
13643
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
3363 |
setNameSpaceForDoIts |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
3364 |
|selectedWorkspace ws| |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
3365 |
|
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
3366 |
(selectedWorkspace := self selectedWorkspace) notNil ifTrue:[ |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
3367 |
(ws := self workspaceViewOfView:selectedWorkspace) notNil ifTrue:[ |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
3368 |
(self compilerClassOf:selectedWorkspace) notNil ifTrue:[ |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
3369 |
ws nameSpaceForDoits:(self namespaceHolder value). |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
3370 |
]. |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
3371 |
] |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
3372 |
]. |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
3373 |
! |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
3374 |
|
3384 | 3375 |
spyOnIt |
3376 |
self selectedWorkspacesTextView spyOnIt |
|
3377 |
! |
|
3378 |
||
10169 | 3379 |
switchToBookmarkEntry: bookmark |
11829
2e8997ff4629
changed: #switchToBookmarkEntry:
Claus Gittinger <cg@exept.de>
parents:
11826
diff
changeset
|
3380 |
| ws file app | |
10169 | 3381 |
|
3382 |
ws := self selectedWorkspace scrolledView. |
|
11725
0b626c2b4b2d
Avoid #isKindOf: where possible
Stefan Vogel <sv@exept.de>
parents:
11713
diff
changeset
|
3383 |
(ws isApplicationSubView) ifTrue:[ |
11829
2e8997ff4629
changed: #switchToBookmarkEntry:
Claus Gittinger <cg@exept.de>
parents:
11826
diff
changeset
|
3384 |
((app := ws application) respondsTo:#switchToBookmarkEntry:) ifTrue:[ |
2e8997ff4629
changed: #switchToBookmarkEntry:
Claus Gittinger <cg@exept.de>
parents:
11826
diff
changeset
|
3385 |
app switchToBookmarkEntry: bookmark |
10730
23c04d952143
much faster startup in openMyWorkspace_new
Claus Gittinger <cg@exept.de>
parents:
10602
diff
changeset
|
3386 |
]. |
23c04d952143
much faster startup in openMyWorkspace_new
Claus Gittinger <cg@exept.de>
parents:
10602
diff
changeset
|
3387 |
^ self. |
10169 | 3388 |
]. |
3389 |
||
3390 |
bookmark isFileBookmark ifTrue:[ |
|
3391 |
file := bookmark path asFilename. |
|
10730
23c04d952143
much faster startup in openMyWorkspace_new
Claus Gittinger <cg@exept.de>
parents:
10602
diff
changeset
|
3392 |
(ws isTextView not or:[ws contents notEmpty]) ifTrue:[ |
10169 | 3393 |
self addWindow: (self createWorkspace) named: file withoutSuffix baseName. |
3394 |
]. |
|
3395 |
file exists ifFalse:[ |
|
18595 | 3396 |
Transcript showCR:'Bookmarked workspace file no longer exists: %1' with:file |
10169 | 3397 |
] ifTrue:[ |
18595 | 3398 |
self loadFile:file. |
10169 | 3399 |
]. |
10730
23c04d952143
much faster startup in openMyWorkspace_new
Claus Gittinger <cg@exept.de>
parents:
10602
diff
changeset
|
3400 |
^ self. |
10169 | 3401 |
]. |
3402 |
||
3403 |
"Created: / 20-06-2011 / 22:45:03 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
3404 |
"Modified: / 21-06-2011 / 08:18:03 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
10730
23c04d952143
much faster startup in openMyWorkspace_new
Claus Gittinger <cg@exept.de>
parents:
10602
diff
changeset
|
3405 |
"Modified: / 28-09-2011 / 07:44:53 / cg" |
18595 | 3406 |
"Modified: / 15-02-2019 / 09:45:01 / Claus Gittinger" |
10169 | 3407 |
! |
3408 |
||
13413
1e726d57eeca
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
12942
diff
changeset
|
3409 |
terminateBackgroundProcesses |
1e726d57eeca
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
12942
diff
changeset
|
3410 |
Processor activeProcess terminateAllSubprocessesInGroup |
1e726d57eeca
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
12942
diff
changeset
|
3411 |
! |
1e726d57eeca
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
12942
diff
changeset
|
3412 |
|
3384 | 3413 |
timeIt |
3414 |
self selectedWorkspacesTextView timeIt |
|
3154 | 3415 |
! ! |
3416 |
||
8763 | 3417 |
!WorkspaceApplication methodsFor:'menu-actions-adding'! |
3418 |
||
10169 | 3419 |
addBookmark |
3420 |
||
3421 |
self menuAddBookmarkTo: self bookmarks root. |
|
3422 |
||
3423 |
"Created: / 20-06-2011 / 22:34:17 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
3424 |
"Modified: / 21-06-2011 / 08:56:19 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
3425 |
! |
|
3426 |
||
8763 | 3427 |
addClassVariableInspector |
3428 |
|v| |
|
3429 |
||
3430 |
ClassVariablesInspectorView isNil ifTrue:[ |
|
3431 |
self error:'Missing class: "ClassVariablesInspectorView"'. |
|
3432 |
^ self. |
|
3433 |
]. |
|
3434 |
v := self addInspectorOn:Smalltalk inspectorClass:ClassVariablesInspectorView suppressPseudoSlots:true. |
|
3435 |
||
3436 |
v fieldListLabel:'Name'. |
|
3437 |
self renameWorkspace:(self selectedWorkspaceIndexHolder value) to:'Class Variables'. |
|
3438 |
||
3439 |
"Modified: / 22-10-2006 / 11:28:14 / cg" |
|
3440 |
! |
|
3441 |
||
3442 |
addEvaluationWorkspace |
|
3443 |
^ self addWindow:(self createEvaluationWorkspace) named:'Eval%1' |
|
3444 |
||
3445 |
"Modified: / 13-10-2006 / 12:16:35 / cg" |
|
3446 |
! |
|
3447 |
||
3448 |
addGlobalVariable |
|
3449 |
|name nameKey selection| |
|
3450 |
||
3451 |
selection := self selectedWorkspacesTextView selection ? ''. |
|
3452 |
||
3453 |
name := Dialog |
|
3454 |
request:'Name of new Global Variable:' |
|
3455 |
initialAnswer:(selection asString string) |
|
3456 |
okLabel:'Add' |
|
3457 |
title:'Enter Variable Name'. |
|
3458 |
name size == 0 ifTrue:[ |
|
3459 |
^ self |
|
3460 |
]. |
|
3461 |
nameKey := name asSymbol. |
|
3462 |
||
3463 |
(Smalltalk includesKey:nameKey) ifTrue:[ |
|
3464 |
self warn:'Global named ''' , name , ''' already exists.'. |
|
3465 |
^ self. |
|
3466 |
]. |
|
3467 |
Smalltalk at:nameKey put:nil. |
|
3468 |
! |
|
3469 |
||
3470 |
addGlobalVariableInspector |
|
3471 |
^ self addNamespaceInspectorFor:Smalltalk |
|
3472 |
||
3473 |
"Modified: / 29-05-2007 / 19:08:58 / cg" |
|
3474 |
! |
|
3475 |
||
3476 |
addInspectorOn:aValue basic:isBasicInspector suppressPseudoSlots:suppressPseudoSlots |
|
3477 |
|inspectorClass| |
|
3478 |
||
3479 |
isBasicInspector ifFalse:[ |
|
12737 | 3480 |
"/ Inspector2 does not work yet!! |
3481 |
"(Tools::Inspector2 notNil and:[UserPreferences current useInspector2])" false ifTrue:[ |
|
3482 |
inspectorClass := Tools::Inspector2. |
|
3483 |
] ifFalse:[ |
|
3484 |
inspectorClass := aValue inspectorClass. |
|
3485 |
]. |
|
8763 | 3486 |
]. |
3487 |
inspectorClass isNil ifTrue:[ |
|
3488 |
inspectorClass := InspectorView |
|
3489 |
]. |
|
3490 |
||
3491 |
^ self |
|
3492 |
addInspectorOn:aValue |
|
3493 |
inspectorClass:inspectorClass |
|
3494 |
suppressPseudoSlots:suppressPseudoSlots |
|
3495 |
! |
|
3496 |
||
3497 |
addInspectorOn:aValue inspectorClass:inspectorClass suppressPseudoSlots:suppressPseudoSlots |
|
3498 |
|view resultString| |
|
3499 |
||
3500 |
view := inspectorClass new. |
|
3501 |
view suppressPseudoSlots:suppressPseudoSlots. |
|
3502 |
view inspect:aValue. |
|
3503 |
"/ v allowFollow:true. |
|
3504 |
aValue isBehavior ifTrue:[ |
|
3505 |
resultString := aValue name |
|
3506 |
] ifFalse:[ |
|
3507 |
resultString := aValue classNameWithArticle |
|
3508 |
]. |
|
3509 |
self addWindow:view named:('Inspecting: ' , resultString). |
|
3510 |
^ view |
|
3511 |
! |
|
3512 |
||
3513 |
addMyWorkspace |
|
16261 | 3514 |
|ws f| |
8763 | 3515 |
|
10169 | 3516 |
self |
16261 | 3517 |
addWindow:(ws := self createWorkspaceView) |
10169 | 3518 |
named:'My Workspace' |
3519 |
asFirst:false. |
|
3520 |
||
3521 |
f := Filename homeDirectory / 'MyWorkspace.wsp'. |
|
3522 |
f exists ifFalse:[ |
|
3523 |
f := Filename homeDirectory / '.smalltalk' / 'MyWorkspace.wsp'. |
|
3524 |
f exists ifFalse:[ |
|
3525 |
f := 'MyWorkspace.wsp' asFilename |
|
3526 |
] |
|
3527 |
]. |
|
3528 |
f exists ifTrue:[ |
|
3529 |
self loadFile:f label:'My Workspace'. |
|
8763 | 3530 |
] ifFalse:[ |
16261 | 3531 |
ws defaultFileNameForFileDialog: f pathName. |
8763 | 3532 |
]. |
3533 |
||
10169 | 3534 |
"Modified: / 21-06-2010 / 08:40:51 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
3535 |
"Modified: / 05-07-2011 / 15:39:08 / cg" |
|
8763 | 3536 |
! |
3537 |
||
3538 |
addNamespaceInspector |
|
3539 |
|ns| |
|
3540 |
||
3541 |
ns := Dialog requestNameSpace:'Namespace' initialAnswer:nil. |
|
3542 |
ns isEmptyOrNil ifTrue:[^ self]. |
|
3543 |
^ self addNamespaceInspectorFor:(Smalltalk at:ns asSymbol) |
|
3544 |
||
3545 |
"Created: / 29-05-2007 / 19:10:50 / cg" |
|
3546 |
! |
|
3547 |
||
3548 |
addNamespaceInspectorFor:aNameSpaceOrSharedPool |
|
3549 |
|v label| |
|
3550 |
||
3551 |
SmalltalkInspectorView isNil ifTrue:[ |
|
3552 |
self error:'Missing class: "SmalltalkInspectorView"'. |
|
3553 |
^ nil. |
|
3554 |
]. |
|
3555 |
||
3556 |
v := self |
|
3557 |
addInspectorOn:aNameSpaceOrSharedPool |
|
3558 |
inspectorClass:SmalltalkInspectorView |
|
3559 |
suppressPseudoSlots:true. |
|
3560 |
||
3561 |
v fieldListLabel:'Name'. |
|
3562 |
aNameSpaceOrSharedPool == Smalltalk ifTrue:[ |
|
3563 |
label := 'Smalltalk (Globals)' |
|
3564 |
] ifFalse:[ |
|
3565 |
aNameSpaceOrSharedPool isSharedPool ifTrue:[ |
|
3566 |
label := aNameSpaceOrSharedPool name,' (SharedPool)' |
|
3567 |
] ifFalse:[ |
|
3568 |
label := aNameSpaceOrSharedPool name,' (Namespace)' |
|
3569 |
]. |
|
3570 |
]. |
|
3571 |
||
3572 |
self |
|
3573 |
renameWorkspace:(self selectedWorkspaceIndexHolder value) |
|
3574 |
to:label. |
|
3575 |
^ v |
|
3576 |
||
3577 |
"Created: / 29-05-2007 / 19:08:45 / cg" |
|
3578 |
! |
|
3579 |
||
13852 | 3580 |
addSQLWorkspace |
3581 |
|page view | |
|
3582 |
||
3583 |
page := (Smalltalk at:#'SQL::WorkspacePage') new. |
|
3584 |
view := ApplicationSubView new. |
|
3585 |
view client:page spec:#windowSpec. |
|
3586 |
self addWindow:view named:'SQL Workspace %1'. |
|
3587 |
||
3588 |
"Created: / 10-05-2012 / 18:48:49 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
3589 |
! |
|
3590 |
||
14830
ae72eee69f1c
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14818
diff
changeset
|
3591 |
addSelectionToSnippets |
13500 | 3592 |
|selection snippetsBaseName snippetsName nr snippetsDictionary| |
8763 | 3593 |
|
3594 |
selection := (self selectedWorkspacesTextView selection ? '') asString. |
|
3595 |
selection isEmpty ifTrue:[ |
|
3596 |
Dialog information:(resources string:'Nothing Selected'). |
|
3597 |
^ self |
|
3598 |
]. |
|
3599 |
||
13500 | 3600 |
snippetsBaseName := Dialog request:(resources string:'Name of Snippet:'). |
3601 |
snippetsBaseName isNil ifTrue:[ |
|
8763 | 3602 |
^ self |
3603 |
]. |
|
13500 | 3604 |
snippetsBaseName isEmpty ifTrue:[ |
3605 |
snippetsBaseName := Time now asString. |
|
8763 | 3606 |
]. |
14830
ae72eee69f1c
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14818
diff
changeset
|
3607 |
snippetsDictionary := Workspace snippets. |
13500 | 3608 |
|
3609 |
snippetsName := snippetsBaseName. |
|
3610 |
(snippetsDictionary includesKey:snippetsName) ifTrue:[ |
|
3611 |
(Dialog confirm:(resources string:'Replace existing snippet named "%1" ?' with:snippetsName)) |
|
8763 | 3612 |
ifFalse:[ |
13500 | 3613 |
[snippetsDictionary includesKey:snippetsName] whileTrue:[ |
8763 | 3614 |
nr := (nr ? 1) + 1. |
13500 | 3615 |
snippetsName := (snippetsBaseName,'(%1)') bindWith:nr |
8763 | 3616 |
]. |
3617 |
] |
|
3618 |
]. |
|
13500 | 3619 |
snippetsDictionary at:snippetsName put:selection |
8763 | 3620 |
|
3621 |
"Modified: / 24-11-2006 / 12:44:16 / cg" |
|
3622 |
! |
|
3623 |
||
3624 |
addSharedPool |
|
3625 |
|allPools poolToAdd| |
|
3626 |
||
3627 |
allPools := SharedPool allSubclasses collect:[:p | p name]. |
|
3628 |
allPools removeAll:(poolsConsideredInDoIts ? #()). |
|
9671 | 3629 |
allPools sort. |
8763 | 3630 |
|
3631 |
poolToAdd := Dialog |
|
3632 |
choose:'Select a SharedPool to Add (To be known in doIt-Evaluations):' |
|
3633 |
fromList:allPools |
|
3634 |
lines:15. |
|
3635 |
poolToAdd isNil ifTrue:[ |
|
3636 |
^ self |
|
3637 |
]. |
|
3638 |
poolsConsideredInDoIts isNil ifTrue:[ |
|
3639 |
poolsConsideredInDoIts := (Set new). |
|
3640 |
]. |
|
3641 |
poolsConsideredInDoIts add:poolToAdd. |
|
11481
d0a2a73ed69d
added: #selectedWorkspaceIsTextView
Stefan Vogel <sv@exept.de>
parents:
11480
diff
changeset
|
3642 |
workspaces do:[:eachWs | |
d0a2a73ed69d
added: #selectedWorkspaceIsTextView
Stefan Vogel <sv@exept.de>
parents:
11480
diff
changeset
|
3643 |
|ws| |
d0a2a73ed69d
added: #selectedWorkspaceIsTextView
Stefan Vogel <sv@exept.de>
parents:
11480
diff
changeset
|
3644 |
ws := self workspaceViewOfView:eachWs. |
d0a2a73ed69d
added: #selectedWorkspaceIsTextView
Stefan Vogel <sv@exept.de>
parents:
11480
diff
changeset
|
3645 |
ws notNil ifTrue:[ |
d0a2a73ed69d
added: #selectedWorkspaceIsTextView
Stefan Vogel <sv@exept.de>
parents:
11480
diff
changeset
|
3646 |
ws poolsConsideredInDoIts:poolsConsideredInDoIts. |
d0a2a73ed69d
added: #selectedWorkspaceIsTextView
Stefan Vogel <sv@exept.de>
parents:
11480
diff
changeset
|
3647 |
]. |
8763 | 3648 |
]. |
3649 |
||
3650 |
"Modified: / 24-11-2006 / 12:44:16 / cg" |
|
3651 |
! |
|
3652 |
||
3653 |
addSharedPoolInspector |
|
3654 |
|pool| |
|
3655 |
||
3656 |
pool := Dialog requestSharedPool:'SharedPool' title:nil initialAnswer:nil. |
|
3657 |
pool isEmptyOrNil ifTrue:[^ self]. |
|
3658 |
^ self addNamespaceInspectorFor:(Smalltalk at:pool asSymbol) |
|
3659 |
||
3660 |
"Created: / 29-05-2007 / 19:10:50 / cg" |
|
3661 |
! |
|
3662 |
||
3663 |
addStopWatch |
|
16485 | 3664 |
|v clockViewClass clock| |
8763 | 3665 |
|
3666 |
v := View new. |
|
3667 |
v viewBackground:Color white. |
|
16485 | 3668 |
"/ avoid making stx:libwidg3 a prerequisite. |
3669 |
Smalltalk loadPackage:#'stx:libwidg3'. "/ ClockView package |
|
3670 |
clockViewClass := Smalltalk at:#ClockView. |
|
3671 |
||
3672 |
clock := clockViewClass in:v. |
|
8763 | 3673 |
clock beStopWatch. |
3674 |
||
3675 |
clock |
|
3676 |
origin:[ |
|
3677 |
|ext| |
|
3678 |
||
3679 |
ext := (v height) min:(v width). |
|
3680 |
(v extent - ext) // 2 |
|
3681 |
] |
|
3682 |
extent:[ |
|
3683 |
|ext| |
|
3684 |
||
3685 |
ext := (v height) min:(v width). |
|
3686 |
ext @ ext |
|
3687 |
]. |
|
3688 |
||
14804
3cd896cf9959
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14747
diff
changeset
|
3689 |
self addWindow:v named:'StopWatch%1' tabIcon:(ToolbarIconLibrary clock13x13Icon). |
8763 | 3690 |
! |
3691 |
||
3692 |
addTeaTimer |
|
10169 | 3693 |
"you think that is a useless gimmick ? |
3694 |
I use it in the office and as a wakeup clock timer" |
|
3695 |
||
9569 | 3696 |
|l dt tEnd dur answer confirmed confirmButton| |
8763 | 3697 |
|
3698 |
dt := LastTeaWaitTime ? (3*60). |
|
3699 |
answer := Dialog |
|
17308 | 3700 |
request:(resources string:'Delta-Time (seconds), Duration (n s/m/h) or End-Time (hh:mm:ss):') |
8763 | 3701 |
initialAnswer:(TimeDuration seconds:dt) printString. |
3702 |
answer isEmptyOrNil ifTrue:[^ self]. |
|
3703 |
||
3704 |
"/ allow 3 formats: |
|
3705 |
"/ hh:mm:ss -> endTime |
|
3706 |
"/ nnn s -> x seconds |
|
3707 |
"/ nnn m -> x minutes |
|
3708 |
"/ nnn h -> x hours |
|
3709 |
"/ nnn -> seconds |
|
3710 |
||
3711 |
tEnd := Time readFromString:answer onError:nil. |
|
3712 |
tEnd isNil ifTrue:[ |
|
3713 |
dur := TimeDuration readFromString:answer onError:nil. |
|
3714 |
dur isNil ifTrue:[ |
|
3715 |
dt := Number readFromString:answer onError:[^ self]. |
|
3716 |
LastTeaWaitTime := dt. |
|
3717 |
tEnd := Timestamp now addSeconds:dt. |
|
3718 |
] ifFalse:[ |
|
3719 |
dt := dur asSeconds. |
|
3720 |
tEnd := Timestamp now + dur. |
|
3721 |
]. |
|
3722 |
] ifFalse:[ |
|
9569 | 3723 |
tEnd < Time now ifTrue:[ |
17308 | 3724 |
(Dialog confirm:(resources string:'Tomorrow ?')) ifFalse:[^ self]. |
9569 | 3725 |
tEnd := tEnd asTimestamp addDays:1. |
3726 |
dt := tEnd - Timestamp now. |
|
3727 |
] ifFalse:[ |
|
3728 |
dt := tEnd - Time now. |
|
3729 |
tEnd := tEnd asTimestamp. |
|
3730 |
]. |
|
8763 | 3731 |
]. |
3732 |
||
3733 |
l := Label new. |
|
3734 |
l sizeFixed:true. |
|
17308 | 3735 |
l label:(resources string:'Waiting... [%1]' with:dt printString). |
8763 | 3736 |
l viewBackground:Color red. |
9569 | 3737 |
confirmButton := (Button label:'OK') action:[ confirmed := true. confirmButton beInvisible. ]. |
3738 |
confirmButton beInvisible. |
|
3739 |
l add:confirmButton. |
|
14804
3cd896cf9959
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14747
diff
changeset
|
3740 |
|
3cd896cf9959
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14747
diff
changeset
|
3741 |
self addWindow:l named:'TeaTimer%1' tabIcon:(ToolbarIconLibrary clock13x13Icon). |
8763 | 3742 |
|
3743 |
[ |
|
10169 | 3744 |
Error handle:[ |
14368 | 3745 |
self error:'check this, please'. |
8763 | 3746 |
#intentionallyLeftBlank |
3747 |
] do:[ |
|
14368 | 3748 |
|remaining wg waitTime| |
3749 |
||
3750 |
waitTime := TimeDuration fromSeconds:1. |
|
9569 | 3751 |
confirmed := false. |
11480 | 3752 |
[Timestamp now < tEnd ] whileTrue:[ |
14368 | 3753 |
remaining := (tEnd - Timestamp now) roundTo:waitTime. |
3754 |
l label:'Waiting... [', remaining printString, ']'. |
|
3755 |
Delay waitFor:waitTime. |
|
8763 | 3756 |
]. |
9569 | 3757 |
|
17307 | 3758 |
(tEnd - Timestamp now) > 10 minutes ifTrue:[ |
17308 | 3759 |
l label:(resources string:'Wake up !!'). |
17307 | 3760 |
] ifFalse:[ |
17308 | 3761 |
l label:(resources string:'TEA is ready !!'). |
17307 | 3762 |
]. |
12735
44e8ea95cd2f
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
12699
diff
changeset
|
3763 |
self window topView raiseDeiconified. |
9632 | 3764 |
"/ could have been removed in the meantime.... |
3765 |
(wg := confirmButton windowGroup) notNil ifTrue:[ |
|
3766 |
confirmButton beVisible. |
|
3767 |
wg repairDamage. |
|
3768 |
||
3769 |
[ confirmed ] whileFalse:[ |
|
12735
44e8ea95cd2f
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
12699
diff
changeset
|
3770 |
self window topView raiseDeiconified. |
9632 | 3771 |
3 timesRepeat:[ l beep. Delay waitForSeconds:0.4 ]. |
3772 |
Delay waitForSeconds:5. |
|
3773 |
]. |
|
3774 |
||
3775 |
l viewBackground:Color green. |
|
9569 | 3776 |
]. |
8763 | 3777 |
] |
3778 |
] fork. |
|
3779 |
||
9632 | 3780 |
"Modified: / 16-11-2010 / 14:54:05 / cg" |
10169 | 3781 |
"Modified (comment): / 05-07-2011 / 14:30:48 / cg" |
3782 |
! |
|
3783 |
||
3784 |
addTerminal |
|
3785 |
| v termView | |
|
3786 |
||
13906
e13d8ad35a46
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13901
diff
changeset
|
3787 |
(OperatingSystem isUNIXlike |
14457
75bcb6c122a7
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14446
diff
changeset
|
3788 |
"/ mhm - xterm embedding seems to no longer work; the default from user prefs is therefore false |
75bcb6c122a7
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14446
diff
changeset
|
3789 |
and:[UserPreferences current useXTermViewIfAvailable |
13906
e13d8ad35a46
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13901
diff
changeset
|
3790 |
and:[XTermView notNil |
e13d8ad35a46
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13901
diff
changeset
|
3791 |
and:[XTermView isAvailable]]]) ifTrue:[ |
10169 | 3792 |
v := termView := XTermView new |
3793 |
] ifFalse:[ |
|
14457
75bcb6c122a7
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14446
diff
changeset
|
3794 |
VT100TerminalView isNil ifTrue:[ |
75bcb6c122a7
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14446
diff
changeset
|
3795 |
Dialog warn:('Missing class: ' , 'VT100TerminalView' allBold). |
75bcb6c122a7
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14446
diff
changeset
|
3796 |
AbortOperationRequest raise |
75bcb6c122a7
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14446
diff
changeset
|
3797 |
]. |
10169 | 3798 |
v := (HVScrollableView for:VT100TerminalView). |
3799 |
termView := v scrolledView. |
|
3800 |
v autoHideScrollBars:false. |
|
3801 |
v horizontalMini:true. |
|
3802 |
"/ the startShell seems to realize the view, which is not allowed. |
|
3803 |
"/ do it later (after adding to myself) |
|
3804 |
"/ termView startShellIn: Filename currentDirectory asString. |
|
3805 |
]. |
|
3806 |
||
14804
3cd896cf9959
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14747
diff
changeset
|
3807 |
self addWindow:v named:'Terminal%1' tabIcon:(ToolbarIconLibrary console13x13Icon). |
10169 | 3808 |
|
3809 |
termView shellTerminateAction:[ termView cr; nextPutLine:'*** shell terminated ***' allBold; cr.]. |
|
3810 |
termView startShellIn: Filename currentDirectory asString. |
|
3811 |
||
3812 |
"Modified: / 09-12-2010 / 23:22:09 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
3813 |
"Modified: / 05-07-2011 / 14:42:39 / cg" |
|
3814 |
! |
|
3815 |
||
3816 |
addWebBrowser |
|
3817 |
|view browser| |
|
3818 |
||
3819 |
browser := Tools::WebBrowserPage new. |
|
3820 |
browser toolBarVisibleHolder value:false. |
|
3821 |
view := ApplicationSubView new. |
|
3822 |
view client:browser spec:#windowSpec. |
|
13852 | 3823 |
self addWindow:view named:'Web Browser %1'. |
10169 | 3824 |
|
3825 |
"Created: / 10-06-2011 / 23:27:52 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
3826 |
"Modified (format): / 05-07-2011 / 14:30:59 / cg" |
|
13852 | 3827 |
"Modified: / 10-05-2012 / 18:49:02 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
8763 | 3828 |
! |
3829 |
||
3830 |
addWorkspaceVariable |
|
3831 |
|name selectedWorkspacesTextView selection| |
|
3832 |
||
3833 |
selectedWorkspacesTextView := self selectedWorkspacesTextView. |
|
3834 |
selectedWorkspacesTextView notNil ifTrue:[ |
|
3835 |
selection := selectedWorkspacesTextView selection. |
|
3836 |
]. |
|
3837 |
||
3838 |
name := Dialog |
|
3839 |
request:'Name of new Workspace Variable:' |
|
3840 |
initialAnswer:(selection ? '') asString string |
|
3841 |
okLabel:'Add' |
|
3842 |
title:'Enter Variable Name'. |
|
3843 |
name size == 0 ifTrue:[ |
|
3844 |
^ self |
|
3845 |
]. |
|
3846 |
Workspace addWorkspaceVariable:name. |
|
3847 |
||
3848 |
"Modified: / 24-11-2006 / 12:44:16 / cg" |
|
3849 |
! |
|
3850 |
||
3851 |
addWorkspaceVariableInspector |
|
3852 |
|v| |
|
3853 |
||
3854 |
v := self addInspectorOn:(Workspace workspaceVariables) basic:false suppressPseudoSlots:true. |
|
3855 |
v dereferenceValueHolders:true. |
|
3856 |
v fieldListLabel:'Name'. |
|
9085 | 3857 |
self renameWorkspace:(self selectedWorkspaceIndexHolder value) to:'Workspace Variables'. |
10169 | 3858 |
! |
3859 |
||
17719 | 3860 |
addWorkspaceWithSameContents |
3861 |
|contents| |
|
3862 |
||
3863 |
contents := self selectedWorkspacesTextView contents. |
|
3864 |
self addWorkspace. |
|
3865 |
self selectedWorkspacesTextView contents:contents. |
|
3866 |
||
3867 |
"Created: / 22-10-2017 / 20:41:26 / cg" |
|
3868 |
! |
|
3869 |
||
10169 | 3870 |
menuAddBookmarkTo: folder |
3871 |
||
3872 |
| ws file | |
|
3873 |
||
3874 |
ws := self selectedWorkspace scrolledView. |
|
3875 |
ws isTextView ifTrue:[ |
|
3876 |
file := ws defaultFileNameForFileDialog. |
|
3877 |
file ifNotNil:[folder add: (Bookmark forFile: file)]. |
|
3878 |
folder model save. |
|
3879 |
] ifFalse:[ |
|
11480 | 3880 |
self shouldImplement |
10169 | 3881 |
] |
3882 |
||
3883 |
"Created: / 21-06-2011 / 08:56:24 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
8763 | 3884 |
! ! |
3885 |
||
4790 | 3886 |
!WorkspaceApplication methodsFor:'menu-actions-editing'! |
3887 |
||
3888 |
babelFishTranslate:fromToModeString |
|
17054 | 3889 |
"translate the selected text and paste it after the selection. |
3890 |
This is now obsolete, as that web service no longer exists (sigh)" |
|
4790 | 3891 |
|
9653 | 3892 |
SOAP::BabelFishClient isNil ifTrue:[ |
3893 |
Dialog information:'Sorry the SOAP-BabelFish translation-client is not available'. |
|
3894 |
^ self. |
|
3895 |
]. |
|
4790 | 3896 |
self selectedWorkspace babelFishTranslate:fromToModeString |
9653 | 3897 |
|
3898 |
"Modified: / 01-12-2010 / 12:24:34 / cg" |
|
4790 | 3899 |
! |
3900 |
||
7831 | 3901 |
changesBrowserOnText |
11713
3073bed82974
changed: #changesBrowserOnText
Claus Gittinger <cg@exept.de>
parents:
11654
diff
changeset
|
3902 |
(UserPreferences current changeSetBrowserClass) |
7831 | 3903 |
openOn:(ChangeSet fromStream:self selectedWorkspacesTextView contentsAsString readStream) |
3904 |
||
3905 |
"Created: / 27-08-2007 / 10:57:30 / cg" |
|
3906 |
! |
|
3907 |
||
10169 | 3908 |
editBookmarks |
3909 |
||
3910 |
BookmarkListEditor new |
|
3911 |
bookmarkList: self bookmarks; |
|
3912 |
open. |
|
3913 |
||
3914 |
"Created: / 20-06-2011 / 22:34:07 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
3915 |
! |
|
3916 |
||
9695 | 3917 |
editModeInsert |
3918 |
self selectedWorkspace editModeInsert |
|
3919 |
||
3920 |
"Created: / 22-01-2011 / 11:51:12 / cg" |
|
3921 |
! |
|
3922 |
||
3923 |
editModeInsertAndSelect |
|
3924 |
self selectedWorkspace editModeInsertAndSelect |
|
3925 |
||
3926 |
"Created: / 22-01-2011 / 11:52:52 / cg" |
|
3927 |
! |
|
3928 |
||
3929 |
editModeOverwrite |
|
3930 |
self selectedWorkspace editModeOverwrite |
|
3931 |
||
3932 |
"Created: / 22-01-2011 / 11:52:15 / cg" |
|
3933 |
! |
|
3934 |
||
5261 | 3935 |
fileInText |
13917
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
3936 |
"filein the selected workspace's contents as if read from a file" |
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
3937 |
|
5261 | 3938 |
self selectedWorkspacesTextView contentsAsString readStream fileIn |
3939 |
! |
|
3940 |
||
4790 | 3941 |
filterText |
13917
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
3942 |
"a filterblock is asked for, which is applied to the |
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
3943 |
selected line range. |
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
3944 |
Each line for which the filter evaluats to false is removed" |
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
3945 |
|
11496 | 3946 |
|template filterBlock newList oldList answer nDeleted deletedLines |
3947 |
prevLine nextLine line| |
|
4790 | 3948 |
|
17054 | 3949 |
template := self class filterTemplate. |
4790 | 3950 |
|
11496 | 3951 |
filterBlock := self askForFilterBlock:'Filter block (to remove lines):' |
4790 | 3952 |
template:template |
3953 |
rememberIn:#LastFilterBlockString. |
|
3954 |
filterBlock isNil ifTrue:[^ self]. |
|
3955 |
||
3956 |
oldList := self selectedWorkspacesTextView list. |
|
11496 | 3957 |
newList := StringCollection new. |
3958 |
deletedLines := OrderedCollection new. |
|
3959 |
||
3960 |
oldList notEmptyOrNil ifTrue:[ |
|
3961 |
line := nil. |
|
3962 |
nextLine := oldList at: 1. |
|
3963 |
1 to: oldList size do:[:lineNr | |
|
3964 |
prevLine := line. |
|
3965 |
line := nextLine. |
|
3966 |
nextLine := oldList at: lineNr + 1 ifAbsent: nil. |
|
3967 |
||
3968 |
(filterBlock |
|
3969 |
value:(line ? '') |
|
3970 |
value: lineNr |
|
3971 |
value: (prevLine ? '') |
|
3972 |
value: (nextLine ? '') |
|
3973 |
) ifTrue: [ |
|
3974 |
newList add: line |
|
3975 |
] ifFalse:[ |
|
3976 |
deletedLines add: line. |
|
3977 |
] |
|
3978 |
]. |
|
3979 |
||
3980 |
newList := newList collect:[:line | (line isString and:[line size == 0]) ifTrue:[nil] ifFalse:[line]]. |
|
3981 |
]. |
|
3982 |
||
3983 |
nDeleted := deletedLines size. |
|
4790 | 3984 |
nDeleted == 0 ifTrue:[ |
3985 |
self information:'No lines were deleted.'. |
|
3986 |
^ self |
|
3987 |
]. |
|
3988 |
||
11496 | 3989 |
answer := OptionBox |
3990 |
request:(resources |
|
4790 | 3991 |
string:'%1 lines remain (%2 deleted). Change text ?' |
3992 |
with:newList size |
|
3993 |
with:nDeleted) |
|
11496 | 3994 |
buttonLabels:#( 'Cancel' 'No, Show Deleted' 'Yes, but Show Deleted' 'Yes') |
3995 |
values:#(nil false yesAndShow true) |
|
3996 |
default:true. |
|
4790 | 3997 |
answer isNil ifTrue:[^ self]. |
11496 | 3998 |
(answer ~~ true) ifTrue:[ |
4790 | 3999 |
TextBox openOn:(deletedLines asStringCollection) title:'Filtered lines'. |
11496 | 4000 |
(answer == false) ifTrue:[ |
4001 |
^ self. |
|
4002 |
]. |
|
4790 | 4003 |
]. |
4004 |
||
4005 |
self selectedWorkspacesTextView list:newList. |
|
11496 | 4006 |
|
4007 |
"Modified: / 04-05-2012 / 16:03:32 / cg" |
|
4790 | 4008 |
! |
4009 |
||
13917
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
4010 |
generateText |
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
4011 |
"a generatorblock is asked for, which is evaluated to generate |
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
4012 |
lines onto an output stream. |
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
4013 |
The generated text is inserted (or replaces the current selection)" |
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
4014 |
|
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
4015 |
|template generatorBlock oldText outStream| |
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
4016 |
|
17054 | 4017 |
template := self class generatorTemplate. |
13917
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
4018 |
|
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
4019 |
generatorBlock := self askForFilterBlock:'Generator block (to insert text):' |
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
4020 |
template:template |
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
4021 |
rememberIn:#LastGeneratorBlockString. |
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
4022 |
generatorBlock isNil ifTrue:[^ self]. |
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
4023 |
|
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
4024 |
oldText := self selectedWorkspacesTextView selection. |
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
4025 |
outStream := '' writeStream. |
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
4026 |
generatorBlock |
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
4027 |
value:outStream |
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
4028 |
value:oldText. |
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
4029 |
|
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
4030 |
self selectedWorkspacesTextView pasteOrReplace:(outStream contents). |
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
4031 |
! |
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
4032 |
|
4790 | 4033 |
googleSpellingSuggestion |
4034 |
self selectedWorkspacesTextView googleSpellingSuggestion |
|
4035 |
! |
|
4036 |
||
8499 | 4037 |
indent |
9810 | 4038 |
self selectedWorkspacesTextView indentBy4. |
8499 | 4039 |
! |
4040 |
||
4790 | 4041 |
pasteLastDoIt |
4042 |
|s| |
|
4043 |
||
4044 |
s := self lastDoItsString. |
|
4045 |
s notNil ifTrue:[ |
|
4046 |
self paste:s |
|
4047 |
] |
|
8499 | 4048 |
! |
4049 |
||
13917
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
4050 |
processText |
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
4051 |
"a block is asked for, which is applied to each line of the selected line range. |
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
4052 |
Each line is replaced by the corresponding output of the processing block" |
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
4053 |
|
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
4054 |
|template filterBlock newList oldList answer nChanged changedLines flags| |
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
4055 |
|
17054 | 4056 |
template := self class textProcessorTemplate. |
4057 |
||
13917
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
4058 |
filterBlock := self askForFilterBlock:'Processing block:' |
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
4059 |
template:template |
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
4060 |
rememberIn:#LastProcessingBlockString. |
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
4061 |
filterBlock isNil ifTrue:[^ self]. |
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
4062 |
|
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
4063 |
oldList := self selectedWorkspacesTextView list. |
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
4064 |
oldList := oldList collect:[:lineOrNil | lineOrNil ? '']. |
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
4065 |
newList := oldList collect:[:line | |newLine| |
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
4066 |
newLine := line. |
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
4067 |
Error handle:[:ex | |
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
4068 |
] do:[ |
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
4069 |
newLine := filterBlock value:line |
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
4070 |
]. |
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
4071 |
newLine |
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
4072 |
]. |
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
4073 |
newList := newList collect:[:line | (line isString and:[line size == 0]) ifTrue:[nil] ifFalse:[line]]. |
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
4074 |
|
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
4075 |
flags := (1 to:oldList size) collect:[:i | (oldList at:i) ~= (newList at:i)]. |
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
4076 |
flags := flags select:[:flag | flag]. |
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
4077 |
nChanged := flags size. |
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
4078 |
nChanged == 0 ifTrue:[ |
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
4079 |
self information:'No lines were changed.'. |
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
4080 |
^ self |
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
4081 |
]. |
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
4082 |
|
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
4083 |
answer := Dialog confirmWithCancel:(resources |
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
4084 |
string:'%1 lines changed. Change text ?' |
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
4085 |
with:nChanged) |
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
4086 |
labels:#( 'Cancel' 'No, Show Changed' 'Yes'). |
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
4087 |
answer isNil ifTrue:[^ self]. |
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
4088 |
answer ifFalse:[ |
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
4089 |
changedLines := (1 to:oldList size) select:[:i | (oldList at:i) ~= (newList at:i)]. |
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
4090 |
changedLines := changedLines collect:[:i | (newList at:i)]. |
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
4091 |
TextBox openOn:(changedLines asStringCollection) title:'Changed lines'. |
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
4092 |
^ self. |
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
4093 |
]. |
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
4094 |
|
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
4095 |
self selectedWorkspacesTextView list:newList. |
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
4096 |
! |
2e1f7f77627e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13914
diff
changeset
|
4097 |
|
8499 | 4098 |
undent |
9810 | 4099 |
self selectedWorkspacesTextView undentBy4. |
4790 | 4100 |
! ! |
4101 |
||
4136 | 4102 |
!WorkspaceApplication methodsFor:'menu-dynamic'! |
4103 |
||
10169 | 4104 |
bookmarkMenu |
14635
bed940a94253
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14594
diff
changeset
|
4105 |
<resource: #programMenu > |
bed940a94253
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14594
diff
changeset
|
4106 |
|
10169 | 4107 |
| menu item | |
10283 | 4108 |
|
18898 | 4109 |
menu := self bookmarks asMenuUsingBuilder: (BookmarkMenuBuilder new). |
10169 | 4110 |
menu hasItems ifTrue:[menu addSeparator]. |
4111 |
||
13432
1f561d84a826
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13413
diff
changeset
|
4112 |
item := MenuItem |
1f561d84a826
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13413
diff
changeset
|
4113 |
label:(resources string:'Add Bookmark') |
1f561d84a826
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13413
diff
changeset
|
4114 |
itemValue:#addBookmark |
1f561d84a826
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13413
diff
changeset
|
4115 |
enabled:[self canAddBookmark]. |
10169 | 4116 |
menu addItem: item. |
4117 |
||
4118 |
menu addSeparator. |
|
4119 |
||
13432
1f561d84a826
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13413
diff
changeset
|
4120 |
item := MenuItem |
1f561d84a826
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13413
diff
changeset
|
4121 |
label:(resources string:'Edit Bookmarks') |
1f561d84a826
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13413
diff
changeset
|
4122 |
itemValue:#editBookmarks. |
10169 | 4123 |
menu addItem: item. |
4124 |
^menu |
|
4125 |
||
4126 |
"Created: / 20-06-2011 / 22:21:14 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
4127 |
"Modified: / 21-06-2011 / 08:05:56 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
11787 | 4128 |
"Modified: / 09-09-2012 / 13:25:48 / cg" |
18898 | 4129 |
"Modified: / 13-07-2019 / 16:01:43 / Claus Gittinger" |
10169 | 4130 |
! |
4131 |
||
9695 | 4132 |
editModeInfoLabelMenu |
4133 |
^ self class editModeInfoLabelMenu |
|
4134 |
||
4135 |
"Created: / 22-01-2011 / 11:50:35 / cg" |
|
4136 |
! |
|
4137 |
||
9300
07364a10a823
syntax to choose from is fetched via ProgramminLanguage list;
Claus Gittinger <cg@exept.de>
parents:
9166
diff
changeset
|
4138 |
languageListMenuSlice |
17319 | 4139 |
"dynamically generate a slice containing the available |
16057 | 4140 |
programming languages" |
17319 | 4141 |
|
14635
bed940a94253
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14594
diff
changeset
|
4142 |
<resource: #programMenu > |
bed940a94253
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14594
diff
changeset
|
4143 |
|
13852 | 4144 |
|m allLanguages | |
4145 |
||
18852 | 4146 |
allLanguages := ProgrammingLanguage allSortedByNameExcept:#isSmalltalk. |
9300
07364a10a823
syntax to choose from is fetched via ProgramminLanguage list;
Claus Gittinger <cg@exept.de>
parents:
9166
diff
changeset
|
4147 |
|
07364a10a823
syntax to choose from is fetched via ProgramminLanguage list;
Claus Gittinger <cg@exept.de>
parents:
9166
diff
changeset
|
4148 |
m := Menu new. |
17319 | 4149 |
m addItem:((MenuItem |
13914
052e6eae550d
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13906
diff
changeset
|
4150 |
label:'Text' |
052e6eae550d
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13906
diff
changeset
|
4151 |
choice: #syntaxHolder |
14635
bed940a94253
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14594
diff
changeset
|
4152 |
choiceValue:nil) |
13914
052e6eae550d
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13906
diff
changeset
|
4153 |
itemValue:#syntaxChangedByUser). |
13852 | 4154 |
m addItem:((MenuItem |
11483
5f545a7d153a
fixed language related valueholder handling
Claus Gittinger <cg@exept.de>
parents:
11481
diff
changeset
|
4155 |
label:'Smalltalk' |
13852 | 4156 |
choice:#syntaxHolder |
4157 |
choiceValue:SmalltalkLanguage instance) |
|
14635
bed940a94253
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14594
diff
changeset
|
4158 |
translateLabel:false; |
13852 | 4159 |
enabled: self canChangeLanguageHolder). |
9341
aa3c5825ec98
refactored to allow redefinition of defaultSyntax
Claus Gittinger <cg@exept.de>
parents:
9304
diff
changeset
|
4160 |
|
11235
9a0429235c45
changed: #languageListMenuSlice
Claus Gittinger <cg@exept.de>
parents:
10786
diff
changeset
|
4161 |
"/ allLanguages notEmpty ifTrue:[ |
9a0429235c45
changed: #languageListMenuSlice
Claus Gittinger <cg@exept.de>
parents:
10786
diff
changeset
|
4162 |
"/ m addItem:(MenuItem separator). |
9300
07364a10a823
syntax to choose from is fetched via ProgramminLanguage list;
Claus Gittinger <cg@exept.de>
parents:
9166
diff
changeset
|
4163 |
|
9304
6d9d835a55bf
changed: #languageListMenuSlice
Claus Gittinger <cg@exept.de>
parents:
9301
diff
changeset
|
4164 |
allLanguages do:[:eachLanguage | |
13852 | 4165 |
"JV@2012-02-18: Add language only iff it supports |
4166 |
evaluation (most of then do, but some may not - |
|
4167 |
such as Java)" |
|
17319 | 4168 |
(eachLanguage isJava not |
13852 | 4169 |
"/ Java is funny - we don't have an evaluator for Java |
4170 |
"/ but we have to define evaluatorClass to return GroovyEvaluator |
|
4171 |
"/ to be able to inspect code in debugger/inspector. Hence this hack. |
|
4172 |
"/ We may need something like evaluatorClassForInspector/Debugger. |
|
4173 |
and:[eachLanguage evaluatorClass notNil |
|
16057 | 4174 |
and:[true "eachLanguage evaluatorClass canUnderstand: #evaluate:in:receiver:notifying:logged:ifFail:"] |
17319 | 4175 |
]) |
14635
bed940a94253
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14594
diff
changeset
|
4176 |
ifTrue:[ |
13852 | 4177 |
m addItem:((MenuItem |
4178 |
label:(eachLanguage name) |
|
4179 |
choice:#syntaxHolder |
|
4180 |
choiceValue:eachLanguage) |
|
14635
bed940a94253
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14594
diff
changeset
|
4181 |
translateLabel:false; |
13852 | 4182 |
enabled: self canChangeLanguageHolder). |
4183 |
]. |
|
9304
6d9d835a55bf
changed: #languageListMenuSlice
Claus Gittinger <cg@exept.de>
parents:
9301
diff
changeset
|
4184 |
]. |
11235
9a0429235c45
changed: #languageListMenuSlice
Claus Gittinger <cg@exept.de>
parents:
10786
diff
changeset
|
4185 |
"/ ]. |
9300
07364a10a823
syntax to choose from is fetched via ProgramminLanguage list;
Claus Gittinger <cg@exept.de>
parents:
9166
diff
changeset
|
4186 |
^ m |
11235
9a0429235c45
changed: #languageListMenuSlice
Claus Gittinger <cg@exept.de>
parents:
10786
diff
changeset
|
4187 |
|
13852 | 4188 |
"Modified: / 04-02-2012 / 11:52:07 / cg" |
4189 |
"Modified: / 29-08-2013 / 12:18:28 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
18852 | 4190 |
"Modified: / 27-06-2019 / 12:36:39 / Claus Gittinger" |
9300
07364a10a823
syntax to choose from is fetched via ProgramminLanguage list;
Claus Gittinger <cg@exept.de>
parents:
9166
diff
changeset
|
4191 |
! |
07364a10a823
syntax to choose from is fetched via ProgramminLanguage list;
Claus Gittinger <cg@exept.de>
parents:
9166
diff
changeset
|
4192 |
|
8350 | 4193 |
makeRecentDoItsMenuFor:aSelector |
14635
bed940a94253
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14594
diff
changeset
|
4194 |
<resource: #programMenu > |
bed940a94253
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14594
diff
changeset
|
4195 |
|
8350 | 4196 |
|doIts m cmdLabelLen| |
4197 |
||
4198 |
cmdLabelLen := 40. |
|
4199 |
||
4200 |
doIts := Workspace doItHistory. |
|
4201 |
doIts size > 0 ifTrue:[ |
|
4202 |
m := Menu new. |
|
4203 |
doIts do:[:doItEntry | |
|
4204 |
|lines label item| |
|
4205 |
||
4206 |
lines := doItEntry withoutLeadingSeparators asStringCollection. |
|
4207 |
label := lines first. |
|
4208 |
(label size > cmdLabelLen) ifTrue:[ |
|
4209 |
label := (label contractTo:cmdLabelLen) |
|
4210 |
]. |
|
4211 |
(lines size > 1) ifTrue:[ |
|
4212 |
label := label , ' [...]' |
|
4213 |
]. |
|
4214 |
label := '''' , label , ''''. |
|
4215 |
||
14594
5c29d5fd8235
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14457
diff
changeset
|
4216 |
item := MenuItem label:label itemValue:aSelector argument:doItEntry. |
8350 | 4217 |
m addItem:item. |
4218 |
]. |
|
11787 | 4219 |
m addSeparator. |
8350 | 4220 |
m addItem: (MenuItem new |
14594
5c29d5fd8235
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14457
diff
changeset
|
4221 |
label: (resources string:'Clear History') |
5c29d5fd8235
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14457
diff
changeset
|
4222 |
itemValue: #clearHistory |
5c29d5fd8235
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14457
diff
changeset
|
4223 |
translateLabel:false; |
5c29d5fd8235
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14457
diff
changeset
|
4224 |
activeHelpKey: #historyEmptyMenu ). |
8350 | 4225 |
]. |
4226 |
^ m |
|
11787 | 4227 |
|
4228 |
"Modified: / 09-09-2012 / 13:25:30 / cg" |
|
8350 | 4229 |
! |
4230 |
||
13643
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
4231 |
namespaceInfoLabelMenu |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
4232 |
|m allNamespaces| |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
4233 |
|
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
4234 |
allNamespaces := NameSpace allNameSpaces asNewOrderedCollection. |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
4235 |
allNamespaces sort:[:a :b | a name < b name]. |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
4236 |
allNamespaces remove:Smalltalk. |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
4237 |
allNamespaces addFirst:Smalltalk. |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
4238 |
|
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
4239 |
m := Menu new. |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
4240 |
|
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
4241 |
allNamespaces do:[:eachNameSpace | |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
4242 |
m addItem:((MenuItem |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
4243 |
label:(eachNameSpace name) |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
4244 |
choice: #namespaceHolder |
14635
bed940a94253
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14594
diff
changeset
|
4245 |
choiceValue:eachNameSpace) |
bed940a94253
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14594
diff
changeset
|
4246 |
translateLabel:false; |
13643
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
4247 |
itemValue:#namespaceChangedByUser). |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
4248 |
eachNameSpace == Smalltalk ifTrue:[ |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
4249 |
m addSeparator |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
4250 |
]. |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
4251 |
]. |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
4252 |
^ m |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
4253 |
! |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
4254 |
|
14635
bed940a94253
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14594
diff
changeset
|
4255 |
namespaceInfoLabelMenuHolder |
bed940a94253
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14594
diff
changeset
|
4256 |
^ [self namespaceInfoLabelMenu] |
bed940a94253
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14594
diff
changeset
|
4257 |
! |
bed940a94253
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14594
diff
changeset
|
4258 |
|
4267 | 4259 |
pasteRecentDoItMenu |
4260 |
<resource: #programMenu > |
|
4261 |
||
4262 |
^ self recentDoItsMenuFor:#'paste:' |
|
4263 |
! |
|
4264 |
||
4265 |
recentDoItsMenuFor:aSelector |
|
4136 | 4266 |
<resource: #programMenu > |
4267 |
||
4268 |
^ [ |
|
8350 | 4269 |
self makeRecentDoItsMenuFor:aSelector |
4136 | 4270 |
]. |
4267 | 4271 |
! |
4272 |
||
4273 |
redoRecentDoItMenu |
|
4274 |
<resource: #programMenu > |
|
4275 |
||
4276 |
^ self recentDoItsMenuFor:#'pasteAndExecute:' |
|
4136 | 4277 |
! ! |
4278 |
||
3154 | 4279 |
!WorkspaceApplication methodsFor:'private'! |
4280 |
||
4031
4ace4ff5fbbd
look for unsaved text in ANY workspace
Claus Gittinger <cg@exept.de>
parents:
3845
diff
changeset
|
4281 |
askIfAnyModified:question yesButton:yesButtonText |
14818
c76a3a590773
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14804
diff
changeset
|
4282 |
|someModifiedWorkspace index label| |
c76a3a590773
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14804
diff
changeset
|
4283 |
|
c76a3a590773
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14804
diff
changeset
|
4284 |
someModifiedWorkspace := workspaces detect:[:aView | self isModifiedWorkspace:aView] |
c76a3a590773
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14804
diff
changeset
|
4285 |
ifNone:nil. |
c76a3a590773
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14804
diff
changeset
|
4286 |
someModifiedWorkspace isNil ifTrue:[^ true]. |
c76a3a590773
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14804
diff
changeset
|
4287 |
|
c76a3a590773
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14804
diff
changeset
|
4288 |
index := workspaces indexOf:someModifiedWorkspace. |
c76a3a590773
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14804
diff
changeset
|
4289 |
label := tabList at:index ifAbsent:'Edit Window'. |
4031
4ace4ff5fbbd
look for unsaved text in ANY workspace
Claus Gittinger <cg@exept.de>
parents:
3845
diff
changeset
|
4290 |
|
4ace4ff5fbbd
look for unsaved text in ANY workspace
Claus Gittinger <cg@exept.de>
parents:
3845
diff
changeset
|
4291 |
(Dialog |
14818
c76a3a590773
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14804
diff
changeset
|
4292 |
confirm:(resources stringWithCRs:question with:label) |
6636 | 4293 |
yesLabel:(resources string:yesButtonText) |
4294 |
noLabel:(resources string:'Cancel')) |
|
4031
4ace4ff5fbbd
look for unsaved text in ANY workspace
Claus Gittinger <cg@exept.de>
parents:
3845
diff
changeset
|
4295 |
ifTrue:[ |
4ace4ff5fbbd
look for unsaved text in ANY workspace
Claus Gittinger <cg@exept.de>
parents:
3845
diff
changeset
|
4296 |
"/ reset modified flag so question is asked only once |
6045 | 4297 |
workspaces |
4298 |
select:[:aView | (self isModifiedWorkspace:aView)] |
|
4299 |
thenDo:[:eachModifiedTextView | |
|
7662 | 4300 |
eachModifiedTextView |
4301 |
perform:#modified: with:false |
|
4302 |
ifNotUnderstood:[]. |
|
6045 | 4303 |
]. |
4031
4ace4ff5fbbd
look for unsaved text in ANY workspace
Claus Gittinger <cg@exept.de>
parents:
3845
diff
changeset
|
4304 |
^ true |
4ace4ff5fbbd
look for unsaved text in ANY workspace
Claus Gittinger <cg@exept.de>
parents:
3845
diff
changeset
|
4305 |
]. |
4ace4ff5fbbd
look for unsaved text in ANY workspace
Claus Gittinger <cg@exept.de>
parents:
3845
diff
changeset
|
4306 |
^ false |
4ace4ff5fbbd
look for unsaved text in ANY workspace
Claus Gittinger <cg@exept.de>
parents:
3845
diff
changeset
|
4307 |
! |
4ace4ff5fbbd
look for unsaved text in ANY workspace
Claus Gittinger <cg@exept.de>
parents:
3845
diff
changeset
|
4308 |
|
5852 | 4309 |
compilerClassForSyntaxName:syntax |
4310 |
syntax == #Smalltalk ifTrue:[ |
|
4311 |
^ Compiler |
|
4312 |
]. |
|
4313 |
syntax == #JavaScript ifTrue:[ |
|
4314 |
^ JavaScriptCompiler |
|
4315 |
]. |
|
4316 |
^ Compiler |
|
4317 |
! |
|
4318 |
||
13643
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
4319 |
compilerClassOf:aWorkspace |
17373 | 4320 |
^ [ |
15409
cfc502624aeb
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15392
diff
changeset
|
4321 |
"/ catch, because it could be a non-edit view there (VT100, TeaTimer etc.) |
17373 | 4322 |
aWorkspace compilerClass. |
4323 |
] on:MessageNotUnderstood do:[nil]. |
|
4324 |
||
4325 |
"Modified: / 08-02-2017 / 19:26:00 / stefan" |
|
13643
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
4326 |
! |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
4327 |
|
6699 | 4328 |
createEvaluationWorkspace |
8292 | 4329 |
|ws l b box resultView environmentView panel workspaceVariables timeLabel| |
6699 | 4330 |
|
4331 |
workspaceVariables := Workspace workspaceVariables. |
|
4332 |
||
4333 |
panel := VariableVerticalPanel new. |
|
7541
957ae975e391
handles in the eval-workspace
Claus Gittinger <cg@exept.de>
parents:
7537
diff
changeset
|
4334 |
panel showHandle:true. |
6699 | 4335 |
|
4336 |
box := View new. |
|
4337 |
l := Label new. |
|
8292 | 4338 |
l label:(resources string:'Eval:'). |
6865 | 4339 |
l layout:((0.0@0.0 corner:0.5@0.0) asLayout bottomOffset:22). |
6699 | 4340 |
l adjust:#left. |
4341 |
box add:l. |
|
4342 |
||
4343 |
ws := HVScrollableView for:Workspace. |
|
7662 | 4344 |
ws scrolledView name:#'Workspace'. |
6699 | 4345 |
ws autoDefineVariables:#workspace. |
6865 | 4346 |
ws layout:((0.0@0.0 corner:1.0@1.0) asLayout topOffset:22; bottomOffset:-22). |
6699 | 4347 |
box add:ws. |
6865 | 4348 |
|
4349 |
b := Button new. |
|
4350 |
b label:'DoIt'. |
|
4351 |
b layout:((0.25@1.0 corner:0.5@1.0) asLayout topOffset:-22). |
|
4352 |
b adjust:#left. |
|
4353 |
b action:[ws doIt]. |
|
4354 |
box add:b. |
|
4355 |
||
4356 |
b := Button new. |
|
4357 |
b label:'InspectIt'. |
|
4358 |
b layout:((0.5@1.0 corner:0.75@1.0) asLayout topOffset:-22). |
|
4359 |
b adjust:#left. |
|
4360 |
b action:[ws inspectIt]. |
|
4361 |
box add:b. |
|
4362 |
||
4363 |
b := Button new. |
|
4364 |
b label:'BrowseIt'. |
|
4365 |
b layout:((0.75@1.0 corner:1.0@1.0) asLayout topOffset:-22). |
|
4366 |
b adjust:#left. |
|
4367 |
b action:[ws browseIt]. |
|
4368 |
box add:b. |
|
4369 |
||
6699 | 4370 |
panel add:box. |
4371 |
||
4372 |
box := View new. |
|
8292 | 4373 |
box add:(Label new label:(resources string:'Value:'); adjust:#left; layout:((0.0@0.0 corner:0.5@0.0) asLayout bottomOffset:22)). |
4374 |
box add:(timeLabel := Label new label:''; adjust:#right; layout:((0.5@0.0 corner:1.0@0.0) asLayout bottomOffset:22)). |
|
6699 | 4375 |
resultView := HVScrollableView for:TextCollector. |
4376 |
box add:(resultView layout:((0@0 corner:1.0@1.0) asLayout topOffset:22); yourself). |
|
4377 |
||
4378 |
panel add:box. |
|
4379 |
||
4380 |
box := View new. |
|
8292 | 4381 |
box add:(Label new label:(resources string:'Environment:'); adjust:#left; layout:((0.0@0.0 corner:1.0@0.0) asLayout bottomOffset:22)). |
6699 | 4382 |
environmentView := DictionaryInspectorView new. |
4383 |
environmentView suppressPseudoSlots:true. |
|
4384 |
environmentView inspect:workspaceVariables. |
|
4385 |
environmentView dereferenceValueHolders:true. |
|
4386 |
environmentView fieldListLabel:'Variable'. |
|
4387 |
box add:(environmentView layout:((0@0 corner:1.0@1.0) asLayout topOffset:22); yourself). |
|
4388 |
||
4389 |
panel add:box. |
|
4390 |
||
4391 |
"/ self renameWorkspace:(self selectedWorkspaceIndexHolder value) to:'Eval'. |
|
4392 |
||
4393 |
ws doItAction:[:theCode | |
|
8292 | 4394 |
|t result resultString| |
6699 | 4395 |
|
8292 | 4396 |
t := TimeDuration toRun:[ |
4397 |
result := ws executeDoIt:theCode. |
|
4398 |
]. |
|
4399 |
timeLabel label:(resources string:'Exec. Time: %1' with:t printString). |
|
4400 |
||
6752 | 4401 |
resultString := [ |
4402 |
result storeString |
|
4403 |
] on:Error do:[ |
|
4404 |
result printString |
|
4405 |
]. |
|
4406 |
||
4407 |
resultView showCR:resultString. |
|
17014 | 4408 |
Workspace rememberResultAsWorkspaceVariable:result. |
6699 | 4409 |
environmentView doUpdate. |
4410 |
result. |
|
4411 |
]. |
|
6865 | 4412 |
panel relativeCorners:#(0.4 0.6 1.0). |
6699 | 4413 |
^ panel |
7541
957ae975e391
handles in the eval-workspace
Claus Gittinger <cg@exept.de>
parents:
7537
diff
changeset
|
4414 |
|
957ae975e391
handles in the eval-workspace
Claus Gittinger <cg@exept.de>
parents:
7537
diff
changeset
|
4415 |
"Modified: / 24-11-2006 / 11:06:33 / cg" |
6699 | 4416 |
! |
4417 |
||
5295
e3c5a7b20d9d
refactored (added abstract superclass)
Claus Gittinger <cg@exept.de>
parents:
5262
diff
changeset
|
4418 |
createWorkspace |
5547
65af7af97085
initial value of #autoDefine was not set correctly
Claus Gittinger <cg@exept.de>
parents:
5490
diff
changeset
|
4419 |
|ws| |
65af7af97085
initial value of #autoDefine was not set correctly
Claus Gittinger <cg@exept.de>
parents:
5490
diff
changeset
|
4420 |
|
10169 | 4421 |
ws := self createWorkspaceView. |
13852 | 4422 |
ws autoDefineVariables:self autoDefineVariables value. |
7931 | 4423 |
ws poolsConsideredInDoIts:poolsConsideredInDoIts. |
5547
65af7af97085
initial value of #autoDefine was not set correctly
Claus Gittinger <cg@exept.de>
parents:
5490
diff
changeset
|
4424 |
^ ws |
9746
d7c05875edc0
initial language setting fixed
Claus Gittinger <cg@exept.de>
parents:
9745
diff
changeset
|
4425 |
|
10169 | 4426 |
"Modified (format): / 05-07-2011 / 14:18:52 / cg" |
13852 | 4427 |
"Modified: / 18-03-2012 / 23:37:56 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
3193 | 4428 |
! |
4429 |
||
10169 | 4430 |
createWorkspaceView |
11615
f9dfb7daa5e4
corrected switching languages between tabs
Claus Gittinger <cg@exept.de>
parents:
11612
diff
changeset
|
4431 |
|ws language| |
10169 | 4432 |
|
4433 |
ws := self class createWorkspaceView. |
|
15294
4bd3f000c743
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15273
diff
changeset
|
4434 |
|
4bd3f000c743
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15273
diff
changeset
|
4435 |
ws codeAspect: SyntaxHighlighter codeAspectExpression. |
13852 | 4436 |
ws acceptAction:[:code | self menuSave ]. |
15294
4bd3f000c743
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15273
diff
changeset
|
4437 |
|
4bd3f000c743
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15273
diff
changeset
|
4438 |
"/ (ws respondsTo:#languageHolder:) ifTrue:[ |
4bd3f000c743
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15273
diff
changeset
|
4439 |
"/ ws languageHolder:self syntaxHolder |
4bd3f000c743
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15273
diff
changeset
|
4440 |
"/ ]. |
4bd3f000c743
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15273
diff
changeset
|
4441 |
language := self syntaxHolder value ? Smalltalk programmingLanguage. |
4bd3f000c743
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15273
diff
changeset
|
4442 |
language notNil ifTrue:[ |
11615
f9dfb7daa5e4
corrected switching languages between tabs
Claus Gittinger <cg@exept.de>
parents:
11612
diff
changeset
|
4443 |
ws compilerClass:(language evaluatorClass). |
13581
75759c16ab7f
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13500
diff
changeset
|
4444 |
ws editedLanguage:language. |
11615
f9dfb7daa5e4
corrected switching languages between tabs
Claus Gittinger <cg@exept.de>
parents:
11612
diff
changeset
|
4445 |
]. |
10169 | 4446 |
^ ws |
4447 |
||
11615
f9dfb7daa5e4
corrected switching languages between tabs
Claus Gittinger <cg@exept.de>
parents:
11612
diff
changeset
|
4448 |
"Modified: / 19-07-2012 / 16:39:15 / cg" |
13852 | 4449 |
"Modified: / 21-08-2012 / 17:20:24 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
10169 | 4450 |
! |
4451 |
||
15294
4bd3f000c743
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15273
diff
changeset
|
4452 |
createWorkspaceViewForText |
4bd3f000c743
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15273
diff
changeset
|
4453 |
"creates a language unaware workspace" |
4bd3f000c743
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15273
diff
changeset
|
4454 |
|
4bd3f000c743
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15273
diff
changeset
|
4455 |
|ws| |
4bd3f000c743
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15273
diff
changeset
|
4456 |
|
4bd3f000c743
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15273
diff
changeset
|
4457 |
ws := self class createWorkspaceView. |
4bd3f000c743
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15273
diff
changeset
|
4458 |
|
4bd3f000c743
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15273
diff
changeset
|
4459 |
ws acceptAction:[:code | self menuSave ]. |
4bd3f000c743
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15273
diff
changeset
|
4460 |
"/ (ws respondsTo:#languageHolder:) ifTrue:[ |
4bd3f000c743
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15273
diff
changeset
|
4461 |
"/ ws languageHolder:nil |
4bd3f000c743
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15273
diff
changeset
|
4462 |
"/ ]. |
4bd3f000c743
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15273
diff
changeset
|
4463 |
ws compilerClass:(Smalltalk programmingLanguage). |
4bd3f000c743
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15273
diff
changeset
|
4464 |
ws editedLanguage:nil. |
4bd3f000c743
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15273
diff
changeset
|
4465 |
ws codeAspect:nil. |
4bd3f000c743
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15273
diff
changeset
|
4466 |
^ ws |
4bd3f000c743
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15273
diff
changeset
|
4467 |
! |
4bd3f000c743
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15273
diff
changeset
|
4468 |
|
10169 | 4469 |
isModifiedWorkspace:aView |
4031
4ace4ff5fbbd
look for unsaved text in ANY workspace
Claus Gittinger <cg@exept.de>
parents:
3845
diff
changeset
|
4470 |
|view| |
4ace4ff5fbbd
look for unsaved text in ANY workspace
Claus Gittinger <cg@exept.de>
parents:
3845
diff
changeset
|
4471 |
|
10169 | 4472 |
aView isNil ifTrue:[ |
4031
4ace4ff5fbbd
look for unsaved text in ANY workspace
Claus Gittinger <cg@exept.de>
parents:
3845
diff
changeset
|
4473 |
^ false |
4ace4ff5fbbd
look for unsaved text in ANY workspace
Claus Gittinger <cg@exept.de>
parents:
3845
diff
changeset
|
4474 |
]. |
10169 | 4475 |
view := self workspaceViewOfView:aView. |
4476 |
(view isNil |
|
4477 |
or:[ view modified not |
|
4478 |
or:[ view contentsWasSaved |
|
4479 |
or:[ view contents withoutSeparators isEmpty ]]]) |
|
4480 |
ifTrue:[ |
|
4481 |
^ false |
|
4482 |
]. |
|
4031
4ace4ff5fbbd
look for unsaved text in ANY workspace
Claus Gittinger <cg@exept.de>
parents:
3845
diff
changeset
|
4483 |
^ true |
10169 | 4484 |
|
4485 |
"Modified: / 03-06-2011 / 11:03:48 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
4486 |
"Modified (format): / 05-07-2011 / 15:01:08 / cg" |
|
4031
4ace4ff5fbbd
look for unsaved text in ANY workspace
Claus Gittinger <cg@exept.de>
parents:
3845
diff
changeset
|
4487 |
! |
4ace4ff5fbbd
look for unsaved text in ANY workspace
Claus Gittinger <cg@exept.de>
parents:
3845
diff
changeset
|
4488 |
|
4267 | 4489 |
lastDoItsString |
4490 |
|history| |
|
3198 | 4491 |
|
4267 | 4492 |
history := Workspace doItHistory. |
4493 |
history size > 0 ifFalse:[ |
|
4494 |
self selectedWorkspacesTextView flash. |
|
4495 |
^ nil |
|
3198 | 4496 |
]. |
4267 | 4497 |
^ history first |
5852 | 4498 |
! |
4499 |
||
14724
74a5e633ef41
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14635
diff
changeset
|
4500 |
syntaxFromEvaluatorClass:aClass |
74a5e633ef41
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14635
diff
changeset
|
4501 |
"knowing the evaluator class, determine the syntax highlighter class" |
74a5e633ef41
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14635
diff
changeset
|
4502 |
|
74a5e633ef41
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14635
diff
changeset
|
4503 |
aClass notNil ifTrue:[ |
18852 | 4504 |
^ ProgrammingLanguage allDetect:[:lang | lang evaluatorClass = aClass] ifNone:[nil]. |
5852 | 4505 |
]. |
14724
74a5e633ef41
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
14635
diff
changeset
|
4506 |
"Unknown language - should not happen :-)" |
10169 | 4507 |
^ nil |
4508 |
||
11483
5f545a7d153a
fixed language related valueholder handling
Claus Gittinger <cg@exept.de>
parents:
11481
diff
changeset
|
4509 |
"Created: / 26-04-2012 / 12:59:32 / cg" |
18852 | 4510 |
"Modified: / 27-06-2019 / 12:37:50 / Claus Gittinger" |
5852 | 4511 |
! |
4512 |
||
4513 |
workspaceSelectionChanged |
|
9695 | 4514 |
"attach line, col and mode holders to the current workspace window" |
4515 |
||
13852 | 4516 |
|compilerClass selectedWorkspace selectedWorkspaceApp | |
4517 |
||
4518 |
"JV@2012-05-10: Modified to better support complex application models as tabs" |
|
5852 | 4519 |
|
4520 |
super workspaceSelectionChanged. |
|
9695 | 4521 |
|
5855 | 4522 |
selectedWorkspace := self selectedWorkspace. |
13852 | 4523 |
selectedWorkspaceApp := self selectedWorkspaceApplication. |
4524 |
||
4525 |
(selectedWorkspace notNil and:[selectedWorkspace isScrollWrapper]) ifTrue:[ |
|
9746
d7c05875edc0
initial language setting fixed
Claus Gittinger <cg@exept.de>
parents:
9745
diff
changeset
|
4526 |
selectedWorkspace := selectedWorkspace scrolledView |
d7c05875edc0
initial language setting fixed
Claus Gittinger <cg@exept.de>
parents:
9745
diff
changeset
|
4527 |
]. |
13852 | 4528 |
|
13906
e13d8ad35a46
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13901
diff
changeset
|
4529 |
compilerClass := self compilerClassOf: selectedWorkspaceApp ? selectedWorkspace. |
13852 | 4530 |
self canChangeLanguageHolder value: |
4531 |
(selectedWorkspaceApp ? selectedWorkspace respondsTo: #compilerClass:). |
|
4532 |
||
4533 |
self syntaxHolder value:(self syntaxFromEvaluatorClass:compilerClass). |
|
4534 |
||
4535 |
(selectedWorkspace notNil and:[ selectedWorkspace scrolledView isTextView or:[selectedWorkspaceApp notNil] ]) ifTrue:[ |
|
15817
f6046130309e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15816
diff
changeset
|
4536 |
self cursorLineAndColumnLabelHolder valueHolder:( selectedWorkspaceApp ? selectedWorkspace perform:#cursorLineAndColumnLabelHolder ifNotUnderstood:nil ). |
13852 | 4537 |
self cursorLineHolder valueHolder:( selectedWorkspaceApp ? selectedWorkspace perform:#cursorLineHolder ifNotUnderstood:nil ). |
4538 |
self cursorColHolder valueHolder:( selectedWorkspaceApp ? selectedWorkspace perform:#cursorColHolder ifNotUnderstood:nil ). |
|
4539 |
self modeLabelHolder valueHolder:( selectedWorkspaceApp ? selectedWorkspace perform:#modeLabelHolder ifNotUnderstood:nil ). |
|
9695 | 4540 |
] ifFalse:[ |
15817
f6046130309e
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15816
diff
changeset
|
4541 |
self cursorLineAndColumnLabelHolder valueHolder:nil. |
9695 | 4542 |
self cursorLineHolder valueHolder:nil. |
4543 |
self cursorColHolder valueHolder:nil. |
|
4544 |
self modeLabelHolder valueHolder:nil. |
|
4545 |
]. |
|
4546 |
||
10169 | 4547 |
"Update toolbar" |
15409
cfc502624aeb
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15392
diff
changeset
|
4548 |
(selectedWorkspaceApp notNil |
cfc502624aeb
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15392
diff
changeset
|
4549 |
and:[ (selectedWorkspaceApp class respondsTo: #toolBarSpec) ]) ifTrue:[ |
cfc502624aeb
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15392
diff
changeset
|
4550 |
"/ client provides one |
cfc502624aeb
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15392
diff
changeset
|
4551 |
self toolBarView client: selectedWorkspaceApp spec: #toolBarSpec |
10169 | 4552 |
] ifFalse:[ |
15816
64d953f953a1
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15737
diff
changeset
|
4553 |
"/ I provide it |
15409
cfc502624aeb
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15392
diff
changeset
|
4554 |
self toolBarView client: self spec: #toolBarSpec builder: builder. |
10169 | 4555 |
] |
3154 | 4556 |
! ! |
4557 |
||
14747 | 4558 |
!WorkspaceApplication methodsFor:'special startup'! |
4559 |
||
4560 |
openSystemWorkspace |
|
15294
4bd3f000c743
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15273
diff
changeset
|
4561 |
"create the tabs for the initial welcome system workspace" |
4bd3f000c743
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15273
diff
changeset
|
4562 |
|
14747 | 4563 |
|path needRemove font| |
4564 |
||
4565 |
needRemove := true. |
|
4566 |
||
4567 |
self allButOpen. |
|
4568 |
||
4569 |
(self builder componentAt:'NoteBook') |
|
4570 |
destroyTabAction:[:tabIndex| self removeWorkspace:tabIndex]. |
|
4571 |
||
4572 |
self window extent:640@400. |
|
4573 |
||
4574 |
path := (Smalltalk getSystemFileName:'README') ? '../../README'. |
|
4575 |
path := path asFilename. |
|
4576 |
path isReadable ifTrue:[ |
|
15294
4bd3f000c743
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15273
diff
changeset
|
4577 |
self addWindow:(self createWorkspaceViewForText) named:'README' asFirst:false. |
14747 | 4578 |
self loadFile:path. |
4579 |
self removeWorkspace:1. "/ the original Workspace |
|
4580 |
self renameWorkspace:1 to:'LICENCE README'. |
|
4581 |
needRemove := false. |
|
4582 |
]. |
|
4583 |
||
4584 |
"/ path := (Smalltalk getSystemFileName:'doc/online/english/LICENCE_STX.html') ? '../../doc/online/english/LICENCE_STX.html'. |
|
4585 |
"/ path asFilename exists ifTrue:[ |
|
4586 |
"/ self addWindow:(licenceView := HVScrollableView for:HTMLDocumentView) named:'License' asFirst:false. |
|
4587 |
"/ licenceView homeDocument:'../../doc/online/english/LICENCE_STX.html'. |
|
4588 |
"/ licenceView updateLabelFlag:false. |
|
4589 |
"/ needRemove ifTrue:[self removeWorkspace:1]. "/ the original Workspace |
|
4590 |
"/ needRemove := false. |
|
4591 |
"/ ]. |
|
4592 |
||
18941 | 4593 |
device isX11Platform ifTrue:[ |
18825 | 4594 |
"/ font := Font family:'DejaVuSansMono' face:'medium' style:'roman' size:16 encoding:'iso10646-1'. |
4595 |
"/ font := font onDevice:device ifAbsent:nil. |
|
17014 | 4596 |
font isNil ifTrue:[ |
18825 | 4597 |
font := Font family:'FreeMono' face:'regular' style:'roman' size:12 encoding:'iso10646-1'. |
16966 | 4598 |
font := font onDevice:device ifAbsent:nil. |
16967 | 4599 |
font isNil ifTrue:[ |
18825 | 4600 |
font := Font family:'unifont' face:'medium' style:'roman' size:12 encoding:'iso10646-1'. |
16957 | 4601 |
font := font onDevice:device ifAbsent:nil. |
4602 |
font isNil ifTrue:[ |
|
17014 | 4603 |
font := Font family:'arial' face:'medium' style:'roman' size:12 encoding:'iso10646-1'. |
16957 | 4604 |
font := font onDevice:device ifAbsent:nil. |
18825 | 4605 |
font isNil ifTrue:[ |
4606 |
font := Font family:'courier' face:'regular' style:'roman' size:12 encoding:'iso10646-1'. |
|
4607 |
font := font onDevice:device ifAbsent:nil. |
|
4608 |
]. |
|
16957 | 4609 |
]. |
4610 |
]. |
|
14747 | 4611 |
]. |
4612 |
] ifFalse:[ |
|
4613 |
"/ font := Font family:'Arial Unicode MS' face:'medium' style:'roman' size:10 encoding:'ms-ansi'. |
|
4614 |
font := Font family:'arial' face:'medium' style:'roman' size:10 encoding:'ms-ansi'. |
|
16244 | 4615 |
font := font onDevice:device ifAbsent:nil. |
14747 | 4616 |
]. |
4617 |
||
4618 |
#( "/ file resourceKey title forcedEncoding type |
|
4619 |
('Hello_utf8.wsp' HELLO_UTF_FILE 'Hello' #'utf8' #text) |
|
4620 |
('Welcome.wsp' WELCOME_FILE 'This Release' nil #text) |
|
4621 |
"/ ('Setup.wsp' SETUP_FILE 'Setup' nil #text) |
|
4622 |
('Keyboard.wsp' KEYBOARD_FILE 'Keyboard' nil #text) |
|
4623 |
"/ ('GettingStarted.wsp' GETTING_STARTED_FILE 'Getting Started' nil #text) |
|
4624 |
('../../doc/online/english/GettingStarted.html' GETTING_STARTED_TML_FILE 'Getting Started' nil #html) |
|
4625 |
('../../doc/books/JoyOfST/IntroToST.html' INTRO_TO_ST_FILE 'Smalltalk Introduction' nil #html) |
|
4626 |
"/ if these are present, show them. |
|
15294
4bd3f000c743
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15273
diff
changeset
|
4627 |
('Private.wsp' PRIVATE_FILE 'Private Workspace' nil #code) |
4bd3f000c743
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15273
diff
changeset
|
4628 |
('MyWorkspace.wsp' MYWORKSPACE_FILE 'My Workspace' nil #code) |
4bd3f000c743
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15273
diff
changeset
|
4629 |
('PackageLoading.wsp' PACKAGELOADING_FILE 'Packages' nil #code) |
14747 | 4630 |
) do:[:tuple | |
4631 |
|file resKey title forcedEncoding type pane encoding htmlView| |
|
4632 |
||
4633 |
file := tuple at:1. |
|
4634 |
resKey := tuple at:2. |
|
4635 |
file := self resources string:resKey default:file. |
|
4636 |
||
4637 |
title := tuple at:3. |
|
4638 |
forcedEncoding := tuple at:4. |
|
4639 |
type := tuple at:5. |
|
4640 |
||
4641 |
path := Smalltalk getSystemFileName:file. |
|
4642 |
(path notNil and:[path asFilename isReadable]) ifTrue:[ |
|
4643 |
type == #html ifTrue:[ |
|
4644 |
self addWindow:(htmlView := HVScrollableView for:HTMLDocumentView) named:title asFirst:false. |
|
4645 |
htmlView homeDocument:path. |
|
4646 |
htmlView infoHolder:self infoLabelHolder. |
|
4647 |
htmlView updateTopViewsTitleFlag:false. |
|
4648 |
] ifFalse:[ |
|
15294
4bd3f000c743
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15273
diff
changeset
|
4649 |
type == #code ifTrue:[ |
4bd3f000c743
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15273
diff
changeset
|
4650 |
self addWindow:(pane := self createWorkspaceView) named:title asFirst:false. |
4bd3f000c743
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15273
diff
changeset
|
4651 |
] ifFalse:[ |
4bd3f000c743
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15273
diff
changeset
|
4652 |
self addWindow:(pane := self createWorkspaceViewForText) named:title asFirst:false. |
4bd3f000c743
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15273
diff
changeset
|
4653 |
]. |
14747 | 4654 |
forcedEncoding notNil ifTrue:[ |
4655 |
encoding := forcedEncoding. |
|
4656 |
font notNil ifTrue:[ |
|
4657 |
pane font:font. |
|
4658 |
] |
|
4659 |
] ifFalse:[ |
|
4660 |
encoding := CharacterEncoder guessEncodingOfFile:path. |
|
4661 |
(encoding == #'iso8859-1' or:[encoding == #'ascii']) ifTrue:[ |
|
4662 |
encoding := nil |
|
4663 |
]. |
|
4664 |
]. |
|
4665 |
self loadFile:path encoding:encoding label:title. |
|
4666 |
]. |
|
4667 |
needRemove ifTrue:[self removeWorkspace:1]. "/ the original Workspace |
|
4668 |
needRemove := false. |
|
4669 |
]. |
|
4670 |
]. |
|
4671 |
self openWindow. |
|
4672 |
self selectedWorkspaceIndexHolder value:2. |
|
4673 |
||
4674 |
" |
|
4675 |
|ws b| |
|
4676 |
ws := self openSystemWorkspace. |
|
4677 |
ws addMyWorkspace. |
|
4678 |
ws selectedWorkspaceIndexHolder value:(ws workspaces size). |
|
4679 |
ws selectedWorkspace contents:'Tools::NewSystemBrowser open'; selectAll. |
|
4680 |
ws selectedWorkspace |
|
4681 |
add:(b := Button label:'DoIt' action:[ws doIt. b destroy]) |
|
4682 |
" |
|
4683 |
" |
|
4684 |
|ws b| |
|
4685 |
ws := self new. |
|
4686 |
ws open. |
|
4687 |
ws selectedWorkspace contents:'Tools::NewSystemBrowser open'; selectAll. |
|
4688 |
" |
|
4689 |
||
4690 |
"Modified: / 14-02-2010 / 23:02:59 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
4691 |
"Modified: / 05-07-2011 / 15:34:40 / cg" |
|
18941 | 4692 |
"Modified: / 25-07-2019 / 12:32:46 / Claus Gittinger" |
14747 | 4693 |
! ! |
4694 |
||
7825 | 4695 |
!WorkspaceApplication methodsFor:'user actions'! |
4696 |
||
4697 |
infoVisibilityChanged |
|
4698 |
super infoVisibilityChanged. |
|
4699 |
UserPreferences current infoVisibleInWorkspace:(self infoVisibleHolder value) |
|
4700 |
||
4701 |
"Created: / 14-07-2007 / 16:46:58 / cg" |
|
4702 |
! |
|
4703 |
||
13643
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
4704 |
namespaceChangedByUser |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
4705 |
"remember as default for next new workspace" |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
4706 |
|
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
4707 |
LastNamespace := self namespaceHolder value. |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
4708 |
! |
38d9fae397cd
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
13585
diff
changeset
|
4709 |
|
11483
5f545a7d153a
fixed language related valueholder handling
Claus Gittinger <cg@exept.de>
parents:
11481
diff
changeset
|
4710 |
syntaxChangedByUser |
5f545a7d153a
fixed language related valueholder handling
Claus Gittinger <cg@exept.de>
parents:
11481
diff
changeset
|
4711 |
"remember as default for next new workspace" |
5f545a7d153a
fixed language related valueholder handling
Claus Gittinger <cg@exept.de>
parents:
11481
diff
changeset
|
4712 |
LastLanguage := self syntaxHolder value. |
5f545a7d153a
fixed language related valueholder handling
Claus Gittinger <cg@exept.de>
parents:
11481
diff
changeset
|
4713 |
|
5f545a7d153a
fixed language related valueholder handling
Claus Gittinger <cg@exept.de>
parents:
11481
diff
changeset
|
4714 |
"Created: / 26-04-2012 / 12:31:04 / cg" |
5f545a7d153a
fixed language related valueholder handling
Claus Gittinger <cg@exept.de>
parents:
11481
diff
changeset
|
4715 |
! |
5f545a7d153a
fixed language related valueholder handling
Claus Gittinger <cg@exept.de>
parents:
11481
diff
changeset
|
4716 |
|
7825 | 4717 |
toolBarVisibilityChanged |
4718 |
super toolBarVisibilityChanged. |
|
8499 | 4719 |
UserPreferences current toolbarVisibleInWorkspace:(self toolBarVisibleHolder value). |
4720 |
UserPreferences current editToolbarVisibleInWorkspace:(self editToolBarVisibleHolder value). |
|
7825 | 4721 |
|
4722 |
"Created: / 14-07-2007 / 16:45:31 / cg" |
|
4723 |
! ! |
|
4724 |
||
3154 | 4725 |
!WorkspaceApplication class methodsFor:'documentation'! |
4726 |
||
10318 | 4727 |
version |
15737
5f5dd0d93690
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15608
diff
changeset
|
4728 |
^ '$Header$' |
10318 | 4729 |
! |
4730 |
||
9059 | 4731 |
version_CVS |
15737
5f5dd0d93690
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15608
diff
changeset
|
4732 |
^ '$Header$' |
10394 | 4733 |
! |
4734 |
||
4735 |
version_SVN |
|
15737
5f5dd0d93690
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
15608
diff
changeset
|
4736 |
^ '$Id$' |
3154 | 4737 |
! ! |
12340
8332590c5a41
class: WorkspaceApplication
Claus Gittinger <cg@exept.de>
parents:
12032
diff
changeset
|
4738 |