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