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