author | Claus Gittinger <cg@exept.de> |
Thu, 05 Mar 2020 11:17:15 +0100 | |
changeset 19546 | f44be5ec67e5 |
parent 19367 | e9085f37cd33 |
permissions | -rw-r--r-- |
19235 | 1 |
"{ Encoding: utf8 }" |
2 |
||
36 | 3 |
" |
4 |
COPYRIGHT (c) 1989 by Claus Gittinger |
|
4158 | 5 |
All Rights Reserved |
36 | 6 |
|
7 |
This software is furnished under a license and may be used |
|
8 |
only in accordance with the terms of that license and with the |
|
9 |
inclusion of the above copyright notice. This software may not |
|
10 |
be provided or otherwise made available to, or used by, any |
|
11 |
other person. No title to or ownership of the software is |
|
12 |
hereby transferred. |
|
13 |
" |
|
2655
9e90bbd1eb18
apropos search is now: selectors containing
Claus Gittinger <cg@exept.de>
parents:
2642
diff
changeset
|
14 |
"{ Package: 'stx:libtool' }" |
9e90bbd1eb18
apropos search is now: selectors containing
Claus Gittinger <cg@exept.de>
parents:
2642
diff
changeset
|
15 |
|
15206 | 16 |
"{ NameSpace: Smalltalk }" |
17 |
||
85 | 18 |
ApplicationModel subclass:#SystemBrowser |
4165 | 19 |
instanceVariableNames:'' |
20 |
classVariableNames:'CheckForInstancesWhenRemovingClasses ClassHistory |
|
21 |
EmphasisForDifferentPackage EmphasisForModifiedBuffer |
|
22 |
EmphasisForObsoleteCode EmphasisForReadVariable |
|
11271 | 23 |
EmphasisForWrittenVariable EmphasisForChangedCode |
13028 | 24 |
LastSearchPatterns LastClassSearchBoxShowedFullName' |
4165 | 25 |
poolDictionaries:'' |
26 |
category:'Interface-Browsers' |
|
36 | 27 |
! |
28 |
||
3131
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
29 |
Object subclass:#BrowserHistoryEntry |
4165 | 30 |
instanceVariableNames:'className meta selector' |
31 |
classVariableNames:'' |
|
32 |
poolDictionaries:'' |
|
33 |
privateIn:SystemBrowser |
|
3131
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
34 |
! |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
35 |
|
820
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
36 |
!SystemBrowser class methodsFor:'documentation'! |
203 | 37 |
|
38 |
copyright |
|
39 |
" |
|
40 |
COPYRIGHT (c) 1989 by Claus Gittinger |
|
4158 | 41 |
All Rights Reserved |
203 | 42 |
|
43 |
This software is furnished under a license and may be used |
|
44 |
only in accordance with the terms of that license and with the |
|
45 |
inclusion of the above copyright notice. This software may not |
|
46 |
be provided or otherwise made available to, or used by, any |
|
47 |
other person. No title to or ownership of the software is |
|
48 |
hereby transferred. |
|
49 |
" |
|
50 |
! |
|
51 |
||
52 |
documentation |
|
53 |
" |
|
8893 | 54 |
Notice: SystemBrowser has been completely rewritten to be an instance |
16016 | 55 |
of ApplicationModel. This rewritten version is found under Tools::NewSystemBrowser. |
8893 | 56 |
Because the class protocol here was used by many others, it is left here |
57 |
as an instance-less functionality provider only. |
|
203 | 58 |
|
59 |
written winter 89 by claus. |
|
60 |
||
508 | 61 |
[author:] |
62 |
Claus Gittinger |
|
63 |
||
203 | 64 |
" |
65 |
! ! |
|
66 |
||
820
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
67 |
!SystemBrowser class methodsFor:'initialization'! |
75 | 68 |
|
69 |
initialize |
|
70 |
"Browser configuration; |
|
71 |
(values can be changed from your private startup file)" |
|
45 | 72 |
|
254 | 73 |
"/ self classResources. |
85 | 74 |
|
75 | 75 |
" |
76 |
setting this to false, the removeClass function will remove |
|
77 |
classes WITHOUT checking for instances. Otherwise, |
|
78 |
it will check and let you confirm in case there are instances. |
|
79 |
Checking for instances may be a bit time consuming, though. |
|
80 |
The default is true - therefore, it will check |
|
81 |
" |
|
82 |
CheckForInstancesWhenRemovingClasses := true |
|
83 |
||
84 |
" |
|
85 |
CheckForInstancesWhenRemovingClasses := true |
|
86 |
CheckForInstancesWhenRemovingClasses := false |
|
87 |
||
85 | 88 |
SystemBrowser initialize |
75 | 89 |
" |
90 |
! ! |
|
36 | 91 |
|
820
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
92 |
!SystemBrowser class methodsFor:'instance creation'! |
52 | 93 |
|
75 | 94 |
open |
95 |
"launch a standard browser" |
|
96 |
||
2631 | 97 |
self == SystemBrowser ifFalse:[ |
98 |
^ super open |
|
99 |
]. |
|
100 |
||
105 | 101 |
^ self openOnDevice:(Screen current) |
75 | 102 |
|
93 | 103 |
" |
15831 | 104 |
SystemBrowser default open |
93 | 105 |
SystemBrowser open |
106 |
" |
|
194 | 107 |
! |
108 |
||
523 | 109 |
openInClass:aClass |
110 |
"launch a standard browser which immediately switches |
|
111 |
to aClass" |
|
112 |
||
113 |
^ self openInClass:aClass selector:nil |
|
114 |
||
115 |
" |
|
15831 | 116 |
SystemBrowser default openInClass:Object |
523 | 117 |
SystemBrowser openInClass:Object |
118 |
" |
|
119 |
||
120 |
"Created: 30.4.1996 / 14:43:45 / cg" |
|
121 |
! |
|
122 |
||
194 | 123 |
openInClass:aClass selector:aSelector |
124 |
"launch a standard browser which immediately switches |
|
19235 | 125 |
to aClass ยป aSelector. Returns the browser" |
194 | 126 |
|
3626 | 127 |
|brwsr classesName| |
194 | 128 |
|
129 |
brwsr := self openOnDevice:(Screen current). |
|
130 |
brwsr waitUntilVisible. |
|
1561 | 131 |
|
3360
2eab40d1a498
isMeta/soleInstance -> theNonMetaclass
Claus Gittinger <cg@exept.de>
parents:
3354
diff
changeset
|
132 |
aClass notNil ifTrue:[ |
2eab40d1a498
isMeta/soleInstance -> theNonMetaclass
Claus Gittinger <cg@exept.de>
parents:
3354
diff
changeset
|
133 |
"/ cls := aClass. |
2eab40d1a498
isMeta/soleInstance -> theNonMetaclass
Claus Gittinger <cg@exept.de>
parents:
3354
diff
changeset
|
134 |
"/ cls isMeta ifTrue:[ |
2eab40d1a498
isMeta/soleInstance -> theNonMetaclass
Claus Gittinger <cg@exept.de>
parents:
3354
diff
changeset
|
135 |
"/ cls := aClass soleInstance |
2eab40d1a498
isMeta/soleInstance -> theNonMetaclass
Claus Gittinger <cg@exept.de>
parents:
3354
diff
changeset
|
136 |
"/ ]. |
1561 | 137 |
aClass isMeta ifTrue:[ |
138 |
brwsr instanceProtocol:false |
|
139 |
]. |
|
1931
03de5c5f4402
care for javaClass in #openInClass:selector:
Claus Gittinger <cg@exept.de>
parents:
1919
diff
changeset
|
140 |
aClass isJavaClass ifTrue:[ |
3360
2eab40d1a498
isMeta/soleInstance -> theNonMetaclass
Claus Gittinger <cg@exept.de>
parents:
3354
diff
changeset
|
141 |
classesName := aClass fullName. |
1931
03de5c5f4402
care for javaClass in #openInClass:selector:
Claus Gittinger <cg@exept.de>
parents:
1919
diff
changeset
|
142 |
] ifFalse:[ |
3360
2eab40d1a498
isMeta/soleInstance -> theNonMetaclass
Claus Gittinger <cg@exept.de>
parents:
3354
diff
changeset
|
143 |
classesName := aClass name. |
1931
03de5c5f4402
care for javaClass in #openInClass:selector:
Claus Gittinger <cg@exept.de>
parents:
1919
diff
changeset
|
144 |
]. |
3360
2eab40d1a498
isMeta/soleInstance -> theNonMetaclass
Claus Gittinger <cg@exept.de>
parents:
3354
diff
changeset
|
145 |
brwsr switchToClassNamed:classesName. |
1681 | 146 |
brwsr classSelectionChanged. |
1561 | 147 |
aSelector notNil ifTrue:[ |
148 |
brwsr switchToMethodNamed:aSelector. |
|
149 |
] |
|
194 | 150 |
]. |
151 |
^ brwsr |
|
152 |
||
153 |
" |
|
154 |
SystemBrowser openInClass:Object selector:#at:put: |
|
155 |
SystemBrowser openInClass:Object selector:nil |
|
156 |
SystemBrowser openInClass:nil selector:nil |
|
157 |
" |
|
158 |
||
1561 | 159 |
"Created: / 22.11.1995 / 21:04:50 / cg" |
3360
2eab40d1a498
isMeta/soleInstance -> theNonMetaclass
Claus Gittinger <cg@exept.de>
parents:
3354
diff
changeset
|
160 |
"Modified: / 5.11.2001 / 16:51:02 / cg" |
203 | 161 |
! |
162 |
||
3588 | 163 |
openOn:anEnvironment |
18614 | 164 |
"open on a namespace" |
165 |
||
4921 | 166 |
^ self |
167 |
openOn:anEnvironment |
|
168 |
label:(self classResources string:'System Browser') |
|
3588 | 169 |
|
170 |
" |
|
15831 | 171 |
SystemBrowser default openOn:Smalltalk |
172 |
SystemBrowser default openOn:Demos |
|
173 |
||
3588 | 174 |
SystemBrowser openOn:Smalltalk |
3589 | 175 |
SystemBrowser openOn:Demos |
3588 | 176 |
" |
18614 | 177 |
|
178 |
"Modified: / 22-02-2019 / 10:14:45 / Claus Gittinger" |
|
3588 | 179 |
! |
180 |
||
4921 | 181 |
openOn:aClassEnvironment label:title |
18614 | 182 |
"open on a namespace" |
183 |
||
4921 | 184 |
^ self |
185 |
openOn:aClassEnvironment |
|
186 |
label:title |
|
187 |
onDevice:(Screen current) |
|
18614 | 188 |
|
189 |
"Modified (comment): / 22-02-2019 / 10:14:37 / Claus Gittinger" |
|
4921 | 190 |
! |
191 |
||
192 |
openOn:aClassEnvironment label:title onDevice:aDisplayDevice |
|
18614 | 193 |
"open on a nameSpace" |
194 |
||
4921 | 195 |
|browser| |
196 |
||
18614 | 197 |
"/ to avoid errors when accessing the namespace... |
198 |
aClassEnvironment isNameSpace ifFalse:[ |
|
199 |
^ self openInClass:aClassEnvironment |
|
200 |
]. |
|
201 |
||
4921 | 202 |
browser := self |
203 |
newWithLabel:title |
|
204 |
setupBlock:[:browser | browser environment:aClassEnvironment. |
|
205 |
browser setupForAll] |
|
206 |
onDevice:aDisplayDevice. |
|
207 |
^ browser |
|
18614 | 208 |
|
209 |
"Modified (format): / 22-02-2019 / 10:15:20 / Claus Gittinger" |
|
4921 | 210 |
! |
211 |
||
203 | 212 |
openOnDevice:aDisplay |
213 |
"launch a standard browser on another display." |
|
214 |
||
2631 | 215 |
self == SystemBrowser ifFalse:[ |
216 |
^ super openOnDevice:aDisplay |
|
217 |
]. |
|
218 |
||
3519 | 219 |
^ self |
4921 | 220 |
openOn:Smalltalk |
221 |
label:(self classResources string:'System Browser') |
|
3519 | 222 |
onDevice:aDisplay |
203 | 223 |
|
224 |
"|d| |
|
225 |
||
226 |
d := XWorkstation new initializeFor:'porty:0'. |
|
227 |
d startDispatch. |
|
228 |
SystemBrowser openOnDevice:d |
|
229 |
" |
|
2818 | 230 |
! |
231 |
||
3573 | 232 |
openOnRemoteImageOnHost:aHostName port:portOrNil |
4921 | 233 |
|environment| |
3573 | 234 |
|
235 |
environment := RemoteImage onHost:aHostName port:portOrNil. |
|
4921 | 236 |
^ self |
237 |
openOn:environment |
|
238 |
label:(self classResources string:'RemoteImage Browser - %1' with:aHostName) |
|
3573 | 239 |
|
240 |
" |
|
241 |
SystemBrowser openOnRemoteImageOnHost:'funkfix' port:nil |
|
7998 | 242 |
SystemBrowser openOnRemoteImageOnHost:'192.168.8.1' port:nil |
3573 | 243 |
" |
244 |
! |
|
245 |
||
2818 | 246 |
openOnSnapShotImage:anImageFileName |
4921 | 247 |
|environment| |
2818 | 248 |
|
249 |
environment := SnapShotImage for:anImageFileName. |
|
4921 | 250 |
^ self |
251 |
openOn:environment |
|
252 |
label:(self classResources string:'Image Browser - %1' with:anImageFileName asFilename baseName) |
|
2818 | 253 |
|
254 |
" |
|
2822
8127e7726fdd
changes for environment browsing
Claus Gittinger <cg@exept.de>
parents:
2818
diff
changeset
|
255 |
SystemBrowser openOnSnapShotImage:('/tmp/stmeas.img') |
2824 | 256 |
" |
257 |
! ! |
|
36 | 258 |
|
4909 | 259 |
!SystemBrowser class methodsFor:'Compatibility-ST80'! |
1356 | 260 |
|
261 |
newOnClass:aClass |
|
262 |
^ self browseClass:aClass |
|
263 |
||
264 |
"Created: / 27.10.1997 / 20:10:39 / cg" |
|
265 |
! ! |
|
266 |
||
4909 | 267 |
!SystemBrowser class methodsFor:'accessing-history'! |
3131
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
268 |
|
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
269 |
addToHistory:aClass selector:aSelectorOrNil |
3679 | 270 |
|newEntry oldEntry classHistory| |
3131
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
271 |
|
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
272 |
(newEntry := self historyEntryForClass:aClass selector:aSelectorOrNil) isNil ifTrue:[^ self]. |
3679 | 273 |
classHistory := self classHistory. |
274 |
||
10173
ed7cc5e574cb
comment/format in: #addToHistory:selector:
Claus Gittinger <cg@exept.de>
parents:
10048
diff
changeset
|
275 |
oldEntry := classHistory detect:[:entry | (entry className = newEntry className) |
ed7cc5e574cb
comment/format in: #addToHistory:selector:
Claus Gittinger <cg@exept.de>
parents:
10048
diff
changeset
|
276 |
"and:[entry selector = newEntry selector]"] ifNone:nil. |
3679 | 277 |
oldEntry notNil ifTrue:[ |
278 |
classHistory removeIdentical:oldEntry. |
|
3131
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
279 |
]. |
3679 | 280 |
classHistory addFirst:newEntry. |
281 |
classHistory size > self visitedHistoryMaxSize ifTrue:[ |
|
282 |
classHistory removeLast |
|
3131
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
283 |
]. |
7524
0257265ae6b7
do not make dependent on the history-list;
Claus Gittinger <cg@exept.de>
parents:
7395
diff
changeset
|
284 |
SystemBrowser changed:#visitedClassHistory with:classHistory. |
0257265ae6b7
do not make dependent on the history-list;
Claus Gittinger <cg@exept.de>
parents:
7395
diff
changeset
|
285 |
|
10173
ed7cc5e574cb
comment/format in: #addToHistory:selector:
Claus Gittinger <cg@exept.de>
parents:
10048
diff
changeset
|
286 |
"Modified: / 05-07-2011 / 16:49:57 / cg" |
3131
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
287 |
! |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
288 |
|
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
289 |
checkClassHistory |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
290 |
"checks the class history for non-existing classes" |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
291 |
|
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
292 |
"/ reverse, since we might modify while enumerating |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
293 |
self classHistory reverseDo:[:histEntry| |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
294 |
(Smalltalk at: (histEntry className) asSymbol) isBehavior |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
295 |
ifFalse:[ |
10346
560fea0fd857
changed: #checkClassHistory
Claus Gittinger <cg@exept.de>
parents:
10327
diff
changeset
|
296 |
self classHistory removeIdentical: histEntry |
3131
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
297 |
] |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
298 |
] |
10346
560fea0fd857
changed: #checkClassHistory
Claus Gittinger <cg@exept.de>
parents:
10327
diff
changeset
|
299 |
|
560fea0fd857
changed: #checkClassHistory
Claus Gittinger <cg@exept.de>
parents:
10327
diff
changeset
|
300 |
"Modified: / 20-07-2011 / 11:59:22 / cg" |
3131
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
301 |
! |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
302 |
|
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
303 |
classHistory |
3679 | 304 |
ClassHistory isNil ifTrue:[ |
305 |
ClassHistory := List new |
|
306 |
]. |
|
307 |
^ ClassHistory |
|
3131
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
308 |
! |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
309 |
|
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
310 |
classHistory:newCollection |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
311 |
ClassHistory := newCollection |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
312 |
! |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
313 |
|
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
314 |
emptyClassHistory |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
315 |
"removes all class history entries" |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
316 |
|
7524
0257265ae6b7
do not make dependent on the history-list;
Claus Gittinger <cg@exept.de>
parents:
7395
diff
changeset
|
317 |
|classHistory| |
0257265ae6b7
do not make dependent on the history-list;
Claus Gittinger <cg@exept.de>
parents:
7395
diff
changeset
|
318 |
|
0257265ae6b7
do not make dependent on the history-list;
Claus Gittinger <cg@exept.de>
parents:
7395
diff
changeset
|
319 |
classHistory := self classHistory. |
0257265ae6b7
do not make dependent on the history-list;
Claus Gittinger <cg@exept.de>
parents:
7395
diff
changeset
|
320 |
classHistory removeAll. |
0257265ae6b7
do not make dependent on the history-list;
Claus Gittinger <cg@exept.de>
parents:
7395
diff
changeset
|
321 |
SystemBrowser changed:#visitedClassHistory with:classHistory. |
0257265ae6b7
do not make dependent on the history-list;
Claus Gittinger <cg@exept.de>
parents:
7395
diff
changeset
|
322 |
|
0257265ae6b7
do not make dependent on the history-list;
Claus Gittinger <cg@exept.de>
parents:
7395
diff
changeset
|
323 |
"Modified: / 20-11-2006 / 12:29:42 / cg" |
3131
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
324 |
! |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
325 |
|
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
326 |
historyEntryForClass:aClass selector:aSelectorOrNil |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
327 |
|newEntry meta cls| |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
328 |
|
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
329 |
aClass isBehavior ifFalse:[^ nil]. |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
330 |
|
3151 | 331 |
(meta := aClass isMeta) ifTrue:[ |
3131
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
332 |
cls := aClass theNonMetaclass. |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
333 |
] ifFalse:[ |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
334 |
cls := aClass |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
335 |
]. |
3151 | 336 |
newEntry := BrowserHistoryEntry new. |
337 |
newEntry |
|
338 |
className:cls name |
|
339 |
meta:meta |
|
340 |
selector:aSelectorOrNil. |
|
3131
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
341 |
^ newEntry |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
342 |
|
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
343 |
"Modified: / 24.2.2000 / 18:03:52 / cg" |
9189
9f57319e21ca
added: #visitedClassNamesHistory
Claus Gittinger <cg@exept.de>
parents:
9157
diff
changeset
|
344 |
! |
9f57319e21ca
added: #visitedClassNamesHistory
Claus Gittinger <cg@exept.de>
parents:
9157
diff
changeset
|
345 |
|
11271 | 346 |
lastSearchPatterns |
347 |
^ LastSearchPatterns |
|
348 |
! |
|
349 |
||
350 |
rememberSearchPattern:aString |
|
351 |
LastSearchPatterns isNil ifTrue:[ |
|
352 |
LastSearchPatterns := OrderedCollection new. |
|
353 |
]. |
|
354 |
(LastSearchPatterns includes:aString) ifTrue:[ |
|
355 |
LastSearchPatterns remove:aString. |
|
356 |
] ifFalse:[ |
|
357 |
LastSearchPatterns size > 20 ifTrue:[ |
|
358 |
LastSearchPatterns removeFirst |
|
359 |
] |
|
360 |
]. |
|
361 |
LastSearchPatterns addFirst:aString. |
|
362 |
||
363 |
"Modified: / 24-11-2010 / 12:51:31 / cg" |
|
364 |
"Created: / 14-02-2012 / 14:00:24 / cg" |
|
365 |
! |
|
366 |
||
9189
9f57319e21ca
added: #visitedClassNamesHistory
Claus Gittinger <cg@exept.de>
parents:
9157
diff
changeset
|
367 |
visitedClassNamesHistory |
9f57319e21ca
added: #visitedClassNamesHistory
Claus Gittinger <cg@exept.de>
parents:
9157
diff
changeset
|
368 |
^ self classHistory |
9f57319e21ca
added: #visitedClassNamesHistory
Claus Gittinger <cg@exept.de>
parents:
9157
diff
changeset
|
369 |
collect:[:e | e className] |
9f57319e21ca
added: #visitedClassNamesHistory
Claus Gittinger <cg@exept.de>
parents:
9157
diff
changeset
|
370 |
thenSelect:[:nm | nm notEmptyOrNil] |
13028 | 371 |
|
372 |
" |
|
373 |
Tools::NewSystemBrowser visitedClassNamesHistory |
|
374 |
" |
|
3131
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
375 |
! ! |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
376 |
|
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
377 |
!SystemBrowser class methodsFor:'defaults'! |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
378 |
|
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
379 |
classHistoryMaxLevels |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
380 |
^ 3 |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
381 |
! |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
382 |
|
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
383 |
classHistoryMaxSize |
12954 | 384 |
"returns maximum size of the visited class history" |
385 |
||
386 |
Screen current height < 768 ifTrue:[ |
|
387 |
^ 15 |
|
388 |
]. |
|
389 |
^ 20 "/ 15 |
|
390 |
||
391 |
"Modified: / 10.2.2000 / 14:07:07 / cg" |
|
3131
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
392 |
! |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
393 |
|
15831 | 394 |
default |
395 |
"convenient getter for the user's preference. |
|
396 |
Returns his choice of browser class" |
|
397 |
||
15940 | 398 |
^ UserPreferences systemBrowserClass |
15831 | 399 |
|
400 |
" |
|
401 |
SystemBrowser default open |
|
402 |
" |
|
403 |
! |
|
404 |
||
16847 | 405 |
largeLabelFont |
406 |
^ Label defaultFont scaled:1.2. |
|
407 |
! |
|
408 |
||
3549 | 409 |
methodTemplate |
8877 | 410 |
"return a method definition template string or nil" |
411 |
||
412 |
^ SmalltalkLanguage instance methodTemplate |
|
3549 | 413 |
! |
414 |
||
3131
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
415 |
visitedHistoryMaxSize |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
416 |
"the maximum number of remembered visited-class-history entries" |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
417 |
|
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
418 |
^ 15 |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
419 |
! ! |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
420 |
|
4909 | 421 |
!SystemBrowser class methodsFor:'defaults-presentation'! |
3240
34f017469465
allow for some colors to be parametrized (Timos red-green blindness)
Claus Gittinger <cg@exept.de>
parents:
3221
diff
changeset
|
422 |
|
3352 | 423 |
emphasisForChangedCode |
4499 | 424 |
^ UserPreferences current emphasisForChangedCode. |
3352 | 425 |
|
426 |
" |
|
427 |
EmphasisForChangedCode := #underwave |
|
4112 | 428 |
EmphasisForChangedCode := #color->Color blue |
3352 | 429 |
EmphasisForChangedCode := #color->Color red lightened lightened lightened |
430 |
" |
|
431 |
||
432 |
"Created: / 31.10.2001 / 10:15:33 / cg" |
|
433 |
! |
|
434 |
||
435 |
emphasisForChangedCode:anEmphasis |
|
436 |
EmphasisForChangedCode := anEmphasis |
|
437 |
||
438 |
" |
|
439 |
self emphasisForChangedCode:#underwave |
|
440 |
self emphasisForChangedCode:(#color->Color red lightened lightened lightened) |
|
441 |
" |
|
442 |
||
443 |
"Created: / 31.10.2001 / 10:15:44 / cg" |
|
444 |
! |
|
445 |
||
3240
34f017469465
allow for some colors to be parametrized (Timos red-green blindness)
Claus Gittinger <cg@exept.de>
parents:
3221
diff
changeset
|
446 |
emphasisForDifferentPackage |
4499 | 447 |
^ UserPreferences current emphasisForDifferentPackage. |
3240
34f017469465
allow for some colors to be parametrized (Timos red-green blindness)
Claus Gittinger <cg@exept.de>
parents:
3221
diff
changeset
|
448 |
|
34f017469465
allow for some colors to be parametrized (Timos red-green blindness)
Claus Gittinger <cg@exept.de>
parents:
3221
diff
changeset
|
449 |
" |
3352 | 450 |
EmphasisForDifferentPackage := nil. |
3240
34f017469465
allow for some colors to be parametrized (Timos red-green blindness)
Claus Gittinger <cg@exept.de>
parents:
3221
diff
changeset
|
451 |
EmphasisForDifferentPackage := #underwave |
34f017469465
allow for some colors to be parametrized (Timos red-green blindness)
Claus Gittinger <cg@exept.de>
parents:
3221
diff
changeset
|
452 |
EmphasisForDifferentPackage := #color->Color red lightened lightened lightened |
34f017469465
allow for some colors to be parametrized (Timos red-green blindness)
Claus Gittinger <cg@exept.de>
parents:
3221
diff
changeset
|
453 |
" |
3352 | 454 |
|
455 |
"Modified: / 31.10.2001 / 10:47:25 / cg" |
|
3240
34f017469465
allow for some colors to be parametrized (Timos red-green blindness)
Claus Gittinger <cg@exept.de>
parents:
3221
diff
changeset
|
456 |
! |
34f017469465
allow for some colors to be parametrized (Timos red-green blindness)
Claus Gittinger <cg@exept.de>
parents:
3221
diff
changeset
|
457 |
|
3241 | 458 |
emphasisForDifferentPackage:anEmphasis |
459 |
EmphasisForDifferentPackage := anEmphasis |
|
460 |
||
461 |
" |
|
462 |
self emphasisForDifferentPackage:#underwave |
|
463 |
self emphasisForDifferentPackage:(#color->Color red lightened lightened lightened) |
|
464 |
" |
|
465 |
! |
|
466 |
||
3240
34f017469465
allow for some colors to be parametrized (Timos red-green blindness)
Claus Gittinger <cg@exept.de>
parents:
3221
diff
changeset
|
467 |
emphasisForModifiedBuffer |
4499 | 468 |
^ UserPreferences current emphasisForModifiedBuffer. |
3240
34f017469465
allow for some colors to be parametrized (Timos red-green blindness)
Claus Gittinger <cg@exept.de>
parents:
3221
diff
changeset
|
469 |
! |
34f017469465
allow for some colors to be parametrized (Timos red-green blindness)
Claus Gittinger <cg@exept.de>
parents:
3221
diff
changeset
|
470 |
|
3241 | 471 |
emphasisForModifiedBuffer:anEmphasis |
472 |
EmphasisForModifiedBuffer := anEmphasis |
|
473 |
! |
|
474 |
||
3240
34f017469465
allow for some colors to be parametrized (Timos red-green blindness)
Claus Gittinger <cg@exept.de>
parents:
3221
diff
changeset
|
475 |
emphasisForObsoleteCode |
4499 | 476 |
^ UserPreferences current emphasisForObsoleteCode. |
3240
34f017469465
allow for some colors to be parametrized (Timos red-green blindness)
Claus Gittinger <cg@exept.de>
parents:
3221
diff
changeset
|
477 |
! |
34f017469465
allow for some colors to be parametrized (Timos red-green blindness)
Claus Gittinger <cg@exept.de>
parents:
3221
diff
changeset
|
478 |
|
3241 | 479 |
emphasisForObsoleteCode:anEmphasis |
480 |
EmphasisForObsoleteCode := anEmphasis |
|
481 |
! |
|
482 |
||
3240
34f017469465
allow for some colors to be parametrized (Timos red-green blindness)
Claus Gittinger <cg@exept.de>
parents:
3221
diff
changeset
|
483 |
emphasisForReadVariable |
4499 | 484 |
^ UserPreferences current emphasisForReadVariable. |
3240
34f017469465
allow for some colors to be parametrized (Timos red-green blindness)
Claus Gittinger <cg@exept.de>
parents:
3221
diff
changeset
|
485 |
|
34f017469465
allow for some colors to be parametrized (Timos red-green blindness)
Claus Gittinger <cg@exept.de>
parents:
3221
diff
changeset
|
486 |
" |
34f017469465
allow for some colors to be parametrized (Timos red-green blindness)
Claus Gittinger <cg@exept.de>
parents:
3221
diff
changeset
|
487 |
EmphasisForReadVariable := #underline |
34f017469465
allow for some colors to be parametrized (Timos red-green blindness)
Claus Gittinger <cg@exept.de>
parents:
3221
diff
changeset
|
488 |
EmphasisForReadVariable := Array with:#underline with:#underlineColor->Color yellow |
34f017469465
allow for some colors to be parametrized (Timos red-green blindness)
Claus Gittinger <cg@exept.de>
parents:
3221
diff
changeset
|
489 |
" |
34f017469465
allow for some colors to be parametrized (Timos red-green blindness)
Claus Gittinger <cg@exept.de>
parents:
3221
diff
changeset
|
490 |
! |
34f017469465
allow for some colors to be parametrized (Timos red-green blindness)
Claus Gittinger <cg@exept.de>
parents:
3221
diff
changeset
|
491 |
|
3241 | 492 |
emphasisForReadVariable:anEmphasis |
493 |
EmphasisForReadVariable := anEmphasis |
|
494 |
||
495 |
" |
|
496 |
self emphasisForReadVariable:#underline |
|
497 |
self emphasisForReadVariable:(Array with:#underline with:#underlineColor->Color yellow) |
|
498 |
" |
|
499 |
! |
|
500 |
||
3240
34f017469465
allow for some colors to be parametrized (Timos red-green blindness)
Claus Gittinger <cg@exept.de>
parents:
3221
diff
changeset
|
501 |
emphasisForWrittenVariable |
4499 | 502 |
^ UserPreferences current emphasisForWrittenVariable. |
3240
34f017469465
allow for some colors to be parametrized (Timos red-green blindness)
Claus Gittinger <cg@exept.de>
parents:
3221
diff
changeset
|
503 |
|
34f017469465
allow for some colors to be parametrized (Timos red-green blindness)
Claus Gittinger <cg@exept.de>
parents:
3221
diff
changeset
|
504 |
" |
34f017469465
allow for some colors to be parametrized (Timos red-green blindness)
Claus Gittinger <cg@exept.de>
parents:
3221
diff
changeset
|
505 |
EmphasisForWrittenVariable := #underline |
34f017469465
allow for some colors to be parametrized (Timos red-green blindness)
Claus Gittinger <cg@exept.de>
parents:
3221
diff
changeset
|
506 |
EmphasisForWrittenVariable := Array with:#underline with:#underlineColor->Color red lightened |
34f017469465
allow for some colors to be parametrized (Timos red-green blindness)
Claus Gittinger <cg@exept.de>
parents:
3221
diff
changeset
|
507 |
" |
3241 | 508 |
! |
509 |
||
510 |
emphasisForWrittenVariable:anEmphasis |
|
511 |
EmphasisForWrittenVariable := anEmphasis |
|
512 |
||
513 |
" |
|
514 |
self emphasisForWrittenVariable:#underline |
|
515 |
self emphasisForWrittenVariable:(Array with:#underline with:#underlineColor->Color red lightened) |
|
516 |
" |
|
6901 | 517 |
! |
518 |
||
519 |
iconForClass:aClass |
|
14103 | 520 |
"ask the class for its browser symbol; |
521 |
that's a key/selector in the ToolbarIconLibrary" |
|
6901 | 522 |
|
7827 | 523 |
aClass withAllSuperclassesDo:[:eachCls | |
15540 | 524 |
|icon iconSymbol | |
525 |
||
15565 | 526 |
icon := [ eachCls toolListIcon ] on:Error do:[]. |
15540 | 527 |
icon notNil ifTrue:[^ icon ]. |
7827 | 528 |
|
529 |
iconSymbol := eachCls iconInBrowserSymbol. |
|
530 |
iconSymbol notNil ifTrue:[ |
|
531 |
^ ToolbarIconLibrary perform:iconSymbol |
|
532 |
]. |
|
533 |
]. |
|
15944 | 534 |
(aClass isUtilityClass) ifTrue:[ |
535 |
^ ToolbarIconLibrary utilityClassIcon |
|
536 |
]. |
|
537 |
(aClass isAbstract) ifTrue:[ |
|
538 |
^ ToolbarIconLibrary abstractClassIcon |
|
539 |
]. |
|
7827 | 540 |
|
6901 | 541 |
^ nil |
542 |
||
543 |
"Created: / 17-08-2006 / 09:11:27 / cg" |
|
7827 | 544 |
"Modified: / 20-07-2007 / 09:01:43 / cg" |
6901 | 545 |
! |
546 |
||
547 |
resourceIconForMethod:aMethod |
|
548 |
|resources| |
|
549 |
||
550 |
(resources := aMethod resources) isNil ifTrue:[^ nil]. |
|
551 |
||
18302 | 552 |
(resources includesKey:#todo) ifTrue:[ |
553 |
^ ToolbarIconLibrary underConstructionIcon11x11 |
|
554 |
]. |
|
6901 | 555 |
(resources includesKey:#obsolete) ifTrue:[ |
18411 | 556 |
^ self obsoleteMethodIcon |
557 |
]. |
|
558 |
(resources includesKey:#deprecated) ifTrue:[ |
|
6901 | 559 |
^ self deprecatedMethodIcon |
560 |
]. |
|
561 |
(resources includesKey:#canvas) ifTrue:[ |
|
562 |
^ self canvasIcon |
|
563 |
]. |
|
564 |
(resources includesKey:#menu) ifTrue:[ |
|
565 |
^ self menuIcon |
|
566 |
]. |
|
567 |
(resources includesKey:#image) ifTrue:[ |
|
568 |
^ self imageIcon |
|
569 |
]. |
|
570 |
(resources includesKey:#fileImage) ifTrue:[ |
|
571 |
^ self fileImageIcon |
|
572 |
]. |
|
573 |
(resources includesKey:#programImage) ifTrue:[ |
|
574 |
^ self programImageIcon |
|
575 |
]. |
|
576 |
(resources includesKey:#help) ifTrue:[ |
|
577 |
^ self helpIcon |
|
578 |
]. |
|
579 |
(resources includesKey:#programMenu) ifTrue:[ |
|
580 |
^ self programMenuIcon |
|
581 |
]. |
|
582 |
(resources includesKey:#tableColumns) ifTrue:[ |
|
583 |
^ self tableColumnsIcon |
|
584 |
]. |
|
585 |
(resources includesKey:#tabList) ifTrue:[ |
|
586 |
^ self tabListIcon |
|
587 |
]. |
|
588 |
(resources includesKey:#hierarchicalList) ifTrue:[ |
|
589 |
^ self hierarchicalListIcon |
|
590 |
]. |
|
591 |
(resources includesKey:#programImage) ifTrue:[ |
|
592 |
^ self programImageIcon |
|
593 |
]. |
|
594 |
^ nil |
|
595 |
||
596 |
"Created: / 17-08-2006 / 09:08:11 / cg" |
|
18411 | 597 |
"Modified: / 21-09-2018 / 15:34:34 / Claus Gittinger" |
3240
34f017469465
allow for some colors to be parametrized (Timos red-green blindness)
Claus Gittinger <cg@exept.de>
parents:
3221
diff
changeset
|
598 |
! ! |
34f017469465
allow for some colors to be parametrized (Timos red-green blindness)
Claus Gittinger <cg@exept.de>
parents:
3221
diff
changeset
|
599 |
|
8702 | 600 |
!SystemBrowser class methodsFor:'dialogs'! |
601 |
||
602 |
askForClassNameMatching:matchStringArg inEnvironment:anEnvironmentOrClassOrNil for:aBrowserOrNil |
|
603 |
"open a dialog to ask for a class name. |
|
604 |
env is either a nameSpace or a class (to ask for a private class)" |
|
605 |
||
606 |
|classNames caselessMatchingNames |
|
607 |
substringMatchingNames caselessSubstringMatchingNames |
|
608 |
caselessWithoutPrefixSubstringMatchingNames |
|
609 |
lcMatchString subMatch lcSubMatch box className |
|
610 |
needSearch cls env searchBlock searchBlock2 |
|
611 |
idx pref aMatchString allNames sortedBySpellingDistance msg resources| |
|
612 |
||
613 |
resources := self classResources. |
|
614 |
env := anEnvironmentOrClassOrNil ? Smalltalk. |
|
615 |
||
616 |
aMatchString := matchStringArg. |
|
617 |
||
618 |
"/ try to limit search to a namespace (but only if nameSpace is not a matchCharacter) |
|
619 |
||
620 |
(aMatchString includesString:'::') ifTrue:[ |
|
621 |
"/ pref := aMatchString upTo:$:. |
|
622 |
idx := aMatchString lastIndexOf:$:. |
|
623 |
pref := aMatchString copyTo:idx-2. |
|
624 |
pref includesMatchCharacters ifTrue:[ |
|
625 |
"/ search all in Smalltalk |
|
626 |
] ifFalse:[ |
|
627 |
cls := Smalltalk at:pref asSymbol ifAbsent:nil. |
|
628 |
(cls notNil and:[cls isBehavior]) ifTrue:[ |
|
629 |
env := cls. |
|
630 |
aMatchString := aMatchString copyFrom:pref size + 1 + 2. |
|
631 |
]. |
|
632 |
]. |
|
633 |
]. |
|
634 |
||
635 |
classNames := Set new. |
|
636 |
caselessMatchingNames := Set new. |
|
637 |
substringMatchingNames := Set new. |
|
638 |
caselessSubstringMatchingNames := Set new. |
|
639 |
caselessWithoutPrefixSubstringMatchingNames := Set new. |
|
640 |
||
641 |
lcMatchString := aMatchString asLowercase. |
|
642 |
needSearch := true. |
|
643 |
aMatchString includesMatchCharacters ifFalse:[ |
|
644 |
subMatch := '*' , aMatchString , '*'. |
|
645 |
lcSubMatch := subMatch asLowercase. |
|
646 |
||
647 |
"/ if the name is already a good one, avoid the expensive search |
|
648 |
className := aMatchString asSymbolIfInterned. |
|
649 |
className notNil ifTrue:[ |
|
650 |
env isNameSpace ifTrue:[ |
|
651 |
cls := env at:className ifAbsent:nil. |
|
652 |
] ifFalse:[ |
|
653 |
cls := env privateClassesAt:className. |
|
654 |
]. |
|
655 |
(cls notNil and:[cls isBehavior]) ifTrue:[ |
|
656 |
needSearch := false. |
|
657 |
] |
|
658 |
] |
|
659 |
]. |
|
660 |
||
661 |
needSearch ifTrue:[ |
|
662 |
searchBlock := [:aClass | |
|
663 |
|thisName| |
|
664 |
||
665 |
"/ use dotted names for java |
|
666 |
aClass isJavaClass ifTrue:[ |
|
667 |
thisName := aClass displayString. "/ fullName copyReplaceAll:$/ with:$. |
|
668 |
] ifFalse:[ |
|
669 |
thisName := aClass name |
|
670 |
]. |
|
671 |
(lcMatchString match:aClass name asLowercase) ifTrue:[ |
|
672 |
caselessWithoutPrefixSubstringMatchingNames add:thisName |
|
673 |
]. |
|
674 |
aClass nameWithoutPrefix ~= aClass name ifTrue:[ |
|
675 |
(lcMatchString match:aClass nameWithoutPrefix asLowercase) ifTrue:[ |
|
676 |
caselessWithoutPrefixSubstringMatchingNames add:thisName |
|
677 |
]. |
|
678 |
]. |
|
679 |
||
680 |
(aMatchString match:thisName) ifTrue:[ |
|
681 |
classNames add:thisName |
|
682 |
] ifFalse:[ |
|
683 |
(lcMatchString match:thisName asLowercase) ifTrue:[ |
|
684 |
caselessMatchingNames add:thisName |
|
685 |
] ifFalse:[ |
|
686 |
subMatch notNil ifTrue:[ |
|
687 |
(subMatch match:thisName) ifTrue:[ |
|
688 |
substringMatchingNames add:thisName |
|
689 |
] ifFalse:[ |
|
690 |
(lcSubMatch match:thisName asLowercase) ifTrue:[ |
|
691 |
caselessSubstringMatchingNames add:thisName |
|
692 |
] |
|
693 |
] |
|
694 |
] |
|
695 |
] |
|
696 |
] |
|
697 |
]. |
|
698 |
||
699 |
(env == Smalltalk or:[env isNameSpace]) ifTrue:[ |
|
700 |
env allClassesDo:searchBlock |
|
701 |
] ifFalse:[ |
|
702 |
env allPrivateClasses do:searchBlock |
|
703 |
]. |
|
704 |
||
705 |
sortedBySpellingDistance := false. |
|
706 |
"/ if nothing matched - try caseless matches |
|
707 |
classNames size == 0 ifTrue:[ |
|
708 |
classNames := caselessMatchingNames. |
|
709 |
||
710 |
"/ if nothing matched - try substring matches |
|
711 |
classNames size == 0 ifTrue:[ |
|
8704 | 712 |
aMatchString isUppercaseFirst ifTrue:[ |
8702 | 713 |
classNames := substringMatchingNames. |
714 |
]. |
|
715 |
"/ if nothing matched - try caseless substring matches |
|
716 |
classNames size == 0 ifTrue:[ |
|
717 |
classNames := caselessSubstringMatchingNames. |
|
718 |
||
719 |
"/ if nothing matched - try best fitting |
|
720 |
classNames size == 0 ifTrue:[ |
|
721 |
aMatchString includesMatchCharacters ifFalse:[ |
|
722 |
allNames := SortedCollection sortBlock:[:a :b | a value > b value]. |
|
723 |
searchBlock2 := |
|
724 |
[:aClass | |
|
725 |
|thisName dist| |
|
726 |
||
727 |
aClass isJavaClass ifTrue:[ |
|
728 |
thisName := aClass displayString. "/ fullName copyReplaceAll:$/ with:$. |
|
729 |
] ifFalse:[ |
|
730 |
thisName := aClass name |
|
731 |
]. |
|
732 |
dist := thisName asLowercase spellAgainst:lcMatchString. |
|
733 |
(thisName asLowercase startsWith:lcMatchString) ifTrue:[ |
|
734 |
dist := dist + (thisName size * 10). |
|
735 |
]. |
|
736 |
allNames add:(thisName -> dist). |
|
737 |
]. |
|
738 |
(env == Smalltalk or:[env isNameSpace]) ifTrue:[ |
|
739 |
env allClassesDo:searchBlock2 |
|
740 |
] ifFalse:[ |
|
741 |
env allPrivateClasses do:searchBlock2 |
|
742 |
]. |
|
743 |
classNames := (allNames copyTo:(allNames size min:40)) collect:[:each | each key]. |
|
744 |
sortedBySpellingDistance := true. |
|
745 |
] |
|
746 |
] |
|
747 |
] |
|
748 |
] |
|
749 |
]. |
|
750 |
||
751 |
(classNames size == 0) ifTrue:[^ nil]. |
|
752 |
(classNames size == 1) ifTrue:[ |
|
753 |
className := classNames first |
|
754 |
] ifFalse:[ |
|
755 |
|browseButton| |
|
756 |
||
757 |
sortedBySpellingDistance ifFalse:[ |
|
758 |
classNames := classNames asArray sort. |
|
759 |
]. |
|
760 |
||
761 |
aMatchString includesMatchCharacters ifTrue:[ |
|
18149 | 762 |
msg := 'Class names matching or similar to "%1"\\Select or enter name of class to switch to:' |
8702 | 763 |
] ifFalse:[ |
18149 | 764 |
msg := 'Class names containing or similar to "%1"\\Select or enter name of class to switch to:' |
8702 | 765 |
]. |
766 |
||
767 |
box := self listBoxTitle:(resources string:msg with:matchStringArg) withCRs |
|
768 |
okText:'OK' |
|
769 |
list:classNames. |
|
770 |
caselessWithoutPrefixSubstringMatchingNames notEmpty ifTrue:[ |
|
771 |
box initialText:(caselessWithoutPrefixSubstringMatchingNames first). |
|
772 |
]. |
|
773 |
box action:[:aString | className := aString]. |
|
774 |
||
775 |
browseButton := Button label:(resources string:'Browse All'). |
|
776 |
browseButton action:[ |
|
777 |
|classes title| |
|
778 |
||
18149 | 779 |
title := resources string:'Class Names Matching or Similar to "%1"' with:matchStringArg. |
8702 | 780 |
classes := classNames collect:[:nm | Smalltalk classNamed:nm]. |
781 |
aBrowserOrNil isNil ifTrue:[ |
|
782 |
SystemBrowser |
|
783 |
browseClasses:classes |
|
784 |
label:title. |
|
785 |
] ifFalse:[ |
|
786 |
aBrowserOrNil |
|
787 |
spawnClassBrowserFor:classes |
|
788 |
label:title |
|
789 |
in:#newBrowser |
|
790 |
select:false. |
|
791 |
]. |
|
13365 | 792 |
box hide. |
793 |
box closeRequest |
|
8702 | 794 |
]. |
795 |
box addButton:browseButton before:box okButton. |
|
14502 | 796 |
|
797 |
aMatchString isLowercaseFirst ifTrue:[ |
|
798 |
|browseImplementorsButton| |
|
799 |
||
800 |
browseImplementorsButton := Button label:(resources string:'Implementors'). |
|
801 |
browseImplementorsButton |
|
802 |
action:[ |
|
803 |
aBrowserOrNil isNil ifTrue:[ |
|
804 |
SystemBrowser browseImplementorsMatching:aMatchString |
|
805 |
] ifFalse:[ |
|
806 |
aBrowserOrNil |
|
807 |
spawnMethodImplementorsBrowserFor:{ aMatchString } match:true in:#newBrowser. |
|
808 |
]. |
|
809 |
box hide. |
|
810 |
box closeRequest |
|
811 |
]. |
|
812 |
box addButton:browseImplementorsButton before:box okButton. |
|
813 |
]. |
|
814 |
||
9157
c8166dbf5a5a
changed: #askForClassNameMatching:inEnvironment:for:
Claus Gittinger <cg@exept.de>
parents:
9065
diff
changeset
|
815 |
box minExtent:300@250. |
8702 | 816 |
|
817 |
box open. |
|
818 |
(box accepted not or:[className isNil]) ifTrue:[ "/ cancel |
|
819 |
^ nil |
|
820 |
] |
|
821 |
]. |
|
822 |
]. |
|
823 |
||
824 |
className notNil ifTrue:[ |
|
825 |
"/ use slashed javaName for search. |
|
14653 | 826 |
className := className copyReplaceAll:$. with:$/ ifNone:className. |
8702 | 827 |
]. |
828 |
||
829 |
"/ pref notNil ifTrue:[ |
|
830 |
"/ ^ pref , '::' , className |
|
831 |
"/ ]. |
|
832 |
^ className |
|
833 |
||
834 |
"Modified: / 16-10-2006 / 11:36:20 / cg" |
|
18149 | 835 |
"Modified: / 24-05-2018 / 08:49:02 / Claus Gittinger" |
8702 | 836 |
! |
837 |
||
838 |
listBoxTitle:title okText:okText list:aList |
|
839 |
"convenient method: setup a listBox & return it" |
|
840 |
||
841 |
|box resources| |
|
842 |
||
843 |
resources := self classResources. |
|
844 |
||
845 |
box := ListSelectionBox |
|
846 |
title:(resources string:title) |
|
847 |
okText:(resources string:okText) |
|
848 |
action:nil. |
|
849 |
box list:aList. |
|
850 |
^ box |
|
13365 | 851 |
|
852 |
" |
|
853 |
(self listBoxTitle:'hello world' okText:'aaa' list:#(1 2 3 4)) open |
|
854 |
" |
|
8702 | 855 |
! ! |
856 |
||
2692 | 857 |
!SystemBrowser class methodsFor:'image specs'! |
858 |
||
2748 | 859 |
abstractMethodIcon |
860 |
<resource: #programImage> |
|
861 |
||
18294 | 862 |
^ ToolbarIconLibrary padLockGrayMiniIcon |
863 |
||
864 |
"Modified: / 28-07-2018 / 10:00:47 / Claus Gittinger" |
|
2748 | 865 |
! |
866 |
||
3813 | 867 |
addBreakPointIcon |
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
868 |
<resource: #image> |
3813 | 869 |
"This resource specification was automatically generated |
870 |
by the ImageEditor of ST/X." |
|
871 |
"Do not manually edit this!! If it is corrupted, |
|
872 |
the ImageEditor may not be able to read the specification." |
|
873 |
" |
|
874 |
self addBreakPointIcon inspect |
|
875 |
ImageEditor openOnClass:self andSelector:#addBreakPointIcon |
|
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
876 |
Icon flushCachedIcons" |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
877 |
|
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
878 |
^ Icon constantNamed:'SystemBrowser class addBreakPointIcon' |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
879 |
ifAbsentPut:[ |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
880 |
(Depth1Image new) |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
881 |
width:16; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
882 |
height:16; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
883 |
photometric:(#palette); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
884 |
bitsPerSample:(#( 1 )); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
885 |
samplesPerPixel:(1); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
886 |
bits:(ByteArray |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
887 |
fromPackedString:'@@@@@@@@@8@C @N@@8@A@@@@@P@C @D@@@@@@@@@@@@b'); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
888 |
colorMapFromArray:#[ 255 0 0 255 255 255 ]; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
889 |
mask:((ImageMask new) |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
890 |
width:16; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
891 |
height:16; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
892 |
bits:(ByteArray |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
893 |
fromPackedString:'@@@O8A?0O?!!??G?<_?1??G?<_?1??C?8G?@O8@@@@@@b'); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
894 |
yourself); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
895 |
yourself |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
896 |
] |
3813 | 897 |
! |
898 |
||
899 |
addBreakPointIcon2 |
|
18283 | 900 |
<resource: #programImage> |
901 |
||
902 |
^ ToolbarIconLibrary addBreakPointIcon2 |
|
903 |
||
904 |
"Modified: / 28-07-2018 / 09:36:24 / Claus Gittinger" |
|
3813 | 905 |
! |
906 |
||
4341 | 907 |
autoloadedClassIcon |
7827 | 908 |
<resource: #programImage> |
909 |
||
910 |
^ ToolbarIconLibrary autoloadedClassBrowserIcon |
|
911 |
||
912 |
"Modified: / 20-07-2007 / 09:15:37 / cg" |
|
4341 | 913 |
! |
914 |
||
12040 | 915 |
breakPointedIcon |
14106
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
916 |
<resource: #obsolete> |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
917 |
|
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
918 |
^ self lineBreakPointedIcon |
12504 | 919 |
"/ ^ self breakPointedIcon2 |
14106
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
920 |
|
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
921 |
"Modified: / 05-03-2014 / 10:26:19 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
12504 | 922 |
! |
923 |
||
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
924 |
canvasIcon |
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
925 |
<resource: #image> |
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
926 |
"This resource specification was automatically generated |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
927 |
by the ImageEditor of ST/X." |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
928 |
"Do not manually edit this!! If it is corrupted, |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
929 |
the ImageEditor may not be able to read the specification." |
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
930 |
" |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
931 |
ImageEditor openOnClass:self andSelector:#canvasIcon" |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
932 |
|
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
933 |
^ Icon constantNamed:'SystemBrowser class canvasIcon' |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
934 |
ifAbsentPut:[ |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
935 |
(Depth4Image new) |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
936 |
width:13; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
937 |
height:11; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
938 |
photometric:(#palette); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
939 |
bitsPerSample:(#( 4 )); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
940 |
samplesPerPixel:(1); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
941 |
bits:(ByteArray |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
942 |
fromPackedString:'@@@@@@@@@@.;.;.;.0@@@@@@@@@@C.;/C.;/@@9&XP9&XP@NY&DNY&D@C&Y!!C&Y!!@@9&XP9&XP@NY&DNY&D@C1DQC1DQ@@@@@@@@@@@b'); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
943 |
colorMapFromArray:#[ 0 0 0 255 255 255 255 0 0 0 255 0 0 0 255 0 255 255 255 255 0 255 0 255 127 0 0 0 127 0 0 0 127 0 127 127 127 127 0 127 0 127 127 127 127 170 170 170 ]; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
944 |
mask:((ImageMask new) |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
945 |
width:13; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
946 |
height:11; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
947 |
bits:(ByteArray fromPackedString:'??#?>O?8??#?>O?8??#?>O?8??#?>@@a'); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
948 |
yourself); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
949 |
yourself |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
950 |
] |
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
951 |
! |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
952 |
|
4143 | 953 |
containerClassIcon |
7827 | 954 |
<resource: #programImage> |
955 |
||
956 |
^ ToolbarIconLibrary containerClassBrowserIcon |
|
957 |
||
958 |
"Modified: / 20-07-2007 / 09:14:54 / cg" |
|
4143 | 959 |
! |
960 |
||
2692 | 961 |
defaultIcon |
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
962 |
<resource: #image> |
2692 | 963 |
"This resource specification was automatically generated |
964 |
by the ImageEditor of ST/X." |
|
965 |
"Do not manually edit this!! If it is corrupted, |
|
966 |
the ImageEditor may not be able to read the specification." |
|
967 |
" |
|
968 |
self defaultIcon inspect |
|
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
969 |
ImageEditor openOnClass:self andSelector:#defaultIcon" |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
970 |
|
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
971 |
^ Icon constantNamed:'SystemBrowser class defaultIcon' |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
972 |
ifAbsentPut:[ |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
973 |
(Depth4Image new) |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
974 |
width:28; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
975 |
height:28; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
976 |
photometric:(#palette); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
977 |
bitsPerSample:(#( 4 )); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
978 |
samplesPerPixel:(1); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
979 |
bits:(ByteArray |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
980 |
fromPackedString:' |
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
981 |
@@@@@@@@@@@@@@@@@@@FY&Y&Y&X0@@@@@@@@@@YDQDQDQB@@@@@@@@@@A$QDQDQDH@@@@@@@@@@CH"H"H"H @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@H@@@ |
3794 | 982 |
@@@@@@@@@@@@@@@ @@@@@@@@@@@@@@@@@B@@@@@@@@@@@@@@@@@@H@@@@@@@@@@@@@@@@@@@@@@@A&Y&Y&Y#@@@@@F@"H"HFDQDQDQH@@@@@@@@@@@L"H"H" |
983 |
H @@@@@ @@@@@@@@@@@@@@@@@B@@@@@@@@@@@@@@@@@@H@@@@@@@@@@@@@@@@@@@@@@@A&Y&Y&Y#@@@@@F@"H"HFUUUUUUH@@@@@@@@@@@L"H"H"H @@@@@@ |
|
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
984 |
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@H@@@@B@B@ @@H@@@@ @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ |
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
985 |
@@@@@@@@@@@@@@@@@@@@@@@@H@@@@@@@@@H@@ @@@@Hb'); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
986 |
colorMapFromArray:#[ 0 0 0 0 255 0 127 127 127 170 170 170 255 0 0 255 255 0 255 255 255 ]; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
987 |
mask:((ImageMask new) |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
988 |
width:28; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
989 |
height:28; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
990 |
bits:(ByteArray |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
991 |
fromPackedString:' |
3794 | 992 |
??0@@O?<@@C??@@@??0@@O?<@@C??@@@@ @@@@H@@@@B@@@@@ O?8@\C?>@G??? A0O?8@HC?>@B@@@@@ O?8@\C?>@G??? A0O?8@@C?>@@@@@@9O\7\IRT |
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
993 |
QDBD%DQ@!!OH''HHRQEABT$QPP99]7\@@a'); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
994 |
yourself); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
995 |
yourself |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
996 |
] |
2846 | 997 |
! |
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
998 |
|
5761
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
999 |
deprecatedMethodIcon |
18283 | 1000 |
<resource: #programImage> |
1001 |
||
18411 | 1002 |
^ ToolbarIconLibrary deprecatedMethodIcon |
1003 |
||
1004 |
"Modified: / 21-09-2018 / 15:30:48 / Claus Gittinger" |
|
5761
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
1005 |
! |
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
1006 |
|
16893 | 1007 |
disabledBreakpointIcon |
1008 |
<resource: #programImage> |
|
1009 |
||
1010 |
^ ToolbarIconLibrary breakpointDisabled9x9 |
|
1011 |
! |
|
1012 |
||
5761
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
1013 |
doNotEnterIcon |
18411 | 1014 |
<resource: #programImage> |
1015 |
||
1016 |
^ ToolbarIconLibrary doNotEnterIcon |
|
1017 |
||
1018 |
"Modified: / 21-09-2018 / 15:29:09 / Claus Gittinger" |
|
5761
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
1019 |
! |
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
1020 |
|
3354 | 1021 |
emptyIcon |
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1022 |
<resource: #image> |
3354 | 1023 |
"This resource specification was automatically generated |
1024 |
by the ImageEditor of ST/X." |
|
1025 |
"Do not manually edit this!! If it is corrupted, |
|
1026 |
the ImageEditor may not be able to read the specification." |
|
1027 |
" |
|
1028 |
self emptyIcon inspect |
|
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1029 |
ImageEditor openOnClass:self andSelector:#emptyIcon" |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1030 |
|
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1031 |
^ Icon constantNamed:'SystemBrowser class emptyIcon' |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1032 |
ifAbsentPut:[ |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1033 |
(Depth4Image new) |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1034 |
width:13; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1035 |
height:11; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1036 |
photometric:(#palette); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1037 |
bitsPerSample:(#( 4 )); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1038 |
samplesPerPixel:(1); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1039 |
bits:(ByteArray |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1040 |
fromPackedString:'@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@b'); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1041 |
colorMapFromArray:#[ 0 0 0 ]; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1042 |
mask:((ImageMask new) |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1043 |
width:13; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1044 |
height:11; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1045 |
bits:(ByteArray fromPackedString:'@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@a'); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1046 |
yourself); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1047 |
yourself |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1048 |
] |
3354 | 1049 |
|
1050 |
"Created: / 5.11.2001 / 09:39:54 / cg" |
|
1051 |
! |
|
1052 |
||
4143 | 1053 |
errorClassIcon |
7827 | 1054 |
<resource: #programImage> |
1055 |
||
1056 |
^ ToolbarIconLibrary errorClassBrowserIcon |
|
1057 |
||
1058 |
"Modified: / 20-07-2007 / 09:14:06 / cg" |
|
4143 | 1059 |
! |
1060 |
||
1061 |
exceptionClassIcon |
|
1062 |
"This resource specification was automatically generated |
|
1063 |
by the ImageEditor of ST/X." |
|
1064 |
||
1065 |
"Do not manually edit this!! If it is corrupted, |
|
1066 |
the ImageEditor may not be able to read the specification." |
|
1067 |
||
1068 |
" |
|
1069 |
self exceptionClassIcon inspect |
|
1070 |
ImageEditor openOnClass:self andSelector:#exceptionClassIcon |
|
1071 |
Icon flushCachedIcons |
|
1072 |
" |
|
1073 |
||
7827 | 1074 |
<resource: #programImage> |
1075 |
||
1076 |
^ ToolbarIconLibrary exceptionClassBrowserIcon |
|
1077 |
||
1078 |
"Modified: / 20-07-2007 / 09:13:18 / cg" |
|
4143 | 1079 |
! |
1080 |
||
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1081 |
fileImageIcon |
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1082 |
<resource: #image> |
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1083 |
"This resource specification was automatically generated |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1084 |
by the ImageEditor of ST/X." |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1085 |
"Do not manually edit this!! If it is corrupted, |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1086 |
the ImageEditor may not be able to read the specification." |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1087 |
" |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1088 |
self fileImageIcon inspect |
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1089 |
ImageEditor openOnClass:self andSelector:#fileImageIcon" |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1090 |
|
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1091 |
^ Icon constantNamed:'SystemBrowser class fileImageIcon' |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1092 |
ifAbsentPut:[ |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1093 |
(Depth4Image new) |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1094 |
width:13; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1095 |
height:11; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1096 |
photometric:(#palette); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1097 |
bitsPerSample:(#( 4 )); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1098 |
samplesPerPixel:(1); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1099 |
bits:(ByteArray |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1100 |
fromPackedString:'@@@@@@@@@@H"H"H"@@@BQBH!!D"@@@$P"HQH"@@H"H"DQH @BH"HQDRH@@"H"DQH"@@L3L3DSL0@CL3L1D3L@@3L3L3L3@@@@@@@@@@@b'); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1101 |
colorMapFromArray:#[ 0 0 0 51 153 153 51 255 255 255 153 0 255 255 0 ]; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1102 |
mask:((ImageMask new) |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1103 |
width:13; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1104 |
height:11; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1105 |
bits:(ByteArray fromPackedString:'?<C?8O?0??#?>O?8??#?>O?8??#?>@@a'); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1106 |
yourself); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1107 |
yourself |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1108 |
] |
2846 | 1109 |
! |
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1110 |
|
14106
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1111 |
fullBreakPointedIcon |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1112 |
<resource: #programImage> |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1113 |
|
15305 | 1114 |
^ ToolbarIconLibrary fullBreakPoint9x9Icon |
14106
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1115 |
"/ ^ self fullBreakPointedIcon2 |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1116 |
|
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1117 |
"Created: / 05-03-2014 / 10:27:24 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1118 |
! |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1119 |
|
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1120 |
fullBreakPointedIcon1 |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1121 |
<resource: #image> |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1122 |
"This resource specification was automatically generated |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1123 |
by the ImageEditor of ST/X." |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1124 |
"Do not manually edit this!! If it is corrupted, |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1125 |
the ImageEditor may not be able to read the specification." |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1126 |
" |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1127 |
self stopIcon1 inspect |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1128 |
ImageEditor openOnClass:self andSelector:#stopIcon1 |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1129 |
Icon flushCachedIcons" |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1130 |
|
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1131 |
^ Icon constantNamed:'SystemBrowser stopIcon1' |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1132 |
ifAbsentPut:[ |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1133 |
(Depth4Image new) |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1134 |
width:13; |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1135 |
height:11; |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1136 |
photometric:(#palette); |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1137 |
bitsPerSample:(#[ 4 ]); |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1138 |
samplesPerPixel:(1); |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1139 |
bits:(ByteArray |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1140 |
fromPackedString:'DQH"H!!DQDAD!!DAD!!DQ@RDP@AD!!DPHQD@@QD!!DBDQ@@DQHQ@!!DQ@QDRDZHQDQDQD!!FBDQDADQHQ@RDP@AD!!DPDRDPDRDQDADRH"HQDQ@b'); |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1141 |
colorMapFromArray:#[ 255 255 255 255 0 0 128 0 0 ]; |
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1142 |
mask:((ImageMask new) |
14106
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1143 |
width:13; |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1144 |
height:11; |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1145 |
bits:(ByteArray fromPackedString:'G0@? G?@?>C?8O? ?>C?8G?@O8@_@@@a'); |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1146 |
yourself); |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1147 |
yourself |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1148 |
] |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1149 |
! |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1150 |
|
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1151 |
fullBreakPointedIcon2 |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1152 |
<resource: #image> |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1153 |
"This resource specification was automatically generated |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1154 |
by the ImageEditor of ST/X." |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1155 |
"Do not manually edit this!! If it is corrupted, |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1156 |
the ImageEditor may not be able to read the specification." |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1157 |
" |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1158 |
self stopIcon2 inspect |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1159 |
ImageEditor openOnClass:self andSelector:#stopIcon2 |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1160 |
Icon flushCachedIcons" |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1161 |
|
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1162 |
^ Icon constantNamed:'SystemBrowser stopIcon2' |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1163 |
ifAbsentPut:[ |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1164 |
(Depth4Image new) |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1165 |
width:13; |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1166 |
height:11; |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1167 |
photometric:(#palette); |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1168 |
bitsPerSample:(#[ 4 ]); |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1169 |
samplesPerPixel:(1); |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1170 |
bits:(ByteArray |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1171 |
fromPackedString:'DQH"H!!DQDAD!!DQD!!DQ@RDQDQD!!DPHQDQDQD!!DBDSL3LQHQ@!!D@@@DRDZHQL3L1D!!FBDQDQDQHQ@RDQDQD!!DPDRDQDRDQDADRH"HQDQ@b'); |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1172 |
colorMapFromArray:#[ 255 255 255 255 0 0 128 0 0 255 163 163 ]; |
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1173 |
mask:((ImageMask new) |
14106
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1174 |
width:13; |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1175 |
height:11; |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1176 |
bits:(ByteArray fromPackedString:'G0@? G?@?>C?8O? ?>C?8G?@O8@_@@@a'); |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1177 |
yourself); |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1178 |
yourself |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1179 |
] |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1180 |
! |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1181 |
|
4166 | 1182 |
greenCheckIcon |
1183 |
"This resource specification was automatically generated |
|
1184 |
by the ImageEditor of ST/X." |
|
18157 | 1185 |
|
4166 | 1186 |
"Do not manually edit this!! If it is corrupted, |
1187 |
the ImageEditor may not be able to read the specification." |
|
18157 | 1188 |
|
4166 | 1189 |
" |
1190 |
self greenCheckIcon inspect |
|
1191 |
ImageEditor openOnClass:self andSelector:#greenCheckIcon |
|
18157 | 1192 |
Icon flushCachedIcons |
1193 |
" |
|
1194 |
||
1195 |
<resource: #image> |
|
1196 |
||
1197 |
^Icon |
|
1198 |
constantNamed:'SystemBrowser class greenCheckIcon' |
|
1199 |
ifAbsentPut:[(Depth2Image width:13 height:11) bits:(ByteArray fromPackedString:'@@@@@@@@@@@@@J@@@@FP@@@BP@@FA$@@A($@@@F)@@@@Y@@@@A@@@@@@@@@b') |
|
1200 |
colorMapFromArray:#[0 0 0 126 190 126 0 127 0] |
|
1201 |
mask:((ImageMask width:13 height:11) bits:(ByteArray fromPackedString:'@@@@@@C@@\@A CN@N0@_@@8@A@@@@@@a'); yourself); yourself] |
|
4166 | 1202 |
! |
1203 |
||
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1204 |
greenLockIcon |
3354 | 1205 |
<resource: #programImage> |
1206 |
||
18283 | 1207 |
^ ToolbarIconLibrary padLockGreenMiniIcon |
1208 |
||
1209 |
"Modified: / 05-11-2001 / 09:40:12 / cg" |
|
1210 |
"Modified: / 28-07-2018 / 09:35:28 / Claus Gittinger" |
|
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1211 |
! |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1212 |
|
4165 | 1213 |
greenThumbUpIcon |
18283 | 1214 |
<resource: #programImage> |
1215 |
||
10327 | 1216 |
^ ToolbarIconLibrary greenThumbUpIcon |
1217 |
||
1218 |
"Modified: / 17-07-2011 / 10:03:34 / cg" |
|
18283 | 1219 |
"Modified: / 28-07-2018 / 09:35:33 / Claus Gittinger" |
4165 | 1220 |
! |
1221 |
||
4166 | 1222 |
greenThumbUpSmallIcon |
18283 | 1223 |
<resource: #programImage> |
1224 |
||
10327 | 1225 |
^ ToolbarIconLibrary greenThumbUpSmallIcon |
1226 |
||
1227 |
"Modified: / 17-07-2011 / 10:03:43 / cg" |
|
18283 | 1228 |
"Modified: / 28-07-2018 / 09:35:35 / Claus Gittinger" |
4166 | 1229 |
! |
1230 |
||
1231 |
greyCheckIcon |
|
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1232 |
<resource: #image> |
4166 | 1233 |
"This resource specification was automatically generated |
1234 |
by the ImageEditor of ST/X." |
|
1235 |
"Do not manually edit this!! If it is corrupted, |
|
1236 |
the ImageEditor may not be able to read the specification." |
|
1237 |
" |
|
1238 |
self greyCheckIcon inspect |
|
1239 |
ImageEditor openOnClass:self andSelector:#greyCheckIcon |
|
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1240 |
Icon flushCachedIcons" |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1241 |
|
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1242 |
^ Icon constantNamed:'SystemBrowser class greyCheckIcon' |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1243 |
ifAbsentPut:[ |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1244 |
(Depth4Image new) |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1245 |
width:13; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1246 |
height:11; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1247 |
photometric:(#palette); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1248 |
bitsPerSample:(#( 4 )); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1249 |
samplesPerPixel:(1); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1250 |
bits:(ByteArray |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1251 |
fromPackedString:'@@@@@@@@@@@@@@@@@@@@@@@@H @@@@@@@"@@@@@@@@H@@@@@@ @"@@@@@@H H@@@@@@@H"@@@@@@@@H@@@@@@@@@@@@@@@@@@@@@@@@b'); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1252 |
colorMapFromArray:#[ 0 0 0 255 255 255 127 127 127 ]; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1253 |
mask:((ImageMask new) |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1254 |
width:13; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1255 |
height:11; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1256 |
bits:(ByteArray fromPackedString:'@@@@@@C@@X@A@AL@F @N@@P@@@@@@@@a'); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1257 |
yourself); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1258 |
yourself |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1259 |
] |
4166 | 1260 |
! |
1261 |
||
4165 | 1262 |
greyThumbUpIcon |
18283 | 1263 |
<resource: #programImage> |
1264 |
||
10327 | 1265 |
^ ToolbarIconLibrary greyThumbUpIcon |
1266 |
||
1267 |
"Modified: / 17-07-2011 / 10:04:06 / cg" |
|
18283 | 1268 |
"Modified: / 28-07-2018 / 09:35:40 / Claus Gittinger" |
4165 | 1269 |
! |
1270 |
||
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1271 |
helpIcon |
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1272 |
<resource: #image> |
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1273 |
"This resource specification was automatically generated |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1274 |
by the ImageEditor of ST/X." |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1275 |
"Do not manually edit this!! If it is corrupted, |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1276 |
the ImageEditor may not be able to read the specification." |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1277 |
" |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1278 |
self helpIcon inspect |
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1279 |
ImageEditor openOnClass:self andSelector:#helpIcon" |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1280 |
|
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1281 |
^ Icon constantNamed:'SystemBrowser class helpIcon' |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1282 |
ifAbsentPut:[ |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1283 |
(Depth1Image new) |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1284 |
width:13; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1285 |
height:11; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1286 |
photometric:(#palette); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1287 |
bitsPerSample:(#( 1 )); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1288 |
samplesPerPixel:(1); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1289 |
bits:(ByteArray fromPackedString:'@@A?<G#0]7A?\G;0__A?<G72_?@@@@@a'); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1290 |
colorMapFromArray:#[ 0 0 0 255 255 255 ]; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1291 |
mask:((ImageMask new) |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1292 |
width:13; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1293 |
height:11; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1294 |
bits:(ByteArray fromPackedString:'??#?>O?8??#?>O?8??#?>O?8??#?>@@a'); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1295 |
yourself); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1296 |
yourself |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1297 |
] |
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1298 |
! |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1299 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1300 |
hierarchicalListIcon |
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1301 |
<resource: #image> |
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1302 |
"This resource specification was automatically generated |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1303 |
by the ImageEditor of ST/X." |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1304 |
"Do not manually edit this!! If it is corrupted, |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1305 |
the ImageEditor may not be able to read the specification." |
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1306 |
" |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1307 |
ImageEditor openOnClass:self andSelector:#hierarchicalListIcon" |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1308 |
|
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1309 |
^ Icon constantNamed:'SystemBrowser class hierarchicalListIcon' |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1310 |
ifAbsentPut:[ |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1311 |
(Depth2Image new) |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1312 |
width:13; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1313 |
height:11; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1314 |
photometric:(#palette); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1315 |
bitsPerSample:(#( 2 )); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1316 |
samplesPerPixel:(1); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1317 |
bits:(ByteArray |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1318 |
fromPackedString:'@@@@NAUUU0@R??8@GO?>@A0@C @\??88G@@N@A3?? @^@@8@N***@@@@@C b'); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1319 |
colorMapFromArray:#[ 0 0 0 255 255 255 127 127 127 170 170 170 ]; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1320 |
mask:((ImageMask new) |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1321 |
width:13; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1322 |
height:11; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1323 |
bits:(ByteArray fromPackedString:'??#?>O?8??#?>O?8??#?>O?8??#?>@@a'); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1324 |
yourself); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1325 |
yourself |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1326 |
] |
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1327 |
! |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1328 |
|
5997 | 1329 |
ignoredMethodIcon |
1330 |
<resource: #programImage> |
|
1331 |
||
18283 | 1332 |
^ ToolbarIconLibrary padLockBlackMiniIcon |
1333 |
||
1334 |
"Modified: / 28-07-2018 / 09:35:17 / Claus Gittinger" |
|
5997 | 1335 |
! |
1336 |
||
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1337 |
imageIcon |
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1338 |
<resource: #image> |
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1339 |
"This resource specification was automatically generated |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1340 |
by the ImageEditor of ST/X." |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1341 |
"Do not manually edit this!! If it is corrupted, |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1342 |
the ImageEditor may not be able to read the specification." |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1343 |
" |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1344 |
self imageIcon inspect |
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1345 |
ImageEditor openOnClass:self andSelector:#imageIcon" |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1346 |
|
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1347 |
^ Icon constantNamed:'SystemBrowser class imageIcon' |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1348 |
ifAbsentPut:[ |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1349 |
(Depth4Image new) |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1350 |
width:13; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1351 |
height:11; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1352 |
photometric:(#palette); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1353 |
bitsPerSample:(#( 4 )); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1354 |
samplesPerPixel:(1); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1355 |
bits:(ByteArray |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1356 |
fromPackedString:'@@@@@@@@@@H"H"H"H @BQBH!!D"H@@$P"HQH"@@H"H"DQH @BH"HQDRH@@"H"DQH"@@L3L3DSL0@CL3L1D3L@@3L3L3L3@@@@@@@@@@@b'); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1357 |
colorMapFromArray:#[ 0 0 0 51 153 153 51 255 255 255 153 0 255 255 0 ]; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1358 |
mask:((ImageMask new) |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1359 |
width:13; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1360 |
height:11; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1361 |
bits:(ByteArray fromPackedString:'??#?>O?8??#?>O?8??#?>O?8??#?>@@a'); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1362 |
yourself); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1363 |
yourself |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1364 |
] |
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1365 |
! |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1366 |
|
10048
9e92f3285051
changed: #instVarOverlayXmlSpec
Claus Gittinger <cg@exept.de>
parents:
9879
diff
changeset
|
1367 |
instVarOverlayXmlSpec |
14390
05d5e002f60d
Change images to use ImageMask instances instead of Depth1Image instances as
Stefan Vogel <sv@exept.de>
parents:
14355
diff
changeset
|
1368 |
<resource: #image> |
10048
9e92f3285051
changed: #instVarOverlayXmlSpec
Claus Gittinger <cg@exept.de>
parents:
9879
diff
changeset
|
1369 |
"This resource specification was automatically generated |
9e92f3285051
changed: #instVarOverlayXmlSpec
Claus Gittinger <cg@exept.de>
parents:
9879
diff
changeset
|
1370 |
by the ImageEditor of ST/X." |
9e92f3285051
changed: #instVarOverlayXmlSpec
Claus Gittinger <cg@exept.de>
parents:
9879
diff
changeset
|
1371 |
"Do not manually edit this!! If it is corrupted, |
9e92f3285051
changed: #instVarOverlayXmlSpec
Claus Gittinger <cg@exept.de>
parents:
9879
diff
changeset
|
1372 |
the ImageEditor may not be able to read the specification." |
9e92f3285051
changed: #instVarOverlayXmlSpec
Claus Gittinger <cg@exept.de>
parents:
9879
diff
changeset
|
1373 |
" |
9e92f3285051
changed: #instVarOverlayXmlSpec
Claus Gittinger <cg@exept.de>
parents:
9879
diff
changeset
|
1374 |
self instVarOverlayXmlSpec inspect |
9e92f3285051
changed: #instVarOverlayXmlSpec
Claus Gittinger <cg@exept.de>
parents:
9879
diff
changeset
|
1375 |
ImageEditor openOnClass:self andSelector:#instVarOverlayXmlSpec |
14390
05d5e002f60d
Change images to use ImageMask instances instead of Depth1Image instances as
Stefan Vogel <sv@exept.de>
parents:
14355
diff
changeset
|
1376 |
Icon flushCachedIcons" |
05d5e002f60d
Change images to use ImageMask instances instead of Depth1Image instances as
Stefan Vogel <sv@exept.de>
parents:
14355
diff
changeset
|
1377 |
|
05d5e002f60d
Change images to use ImageMask instances instead of Depth1Image instances as
Stefan Vogel <sv@exept.de>
parents:
14355
diff
changeset
|
1378 |
^ Icon constantNamed:'SystemBrowser class instVarOverlayXmlSpec' |
05d5e002f60d
Change images to use ImageMask instances instead of Depth1Image instances as
Stefan Vogel <sv@exept.de>
parents:
14355
diff
changeset
|
1379 |
ifAbsentPut:[ |
05d5e002f60d
Change images to use ImageMask instances instead of Depth1Image instances as
Stefan Vogel <sv@exept.de>
parents:
14355
diff
changeset
|
1380 |
(Depth2Image new) |
05d5e002f60d
Change images to use ImageMask instances instead of Depth1Image instances as
Stefan Vogel <sv@exept.de>
parents:
14355
diff
changeset
|
1381 |
width:16; |
05d5e002f60d
Change images to use ImageMask instances instead of Depth1Image instances as
Stefan Vogel <sv@exept.de>
parents:
14355
diff
changeset
|
1382 |
height:16; |
05d5e002f60d
Change images to use ImageMask instances instead of Depth1Image instances as
Stefan Vogel <sv@exept.de>
parents:
14355
diff
changeset
|
1383 |
photometric:(#palette); |
05d5e002f60d
Change images to use ImageMask instances instead of Depth1Image instances as
Stefan Vogel <sv@exept.de>
parents:
14355
diff
changeset
|
1384 |
bitsPerSample:(#[ 2 ]); |
05d5e002f60d
Change images to use ImageMask instances instead of Depth1Image instances as
Stefan Vogel <sv@exept.de>
parents:
14355
diff
changeset
|
1385 |
samplesPerPixel:(1); |
05d5e002f60d
Change images to use ImageMask instances instead of Depth1Image instances as
Stefan Vogel <sv@exept.de>
parents:
14355
diff
changeset
|
1386 |
bits:(ByteArray |
05d5e002f60d
Change images to use ImageMask instances instead of Depth1Image instances as
Stefan Vogel <sv@exept.de>
parents:
14355
diff
changeset
|
1387 |
fromPackedString:'@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@BDP@@BID@@@"Q@@@BDP@@@@@@@@@@@@@@@@@@@a'); |
05d5e002f60d
Change images to use ImageMask instances instead of Depth1Image instances as
Stefan Vogel <sv@exept.de>
parents:
14355
diff
changeset
|
1388 |
colorMapFromArray:#[ 0 0 0 84 84 84 170 170 170 255 255 255 ]; |
05d5e002f60d
Change images to use ImageMask instances instead of Depth1Image instances as
Stefan Vogel <sv@exept.de>
parents:
14355
diff
changeset
|
1389 |
mask:((ImageMask new) |
05d5e002f60d
Change images to use ImageMask instances instead of Depth1Image instances as
Stefan Vogel <sv@exept.de>
parents:
14355
diff
changeset
|
1390 |
width:16; |
05d5e002f60d
Change images to use ImageMask instances instead of Depth1Image instances as
Stefan Vogel <sv@exept.de>
parents:
14355
diff
changeset
|
1391 |
height:16; |
05d5e002f60d
Change images to use ImageMask instances instead of Depth1Image instances as
Stefan Vogel <sv@exept.de>
parents:
14355
diff
changeset
|
1392 |
bits:(ByteArray |
05d5e002f60d
Change images to use ImageMask instances instead of Depth1Image instances as
Stefan Vogel <sv@exept.de>
parents:
14355
diff
changeset
|
1393 |
fromPackedString:' |
10048
9e92f3285051
changed: #instVarOverlayXmlSpec
Claus Gittinger <cg@exept.de>
parents:
9879
diff
changeset
|
1394 |
@@@@@@@@@@@@@@@@BA@XFC@L[>[O8<=#[7X0CA XBA@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ |
9e92f3285051
changed: #instVarOverlayXmlSpec
Claus Gittinger <cg@exept.de>
parents:
9879
diff
changeset
|
1395 |
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ |
14390
05d5e002f60d
Change images to use ImageMask instances instead of Depth1Image instances as
Stefan Vogel <sv@exept.de>
parents:
14355
diff
changeset
|
1396 |
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@a'); |
05d5e002f60d
Change images to use ImageMask instances instead of Depth1Image instances as
Stefan Vogel <sv@exept.de>
parents:
14355
diff
changeset
|
1397 |
yourself); |
05d5e002f60d
Change images to use ImageMask instances instead of Depth1Image instances as
Stefan Vogel <sv@exept.de>
parents:
14355
diff
changeset
|
1398 |
yourself |
05d5e002f60d
Change images to use ImageMask instances instead of Depth1Image instances as
Stefan Vogel <sv@exept.de>
parents:
14355
diff
changeset
|
1399 |
] |
10048
9e92f3285051
changed: #instVarOverlayXmlSpec
Claus Gittinger <cg@exept.de>
parents:
9879
diff
changeset
|
1400 |
! |
9e92f3285051
changed: #instVarOverlayXmlSpec
Claus Gittinger <cg@exept.de>
parents:
9879
diff
changeset
|
1401 |
|
7992 | 1402 |
instrumentationIcon |
1403 |
<resource: #programImage> |
|
1404 |
||
1405 |
^ ToolbarIconLibrary pipette16x16Icon |
|
1406 |
! |
|
1407 |
||
14106
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1408 |
lineBreakPointedIcon |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1409 |
<resource: #programImage> |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1410 |
|
15305 | 1411 |
^ ToolbarIconLibrary lineBreakPoint9x9Icon |
14106
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1412 |
"/ ^ self lineBreakPointedIcon2 |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1413 |
|
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1414 |
"Created: / 05-03-2014 / 10:20:23 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1415 |
! |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1416 |
|
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1417 |
lineBreakPointedIcon1 |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1418 |
<resource: #image> |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1419 |
"This resource specification was automatically generated |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1420 |
by the ImageEditor of ST/X." |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1421 |
"Do not manually edit this!! If it is corrupted, |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1422 |
the ImageEditor may not be able to read the specification." |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1423 |
" |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1424 |
self breakPointedIcon1 inspect |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1425 |
ImageEditor openOnClass:self andSelector:#breakPointedIcon1 |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1426 |
Icon flushCachedIcons" |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1427 |
|
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1428 |
^ Icon constantNamed:'SystemBrowser breakPointedIcon1' |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1429 |
ifAbsentPut:[ |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1430 |
(Depth4Image new) |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1431 |
width:13; |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1432 |
height:11; |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1433 |
photometric:(#palette); |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1434 |
bitsPerSample:(#[ 4 ]); |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1435 |
samplesPerPixel:(1); |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1436 |
bits:(ByteArray |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1437 |
fromPackedString:'@@@@@@@@@P@@L3@@@@$@L@@@L@@H@@@C@@@@APL@DQ@C@@@C@1DS@0@B@0@QD@L@@@@@@0@@@@@@L@@@L@@@@@@3L@@@@ @@@@@@@@ b'); |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1438 |
colorMapFromArray:#[ 255 0 0 255 255 255 0 0 0 255 199 199 ]; |
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1439 |
mask:((ImageMask new) |
14106
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1440 |
width:13; |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1441 |
height:11; |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1442 |
bits:(ByteArray fromPackedString:'@@@N@C>@O8A?0G?@_<@? C>@C @@@@@a'); |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1443 |
yourself); |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1444 |
yourself |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1445 |
] |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1446 |
! |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1447 |
|
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1448 |
lineBreakPointedIcon2 |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1449 |
<resource: #image> |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1450 |
"This resource specification was automatically generated |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1451 |
by the ImageEditor of ST/X." |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1452 |
"Do not manually edit this!! If it is corrupted, |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1453 |
the ImageEditor may not be able to read the specification." |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1454 |
" |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1455 |
self breakPointedIcon2 inspect |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1456 |
ImageEditor openOnClass:self andSelector:#breakPointedIcon2 |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1457 |
Icon flushCachedIcons" |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1458 |
|
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1459 |
^ Icon constantNamed:'SystemBrowser breakPointedIcon2' |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1460 |
ifAbsentPut:[ |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1461 |
(Depth4Image new) |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1462 |
width:13; |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1463 |
height:11; |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1464 |
photometric:(#palette); |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1465 |
bitsPerSample:(#[ 4 ]); |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1466 |
samplesPerPixel:(1); |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1467 |
bits:(ByteArray |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1468 |
fromPackedString:'DQH"H!!DQDAD!!DQD!!DQ@RDQDQD!!DPHQDQDQD!!DBDQDQDQHQ@!!DQDQDRDZHQDQDQD!!FBDQDQDQHQ@RDQDQD!!DPDRDQDRDQDADRH"HQDQ@b'); |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1469 |
colorMapFromArray:#[ 255 255 255 255 0 0 128 0 0 ]; |
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1470 |
mask:((ImageMask new) |
14106
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1471 |
width:13; |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1472 |
height:11; |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1473 |
bits:(ByteArray fromPackedString:'G0@? G?@?>C?8O? ?>C?8G?@O8@_@@@a'); |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1474 |
yourself); |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1475 |
yourself |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1476 |
] |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1477 |
! |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
1478 |
|
16027 | 1479 |
lineTracePointedIcon |
1480 |
<resource: #programImage> |
|
1481 |
||
1482 |
^ ToolbarIconLibrary lineTracePoint9x9Icon |
|
1483 |
! |
|
1484 |
||
3675 | 1485 |
medium_methodEmptyInheritedIcon |
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1486 |
<resource: #image> |
3675 | 1487 |
"This resource specification was automatically generated |
1488 |
by the ImageEditor of ST/X." |
|
1489 |
"Do not manually edit this!! If it is corrupted, |
|
1490 |
the ImageEditor may not be able to read the specification." |
|
1491 |
" |
|
1492 |
self medium_methodEmptyInheritedIcon inspect |
|
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1493 |
ImageEditor openOnClass:self andSelector:#medium_methodEmptyInheritedIcon" |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1494 |
|
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1495 |
^ Icon |
7968 | 1496 |
constantNamed:'SystemBrowser class medium_methodEmptyInheritedIcon' |
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1497 |
ifAbsentPut:[ |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1498 |
(Depth4Image new) |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1499 |
width:9; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1500 |
height:11; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1501 |
photometric:(#palette); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1502 |
bitsPerSample:(#( 4 )); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1503 |
samplesPerPixel:(1); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1504 |
bits:(ByteArray |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1505 |
fromPackedString:'@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@a'); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1506 |
colorMapFromArray:#[ 0 0 0 ]; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1507 |
mask:((ImageMask new) |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1508 |
width:9; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1509 |
height:11; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1510 |
bits:(ByteArray fromPackedString:'@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@a'); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1511 |
yourself); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1512 |
yourself |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1513 |
] |
3675 | 1514 |
! |
1515 |
||
1516 |
medium_methodInheritedFromAboveAndRedefinedBelowIcon |
|
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1517 |
<resource: #image> |
3675 | 1518 |
"This resource specification was automatically generated |
1519 |
by the ImageEditor of ST/X." |
|
1520 |
"Do not manually edit this!! If it is corrupted, |
|
1521 |
the ImageEditor may not be able to read the specification." |
|
1522 |
" |
|
1523 |
self medium_methodInheritedFromAboveAndRedefinedBelowIcon inspect |
|
1524 |
ImageEditor openOnClass:self andSelector:#medium_methodInheritedFromAboveAndRedefinedBelowIcon |
|
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1525 |
Icon flushCachedIcons" |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1526 |
|
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1527 |
^ Icon |
7968 | 1528 |
constantNamed:'SystemBrowser class medium_methodInheritedFromAboveAndRedefinedBelowIcon' |
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1529 |
ifAbsentPut:[ |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1530 |
(Depth2Image new) |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1531 |
width:9; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1532 |
height:11; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1533 |
photometric:(#palette); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1534 |
bitsPerSample:(#( 2 )); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1535 |
samplesPerPixel:(1); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1536 |
bits:(ByteArray |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1537 |
fromPackedString:'@@@@@@@@@B()@B(@A@ @A@ @A@ (EP@HEP@@@@@@@@@@'); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1538 |
colorMapFromArray:#[ 0 0 0 255 255 127 255 127 127 ]; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1539 |
mask:((ImageMask new) |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1540 |
width:9; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1541 |
height:11; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1542 |
bits:(ByteArray fromPackedString:'@@@/ B>@K8A7@G\@]0C:@O(@> @@@@@a'); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1543 |
yourself); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1544 |
yourself |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1545 |
] |
3675 | 1546 |
! |
1547 |
||
1548 |
medium_methodInheritedFromAboveIcon |
|
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1549 |
<resource: #image> |
3675 | 1550 |
"This resource specification was automatically generated |
1551 |
by the ImageEditor of ST/X." |
|
1552 |
"Do not manually edit this!! If it is corrupted, |
|
1553 |
the ImageEditor may not be able to read the specification." |
|
1554 |
" |
|
1555 |
self medium_methodInheritedFromAboveIcon inspect |
|
1556 |
ImageEditor openOnClass:self andSelector:#medium_methodInheritedFromAboveIcon |
|
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1557 |
Icon flushCachedIcons" |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1558 |
|
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1559 |
^ Icon |
7968 | 1560 |
constantNamed:'SystemBrowser class medium_methodInheritedFromAboveIcon' |
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1561 |
ifAbsentPut:[ |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1562 |
(Depth1Image new) |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1563 |
width:9; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1564 |
height:11; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1565 |
photometric:(#palette); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1566 |
bitsPerSample:(#( 1 )); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1567 |
samplesPerPixel:(1); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1568 |
bits:(ByteArray fromPackedString:'@@@@@@@A@@@ @B@@HA=0LG@@@@@@@@@a'); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1569 |
colorMapFromArray:#[ 0 0 0 255 255 127 ]; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1570 |
mask:((ImageMask new) |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1571 |
width:9; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1572 |
height:11; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1573 |
bits:(ByteArray fromPackedString:'@@@ @B@@H@A0@G@@\@C8@O @>@@@@@@a'); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1574 |
yourself); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1575 |
yourself |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1576 |
] |
3675 | 1577 |
! |
1578 |
||
1579 |
medium_methodRedefinedBelowIcon |
|
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1580 |
<resource: #image> |
3675 | 1581 |
"This resource specification was automatically generated |
1582 |
by the ImageEditor of ST/X." |
|
1583 |
"Do not manually edit this!! If it is corrupted, |
|
1584 |
the ImageEditor may not be able to read the specification." |
|
1585 |
" |
|
1586 |
self medium_methodRedefinedBelowIcon inspect |
|
1587 |
ImageEditor openOnClass:self andSelector:#medium_methodRedefinedBelowIcon |
|
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1588 |
Icon flushCachedIcons" |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1589 |
|
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1590 |
^ Icon |
7968 | 1591 |
constantNamed:'SystemBrowser class medium_methodRedefinedBelowIcon' |
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1592 |
ifAbsentPut:[ |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1593 |
(Depth1Image new) |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1594 |
width:9; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1595 |
height:11; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1596 |
photometric:(#palette); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1597 |
bitsPerSample:(#( 1 )); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1598 |
samplesPerPixel:(1); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1599 |
bits:(ByteArray fromPackedString:'@ED@L@\@A0@B@@H@@"8@P@@@@@@@@@@a'); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1600 |
colorMapFromArray:#[ 0 0 0 255 127 127 ]; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1601 |
mask:((ImageMask new) |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1602 |
width:9; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1603 |
height:11; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1604 |
bits:(ByteArray fromPackedString:'@@@O @>@C8@G@@\@A0@B@@H@@ @@@@@a'); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1605 |
yourself); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1606 |
yourself |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1607 |
] |
3675 | 1608 |
! |
1609 |
||
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1610 |
menuIcon |
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1611 |
<resource: #image> |
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1612 |
"This resource specification was automatically generated |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1613 |
by the ImageEditor of ST/X." |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1614 |
"Do not manually edit this!! If it is corrupted, |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1615 |
the ImageEditor may not be able to read the specification." |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1616 |
" |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1617 |
self menuIcon inspect |
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1618 |
ImageEditor openOnClass:self andSelector:#menuIcon" |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1619 |
|
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1620 |
^ Icon constantNamed:'SystemBrowser class menuIcon' |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1621 |
ifAbsentPut:[ |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1622 |
(Depth2Image new) |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1623 |
width:13; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1624 |
height:11; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1625 |
photometric:(#palette); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1626 |
bitsPerSample:(#( 2 )); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1627 |
samplesPerPixel:(1); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1628 |
bits:(ByteArray |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1629 |
fromPackedString:'@@@@@B***P@%UUT@@@@@@B***P@%UUT@@@@@@B***P@%UUT@@@@@@@@@@@@b'); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1630 |
colorMapFromArray:#[ 0 0 0 170 170 170 255 255 255 ]; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1631 |
mask:((ImageMask new) |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1632 |
width:13; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1633 |
height:11; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1634 |
bits:(ByteArray fromPackedString:'??#?>O?8??#?>O?8??#?>O?8?? @@@@a'); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1635 |
yourself); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1636 |
yourself |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1637 |
] |
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1638 |
! |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1639 |
|
3675 | 1640 |
methodEmptyInheritedIcon |
18283 | 1641 |
<resource: #programImage> |
1642 |
||
3675 | 1643 |
^ self small_methodEmptyInheritedIcon |
18283 | 1644 |
|
1645 |
"Modified: / 28-07-2018 / 09:37:15 / Claus Gittinger" |
|
3675 | 1646 |
! |
1647 |
||
1648 |
methodInheritedFromAboveAndRedefinedBelowIcon |
|
18283 | 1649 |
<resource: #programImage> |
1650 |
||
3675 | 1651 |
^ self small_methodInheritedFromAboveAndRedefinedBelowIcon |
18283 | 1652 |
|
1653 |
"Modified: / 28-07-2018 / 09:37:18 / Claus Gittinger" |
|
3675 | 1654 |
! |
1655 |
||
1656 |
methodInheritedFromAboveIcon |
|
18283 | 1657 |
<resource: #programImage> |
1658 |
||
3675 | 1659 |
^ self small_methodInheritedFromAboveIcon |
18283 | 1660 |
|
1661 |
"Modified: / 28-07-2018 / 09:37:23 / Claus Gittinger" |
|
3675 | 1662 |
! |
1663 |
||
5761
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
1664 |
methodIsSubclassResponsibilityAndRedefinedBelowIcon |
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1665 |
<resource: #image> |
5761
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
1666 |
"This resource specification was automatically generated |
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
1667 |
by the ImageEditor of ST/X." |
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
1668 |
"Do not manually edit this!! If it is corrupted, |
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
1669 |
the ImageEditor may not be able to read the specification." |
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
1670 |
" |
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
1671 |
self methodIsSubclassResponsibilityAndRedefinedBelowIcon inspect |
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
1672 |
ImageEditor openOnClass:self andSelector:#methodIsSubclassResponsibilityAndRedefinedBelowIcon |
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1673 |
Icon flushCachedIcons" |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1674 |
|
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1675 |
^ Icon |
7968 | 1676 |
constantNamed:'SystemBrowser class methodIsSubclassResponsibilityAndRedefinedBelowIcon' |
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1677 |
ifAbsentPut:[ |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1678 |
(Depth2Image new) |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1679 |
width:5; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1680 |
height:11; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1681 |
photometric:(#palette); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1682 |
bitsPerSample:(#( 2 )); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1683 |
samplesPerPixel:(1); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1684 |
bits:(ByteArray fromPackedString:' @D@@H@@@@@B@@@@@@4UBHR@A@@"@@@a'); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1685 |
colorMapFromArray:#[ 0 0 0 255 127 127 127 127 127 ]; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1686 |
mask:((ImageMask new) |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1687 |
width:5; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1688 |
height:11; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1689 |
bits:(ByteArray fromPackedString:'<HC DO@@>O#8\G@b'); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1690 |
yourself); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1691 |
yourself |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1692 |
] |
5761
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
1693 |
! |
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
1694 |
|
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
1695 |
methodIsSubclassResponsibilityIcon |
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1696 |
<resource: #image> |
5761
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
1697 |
"This resource specification was automatically generated |
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
1698 |
by the ImageEditor of ST/X." |
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
1699 |
"Do not manually edit this!! If it is corrupted, |
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
1700 |
the ImageEditor may not be able to read the specification." |
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
1701 |
" |
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
1702 |
self methodIsSubclassResponsibilityIcon inspect |
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
1703 |
ImageEditor openOnClass:self andSelector:#methodIsSubclassResponsibilityIcon |
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1704 |
Icon flushCachedIcons" |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1705 |
|
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1706 |
^ Icon |
7968 | 1707 |
constantNamed:'SystemBrowser class methodIsSubclassResponsibilityIcon' |
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1708 |
ifAbsentPut:[ |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1709 |
(Depth2Image new) |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1710 |
width:5; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1711 |
height:11; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1712 |
photometric:(#palette); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1713 |
bitsPerSample:(#( 2 )); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1714 |
samplesPerPixel:(1); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1715 |
bits:(ByteArray fromPackedString:' @D@@H@@@@@B@@@@@ 4@B@H@@@@@@@@a'); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1716 |
colorMapFromArray:#[ 0 0 0 255 127 127 127 127 127 ]; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1717 |
mask:((ImageMask new) |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1718 |
width:5; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1719 |
height:11; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1720 |
bits:(ByteArray fromPackedString:'<HC DO@@<IC0(I@b'); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1721 |
yourself); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1722 |
yourself |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1723 |
] |
5761
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
1724 |
! |
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
1725 |
|
3675 | 1726 |
methodRedefinedBelowIcon |
18294 | 1727 |
<resource: #programImage> |
1728 |
||
3675 | 1729 |
^ self small_methodRedefinedBelowIcon |
18294 | 1730 |
|
1731 |
"Modified: / 28-07-2018 / 09:52:59 / Claus Gittinger" |
|
3675 | 1732 |
! |
1733 |
||
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1734 |
nameSpaceIcon |
7827 | 1735 |
<resource: #programImage> |
1736 |
||
1737 |
^ ToolbarIconLibrary nameSpaceBrowserIcon |
|
1738 |
||
1739 |
"Modified: / 20-07-2007 / 09:12:26 / cg" |
|
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1740 |
! |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1741 |
|
4308 | 1742 |
notificationClassIcon |
7827 | 1743 |
<resource: #programImage> |
1744 |
||
1745 |
^ ToolbarIconLibrary notificationClassBrowserIcon |
|
1746 |
||
1747 |
"Modified: / 20-07-2007 / 09:11:21 / cg" |
|
4308 | 1748 |
! |
1749 |
||
18411 | 1750 |
obsoleteMethodIcon |
1751 |
<resource: #programImage> |
|
1752 |
||
1753 |
^ ToolbarIconLibrary obsoleteMethodIcon |
|
1754 |
||
1755 |
"Created: / 21-09-2018 / 15:29:51 / Claus Gittinger" |
|
1756 |
! |
|
1757 |
||
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1758 |
packageIcon |
8853 | 1759 |
<resource: #programImage> |
1760 |
||
18294 | 1761 |
^ ToolbarIconLibrary packageIcon |
1762 |
||
1763 |
"Modified: / 28-07-2018 / 09:41:22 / Claus Gittinger" |
|
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1764 |
! |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1765 |
|
6954 | 1766 |
packageIconGraySmall |
8853 | 1767 |
<resource: #programImage> |
1768 |
||
1769 |
^ ToolbarIconLibrary smallGrayPackageIcon |
|
6954 | 1770 |
! |
1771 |
||
6925 | 1772 |
packageIconGreenSmall |
8853 | 1773 |
<resource: #programImage> |
1774 |
||
1775 |
^ ToolbarIconLibrary smallGreenPackageIcon |
|
6925 | 1776 |
! |
1777 |
||
1778 |
packageIconOrangeSmall |
|
8853 | 1779 |
<resource: #programImage> |
1780 |
||
1781 |
^ ToolbarIconLibrary smallOrangePackageIcon |
|
6925 | 1782 |
! |
1783 |
||
6901 | 1784 |
packageIconSmall |
8853 | 1785 |
<resource: #programImage> |
1786 |
||
1787 |
^ ToolbarIconLibrary smallYellowPackageIcon |
|
6901 | 1788 |
! |
1789 |
||
5997 | 1790 |
padLockBlackMiniIcon |
6333 | 1791 |
<resource: #programImage> |
1792 |
||
18294 | 1793 |
^ ToolbarIconLibrary padLockBlackMiniIcon |
1794 |
||
1795 |
"Modified: / 28-07-2018 / 10:00:43 / Claus Gittinger" |
|
5997 | 1796 |
! |
1797 |
||
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1798 |
padLockBlueMiniIcon |
6333 | 1799 |
<resource: #programImage> |
1800 |
||
18283 | 1801 |
^ ToolbarIconLibrary padLockBlueMiniIcon |
1802 |
||
1803 |
"Modified: / 28-07-2018 / 09:34:48 / Claus Gittinger" |
|
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1804 |
! |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1805 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1806 |
padLockGrayMiniIcon |
6333 | 1807 |
<resource: #programImage> |
1808 |
||
18283 | 1809 |
^ ToolbarIconLibrary padLockGrayMiniIcon |
1810 |
||
1811 |
"Modified: / 28-07-2018 / 09:34:51 / Claus Gittinger" |
|
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1812 |
! |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1813 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1814 |
padLockGreenMiniIcon |
6333 | 1815 |
<resource: #programImage> |
1816 |
||
18283 | 1817 |
^ ToolbarIconLibrary padLockGreenMiniIcon |
1818 |
||
1819 |
"Modified: / 28-07-2018 / 09:34:58 / Claus Gittinger" |
|
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1820 |
! |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1821 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1822 |
padLockRedMiniIcon |
6333 | 1823 |
<resource: #programImage> |
1824 |
||
18283 | 1825 |
^ ToolbarIconLibrary padLockRedMiniIcon |
1826 |
||
1827 |
"Modified: / 28-07-2018 / 09:33:57 / Claus Gittinger" |
|
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1828 |
! |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1829 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1830 |
privateMethodIcon |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1831 |
<resource: #programImage> |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1832 |
|
18283 | 1833 |
^ ToolbarIconLibrary padLockRedMiniIcon |
1834 |
||
1835 |
"Modified: / 28-07-2018 / 09:34:42 / Claus Gittinger" |
|
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1836 |
! |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1837 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1838 |
programImageIcon |
18294 | 1839 |
<resource: #programImage> |
1840 |
||
1841 |
^ ToolbarIconLibrary programImageIcon |
|
1842 |
||
1843 |
"Modified: / 28-07-2018 / 09:43:41 / Claus Gittinger" |
|
2846 | 1844 |
! |
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1845 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1846 |
programMenuIcon |
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1847 |
<resource: #image> |
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1848 |
"This resource specification was automatically generated |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1849 |
by the ImageEditor of ST/X." |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1850 |
"Do not manually edit this!! If it is corrupted, |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1851 |
the ImageEditor may not be able to read the specification." |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1852 |
" |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1853 |
self programMenuIcon inspect |
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1854 |
ImageEditor openOnClass:self andSelector:#programMenuIcon" |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1855 |
|
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1856 |
^ Icon constantNamed:#'SystemBrowser class programMenuIcon' |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1857 |
ifAbsentPut:[ |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1858 |
(Depth1Image new) |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1859 |
width:13; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1860 |
height:11; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1861 |
photometric:(#palette); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1862 |
bitsPerSample:(#( 1 )); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1863 |
samplesPerPixel:(1); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1864 |
bits:(ByteArray fromPackedString:'@@A?<G?0@@A?<G?0@@A?<G?3@@@@@@@a'); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1865 |
colorMapFromArray:#[ 0 0 0 170 170 170 ]; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1866 |
mask:((ImageMask new) |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1867 |
width:13; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1868 |
height:11; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1869 |
bits:(ByteArray fromPackedString:'??#?>O?8??#?>O?8??#?>O?8?? @@@@a'); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1870 |
yourself); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1871 |
yourself |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1872 |
] |
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1873 |
! |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1874 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1875 |
protectedMethodIcon |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1876 |
<resource: #programImage> |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1877 |
|
18283 | 1878 |
^ ToolbarIconLibrary padLockGreenMiniIcon |
1879 |
||
1880 |
"Modified: / 28-07-2018 / 09:34:10 / Claus Gittinger" |
|
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1881 |
! |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1882 |
|
4308 | 1883 |
queryClassIcon |
7827 | 1884 |
<resource: #programImage> |
1885 |
||
1886 |
^ ToolbarIconLibrary queryClassBrowserIcon |
|
1887 |
||
1888 |
"Modified: / 20-07-2007 / 09:10:32 / cg" |
|
4308 | 1889 |
! |
1890 |
||
4166 | 1891 |
redCheckIcon |
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1892 |
<resource: #image> |
4166 | 1893 |
"This resource specification was automatically generated |
1894 |
by the ImageEditor of ST/X." |
|
1895 |
"Do not manually edit this!! If it is corrupted, |
|
1896 |
the ImageEditor may not be able to read the specification." |
|
1897 |
" |
|
1898 |
self redCheckIcon inspect |
|
1899 |
ImageEditor openOnClass:self andSelector:#redCheckIcon |
|
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1900 |
Icon flushCachedIcons" |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1901 |
|
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1902 |
^ Icon constantNamed:#'SystemBrowser class redCheckIcon' |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1903 |
ifAbsentPut:[ |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1904 |
(Depth4Image new) |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1905 |
width:13; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1906 |
height:11; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1907 |
photometric:(#palette); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1908 |
bitsPerSample:(#( 4 )); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1909 |
samplesPerPixel:(1); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1910 |
bits:(ByteArray |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1911 |
fromPackedString:'@@@@@@@@@@@@@@@@@@@@@@@@@"@@@@@@@BH@@@@ @@H @@@BH @"@@@@@BH"H @@@@@BH"@@@@@@@BH @@@@@@@B@@@@@@@@@@@@@@@b'); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1912 |
colorMapFromArray:#[ 0 0 0 255 255 255 255 0 0 ]; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1913 |
mask:((ImageMask new) |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1914 |
width:13; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1915 |
height:11; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1916 |
bits:(ByteArray fromPackedString:'@@@@@@A @L@!! GL@O0@^@@8@A@@@@@@a'); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1917 |
yourself); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1918 |
yourself |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1919 |
] |
4166 | 1920 |
! |
1921 |
||
4165 | 1922 |
redThumbDownIcon |
18283 | 1923 |
<resource: #programImage> |
1924 |
||
10327 | 1925 |
^ ToolbarIconLibrary redThumbDownIcon |
1926 |
||
1927 |
"Modified: / 17-07-2011 / 10:04:37 / cg" |
|
18283 | 1928 |
"Modified: / 28-07-2018 / 09:37:09 / Claus Gittinger" |
4165 | 1929 |
! |
1930 |
||
4166 | 1931 |
redThumbDownSmallIcon |
18283 | 1932 |
<resource: #programImage> |
1933 |
||
10327 | 1934 |
^ ToolbarIconLibrary redThumbDownSmallIcon |
1935 |
||
1936 |
"Modified: / 17-07-2011 / 10:05:09 / cg" |
|
18283 | 1937 |
"Modified: / 28-07-2018 / 09:37:04 / Claus Gittinger" |
4166 | 1938 |
! |
1939 |
||
3813 | 1940 |
removeBreakPointIcon2 |
18283 | 1941 |
<resource: #programImage> |
1942 |
||
15362 | 1943 |
UserPreferences current useColorsForColorBlindness ifTrue:[ |
1944 |
^ ToolbarIconLibrary removeBreakPointBlueIcon2 |
|
1945 |
]. |
|
1946 |
^ ToolbarIconLibrary removeBreakPointIcon2 |
|
18283 | 1947 |
|
1948 |
"Modified: / 28-07-2018 / 09:36:57 / Claus Gittinger" |
|
3813 | 1949 |
! |
1950 |
||
3675 | 1951 |
small_methodEmptyInheritedIcon |
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1952 |
<resource: #image> |
3675 | 1953 |
"This resource specification was automatically generated |
1954 |
by the ImageEditor of ST/X." |
|
1955 |
"Do not manually edit this!! If it is corrupted, |
|
1956 |
the ImageEditor may not be able to read the specification." |
|
1957 |
" |
|
1958 |
self small_methodEmptyInheritedIcon inspect |
|
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1959 |
ImageEditor openOnClass:self andSelector:#small_methodEmptyInheritedIcon" |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1960 |
|
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1961 |
^ Icon |
3675 | 1962 |
constantNamed:#'SystemBrowser class small_methodEmptyInheritedIcon' |
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1963 |
ifAbsentPut:[ |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1964 |
(Depth4Image new) |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1965 |
width:5; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1966 |
height:11; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1967 |
photometric:(#palette); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1968 |
bitsPerSample:(#( 4 )); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1969 |
samplesPerPixel:(1); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1970 |
bits:(ByteArray |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1971 |
fromPackedString:'@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@'); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1972 |
colorMapFromArray:#[ 0 0 0 ]; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1973 |
mask:((ImageMask new) |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1974 |
width:5; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1975 |
height:11; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1976 |
bits:(ByteArray fromPackedString:'@@@@@@@@@@@@@@@b'); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1977 |
yourself); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1978 |
yourself |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1979 |
] |
3675 | 1980 |
! |
1981 |
||
1982 |
small_methodInheritedFromAboveAndRedefinedBelowIcon |
|
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1983 |
<resource: #image> |
3675 | 1984 |
"This resource specification was automatically generated |
1985 |
by the ImageEditor of ST/X." |
|
1986 |
"Do not manually edit this!! If it is corrupted, |
|
1987 |
the ImageEditor may not be able to read the specification." |
|
1988 |
" |
|
1989 |
self small_methodInheritedFromAboveAndRedefinedBelowIcon inspect |
|
1990 |
ImageEditor openOnClass:self andSelector:#small_methodInheritedFromAboveAndRedefinedBelowIcon |
|
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1991 |
Icon flushCachedIcons" |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1992 |
|
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1993 |
^ Icon |
3675 | 1994 |
constantNamed:#'SystemBrowser class small_methodInheritedFromAboveAndRedefinedBelowIcon' |
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1995 |
ifAbsentPut:[ |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1996 |
(Depth2Image new) |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1997 |
width:5; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1998 |
height:11; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
1999 |
photometric:(#palette); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2000 |
bitsPerSample:(#( 2 )); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2001 |
samplesPerPixel:(1); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2002 |
bits:(ByteArray fromPackedString:'L1@DLLS,ES@@@@@0@@@*@L#@B@@3@@@a'); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2003 |
colorMapFromArray:#[ 0 0 0 255 255 127 255 127 127 127 127 127 ]; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2004 |
mask:((ImageMask new) |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2005 |
width:5; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2006 |
height:11; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2007 |
bits:(ByteArray fromPackedString:'\GC8>O @>O#8\G@b'); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2008 |
yourself); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2009 |
yourself |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2010 |
] |
3675 | 2011 |
! |
2012 |
||
2013 |
small_methodInheritedFromAboveIcon |
|
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2014 |
<resource: #image> |
3675 | 2015 |
"This resource specification was automatically generated |
2016 |
by the ImageEditor of ST/X." |
|
2017 |
"Do not manually edit this!! If it is corrupted, |
|
2018 |
the ImageEditor may not be able to read the specification." |
|
2019 |
" |
|
2020 |
self small_methodInheritedFromAboveIcon inspect |
|
2021 |
ImageEditor openOnClass:self andSelector:#small_methodInheritedFromAboveIcon |
|
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2022 |
Icon flushCachedIcons" |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2023 |
|
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2024 |
^ Icon |
3675 | 2025 |
constantNamed:#'SystemBrowser class small_methodInheritedFromAboveIcon' |
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2026 |
ifAbsentPut:[ |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2027 |
(Depth2Image new) |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2028 |
width:5; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2029 |
height:11; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2030 |
photometric:(#palette); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2031 |
bitsPerSample:(#( 2 )); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2032 |
samplesPerPixel:(1); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2033 |
bits:(ByteArray fromPackedString:'H#HDLHR@EP@@@@@@@BD@IP@!!@B@@IP@a'); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2034 |
colorMapFromArray:#[ 0 0 0 255 255 127 127 127 127 ]; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2035 |
mask:((ImageMask new) |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2036 |
width:5; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2037 |
height:11; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2038 |
bits:(ByteArray fromPackedString:'\GC8>O @@@@@@@@b'); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2039 |
yourself); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2040 |
yourself |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2041 |
] |
3675 | 2042 |
! |
2043 |
||
2044 |
small_methodRedefinedBelowIcon |
|
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2045 |
<resource: #image> |
3675 | 2046 |
"This resource specification was automatically generated |
2047 |
by the ImageEditor of ST/X." |
|
2048 |
"Do not manually edit this!! If it is corrupted, |
|
2049 |
the ImageEditor may not be able to read the specification." |
|
2050 |
" |
|
2051 |
self small_methodRedefinedBelowIcon inspect |
|
2052 |
ImageEditor openOnClass:self andSelector:#small_methodRedefinedBelowIcon |
|
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2053 |
Icon flushCachedIcons" |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2054 |
|
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2055 |
^ Icon |
3675 | 2056 |
constantNamed:#'SystemBrowser class small_methodRedefinedBelowIcon' |
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2057 |
ifAbsentPut:[ |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2058 |
(Depth2Image new) |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2059 |
width:5; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2060 |
height:11; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2061 |
photometric:(#palette); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2062 |
bitsPerSample:(#( 2 )); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2063 |
samplesPerPixel:(1); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2064 |
bits:(ByteArray fromPackedString:'@@D@@@@@@@@@@@@@@@4UBHR@A@@"@@@a'); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2065 |
colorMapFromArray:#[ 0 0 0 255 127 127 127 127 127 ]; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2066 |
mask:((ImageMask new) |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2067 |
width:5; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2068 |
height:11; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2069 |
bits:(ByteArray fromPackedString:'@@@@@@@@>O#8\G@b'); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2070 |
yourself); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2071 |
yourself |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2072 |
] |
3675 | 2073 |
! |
2074 |
||
3354 | 2075 |
startableClassIcon |
7827 | 2076 |
<resource: #programImage> |
2077 |
||
2078 |
^ ToolbarIconLibrary startableClassBrowserIcon |
|
2079 |
||
2080 |
"Created: / 05-11-2001 / 09:50:16 / cg" |
|
2081 |
"Modified: / 20-07-2007 / 09:09:40 / cg" |
|
3354 | 2082 |
! |
2083 |
||
2084 |
startableVisualAppIcon |
|
7827 | 2085 |
<resource: #programImage> |
2086 |
||
2087 |
^ ToolbarIconLibrary visualStartableClassBrowserIcon |
|
2088 |
||
2089 |
"Created: / 05-11-2001 / 09:49:00 / cg" |
|
2090 |
"Modified: / 20-07-2007 / 09:08:34 / cg" |
|
3354 | 2091 |
! |
2092 |
||
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
2093 |
stopIcon |
14106
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
2094 |
<resource: #obsolete> |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
2095 |
|
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
2096 |
^ self fullBreakPointedIcon |
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
2097 |
|
c042bb7e4cee
Added icons fullBreakPointedIcon and lineBreakPointedIcon.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14103
diff
changeset
|
2098 |
"Modified: / 05-03-2014 / 10:27:53 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
2099 |
! |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
2100 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
2101 |
tabListIcon |
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2102 |
<resource: #image> |
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
2103 |
"This resource specification was automatically generated |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
2104 |
by the ImageEditor of ST/X." |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
2105 |
"Do not manually edit this!! If it is corrupted, |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
2106 |
the ImageEditor may not be able to read the specification." |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
2107 |
" |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
2108 |
self tabListIcon inspect |
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2109 |
ImageEditor openOnClass:self andSelector:#tabListIcon" |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2110 |
|
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2111 |
^ Icon constantNamed:#'SystemBrowser class tabListIcon' |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2112 |
ifAbsentPut:[ |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2113 |
(Depth2Image new) |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2114 |
width:13; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2115 |
height:11; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2116 |
photometric:(#palette); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2117 |
bitsPerSample:(#( 2 )); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2118 |
samplesPerPixel:(1); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2119 |
bits:(ByteArray |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2120 |
fromPackedString:'@@@@D3!!QP@@8TT@@N@@J@C***P@:**$AN**)@C***P@:**$@IUUUB @@@@@b'); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2121 |
colorMapFromArray:#[ 0 0 0 127 127 127 170 170 170 255 255 255 ]; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2122 |
mask:((ImageMask new) |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2123 |
width:13; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2124 |
height:11; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2125 |
bits:(ByteArray fromPackedString:'?8C?0O?0??#?>O?8??#?>O?8??#?>@@a'); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2126 |
yourself); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2127 |
yourself |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2128 |
] |
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
2129 |
! |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
2130 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
2131 |
tableColumnsIcon |
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2132 |
<resource: #image> |
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
2133 |
"This resource specification was automatically generated |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
2134 |
by the ImageEditor of ST/X." |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
2135 |
"Do not manually edit this!! If it is corrupted, |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
2136 |
the ImageEditor may not be able to read the specification." |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
2137 |
" |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
2138 |
self tableColumnsIcon inspect |
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2139 |
ImageEditor openOnClass:self andSelector:#tableColumnsIcon" |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2140 |
|
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2141 |
^ Icon constantNamed:#'SystemBrowser class tableColumnsIcon' |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2142 |
ifAbsentPut:[ |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2143 |
(Depth2Image new) |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2144 |
width:13; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2145 |
height:11; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2146 |
photometric:(#palette); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2147 |
bitsPerSample:(#( 2 )); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2148 |
samplesPerPixel:(1); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2149 |
bits:(ByteArray |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2150 |
fromPackedString:'@@@@@C??? @8(($@L@@AHC"""R@0@@D@NJJI@C@@@P@8(($@IUUU@@@@@@@b'); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2151 |
colorMapFromArray:#[ 0 0 0 127 127 127 170 170 170 255 255 255 ]; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2152 |
mask:((ImageMask new) |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2153 |
width:13; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2154 |
height:11; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2155 |
bits:(ByteArray fromPackedString:'??#?>O?8??#?>O?8??#?>O?8??#?>@@a'); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2156 |
yourself); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2157 |
yourself |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2158 |
] |
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
2159 |
! |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
2160 |
|
4150 | 2161 |
testCaseClassIcon |
8862
dece7957557d
comment/format in: #testCaseClassIconFor:
Claus Gittinger <cg@exept.de>
parents:
8853
diff
changeset
|
2162 |
<resource: #programImage> |
dece7957557d
comment/format in: #testCaseClassIconFor:
Claus Gittinger <cg@exept.de>
parents:
8853
diff
changeset
|
2163 |
|
dece7957557d
comment/format in: #testCaseClassIconFor:
Claus Gittinger <cg@exept.de>
parents:
8853
diff
changeset
|
2164 |
"/ only left here for backward compatibility... |
dece7957557d
comment/format in: #testCaseClassIconFor:
Claus Gittinger <cg@exept.de>
parents:
8853
diff
changeset
|
2165 |
^ ToolbarIconLibrary testCaseClassIcon |
4150 | 2166 |
! |
2167 |
||
2168 |
testCaseClassIconFor:cls |
|
4167 | 2169 |
<resource: #programImage> |
2170 |
||
8862
dece7957557d
comment/format in: #testCaseClassIconFor:
Claus Gittinger <cg@exept.de>
parents:
8853
diff
changeset
|
2171 |
"/ decision moved to TestCase - see there. |
dece7957557d
comment/format in: #testCaseClassIconFor:
Claus Gittinger <cg@exept.de>
parents:
8853
diff
changeset
|
2172 |
"/ only left here for backward compatibility... |
dece7957557d
comment/format in: #testCaseClassIconFor:
Claus Gittinger <cg@exept.de>
parents:
8853
diff
changeset
|
2173 |
|
4150 | 2174 |
|lastResult| |
2175 |
||
4235
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
2176 |
lastResult := cls lastTestRunResultOrNil. |
12729 | 2177 |
lastResult notNil ifTrue:[ |
2178 |
lastResult == TestResult statePass ifTrue:[ |
|
2179 |
^ self testCasePassedIcon |
|
2180 |
]. |
|
2181 |
lastResult == TestResult stateFail ifTrue:[ |
|
2182 |
^ self testCaseFailedIcon |
|
2183 |
]. |
|
2184 |
lastResult == TestResult stateError ifTrue:[ |
|
2185 |
^ self testCaseErrorIcon |
|
2186 |
]. |
|
4150 | 2187 |
]. |
2188 |
^ self testCaseUnknownResultIcon |
|
6848 | 2189 |
|
2190 |
"Modified: / 06-08-2006 / 11:14:12 / cg" |
|
4150 | 2191 |
! |
2192 |
||
12729 | 2193 |
testCaseErrorIcon |
2194 |
<resource: #programImage> |
|
2195 |
||
2196 |
"/ only left here for backward compatibility... |
|
2197 |
^ ToolbarIconLibrary testCaseErrorIcon |
|
2198 |
! |
|
2199 |
||
4150 | 2200 |
testCaseFailedIcon |
4166 | 2201 |
<resource: #programImage> |
2202 |
||
8862
dece7957557d
comment/format in: #testCaseClassIconFor:
Claus Gittinger <cg@exept.de>
parents:
8853
diff
changeset
|
2203 |
"/ only left here for backward compatibility... |
dece7957557d
comment/format in: #testCaseClassIconFor:
Claus Gittinger <cg@exept.de>
parents:
8853
diff
changeset
|
2204 |
^ ToolbarIconLibrary testCaseFailedIcon |
4150 | 2205 |
! |
2206 |
||
2207 |
testCasePassedIcon |
|
8862
dece7957557d
comment/format in: #testCaseClassIconFor:
Claus Gittinger <cg@exept.de>
parents:
8853
diff
changeset
|
2208 |
<resource: #programImage> |
dece7957557d
comment/format in: #testCaseClassIconFor:
Claus Gittinger <cg@exept.de>
parents:
8853
diff
changeset
|
2209 |
|
dece7957557d
comment/format in: #testCaseClassIconFor:
Claus Gittinger <cg@exept.de>
parents:
8853
diff
changeset
|
2210 |
"/ only left here for backward compatibility... |
dece7957557d
comment/format in: #testCaseClassIconFor:
Claus Gittinger <cg@exept.de>
parents:
8853
diff
changeset
|
2211 |
^ ToolbarIconLibrary testCasePassedIcon |
4150 | 2212 |
! |
2213 |
||
12631 | 2214 |
testCaseSkippedIcon |
2215 |
<resource: #programImage> |
|
2216 |
||
2217 |
"/ only left here for backward compatibility... |
|
2218 |
^ ToolbarIconLibrary testCaseSkippedIcon |
|
2219 |
! |
|
2220 |
||
4150 | 2221 |
testCaseUnknownResultIcon |
4166 | 2222 |
<resource: #programImage> |
2223 |
||
8862
dece7957557d
comment/format in: #testCaseClassIconFor:
Claus Gittinger <cg@exept.de>
parents:
8853
diff
changeset
|
2224 |
"/ only left here for backward compatibility... |
dece7957557d
comment/format in: #testCaseClassIconFor:
Claus Gittinger <cg@exept.de>
parents:
8853
diff
changeset
|
2225 |
^ ToolbarIconLibrary testCaseClassIcon |
4150 | 2226 |
! |
2227 |
||
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
2228 |
timeIcon |
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2229 |
<resource: #image> |
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
2230 |
"This resource specification was automatically generated |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
2231 |
by the ImageEditor of ST/X." |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
2232 |
"Do not manually edit this!! If it is corrupted, |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
2233 |
the ImageEditor may not be able to read the specification." |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
2234 |
" |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
2235 |
self timeIcon inspect |
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2236 |
ImageEditor openOnClass:self andSelector:#timeIcon" |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2237 |
|
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2238 |
^ Icon constantNamed:#'SystemBrowser class timeIcon' |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2239 |
ifAbsentPut:[ |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2240 |
(Depth1Image new) |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2241 |
width:13; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2242 |
height:11; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2243 |
photometric:(#palette); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2244 |
bitsPerSample:(#( 1 )); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2245 |
samplesPerPixel:(1); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2246 |
bits:(ByteArray fromPackedString:'@@@G@A7@G\@=8C0 O>@_0A?@A0@@@@@a'); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2247 |
colorMapFromArray:#[ 0 0 0 255 255 255 ]; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2248 |
mask:((ImageMask new) |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2249 |
width:13; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2250 |
height:11; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2251 |
bits:(ByteArray fromPackedString:'A0@_0C? O>A?<G?0_?@?8C? G<@G@@@a'); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2252 |
yourself); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2253 |
yourself |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2254 |
] |
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
2255 |
! |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
2256 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
2257 |
traceIcon |
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2258 |
<resource: #image> |
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
2259 |
"This resource specification was automatically generated |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
2260 |
by the ImageEditor of ST/X." |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
2261 |
"Do not manually edit this!! If it is corrupted, |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
2262 |
the ImageEditor may not be able to read the specification." |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
2263 |
" |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
2264 |
self traceIcon inspect |
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2265 |
ImageEditor openOnClass:self andSelector:#traceIcon" |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2266 |
|
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2267 |
^ Icon constantNamed:#'SystemBrowser class traceIcon' |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2268 |
ifAbsentPut:[ |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2269 |
(Depth1Image new) |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2270 |
width:13; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2271 |
height:11; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2272 |
photometric:(#palette); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2273 |
bitsPerSample:(#( 1 )); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2274 |
samplesPerPixel:(1); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2275 |
bits:(ByteArray fromPackedString:'@@@@@@>@C8@G@@\@@ @B@@@@@@@@@@@a'); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2276 |
colorMapFromArray:#[ 255 0 0 255 255 255 ]; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2277 |
mask:((ImageMask new) |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2278 |
width:13; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2279 |
height:11; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2280 |
bits:(ByteArray fromPackedString:'_?A?<C? O>@_0A?@C8@O @\@A0@B@@@a'); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2281 |
yourself); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2282 |
yourself |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2283 |
] |
2830 | 2284 |
! |
2285 |
||
2286 |
visualStartableClassIcon |
|
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2287 |
<resource: #image> |
2830 | 2288 |
"This resource specification was automatically generated |
2289 |
by the ImageEditor of ST/X." |
|
2290 |
"Do not manually edit this!! If it is corrupted, |
|
2291 |
the ImageEditor may not be able to read the specification." |
|
2292 |
" |
|
2293 |
self visualStartableClassIcon inspect |
|
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2294 |
ImageEditor openOnClass:self andSelector:#visualStartableClassIcon" |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2295 |
|
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2296 |
^ Icon constantNamed:#'SystemBrowser class visualStartableClassIcon' |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2297 |
ifAbsentPut:[ |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2298 |
(Depth2Image new) |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2299 |
width:13; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2300 |
height:11; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2301 |
photometric:(#palette); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2302 |
bitsPerSample:(#( 2 )); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2303 |
samplesPerPixel:(1); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2304 |
bits:(ByteArray |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2305 |
fromPackedString:'**J*NJ*"*#"*!!J(@*!!T*@J(DJ B*DR(@*!!T*NJ(*J B*O2(@*+.*@J*** @b'); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2306 |
colorMapFromArray:#[ 0 0 0 127 127 127 255 0 0 255 255 0 ]; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2307 |
mask:((ImageMask new) |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2308 |
width:13; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2309 |
height:11; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2310 |
bits:(ByteArray fromPackedString:'@ @B@@\@C8@O @>@C8@H @>@A0@G@@@a'); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2311 |
yourself); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2312 |
yourself |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2313 |
] |
3354 | 2314 |
|
2315 |
"Modified: / 5.11.2001 / 09:49:30 / cg" |
|
2892 | 2316 |
! |
2317 |
||
4275 | 2318 |
warningClassIcon |
7827 | 2319 |
<resource: #programImage> |
2320 |
||
2321 |
^ ToolbarIconLibrary warningClassBrowserIcon |
|
2322 |
||
2323 |
"Modified: / 20-07-2007 / 09:04:39 / cg" |
|
4275 | 2324 |
! |
2325 |
||
2892 | 2326 |
watchIcon |
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2327 |
<resource: #image> |
2892 | 2328 |
"This resource specification was automatically generated |
2329 |
by the ImageEditor of ST/X." |
|
2330 |
"Do not manually edit this!! If it is corrupted, |
|
2331 |
the ImageEditor may not be able to read the specification." |
|
2332 |
" |
|
2333 |
self watchIcon inspect |
|
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2334 |
ImageEditor openOnClass:self andSelector:#watchIcon" |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2335 |
|
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2336 |
^ Icon constantNamed:#'SystemBrowser class watchIcon' |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2337 |
ifAbsentPut:[ |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2338 |
(Depth4Image new) |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2339 |
width:13; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2340 |
height:12; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2341 |
photometric:(#palette); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2342 |
bitsPerSample:(#( 4 )); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2343 |
samplesPerPixel:(1); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2344 |
bits:(ByteArray |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2345 |
fromPackedString:'@@X@@@X@@@@AE XQY @@XALCDFD@@AD0@CDV@@XAL@@1A @AD0@P@1D@XBI!!DVH A QUPQEEU@@%"EDAVHT@IX]R@%!!5@FQUH@@%U@A&H$@@P"X@'); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2346 |
colorMapFromArray:#[ 0 0 51 0 0 60 0 51 102 51 102 153 71 102 145 128 213 221 153 153 204 153 255 255 255 255 255 ]; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2347 |
mask:((ImageMask new) |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2348 |
width:13; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2349 |
height:12; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2350 |
bits:(ByteArray fromPackedString:'FL@]0C7 O>A?<G?0??#=>O78?_#8>GA0'); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2351 |
yourself); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2352 |
yourself |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2353 |
] |
3354 | 2354 |
! |
2355 |
||
4143 | 2356 |
windowClassIcon |
7827 | 2357 |
<resource: #programImage> |
2358 |
||
2359 |
^ ToolbarIconLibrary windowClassBrowserIcon |
|
2360 |
||
2361 |
"Modified: / 20-07-2007 / 09:05:57 / cg" |
|
4143 | 2362 |
! |
2363 |
||
3354 | 2364 |
windowIcon |
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2365 |
<resource: #image> |
3354 | 2366 |
"This resource specification was automatically generated |
2367 |
by the ImageEditor of ST/X." |
|
2368 |
"Do not manually edit this!! If it is corrupted, |
|
2369 |
the ImageEditor may not be able to read the specification." |
|
2370 |
" |
|
2371 |
self windowIcon inspect |
|
14413
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2372 |
ImageEditor openOnClass:self andSelector:#windowIcon" |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2373 |
|
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2374 |
^ Icon constantNamed:#'SystemBrowser class windowIcon' |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2375 |
ifAbsentPut:[ |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2376 |
(Depth4Image new) |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2377 |
width:13; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2378 |
height:11; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2379 |
photometric:(#palette); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2380 |
bitsPerSample:(#( 4 )); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2381 |
samplesPerPixel:(1); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2382 |
bits:(ByteArray |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2383 |
fromPackedString:'@@@@@@@@@@.;.;.;.0@@@@@@@@@@C.;.;.;/@@9&Y&Y&XP@NY&Y&Y&D@C&Y&Y&Y!!@@9&Y&Y&XP@NY&Y&Y&D@C1DQDQDQ@@@@@@@@@@@b'); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2384 |
colorMapFromArray:#[ 0 0 0 255 255 255 255 0 0 0 255 0 0 0 255 0 255 255 255 255 0 255 0 255 127 0 0 0 127 0 0 0 127 0 127 127 127 127 0 127 0 127 127 127 127 170 170 170 ]; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2385 |
mask:((ImageMask new) |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2386 |
width:13; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2387 |
height:11; |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2388 |
bits:(ByteArray fromPackedString:'??#?>O?8??#?>O?8??#?>O?8??#?>@@a'); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2389 |
yourself); |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2390 |
yourself |
cdd8eaf8a5e3
Use ImageMask instead of Depth1Image for masks
Stefan Vogel <sv@exept.de>
parents:
14390
diff
changeset
|
2391 |
] |
3354 | 2392 |
|
2393 |
"Created: / 5.11.2001 / 09:39:03 / cg" |
|
2846 | 2394 |
! ! |
2692 | 2395 |
|
1203 | 2396 |
!SystemBrowser class methodsFor:'interface specs'! |
2397 |
||
1367 | 2398 |
metaSpec |
2399 |
"UIPainter new openOnClass: self andSelector: #metaSpec" |
|
2400 |
||
2401 |
<resource: #canvas> |
|
2402 |
^#(#FullSpec |
|
2403 |
#window: |
|
2404 |
#(#WindowSpec |
|
2405 |
#label: 'Unlabeled Canvas' |
|
2406 |
#bounds: #(#Rectangle 27 249 325 334 ) ) |
|
2407 |
#component: |
|
2408 |
#(#SpecCollection |
|
2409 |
#collection: #( |
|
2410 |
#(#RadioButtonSpec |
|
2411 |
#layout: #(#LayoutFrame 0 0 4 0 -1 0.575 20 0 ) |
|
2412 |
#name: #instanceSwitch |
|
2413 |
#model: #metaHolder |
|
2414 |
#callbacksSpec: |
|
2415 |
#(#UIEventCallbackSubSpec |
|
2416 |
#requestValueChangeSelector: #changeRequest ) |
|
2417 |
#label: 'instance' |
|
2418 |
#select: false ) |
|
2419 |
#(#RadioButtonSpec |
|
2420 |
#layout: #(#LayoutFrame 1 0.575 4 0 -1 1 20 0 ) |
|
2421 |
#name: #classSwitch |
|
2422 |
#model: #metaHolder |
|
2423 |
#callbacksSpec: |
|
2424 |
#(#UIEventCallbackSubSpec |
|
2425 |
#requestValueChangeSelector: #changeRequest ) |
|
2426 |
#label: 'class' |
|
2427 |
#select: true ) ) ) ) |
|
2428 |
||
2429 |
"Created: / 30.10.1997 / 19:07:29 / cg" |
|
2430 |
! |
|
2431 |
||
1203 | 2432 |
methodMoveDialogSpec |
16847 | 2433 |
"This resource specification was automatically generated |
2434 |
by the UIPainter of ST/X." |
|
2435 |
||
2436 |
"Do not manually edit this!! If it is corrupted, |
|
2437 |
the UIPainter may not be able to read the specification." |
|
1203 | 2438 |
|
2439 |
" |
|
2440 |
UIPainter new openOnClass:SystemBrowser andSelector:#methodMoveDialogSpec |
|
16847 | 2441 |
SystemBrowser new openInterface:#methodMoveDialogSpec |
1203 | 2442 |
" |
2443 |
||
2444 |
<resource: #canvas> |
|
2445 |
||
16847 | 2446 |
^ |
2447 |
#(FullSpec |
|
2448 |
name: methodMoveDialogSpec |
|
2449 |
window: |
|
2450 |
(WindowSpec |
|
2451 |
label: 'move method' |
|
2452 |
name: 'move method' |
|
2453 |
bounds: (Rectangle 0 0 387 118) |
|
2454 |
) |
|
2455 |
component: |
|
2456 |
(SpecCollection |
|
2457 |
collection: ( |
|
2458 |
(HorizontalPanelViewSpec |
|
2459 |
name: 'horizontalPanelView' |
|
2460 |
layout: (LayoutFrame 0 0.0 -35 1.0 0 1.0 -2 1.0) |
|
2461 |
level: 0 |
|
2462 |
horizontalLayout: fitSpace |
|
2463 |
verticalLayout: center |
|
2464 |
horizontalSpace: 4 |
|
2465 |
verticalSpace: 4 |
|
2466 |
component: |
|
2467 |
(SpecCollection |
|
2468 |
collection: ( |
|
2469 |
(ActionButtonSpec |
|
2470 |
label: 'cancel' |
|
2471 |
name: 'actionButton2' |
|
2472 |
translateLabel: true |
|
2473 |
tabable: true |
|
2474 |
model: cancel |
|
2475 |
extent: (Point 187 27) |
|
2476 |
) |
|
2477 |
(ActionButtonSpec |
|
2478 |
label: 'move' |
|
2479 |
name: 'actionButton1' |
|
2480 |
translateLabel: true |
|
2481 |
tabable: true |
|
2482 |
model: accept |
|
2483 |
isDefault: true |
|
2484 |
extent: (Point 188 27) |
|
2485 |
) |
|
2486 |
) |
|
2487 |
||
2488 |
) |
|
2489 |
) |
|
2490 |
(LabelSpec |
|
2491 |
label: 'move current method to which class:' |
|
2492 |
name: 'label' |
|
2493 |
layout: (LayoutFrame 2 0 2 0 -2 1.0 25 0) |
|
2494 |
style: largeLabelFont |
|
2495 |
foregroundColor: (Color 0.0 0.0 0.0) |
|
2496 |
backgroundColor: (Color 67.0 67.0 67.0) |
|
2497 |
translateLabel: true |
|
2498 |
adjust: left |
|
2499 |
) |
|
2500 |
(ComboBoxSpec |
|
2501 |
name: 'comboBox1' |
|
2502 |
layout: (LayoutFrame 2 0 29 0 -2 1.0 51 0) |
|
2503 |
tabable: true |
|
2504 |
model: className |
|
2505 |
comboList: classList |
|
2506 |
) |
|
1203 | 2507 |
) |
16847 | 2508 |
|
2509 |
) |
|
2510 |
) |
|
1203 | 2511 |
! ! |
2512 |
||
17734 | 2513 |
!SystemBrowser class methodsFor:'private-code update'! |
2514 |
||
2515 |
sourceOfMethod:mthd |
|
2516 |
|code| |
|
2517 |
||
2518 |
code := mthd source. |
|
2519 |
code notNil ifTrue:[ ^ code]. |
|
2520 |
||
2521 |
"/ wrong: even if there is no source, we |
|
2522 |
"/ should be able to type in something and accept |
|
2523 |
"/ self setNoAcceptAction. |
|
2524 |
||
2525 |
(mthd sourcePosition isNil |
|
2526 |
or:[mthd getSource isNil]) ifTrue:[ |
|
2527 |
^ '" |
|
2528 |
Sorry, but the method''s sourceCode is not available. |
|
2529 |
||
2530 |
Probably, the method''s sourceCode-info was stripped from the system. |
|
2531 |
"'. |
|
2532 |
]. |
|
2533 |
||
2534 |
^ '" |
|
2535 |
Sorry, but the method''s sourceCode is not available or corrupted. |
|
2536 |
||
2537 |
',(Smalltalk isStandAloneApp ifTrue:['If this is a deployed application, this part of the source is probably not |
|
2538 |
part of the distribution (only the base Smalltalk/X framework is open-source). |
|
2539 |
'] ifFalse:['']),' |
|
2540 |
Please check the setting of your packagePath, which contains a collection of pathNames. |
|
2541 |
The system searches those directories for a package-subdirectories, |
|
19546 | 2542 |
which should either contain the class''s source file. |
17734 | 2543 |
Also, check if that directory and/or sourceFile grants read access. |
2544 |
The packagePath can be accessed via |
|
2545 |
Smalltalk packagePath |
|
2546 |
||
2547 |
To fix this (in the running system), evaluate: |
|
2548 |
Smalltalk packagePath addFirst:''<<pathOfDirContainingPackageDir>>''. |
|
2549 |
Smalltalk flushPathCaches. |
|
2550 |
||
2551 |
You may also want to add those statements to the end of your ''private.rc'' |
|
2552 |
file - so you will not get this error again and again. |
|
2553 |
||
2554 |
Also, check if you have the sourceCodeManagement (CVS) enabled, |
|
2555 |
and (if so) configured correctly. |
|
2556 |
||
2557 |
If all of the above fail, and you know the path of the source file, |
|
2558 |
you can workaround the problem, by adding a symbolic link to that sourcefile |
|
2559 |
in the ''source'' directory. |
|
2560 |
"'. |
|
2561 |
||
2562 |
"Modified: / 09-11-2017 / 08:16:28 / cg" |
|
2563 |
! ! |
|
2564 |
||
4860 | 2565 |
!SystemBrowser class methodsFor:'private-helpers'! |
36 | 2566 |
|
2880
ef6fcc02a924
give user a chance to suppress the annoying package-change-keep
Claus Gittinger <cg@exept.de>
parents:
2846
diff
changeset
|
2567 |
askForPackageChangeFrom:oldPkg to:newPkg |
3626 | 2568 |
|answer box notAgain chk| |
2880
ef6fcc02a924
give user a chance to suppress the annoying package-change-keep
Claus Gittinger <cg@exept.de>
parents:
2846
diff
changeset
|
2569 |
|
ef6fcc02a924
give user a chance to suppress the annoying package-change-keep
Claus Gittinger <cg@exept.de>
parents:
2846
diff
changeset
|
2570 |
box := OptionBox |
ef6fcc02a924
give user a chance to suppress the annoying package-change-keep
Claus Gittinger <cg@exept.de>
parents:
2846
diff
changeset
|
2571 |
title: |
ef6fcc02a924
give user a chance to suppress the annoying package-change-keep
Claus Gittinger <cg@exept.de>
parents:
2846
diff
changeset
|
2572 |
('You are about to change a method from another (system-) package. |
17775 | 2573 |
The method''s original packageID was ''%1''. |
2880
ef6fcc02a924
give user a chance to suppress the annoying package-change-keep
Claus Gittinger <cg@exept.de>
parents:
2846
diff
changeset
|
2574 |
If you proceed, the new method will be marked as belonging |
ef6fcc02a924
give user a chance to suppress the annoying package-change-keep
Claus Gittinger <cg@exept.de>
parents:
2846
diff
changeset
|
2575 |
to the ''%2'' package (and this warning will not be shown again). |
ef6fcc02a924
give user a chance to suppress the annoying package-change-keep
Claus Gittinger <cg@exept.de>
parents:
2846
diff
changeset
|
2576 |
If you proceed with ''keep'', the new method will be installed |
ef6fcc02a924
give user a chance to suppress the annoying package-change-keep
Claus Gittinger <cg@exept.de>
parents:
2846
diff
changeset
|
2577 |
but the old packageID will be preserved. |
ef6fcc02a924
give user a chance to suppress the annoying package-change-keep
Claus Gittinger <cg@exept.de>
parents:
2846
diff
changeset
|
2578 |
Otherwise, hit ''cancel'' to leave the code unchanged. |
ef6fcc02a924
give user a chance to suppress the annoying package-change-keep
Claus Gittinger <cg@exept.de>
parents:
2846
diff
changeset
|
2579 |
|
ef6fcc02a924
give user a chance to suppress the annoying package-change-keep
Claus Gittinger <cg@exept.de>
parents:
2846
diff
changeset
|
2580 |
PS: if you disable this check here, it can be reenabled it in the launchers settings-compilation dialog.' |
ef6fcc02a924
give user a chance to suppress the annoying package-change-keep
Claus Gittinger <cg@exept.de>
parents:
2846
diff
changeset
|
2581 |
bindWith:(oldPkg allBold) |
ef6fcc02a924
give user a chance to suppress the annoying package-change-keep
Claus Gittinger <cg@exept.de>
parents:
2846
diff
changeset
|
2582 |
with:(newPkg allBold)) |
ef6fcc02a924
give user a chance to suppress the annoying package-change-keep
Claus Gittinger <cg@exept.de>
parents:
2846
diff
changeset
|
2583 |
numberOfOptions:3. |
ef6fcc02a924
give user a chance to suppress the annoying package-change-keep
Claus Gittinger <cg@exept.de>
parents:
2846
diff
changeset
|
2584 |
|
3476 | 2585 |
box buttonTitles:#('Cancel' 'Keep' 'Continue'). |
2880
ef6fcc02a924
give user a chance to suppress the annoying package-change-keep
Claus Gittinger <cg@exept.de>
parents:
2846
diff
changeset
|
2586 |
box defaultButtonIndex:3. |
ef6fcc02a924
give user a chance to suppress the annoying package-change-keep
Claus Gittinger <cg@exept.de>
parents:
2846
diff
changeset
|
2587 |
box action:[:n | answer := #(#cancel #keep #continue) at:n]. |
5833
5c2a75846afc
Do not use obsolete methods with #form:
Stefan Vogel <sv@exept.de>
parents:
5802
diff
changeset
|
2588 |
box label:'Method redefinition'; image:(WarningBox iconBitmap). |
2880
ef6fcc02a924
give user a chance to suppress the annoying package-change-keep
Claus Gittinger <cg@exept.de>
parents:
2846
diff
changeset
|
2589 |
box yPosition:(box formLabel bottom max:box textLabel bottom). |
ef6fcc02a924
give user a chance to suppress the annoying package-change-keep
Claus Gittinger <cg@exept.de>
parents:
2846
diff
changeset
|
2590 |
box addVerticalSpace:10. |
17043 | 2591 |
chk := box addCheckBoxAtBottom:'Don''t show this dialog again (never keep)' on:(notAgain := false asValue). |
8158
f7b891e7fb75
added preferredWidth & preferredHeight
Claus Gittinger <cg@exept.de>
parents:
8139
diff
changeset
|
2592 |
box preferredExtent:(box preferredExtent + (0 @ chk preferredHeight) + (0@10)). |
2880
ef6fcc02a924
give user a chance to suppress the annoying package-change-keep
Claus Gittinger <cg@exept.de>
parents:
2846
diff
changeset
|
2593 |
box resize. |
ef6fcc02a924
give user a chance to suppress the annoying package-change-keep
Claus Gittinger <cg@exept.de>
parents:
2846
diff
changeset
|
2594 |
box showAtPointer. |
ef6fcc02a924
give user a chance to suppress the annoying package-change-keep
Claus Gittinger <cg@exept.de>
parents:
2846
diff
changeset
|
2595 |
box destroy. |
ef6fcc02a924
give user a chance to suppress the annoying package-change-keep
Claus Gittinger <cg@exept.de>
parents:
2846
diff
changeset
|
2596 |
|
ef6fcc02a924
give user a chance to suppress the annoying package-change-keep
Claus Gittinger <cg@exept.de>
parents:
2846
diff
changeset
|
2597 |
(answer ~~ #cancel) ifTrue:[ |
ef6fcc02a924
give user a chance to suppress the annoying package-change-keep
Claus Gittinger <cg@exept.de>
parents:
2846
diff
changeset
|
2598 |
notAgain value ifTrue:[ |
ef6fcc02a924
give user a chance to suppress the annoying package-change-keep
Claus Gittinger <cg@exept.de>
parents:
2846
diff
changeset
|
2599 |
Class catchMethodRedefinitions:false. |
ef6fcc02a924
give user a chance to suppress the annoying package-change-keep
Claus Gittinger <cg@exept.de>
parents:
2846
diff
changeset
|
2600 |
]. |
ef6fcc02a924
give user a chance to suppress the annoying package-change-keep
Claus Gittinger <cg@exept.de>
parents:
2846
diff
changeset
|
2601 |
]. |
ef6fcc02a924
give user a chance to suppress the annoying package-change-keep
Claus Gittinger <cg@exept.de>
parents:
2846
diff
changeset
|
2602 |
^ answer. |
11291
d4d27edd6ab4
changed: #askForPackageChangeFrom:to:
Claus Gittinger <cg@exept.de>
parents:
11271
diff
changeset
|
2603 |
|
17775 | 2604 |
"Modified: / 21-11-2017 / 13:09:11 / cg" |
2880
ef6fcc02a924
give user a chance to suppress the annoying package-change-keep
Claus Gittinger <cg@exept.de>
parents:
2846
diff
changeset
|
2605 |
! |
ef6fcc02a924
give user a chance to suppress the annoying package-change-keep
Claus Gittinger <cg@exept.de>
parents:
2846
diff
changeset
|
2606 |
|
203 | 2607 |
showNoneFound |
3244 | 2608 |
self warn:(self classResources string:'None found.'). |
203 | 2609 |
! |
36 | 2610 |
|
203 | 2611 |
showNoneFound:what |
1620 | 2612 |
|rs| |
2613 |
||
2614 |
rs := self classResources. |
|
3244 | 2615 |
self information:((rs string:what) , (rs string:'...\\... none found.')) withCRs. |
203 | 2616 |
! ! |
36 | 2617 |
|
4860 | 2618 |
!SystemBrowser class methodsFor:'private-instance creation'! |
203 | 2619 |
|
2620 |
newWithLabel:aString setupBlock:aBlock |
|
2621 |
"common helper method for all creation methods" |
|
2622 |
||
2623 |
^ self newWithLabel:aString setupBlock:aBlock onDevice:Screen current |
|
36 | 2624 |
! |
2625 |
||
203 | 2626 |
newWithLabel:aString setupBlock:aBlock onDevice:aWorkstation |
2627 |
"common helper method for all creation methods" |
|
36 | 2628 |
|
203 | 2629 |
|newBrowser| |
45 | 2630 |
|
203 | 2631 |
newBrowser := BrowserView onDevice:aWorkstation. |
2632 |
newBrowser title:aString. |
|
2633 |
aBlock value:newBrowser. |
|
45 | 2634 |
|
203 | 2635 |
newBrowser open. |
2636 |
^ newBrowser |
|
2637 |
! |
|
45 | 2638 |
|
203 | 2639 |
newWithLabel:aString setupSelector:aSymbol arg:arg |
2640 |
"common helper method for all creation methods" |
|
36 | 2641 |
|
203 | 2642 |
^ self newWithLabel:aString setupSelector:aSymbol arg:arg onDevice:Screen current |
36 | 2643 |
! |
2644 |
||
203 | 2645 |
newWithLabel:aString setupSelector:aSymbol arg:arg onDevice:aWorkstation |
2646 |
"common helper method for all creation methods" |
|
2647 |
||
2648 |
|newBrowser| |
|
52 | 2649 |
|
203 | 2650 |
newBrowser := BrowserView onDevice:aWorkstation. |
2651 |
newBrowser title:aString. |
|
2652 |
newBrowser perform:aSymbol with:arg. |
|
2653 |
newBrowser open. |
|
2654 |
^ newBrowser |
|
2655 |
! ! |
|
2656 |
||
820
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
2657 |
!SystemBrowser class methodsFor:'special search startup'! |
203 | 2658 |
|
996
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2659 |
allCallsOn:aSelectorString |
16449 | 2660 |
"return a collection of methods which send aSelector. |
2661 |
This takes some time, because source code is parsed to see |
|
2662 |
if there is really a message send inside (and not just a symbol reference)" |
|
996
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2663 |
|
9007 | 2664 |
^ self |
2665 |
allCallsOn:aSelectorString |
|
2666 |
in:(Smalltalk allClasses) |
|
2667 |
ignoreCase:false |
|
2668 |
match:false |
|
996
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2669 |
|
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2670 |
" |
16449 | 2671 |
Time millisecondsToRun:[ |
2672 |
SystemBrowser allCallsOn:#at:put: |
|
2673 |
]. |
|
996
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2674 |
" |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2675 |
|
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2676 |
"Created: 24.1.1997 / 19:42:57 / cg" |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2677 |
! |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2678 |
|
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2679 |
allCallsOn:aSelectorString in:aCollectionOfClasses |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2680 |
"return a collection of methods which send aSelector. |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2681 |
Methods from classes in aCollectionOfClasses are searched only." |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2682 |
|
9007 | 2683 |
^ self |
2684 |
allCallsOn:aSelectorString |
|
2685 |
in:aCollectionOfClasses |
|
2686 |
ignoreCase:false |
|
2687 |
match:false |
|
2623
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2688 |
! |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2689 |
|
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2690 |
allCallsOn:aSelectorString in:aCollectionOfClasses ignoreCase:ignoreCase |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2691 |
"return a collection of methods which send aSelector. |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2692 |
Methods from classes in aCollectionOfClasses are searched only." |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2693 |
|
9007 | 2694 |
^ self |
2695 |
allCallsOn:aSelectorString |
|
2696 |
in:aCollectionOfClasses |
|
2697 |
ignoreCase:ignoreCase |
|
2698 |
match:true |
|
4270 | 2699 |
|
2700 |
" |
|
2701 |
SystemBrowser allCallsOn:#at:put: in:(Smalltalk allClasses) |
|
2702 |
" |
|
2703 |
||
2704 |
"Modified: 18.4.1997 / 10:32:50 / cg" |
|
2705 |
! |
|
2706 |
||
16395 | 2707 |
allCallsOn:aSelectorString in:aCollectionOfClasses ignoreCase:ignoreCase match:doMatchArg |
4270 | 2708 |
"return a collection of methods which send aSelector. |
2709 |
Methods from classes in aCollectionOfClasses are searched only." |
|
2710 |
||
16395 | 2711 |
|doMatch sel searchBlock classesSearched| |
2712 |
||
2713 |
doMatch := doMatchArg. |
|
2714 |
(doMatch and:[aSelectorString includesMatchCharacters not]) ifTrue:[ |
|
2715 |
doMatch := false. |
|
2716 |
]. |
|
2717 |
||
3471
4c4b41516d96
care for empty selector in allCallsOn.
Claus Gittinger <cg@exept.de>
parents:
3470
diff
changeset
|
2718 |
aSelectorString size == 0 ifTrue:[ ^ #() ]. |
16395 | 2719 |
(doMatch or:[ignoreCase]) ifFalse:[ |
2720 |
"/ no need to search, if there is no such symbol in the system |
|
2721 |
sel := aSelectorString asSymbolIfInterned. |
|
2722 |
sel isNil ifTrue:[ ^ #() ]. "/ none (no such selector) |
|
4270 | 2723 |
]. |
4235
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
2724 |
|
2901 | 2725 |
classesSearched := aCollectionOfClasses. |
16395 | 2726 |
doMatch ifFalse:[ |
2727 |
"/ exclude all javaClasses, if the selector cannot be a valid java-selector |
|
4270 | 2728 |
(aSelectorString includes:$() ifFalse:[ |
12831 | 2729 |
classesSearched := classesSearched reject:[:eachClass | eachClass theNonMetaclass isJavaClass ]. |
2846 | 2730 |
]. |
996
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2731 |
]. |
4235
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
2732 |
|
4270 | 2733 |
searchBlock := self searchBlockForAllCallsOn:aSelectorString ignoreCase:ignoreCase match:doMatch. |
4332 | 2734 |
searchBlock isNil ifTrue:[ |
2735 |
^ #() "/ none (no such selector) |
|
2736 |
]. |
|
2901 | 2737 |
^ self allMethodsIn:classesSearched where:searchBlock |
996
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2738 |
|
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2739 |
" |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2740 |
SystemBrowser allCallsOn:#at:put: in:(Smalltalk allClasses) |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2741 |
" |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2742 |
|
1143
0707461e582a
avoid compilation of lazy methods when searching for senders
Claus Gittinger <cg@exept.de>
parents:
1059
diff
changeset
|
2743 |
"Modified: 18.4.1997 / 10:32:50 / cg" |
996
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2744 |
! |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2745 |
|
19026 | 2746 |
allCallsUsingReturnValueOn:aSelectorString in:aCollectionOfClasses ignoreCase:ignoreCase match:doMatchArg |
2747 |
"return a collection of methods which send aSelector and use the return value. |
|
2748 |
Methods from classes in aCollectionOfClasses are searched only." |
|
2749 |
||
2750 |
|doMatch sel searchBlock classesSearched| |
|
2751 |
||
2752 |
doMatch := doMatchArg. |
|
2753 |
(doMatch and:[aSelectorString includesMatchCharacters not]) ifTrue:[ |
|
2754 |
doMatch := false. |
|
2755 |
]. |
|
2756 |
||
2757 |
aSelectorString size == 0 ifTrue:[ ^ #() ]. |
|
2758 |
(doMatch or:[ignoreCase]) ifFalse:[ |
|
2759 |
"/ no need to search, if there is no such symbol in the system |
|
2760 |
sel := aSelectorString asSymbolIfInterned. |
|
2761 |
sel isNil ifTrue:[ ^ #() ]. "/ none (no such selector) |
|
2762 |
]. |
|
2763 |
||
2764 |
classesSearched := aCollectionOfClasses. |
|
2765 |
doMatch ifFalse:[ |
|
2766 |
"/ exclude all javaClasses, if the selector cannot be a valid java-selector |
|
2767 |
(aSelectorString includes:$() ifFalse:[ |
|
2768 |
classesSearched := classesSearched reject:[:eachClass | eachClass theNonMetaclass isJavaClass ]. |
|
2769 |
]. |
|
2770 |
]. |
|
2771 |
||
2772 |
searchBlock := self searchBlockForAllCallsUsingReturnValueOn:aSelectorString ignoreCase:ignoreCase match:doMatch. |
|
2773 |
searchBlock isNil ifTrue:[ |
|
2774 |
^ #() "/ none (no such selector) |
|
2775 |
]. |
|
2776 |
^ self allMethodsIn:classesSearched where:searchBlock |
|
2777 |
||
2778 |
" |
|
2779 |
SystemBrowser allCallsOn:#at:put: in:(Smalltalk allClasses) |
|
2780 |
" |
|
2781 |
||
2782 |
"Modified: 18.4.1997 / 10:32:50 / cg" |
|
2783 |
! |
|
2784 |
||
996
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2785 |
allMethodsIn:aCollectionOfClasses inst:wantInst class:wantClass where:aBlock |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2786 |
"return a collection of methods which pass the given test. |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2787 |
wantInst/wantClass control if instMethods and/or classMethods are to be |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2788 |
considered. |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2789 |
Only classes in aCollectionOfClasses are inspected in the search" |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2790 |
|
2769 | 2791 |
|list activePriority| |
996
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2792 |
|
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2793 |
" |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2794 |
since this may take a long time, lower my priority ... |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2795 |
" |
2769 | 2796 |
activePriority := Processor activePriority. |
2295
4e05198e7dd8
execute BG tasks at a prio range, to ensure progress.
Claus Gittinger <cg@exept.de>
parents:
2208
diff
changeset
|
2797 |
Processor activeProcess |
2769 | 2798 |
withPriority:activePriority-1 to:activePriority |
2295
4e05198e7dd8
execute BG tasks at a prio range, to ensure progress.
Claus Gittinger <cg@exept.de>
parents:
2208
diff
changeset
|
2799 |
do:[ |
2484
afd8d8dbd9e2
care vor methods being found in multiple classes
Claus Gittinger <cg@exept.de>
parents:
2439
diff
changeset
|
2800 |
|checkedClasses checkBlock detectedMethods| |
996
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2801 |
|
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2802 |
checkedClasses := IdentitySet new. |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2803 |
list := OrderedCollection new. |
2484
afd8d8dbd9e2
care vor methods being found in multiple classes
Claus Gittinger <cg@exept.de>
parents:
2439
diff
changeset
|
2804 |
detectedMethods := IdentitySet new. |
996
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2805 |
|
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2806 |
checkBlock := [:cls | |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2807 |
(checkedClasses includes:cls) ifFalse:[ |
8554
441ea25ad1fd
Do not complain about obsolete classes which are unloaded when searching
Stefan Vogel <sv@exept.de>
parents:
8505
diff
changeset
|
2808 |
(cls isObsolete and:[cls isLoaded]) ifTrue:[ |
17466 | 2809 |
Logger debug:'Browser method search: skipping obsolete class: %1' with:cls displayString |
996
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2810 |
] ifFalse:[ |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2811 |
cls methodDictionary keysAndValuesDo:[:sel :method | |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2812 |
(aBlock value:cls value:method value:sel) ifTrue:[ |
2484
afd8d8dbd9e2
care vor methods being found in multiple classes
Claus Gittinger <cg@exept.de>
parents:
2439
diff
changeset
|
2813 |
"/ care for methods being in multiple classes (should not happen) |
afd8d8dbd9e2
care vor methods being found in multiple classes
Claus Gittinger <cg@exept.de>
parents:
2439
diff
changeset
|
2814 |
(detectedMethods includes:method) ifFalse:[ |
afd8d8dbd9e2
care vor methods being found in multiple classes
Claus Gittinger <cg@exept.de>
parents:
2439
diff
changeset
|
2815 |
list add:method. |
afd8d8dbd9e2
care vor methods being found in multiple classes
Claus Gittinger <cg@exept.de>
parents:
2439
diff
changeset
|
2816 |
detectedMethods add:method |
afd8d8dbd9e2
care vor methods being found in multiple classes
Claus Gittinger <cg@exept.de>
parents:
2439
diff
changeset
|
2817 |
] |
996
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2818 |
] |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2819 |
]. |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2820 |
checkedClasses add:cls. |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2821 |
] |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2822 |
] |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2823 |
]. |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2824 |
|
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2825 |
aCollectionOfClasses do:[:aClass | |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2826 |
" |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2827 |
output disabled - it slows down things too much (when searching for |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2828 |
implementors or senders) |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2829 |
" |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2830 |
wantInst ifTrue:[ |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2831 |
"/ Transcript show:'searching '; show:aClass name; showCR:' ...'; endEntry. |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2832 |
checkBlock value:aClass |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2833 |
]. |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2834 |
wantClass ifTrue:[ |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2835 |
"/ Transcript show:'searching '; show:aClass class name; showCR:' ...'; endEntry. |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2836 |
checkBlock value:(aClass class) |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2837 |
]. |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2838 |
Processor yield |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2839 |
] |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2840 |
]. |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2841 |
^ list |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2842 |
|
17466 | 2843 |
"Created: / 24-01-1997 / 19:41:12 / cg" |
2844 |
"Modified: / 14-03-2017 / 12:05:41 / cg" |
|
996
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2845 |
! |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2846 |
|
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2847 |
allMethodsIn:aCollectionOfClasses where:aBlock |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2848 |
"return a collection of methods which pass the given test. |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2849 |
Only classes in aCollectionOfClasses are inspected in the search" |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2850 |
|
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2851 |
^ self |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2852 |
allMethodsIn:aCollectionOfClasses |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2853 |
inst:true |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2854 |
class:true |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2855 |
where:aBlock |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2856 |
|
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2857 |
"Created: 24.1.1997 / 19:41:49 / cg" |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2858 |
! |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2859 |
|
203 | 2860 |
aproposSearch:aString |
2655
9e90bbd1eb18
apropos search is now: selectors containing
Claus Gittinger <cg@exept.de>
parents:
2642
diff
changeset
|
2861 |
"browse all methods, which have aString in their selector." |
203 | 2862 |
|
2863 |
^ self aproposSearch:aString in:(Smalltalk allClasses) |
|
75 | 2864 |
|
52 | 2865 |
! |
2866 |
||
203 | 2867 |
aproposSearch:aString in:aCollectionOfClasses |
2655
9e90bbd1eb18
apropos search is now: selectors containing
Claus Gittinger <cg@exept.de>
parents:
2642
diff
changeset
|
2868 |
"browse all methods, which have aString. |
203 | 2869 |
This is relatively slow, since all source must be processed." |
52 | 2870 |
|
203 | 2871 |
|matchString list s searchBlock browser| |
52 | 2872 |
|
203 | 2873 |
matchString := '*' , aString , '*'. |
52 | 2874 |
|
203 | 2875 |
list := OrderedCollection new. |
52 | 2876 |
|
203 | 2877 |
(aString includesMatchCharacters) ifTrue:[ |
2655
9e90bbd1eb18
apropos search is now: selectors containing
Claus Gittinger <cg@exept.de>
parents:
2642
diff
changeset
|
2878 |
s := '*' , aString asLowercase , '*'. |
256 | 2879 |
"a matchString" |
2880 |
searchBlock := [:text | (text asCollectionOfLinesfindFirst:[:line | s match:line]) ~~ 0]. |
|
203 | 2881 |
] ifFalse:[ |
2655
9e90bbd1eb18
apropos search is now: selectors containing
Claus Gittinger <cg@exept.de>
parents:
2642
diff
changeset
|
2882 |
searchBlock := [:source | (source findString:aString asLowercase) ~~ 0] |
203 | 2883 |
]. |
52 | 2884 |
|
203 | 2885 |
browser := self browseMethodsIn:aCollectionOfClasses |
256 | 2886 |
where:[:class :method :sel | |
2887 |
|comment| |
|
52 | 2888 |
|
2655
9e90bbd1eb18
apropos search is now: selectors containing
Claus Gittinger <cg@exept.de>
parents:
2642
diff
changeset
|
2889 |
(searchBlock value:sel asLowercase) |
256 | 2890 |
] |
2729
9af04074a4bb
no direct access to super-class-instvars
Claus Gittinger <cg@exept.de>
parents:
2728
diff
changeset
|
2891 |
title:(self classResources string:'selectors containing: %1' with:aString). |
52 | 2892 |
|
203 | 2893 |
browser notNil ifTrue:[ |
256 | 2894 |
browser autoSearch:aString |
203 | 2895 |
]. |
2896 |
^ browser |
|
52 | 2897 |
|
2898 |
" |
|
203 | 2899 |
SystemBrowser aproposSearch:'append' in:(Collection withAllSubclasses) |
2900 |
SystemBrowser aproposSearch:'add' in:(Collection withAllSubclasses) |
|
2901 |
SystemBrowser aproposSearch:'sort' in:(Collection withAllSubclasses) |
|
2902 |
SystemBrowser aproposSearch:'[Aa]bsent' in:(Collection withAllSubclasses) |
|
52 | 2903 |
" |
203 | 2904 |
|
256 | 2905 |
"Created: 9.12.1995 / 18:02:36 / cg" |
204
6f4460d5a09d
added supersend searches; offer comparing the current version with the
Claus Gittinger <cg@exept.de>
parents:
203
diff
changeset
|
2906 |
! |
6f4460d5a09d
added supersend searches; offer comparing the current version with the
Claus Gittinger <cg@exept.de>
parents:
203
diff
changeset
|
2907 |
|
203 | 2908 |
browseAllCallsOn:aSelectorString |
4490 | 2909 |
"launch a browser for all senders of aSelector. |
2910 |
Notice: better go via Smalltalk browseAllCallsOn:, which honors the tool-preferences" |
|
52 | 2911 |
|
2623
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2912 |
^ self |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2913 |
browseAllCallsOn:aSelectorString |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2914 |
in:(Smalltalk allClasses) |
52 | 2915 |
|
2916 |
" |
|
203 | 2917 |
SystemBrowser browseAllCallsOn:#+ |
52 | 2918 |
" |
256 | 2919 |
|
2920 |
"Created: 9.12.1995 / 18:00:41 / cg" |
|
666 | 2921 |
"Modified: 10.7.1996 / 10:26:15 / cg" |
2922 |
! |
|
2923 |
||
2924 |
browseAllCallsOn:aSelectorString in:aSetOfClasses |
|
2925 |
"launch a browser for all senders of aSelector" |
|
2926 |
||
996
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2927 |
^ self |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2928 |
browseAllCallsOn:aSelectorString |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2929 |
in:aSetOfClasses |
4200 | 2930 |
title:(self classResources string:'Senders of: %1' with:aSelectorString) |
666 | 2931 |
|
2932 |
" |
|
2933 |
SystemBrowser browseAllCallsOn:#+ in:(Number withAllSubclasses) |
|
2934 |
" |
|
2935 |
||
2936 |
"Created: 10.7.1996 / 10:25:49 / cg" |
|
996
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2937 |
"Modified: 24.1.1997 / 19:49:34 / cg" |
52 | 2938 |
! |
2939 |
||
2623
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2940 |
browseAllCallsOn:aSelectorString in:aSetOfClasses ignoreCase:ignoreCase |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2941 |
"launch a browser for all senders of aSelector" |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2942 |
|
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2943 |
^ self |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2944 |
browseAllCallsOn:aSelectorString |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2945 |
in:aSetOfClasses |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2946 |
ignoreCase:ignoreCase |
6476 | 2947 |
title:(self classResources string:'Senders of: %1' with:aSelectorString) |
2623
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2948 |
|
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2949 |
" |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2950 |
SystemBrowser browseAllCallsOn:#+ in:(Number withAllSubclasses) |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2951 |
" |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2952 |
|
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2953 |
"Created: 10.7.1996 / 10:25:49 / cg" |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2954 |
"Modified: 24.1.1997 / 19:49:34 / cg" |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2955 |
! |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2956 |
|
11271 | 2957 |
browseAllCallsOn:aSelectorString in:aCollectionOfClasses ignoreCase:ignoreCase match:match title:titleArg |
52 | 2958 |
"launch a browser for all senders of aSelector in aCollectionOfClasses" |
2959 |
||
5256
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
2960 |
|list list2 browser selWithColon title rs| |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
2961 |
|
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
2962 |
title := titleArg. |
4200 | 2963 |
|
4270 | 2964 |
list := self allCallsOn:aSelectorString in:aCollectionOfClasses ignoreCase:ignoreCase match:true. |
4200 | 2965 |
list isEmpty ifTrue:[ |
19130 | 2966 |
aSelectorString argumentCount == 0 ifTrue:[ |
5256
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
2967 |
selWithColon := aSelectorString , ':'. |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
2968 |
selWithColon knownAsSymbol ifTrue:[ |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
2969 |
list2 := self allCallsOn:selWithColon in:aCollectionOfClasses ignoreCase:ignoreCase match:true. |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
2970 |
]. |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
2971 |
]. |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
2972 |
list2 size == 0 ifTrue:[ |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
2973 |
self showNoneFound:title. |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
2974 |
^ nil |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
2975 |
]. |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
2976 |
rs := self classResources. |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
2977 |
(Dialog confirm:((rs string:title) , |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
2978 |
(rs string:'...\\... none found.') , |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
2979 |
(rs string:'\\But I found %1 sends of the "%2" message (with colon).\\Browse those ?' |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
2980 |
with:list2 size |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
2981 |
with:selWithColon allBold)) withCRs) ifFalse:[ |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
2982 |
^ nil |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
2983 |
]. |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
2984 |
list := list2. |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
2985 |
title := title , ':'. |
4200 | 2986 |
]. |
2987 |
||
2988 |
browser := self browseMethods:list title:title. |
|
52 | 2989 |
browser notNil ifTrue:[ |
648
6ec086b7972c
Move method's literals form literalArray to indexed instvars.
Stefan Vogel <sv@exept.de>
parents:
634
diff
changeset
|
2990 |
|s| |
52 | 2991 |
|
8139
acdaec7c63a0
auto-search for selector (not string) when searching senders.
Claus Gittinger <cg@exept.de>
parents:
8129
diff
changeset
|
2992 |
"/ " |
17404 | 2993 |
"/ kludge for now, if it's a multipart selector, |
8139
acdaec7c63a0
auto-search for selector (not string) when searching senders.
Claus Gittinger <cg@exept.de>
parents:
8129
diff
changeset
|
2994 |
"/ no easy search is (as yet) possible |
acdaec7c63a0
auto-search for selector (not string) when searching senders.
Claus Gittinger <cg@exept.de>
parents:
8129
diff
changeset
|
2995 |
"/ " |
acdaec7c63a0
auto-search for selector (not string) when searching senders.
Claus Gittinger <cg@exept.de>
parents:
8129
diff
changeset
|
2996 |
"/ s := aSelectorString. |
acdaec7c63a0
auto-search for selector (not string) when searching senders.
Claus Gittinger <cg@exept.de>
parents:
8129
diff
changeset
|
2997 |
"/ (s includes:$:) ifTrue:[ |
acdaec7c63a0
auto-search for selector (not string) when searching senders.
Claus Gittinger <cg@exept.de>
parents:
8129
diff
changeset
|
2998 |
"/ s := s copyTo:(s indexOf:$:) |
acdaec7c63a0
auto-search for selector (not string) when searching senders.
Claus Gittinger <cg@exept.de>
parents:
8129
diff
changeset
|
2999 |
"/ ]. |
acdaec7c63a0
auto-search for selector (not string) when searching senders.
Claus Gittinger <cg@exept.de>
parents:
8129
diff
changeset
|
3000 |
"/ browser autoSearch:s |
16471 | 3001 |
browser setSearchSelector:aSelectorString ignoreCase:ignoreCase doMatch:true. |
52 | 3002 |
]. |
3003 |
^ browser |
|
648
6ec086b7972c
Move method's literals form literalArray to indexed instvars.
Stefan Vogel <sv@exept.de>
parents:
634
diff
changeset
|
3004 |
|
996
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
3005 |
" |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
3006 |
SystemBrowser |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
3007 |
browseAllCallsOn:#+ |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
3008 |
in:(Number withAllSubclasses) |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
3009 |
title:'just a test' |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
3010 |
" |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
3011 |
|
11271 | 3012 |
"Modified: / 24-01-1997 / 19:48:54 / cg" |
3013 |
"Created: / 14-02-2012 / 14:19:51 / cg" |
|
17404 | 3014 |
"Modified (format): / 13-02-2017 / 20:31:46 / cg" |
11271 | 3015 |
! |
3016 |
||
3017 |
browseAllCallsOn:aSelectorString in:aCollectionOfClasses ignoreCase:ignoreCase title:titleArg |
|
3018 |
"launch a browser for all senders of aSelector in aCollectionOfClasses" |
|
3019 |
||
3020 |
^ self |
|
3021 |
browseAllCallsOn:aSelectorString |
|
3022 |
in:aCollectionOfClasses |
|
3023 |
ignoreCase:ignoreCase |
|
3024 |
match:true |
|
3025 |
title:titleArg |
|
3026 |
||
3027 |
" |
|
3028 |
SystemBrowser |
|
3029 |
browseAllCallsOn:#+ |
|
3030 |
in:(Number withAllSubclasses) |
|
3031 |
title:'just a test' |
|
3032 |
" |
|
3033 |
||
3034 |
"Modified: / 14-02-2012 / 14:20:17 / cg" |
|
52 | 3035 |
! |
3036 |
||
2623
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3037 |
browseAllCallsOn:aSelectorString in:aCollectionOfClasses title:title |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3038 |
"launch a browser for all senders of aSelector in aCollectionOfClasses" |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3039 |
|
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3040 |
^ self |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3041 |
browseAllCallsOn:aSelectorString |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3042 |
in:aCollectionOfClasses |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3043 |
ignoreCase:false |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3044 |
title:title |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3045 |
|
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3046 |
" |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3047 |
SystemBrowser |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3048 |
browseAllCallsOn:#+ |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3049 |
in:(Number withAllSubclasses) |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3050 |
title:'just a test' |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3051 |
" |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3052 |
|
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3053 |
"Modified: 24.1.1997 / 19:48:54 / cg" |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3054 |
! |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3055 |
|
203 | 3056 |
browseCallsOn:aSelectorString under:aClass |
3057 |
"launch a browser for all senders of aSelector in aClass and subclasses" |
|
3058 |
||
996
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
3059 |
^ self |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
3060 |
browseAllCallsOn:aSelectorString |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
3061 |
in:(aClass withAllSubclasses) |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
3062 |
title:(self classResources |
6476 | 3063 |
string:'Senders of: %1 (in and below %2)' |
996
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
3064 |
with:aSelectorString |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
3065 |
with:aClass name) |
203 | 3066 |
|
3067 |
" |
|
256 | 3068 |
SystemBrowser browseCallsOn:#+ under:Number |
203 | 3069 |
" |
256 | 3070 |
|
3071 |
"Created: 9.12.1995 / 17:59:57 / cg" |
|
996
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
3072 |
"Modified: 24.1.1997 / 19:50:33 / cg" |
203 | 3073 |
! |
3074 |
||
3075 |
browseClassRefsTo:aString in:aCollectionOfClasses modificationsOnly:modsOnly |
|
3076 |
"launch a browser for all methods in aClass where the classVar named |
|
3077 |
aString is referenced; if modsOnly is true, browse only methods where the |
|
3078 |
classvar is modified" |
|
3079 |
||
3080 |
^ self browseRefsTo:aString classVars:true in:aCollectionOfClasses modificationsOnly:modsOnly |
|
3081 |
! |
|
3082 |
||
3083 |
browseClassRefsTo:varName in:aCollectionOfClasses modificationsOnly:modsOnly title:title |
|
3084 |
"launch a browser for all methods in aCollectionOfClasses, |
|
3085 |
where the classVar named aString is referenced; |
|
3086 |
if modsOnly is true, browse only methods where the classvar is modified" |
|
3087 |
||
3088 |
^ self browseRefsTo:varName classVars:true in:aCollectionOfClasses modificationsOnly:modsOnly title:title |
|
3089 |
! |
|
3090 |
||
3091 |
browseClassRefsTo:aString under:aClass modificationsOnly:modsOnly |
|
3092 |
"launch a browser for all methods in aClass and subclasses |
|
3093 |
where the classVar named aString is referenced; |
|
3094 |
if modsOnly is true, browse only methods where the classvar is modified" |
|
3095 |
||
3096 |
^ self browseClassRefsTo:aString in:(aClass withAllSubclasses) modificationsOnly:modsOnly |
|
3097 |
||
3098 |
! |
|
3099 |
||
929
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
3100 |
browseForResource:aResourceSymbol containing:item in:aCollectionOfClasses title:title |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
3101 |
"launch a browser for all methods which have a particular (or any, ifNil) |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
3102 |
resource in aCollectionOfClasses. |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
3103 |
If aKey is nonNil, only methods which have aKey in the (any) resourceSpec |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
3104 |
are parsed. |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
3105 |
I.e. to find all methods, which access the styleSheets, use: |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
3106 |
browseForResource:#style containing:nil in:... title:... |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
3107 |
to find methods which access the 'arrowButtonDownForm' styleSheet entry, use: |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
3108 |
browseForResource:#style containing:'arrowButtonDownForm' in:... title:..." |
573
e32bd3e46a72
added startup for searching resourceSpecs
Claus Gittinger <cg@exept.de>
parents:
553
diff
changeset
|
3109 |
|
742
2ef5e22d8983
code cleanup (unused vars eliminated)
Claus Gittinger <cg@exept.de>
parents:
675
diff
changeset
|
3110 |
|browser searchBlock| |
573
e32bd3e46a72
added startup for searching resourceSpecs
Claus Gittinger <cg@exept.de>
parents:
553
diff
changeset
|
3111 |
|
1356 | 3112 |
"/ search for any resource can be done without looking |
3113 |
"/ at the source ... |
|
3114 |
(aResourceSymbol isNil and:[item isNil]) ifTrue:[ |
|
3115 |
searchBlock := [:class :method :s | method hasResource] |
|
3116 |
] ifFalse:[ |
|
3117 |
searchBlock := [:class :method :s | |
|
1573
4b6ce12dff2b
dont duplicate the code in method>>resources
Claus Gittinger <cg@exept.de>
parents:
1561
diff
changeset
|
3118 |
|rsrc val found| |
929
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
3119 |
|
1356 | 3120 |
found := false. |
3121 |
method hasResource ifTrue:[ |
|
1573
4b6ce12dff2b
dont duplicate the code in method>>resources
Claus Gittinger <cg@exept.de>
parents:
1561
diff
changeset
|
3122 |
rsrc := method resources. |
4b6ce12dff2b
dont duplicate the code in method>>resources
Claus Gittinger <cg@exept.de>
parents:
1561
diff
changeset
|
3123 |
rsrc notNil ifTrue:[ |
4b6ce12dff2b
dont duplicate the code in method>>resources
Claus Gittinger <cg@exept.de>
parents:
1561
diff
changeset
|
3124 |
aResourceSymbol isNil ifTrue:[ |
4b6ce12dff2b
dont duplicate the code in method>>resources
Claus Gittinger <cg@exept.de>
parents:
1561
diff
changeset
|
3125 |
item isNil ifTrue:[ |
4b6ce12dff2b
dont duplicate the code in method>>resources
Claus Gittinger <cg@exept.de>
parents:
1561
diff
changeset
|
3126 |
found := true |
4b6ce12dff2b
dont duplicate the code in method>>resources
Claus Gittinger <cg@exept.de>
parents:
1561
diff
changeset
|
3127 |
] ifFalse:[ |
4b6ce12dff2b
dont duplicate the code in method>>resources
Claus Gittinger <cg@exept.de>
parents:
1561
diff
changeset
|
3128 |
rsrc isCollection ifTrue:[ |
4b6ce12dff2b
dont duplicate the code in method>>resources
Claus Gittinger <cg@exept.de>
parents:
1561
diff
changeset
|
3129 |
rsrc keysAndValuesDo:[:rsrc :val | |
4b6ce12dff2b
dont duplicate the code in method>>resources
Claus Gittinger <cg@exept.de>
parents:
1561
diff
changeset
|
3130 |
val isCollection ifTrue:[ |
4b6ce12dff2b
dont duplicate the code in method>>resources
Claus Gittinger <cg@exept.de>
parents:
1561
diff
changeset
|
3131 |
val do:[:v | |
4b6ce12dff2b
dont duplicate the code in method>>resources
Claus Gittinger <cg@exept.de>
parents:
1561
diff
changeset
|
3132 |
found := item match:v printString |
929
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
3133 |
] |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
3134 |
] ifFalse:[ |
1573
4b6ce12dff2b
dont duplicate the code in method>>resources
Claus Gittinger <cg@exept.de>
parents:
1561
diff
changeset
|
3135 |
found := item match:val printString |
929
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
3136 |
] |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
3137 |
] |
1356 | 3138 |
] ifFalse:[ |
1573
4b6ce12dff2b
dont duplicate the code in method>>resources
Claus Gittinger <cg@exept.de>
parents:
1561
diff
changeset
|
3139 |
found := item match:rsrc printString |
4b6ce12dff2b
dont duplicate the code in method>>resources
Claus Gittinger <cg@exept.de>
parents:
1561
diff
changeset
|
3140 |
] |
4b6ce12dff2b
dont duplicate the code in method>>resources
Claus Gittinger <cg@exept.de>
parents:
1561
diff
changeset
|
3141 |
] |
4b6ce12dff2b
dont duplicate the code in method>>resources
Claus Gittinger <cg@exept.de>
parents:
1561
diff
changeset
|
3142 |
] ifFalse:[ |
4b6ce12dff2b
dont duplicate the code in method>>resources
Claus Gittinger <cg@exept.de>
parents:
1561
diff
changeset
|
3143 |
(rsrc includesKey:aResourceSymbol) ifTrue:[ |
4b6ce12dff2b
dont duplicate the code in method>>resources
Claus Gittinger <cg@exept.de>
parents:
1561
diff
changeset
|
3144 |
item isNil ifTrue:[ |
4b6ce12dff2b
dont duplicate the code in method>>resources
Claus Gittinger <cg@exept.de>
parents:
1561
diff
changeset
|
3145 |
found := true |
4b6ce12dff2b
dont duplicate the code in method>>resources
Claus Gittinger <cg@exept.de>
parents:
1561
diff
changeset
|
3146 |
] ifFalse:[ |
4b6ce12dff2b
dont duplicate the code in method>>resources
Claus Gittinger <cg@exept.de>
parents:
1561
diff
changeset
|
3147 |
rsrc isCollection ifTrue:[ |
4b6ce12dff2b
dont duplicate the code in method>>resources
Claus Gittinger <cg@exept.de>
parents:
1561
diff
changeset
|
3148 |
val := rsrc at:aResourceSymbol. |
4b6ce12dff2b
dont duplicate the code in method>>resources
Claus Gittinger <cg@exept.de>
parents:
1561
diff
changeset
|
3149 |
val isCollection ifTrue:[ |
4b6ce12dff2b
dont duplicate the code in method>>resources
Claus Gittinger <cg@exept.de>
parents:
1561
diff
changeset
|
3150 |
val do:[:v | |
4b6ce12dff2b
dont duplicate the code in method>>resources
Claus Gittinger <cg@exept.de>
parents:
1561
diff
changeset
|
3151 |
found := item match:v printString |
4b6ce12dff2b
dont duplicate the code in method>>resources
Claus Gittinger <cg@exept.de>
parents:
1561
diff
changeset
|
3152 |
] |
1356 | 3153 |
] ifFalse:[ |
1573
4b6ce12dff2b
dont duplicate the code in method>>resources
Claus Gittinger <cg@exept.de>
parents:
1561
diff
changeset
|
3154 |
found := item match:val printString |
1356 | 3155 |
] |
1573
4b6ce12dff2b
dont duplicate the code in method>>resources
Claus Gittinger <cg@exept.de>
parents:
1561
diff
changeset
|
3156 |
] ifFalse:[ |
4b6ce12dff2b
dont duplicate the code in method>>resources
Claus Gittinger <cg@exept.de>
parents:
1561
diff
changeset
|
3157 |
found := item match:rsrc printString |
1356 | 3158 |
] |
929
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
3159 |
] |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
3160 |
] |
573
e32bd3e46a72
added startup for searching resourceSpecs
Claus Gittinger <cg@exept.de>
parents:
553
diff
changeset
|
3161 |
] |
1356 | 3162 |
]. |
929
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
3163 |
]. |
1356 | 3164 |
found |
3165 |
]. |
|
3166 |
]. |
|
573
e32bd3e46a72
added startup for searching resourceSpecs
Claus Gittinger <cg@exept.de>
parents:
553
diff
changeset
|
3167 |
|
e32bd3e46a72
added startup for searching resourceSpecs
Claus Gittinger <cg@exept.de>
parents:
553
diff
changeset
|
3168 |
browser := self browseMethodsIn:aCollectionOfClasses |
e32bd3e46a72
added startup for searching resourceSpecs
Claus Gittinger <cg@exept.de>
parents:
553
diff
changeset
|
3169 |
where:searchBlock |
e32bd3e46a72
added startup for searching resourceSpecs
Claus Gittinger <cg@exept.de>
parents:
553
diff
changeset
|
3170 |
title:title. |
e32bd3e46a72
added startup for searching resourceSpecs
Claus Gittinger <cg@exept.de>
parents:
553
diff
changeset
|
3171 |
browser notNil ifTrue:[ |
e32bd3e46a72
added startup for searching resourceSpecs
Claus Gittinger <cg@exept.de>
parents:
553
diff
changeset
|
3172 |
browser autoSearch:'resource:' |
e32bd3e46a72
added startup for searching resourceSpecs
Claus Gittinger <cg@exept.de>
parents:
553
diff
changeset
|
3173 |
]. |
e32bd3e46a72
added startup for searching resourceSpecs
Claus Gittinger <cg@exept.de>
parents:
553
diff
changeset
|
3174 |
^ browser |
e32bd3e46a72
added startup for searching resourceSpecs
Claus Gittinger <cg@exept.de>
parents:
553
diff
changeset
|
3175 |
|
e32bd3e46a72
added startup for searching resourceSpecs
Claus Gittinger <cg@exept.de>
parents:
553
diff
changeset
|
3176 |
" |
e32bd3e46a72
added startup for searching resourceSpecs
Claus Gittinger <cg@exept.de>
parents:
553
diff
changeset
|
3177 |
SystemBrowser |
929
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
3178 |
browseForResource:nil |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
3179 |
in:Smalltalk allClasses |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
3180 |
title:'methods with a resource' |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
3181 |
" |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
3182 |
" |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
3183 |
SystemBrowser |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
3184 |
browseForResource:#style |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
3185 |
containing:nil |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
3186 |
in:Smalltalk allClasses |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
3187 |
title:'methods with a #style resource' |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
3188 |
" |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
3189 |
" |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
3190 |
SystemBrowser |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
3191 |
browseForResource:#style |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
3192 |
containing:'arrowButton*' |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
3193 |
in:Smalltalk allClasses |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
3194 |
title:'methods with a #style resource' |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
3195 |
" |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
3196 |
|
1573
4b6ce12dff2b
dont duplicate the code in method>>resources
Claus Gittinger <cg@exept.de>
parents:
1561
diff
changeset
|
3197 |
"Modified: / 22.4.1998 / 10:29:20 / cg" |
929
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
3198 |
! |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
3199 |
|
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
3200 |
browseForResource:aResourceSymbol in:aCollectionOfClasses title:title |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
3201 |
"launch a browser for all methods which have a particular (or any, ifNil) |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
3202 |
resource in aCollectionOfClasses" |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
3203 |
|
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
3204 |
^ self |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
3205 |
browseForResource:aResourceSymbol |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
3206 |
containing:nil |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
3207 |
in:aCollectionOfClasses |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
3208 |
title:title |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
3209 |
|
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
3210 |
" |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
3211 |
SystemBrowser |
573
e32bd3e46a72
added startup for searching resourceSpecs
Claus Gittinger <cg@exept.de>
parents:
553
diff
changeset
|
3212 |
browseForResource:#style |
e32bd3e46a72
added startup for searching resourceSpecs
Claus Gittinger <cg@exept.de>
parents:
553
diff
changeset
|
3213 |
in:Smalltalk allClasses |
929
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
3214 |
title:'methods accessing styleSheet values' |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
3215 |
" |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
3216 |
" |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
3217 |
SystemBrowser |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
3218 |
browseForResource:#keyboard |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
3219 |
in:Smalltalk allClasses |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
3220 |
title:'methods handling keyboard events' |
573
e32bd3e46a72
added startup for searching resourceSpecs
Claus Gittinger <cg@exept.de>
parents:
553
diff
changeset
|
3221 |
" |
e32bd3e46a72
added startup for searching resourceSpecs
Claus Gittinger <cg@exept.de>
parents:
553
diff
changeset
|
3222 |
" |
e32bd3e46a72
added startup for searching resourceSpecs
Claus Gittinger <cg@exept.de>
parents:
553
diff
changeset
|
3223 |
SystemBrowser |
e32bd3e46a72
added startup for searching resourceSpecs
Claus Gittinger <cg@exept.de>
parents:
553
diff
changeset
|
3224 |
browseForResource:nil |
e32bd3e46a72
added startup for searching resourceSpecs
Claus Gittinger <cg@exept.de>
parents:
553
diff
changeset
|
3225 |
in:Smalltalk allClasses |
e32bd3e46a72
added startup for searching resourceSpecs
Claus Gittinger <cg@exept.de>
parents:
553
diff
changeset
|
3226 |
title:'methods with a resource' |
e32bd3e46a72
added startup for searching resourceSpecs
Claus Gittinger <cg@exept.de>
parents:
553
diff
changeset
|
3227 |
" |
e32bd3e46a72
added startup for searching resourceSpecs
Claus Gittinger <cg@exept.de>
parents:
553
diff
changeset
|
3228 |
|
929
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
3229 |
"Modified: 9.1.1997 / 12:44:38 / cg" |
573
e32bd3e46a72
added startup for searching resourceSpecs
Claus Gittinger <cg@exept.de>
parents:
553
diff
changeset
|
3230 |
! |
e32bd3e46a72
added startup for searching resourceSpecs
Claus Gittinger <cg@exept.de>
parents:
553
diff
changeset
|
3231 |
|
203 | 3232 |
browseForString:aString |
16471 | 3233 |
<resource: #obsolete> |
203 | 3234 |
"launch a browser for all methods containing a string in their source. |
3235 |
This may be slow, since source-code has to be scanned." |
|
3236 |
||
1703
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
3237 |
^ self browseForString:aString in:(Smalltalk allClasses) ignoreCase:false |
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
3238 |
|
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
3239 |
"Modified: / 18.6.1998 / 16:42:39 / cg" |
203 | 3240 |
! |
3241 |
||
3242 |
browseForString:aString in:aCollectionOfClasses |
|
16471 | 3243 |
<resource: #obsolete> |
203 | 3244 |
"launch a browser for all methods in aCollectionOfClasses |
3245 |
containing a string in their source. |
|
3246 |
This may be slow, since source-code has to be scanned." |
|
3247 |
||
1703
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
3248 |
^ self |
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
3249 |
browseForString:aString |
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
3250 |
in:aCollectionOfClasses |
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
3251 |
ignoreCase:false |
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
3252 |
|
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
3253 |
" |
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
3254 |
SystemBrowser browseForString:'all' in:(Array with:Object) |
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
3255 |
SystemBrowser browseForString:'should' in:(Array with:Object) |
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
3256 |
SystemBrowser browseForString:'[eE]rror' in:(Array with:Object) |
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
3257 |
" |
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
3258 |
|
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
3259 |
"Created: / 9.12.1995 / 18:03:12 / cg" |
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
3260 |
"Modified: / 18.6.1998 / 16:43:27 / cg" |
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
3261 |
! |
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
3262 |
|
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
3263 |
browseForString:aString in:aCollectionOfClasses ignoreCase:ignoreCase |
16471 | 3264 |
<resource: #obsolete> |
1703
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
3265 |
"launch a browser for all methods in aCollectionOfClasses |
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
3266 |
containing a string in their source. |
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
3267 |
This may be slow, since source-code has to be scanned." |
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
3268 |
|
203 | 3269 |
|browser searchBlock title s| |
3270 |
||
6476 | 3271 |
title := self classResources string:'Methods containing: %1' with:aString displayString. |
203 | 3272 |
|
1703
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
3273 |
(aString includesMatchCharacters |
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
3274 |
or:[ignoreCase]) ifTrue:[ |
256 | 3275 |
s := '*' , aString , '*'. |
3276 |
"a matchString" |
|
475
b14b3ab39af6
dont crash if searching a string in a method which has no accessable source
Claus Gittinger <cg@exept.de>
parents:
436
diff
changeset
|
3277 |
searchBlock := [:c :m :sel | |
b14b3ab39af6
dont crash if searching a string in a method which has no accessable source
Claus Gittinger <cg@exept.de>
parents:
436
diff
changeset
|
3278 |
|src| |
b14b3ab39af6
dont crash if searching a string in a method which has no accessable source
Claus Gittinger <cg@exept.de>
parents:
436
diff
changeset
|
3279 |
src := m source. |
1703
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
3280 |
src isNil ifTrue:[ |
19367 | 3281 |
('Browser [info]: no source for ' , m whoString "printString") infoPrintCR. |
1703
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
3282 |
false |
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
3283 |
] ifFalse:[ |
13438 | 3284 |
s match:src caseSensitive:ignoreCase not |
1703
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
3285 |
] |
475
b14b3ab39af6
dont crash if searching a string in a method which has no accessable source
Claus Gittinger <cg@exept.de>
parents:
436
diff
changeset
|
3286 |
] |
203 | 3287 |
] ifFalse:[ |
475
b14b3ab39af6
dont crash if searching a string in a method which has no accessable source
Claus Gittinger <cg@exept.de>
parents:
436
diff
changeset
|
3288 |
searchBlock := [:c :m :sel | |
b14b3ab39af6
dont crash if searching a string in a method which has no accessable source
Claus Gittinger <cg@exept.de>
parents:
436
diff
changeset
|
3289 |
|src| |
b14b3ab39af6
dont crash if searching a string in a method which has no accessable source
Claus Gittinger <cg@exept.de>
parents:
436
diff
changeset
|
3290 |
|
b14b3ab39af6
dont crash if searching a string in a method which has no accessable source
Claus Gittinger <cg@exept.de>
parents:
436
diff
changeset
|
3291 |
src := m source. |
1703
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
3292 |
src isNil ifTrue:[ |
19367 | 3293 |
('Browser [info]: no source for ' , m whoString "printString") infoPrintCR. |
1703
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
3294 |
false |
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
3295 |
] ifFalse:[ |
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
3296 |
(src findString:aString) ~~ 0 |
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
3297 |
] |
475
b14b3ab39af6
dont crash if searching a string in a method which has no accessable source
Claus Gittinger <cg@exept.de>
parents:
436
diff
changeset
|
3298 |
] |
203 | 3299 |
]. |
3300 |
browser := self browseMethodsIn:aCollectionOfClasses where:searchBlock title:title. |
|
3301 |
||
3302 |
browser notNil ifTrue:[ |
|
1703
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
3303 |
browser autoSearch:aString ignoreCase:ignoreCase |
203 | 3304 |
]. |
3305 |
^ browser |
|
3306 |
||
3307 |
" |
|
1703
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
3308 |
SystemBrowser browseForString:'all' in:(Array with:Object) |
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
3309 |
SystemBrowser browseForString:'should' in:(Array with:Object) |
203 | 3310 |
SystemBrowser browseForString:'[eE]rror' in:(Array with:Object) |
3311 |
" |
|
3312 |
||
1703
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
3313 |
"Created: / 18.6.1998 / 16:42:50 / cg" |
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
3314 |
"Modified: / 18.6.1998 / 16:51:25 / cg" |
203 | 3315 |
! |
3316 |
||
3317 |
browseForSymbol:aSymbol |
|
3318 |
"launch a browser for all methods referencing aSymbol" |
|
3319 |
||
666 | 3320 |
^ self |
3321 |
browseForSymbol:aSymbol |
|
6476 | 3322 |
title:(self classResources string:'Users of: %1' with:aSymbol) |
666 | 3323 |
warnIfNone:true |
256 | 3324 |
|
3325 |
"Created: 9.12.1995 / 18:04:34 / cg" |
|
666 | 3326 |
"Modified: 10.7.1996 / 10:35:34 / cg" |
3327 |
! |
|
3328 |
||
3329 |
browseForSymbol:aSymbol in:aSetOfClasses title:title warnIfNone:doWarn |
|
3330 |
"launch a browser for all methods referencing aSymbol" |
|
3331 |
||
7914 | 3332 |
^ self |
3333 |
browseForSymbol:aSymbol |
|
3334 |
in:aSetOfClasses |
|
3335 |
title:title |
|
3336 |
warnIfNone:doWarn |
|
3337 |
searchFor:aSymbol |
|
203 | 3338 |
! |
3339 |
||
820
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
3340 |
browseForSymbol:aSymbol in:aSetOfClasses title:title warnIfNone:doWarn searchFor:searchString |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
3341 |
"launch a browser for all methods referencing aSymbol" |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
3342 |
|
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
3343 |
|browser searchBlock sym| |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
3344 |
|
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
3345 |
(aSymbol includesMatchCharacters) ifTrue:[ |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
3346 |
"a matchString" |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
3347 |
searchBlock := [:c :m :s | |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
3348 |
(m literalsDetect:[:aLiteral| |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
3349 |
(aLiteral isMemberOf:Symbol) |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
3350 |
and:[aSymbol match:aLiteral] |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
3351 |
] ifNone:nil) notNil |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
3352 |
]. |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
3353 |
] ifFalse:[ |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
3354 |
" |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
3355 |
can do a faster search |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
3356 |
" |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
3357 |
sym := aSymbol asSymbolIfInterned. |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
3358 |
sym isNil ifTrue:[ |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
3359 |
self showNoneFound:title. |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
3360 |
^ nil |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
3361 |
]. |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
3362 |
|
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
3363 |
searchBlock := [:c :m :s | |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
3364 |
(m literalsDetect:[:aLiteral| |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
3365 |
(sym == aLiteral) |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
3366 |
] ifNone:nil) notNil |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
3367 |
]. |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
3368 |
]. |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
3369 |
doWarn ifFalse:[ |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
3370 |
WarningSignal ignoreIn:[ |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
3371 |
browser := self browseMethodsIn:aSetOfClasses where:searchBlock title:title. |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
3372 |
] |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
3373 |
] ifTrue:[ |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
3374 |
browser := self browseMethodsIn:aSetOfClasses where:searchBlock title:title. |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
3375 |
]. |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
3376 |
|
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
3377 |
(browser notNil |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
3378 |
and:[searchString notNil]) ifTrue:[ |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
3379 |
browser autoSearch:searchString |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
3380 |
]. |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
3381 |
^ browser |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
3382 |
|
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
3383 |
"Modified: 24.6.1996 / 14:39:07 / stefan" |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
3384 |
"Modified: 30.6.1996 / 16:45:25 / cg" |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
3385 |
"Created: 31.10.1996 / 14:57:30 / cg" |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
3386 |
! |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
3387 |
|
2409 | 3388 |
browseForSymbol:aSymbol title:title ifNone:actionIfNoneFound searchFor:searchString |
820
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
3389 |
"launch a browser for all methods referencing aSymbol" |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
3390 |
|
11452 | 3391 |
|browser searchBlock| |
3392 |
||
3393 |
searchBlock := self searchBlockForSymbol:aSymbol. |
|
12866 | 3394 |
searchBlock == false ifTrue:[ |
3395 |
actionIfNoneFound value. |
|
3396 |
^ nil |
|
3397 |
]. |
|
2409 | 3398 |
|
3399 |
WarningSignal ignoreIn:[ |
|
3400 |
InformationSignal ignoreIn:[ |
|
375 | 3401 |
browser := self browseMethodsWhere:searchBlock title:title. |
3402 |
] |
|
2409 | 3403 |
]. |
3404 |
browser isNil ifTrue:[ |
|
12866 | 3405 |
actionIfNoneFound value. |
3406 |
^ nil |
|
215
244f3a9b2a60
check for existing class in rename; avoid warnbox if no refs are found after rename
Claus Gittinger <cg@exept.de>
parents:
204
diff
changeset
|
3407 |
]. |
820
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
3408 |
|
11452 | 3409 |
(browser notNil and:[searchString notNil]) ifTrue:[ |
820
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
3410 |
browser autoSearch:searchString |
203 | 3411 |
]. |
3412 |
^ browser |
|
375 | 3413 |
|
11452 | 3414 |
"Modified: / 24-06-1996 / 14:39:07 / stefan" |
3415 |
"Created: / 31-10-1996 / 14:45:08 / cg" |
|
3416 |
"Modified: / 22-03-2012 / 06:58:07 / cg" |
|
203 | 3417 |
! |
3418 |
||
2409 | 3419 |
browseForSymbol:aSymbol title:title warnIfNone:doWarn |
3420 |
"launch a browser for all methods referencing aSymbol" |
|
3421 |
||
3422 |
^ self |
|
3423 |
browseForSymbol:aSymbol |
|
3424 |
title:title |
|
3425 |
warnIfNone:doWarn |
|
3426 |
searchFor:aSymbol |
|
3427 |
||
3428 |
"Modified: 31.10.1996 / 14:45:38 / cg" |
|
3429 |
! |
|
3430 |
||
3431 |
browseForSymbol:aSymbol title:title warnIfNone:doWarn searchFor:searchString |
|
3432 |
"launch a browser for all methods referencing aSymbol" |
|
3433 |
||
2414 | 3434 |
|b| |
3435 |
||
3436 |
doWarn ifTrue: [ |
|
4158 | 3437 |
b := [self showNoneFound:title] |
2414 | 3438 |
]. |
2409 | 3439 |
^ self |
3440 |
browseForSymbol:aSymbol |
|
3441 |
title:title |
|
2414 | 3442 |
ifNone:b |
2409 | 3443 |
searchFor:searchString |
3444 |
! |
|
3445 |
||
4158 | 3446 |
browseImplementorsMatching:aSelectorString |
3447 |
"launch a browser for all implementors of aSelector" |
|
3448 |
||
3449 |
^ self |
|
3450 |
browseImplementorsMatching:aSelectorString |
|
3451 |
in:(Smalltalk allClasses) |
|
3452 |
||
3453 |
" |
|
3454 |
SystemBrowser browseImplementorsOf:#+ |
|
3455 |
NewSystemBrowser browseImplementorsOf:#+ |
|
3456 |
" |
|
3457 |
||
3458 |
"Created: / 9.12.1995 / 18:01:18 / cg" |
|
3459 |
"Modified: / 5.11.2001 / 17:31:11 / cg" |
|
3460 |
! |
|
3461 |
||
3462 |
browseImplementorsMatching:aSelectorString in:aSetOfClasses |
|
3463 |
"launch a browser for all implementors of aSelector" |
|
3464 |
||
3465 |
^ self |
|
3466 |
browseImplementorsMatching:aSelectorString |
|
3467 |
in:aSetOfClasses |
|
3468 |
title:(self classResources string:'implementors of: %1' with:aSelectorString) |
|
3469 |
||
3470 |
" |
|
3471 |
SystemBrowser browseImplementorsOf:#+ in:(Number withAllSubclasses) |
|
3472 |
NewSystemBrowser browseImplementorsOf:#+ in:(Number withAllSubclasses) |
|
3473 |
" |
|
3474 |
||
3475 |
"Created: / 10.7.1996 / 10:20:59 / cg" |
|
3476 |
"Modified: / 5.11.2001 / 17:30:57 / cg" |
|
3477 |
! |
|
3478 |
||
3479 |
browseImplementorsMatching:aSelectorString in:aSetOfClasses ignoreCase:ignoreCase |
|
3480 |
"launch a browser for all implementors of aSelector" |
|
3481 |
||
3482 |
^ self |
|
3483 |
browseImplementorsMatching:aSelectorString |
|
3484 |
in:aSetOfClasses |
|
3485 |
ignoreCase:ignoreCase |
|
3486 |
title:(self classResources string:'implementors of: %1' with:aSelectorString) |
|
3487 |
||
3488 |
" |
|
3489 |
SystemBrowser browseImplementorsOf:#+ in:(Number withAllSubclasses) |
|
3490 |
NewSystemBrowser browseImplementorsOf:#+ in:(Number withAllSubclasses) |
|
3491 |
" |
|
3492 |
||
3493 |
"Created: / 10.7.1996 / 10:20:59 / cg" |
|
3494 |
"Modified: / 5.11.2001 / 17:30:43 / cg" |
|
3495 |
! |
|
3496 |
||
3497 |
browseImplementorsMatching:aSelectorString in:aCollectionOfClasses ignoreCase:ignoreCase title:title |
|
3498 |
"launch a browser for all implementors of aSelector in |
|
16586 | 3499 |
the classes contained in aCollectionOfClasses and their metaclasses" |
4158 | 3500 |
|
3501 |
|list| |
|
3502 |
||
3503 |
list := self |
|
3504 |
findImplementorsMatching:aSelectorString |
|
3505 |
in:aCollectionOfClasses |
|
3506 |
ignoreCase:ignoreCase. |
|
3507 |
||
3508 |
list size == 0 ifTrue:[ |
|
3509 |
self showNoneFound:title. |
|
3510 |
^ nil |
|
3511 |
]. |
|
3512 |
||
3513 |
^ self browseMethods:list asOrderedCollection title:title |
|
3514 |
||
3515 |
" |
|
3516 |
SystemBrowser browseImplementorsOf:#+ |
|
3517 |
in:(Array with:Number |
|
3518 |
with:Float |
|
3519 |
with:SmallInteger) |
|
3520 |
title:'some implementors of +' |
|
3521 |
||
3522 |
NewSystemBrowser browseImplementorsOf:#+ |
|
3523 |
in:(Array with:Number |
|
3524 |
with:Float |
|
3525 |
with:SmallInteger) |
|
3526 |
title:'some implementors of +' |
|
3527 |
" |
|
3528 |
||
3529 |
"Modified: / 4.9.1995 / 17:33:39 / claus" |
|
3530 |
"Modified: / 19.6.1996 / 14:19:02 / stefan" |
|
3531 |
"Modified: / 5.11.2001 / 17:30:38 / cg" |
|
3532 |
! |
|
3533 |
||
3534 |
browseImplementorsMatching:aSelectorString in:aCollectionOfClasses title:title |
|
3535 |
"launch a browser for all implementors of aSelector in |
|
16586 | 3536 |
the classes contained in aCollectionOfClasses and their metaclasses" |
4158 | 3537 |
|
3538 |
^ self |
|
3539 |
browseImplementorsMatching:aSelectorString |
|
3540 |
in:aCollectionOfClasses |
|
3541 |
ignoreCase:false |
|
3542 |
title:title |
|
3543 |
! |
|
3544 |
||
3545 |
browseImplementorsMatching:aSelectorString under:aClass |
|
3546 |
"launch a browser for all implementors of aSelector in aClass |
|
3547 |
and its subclasses" |
|
3548 |
||
3549 |
^ self |
|
3550 |
browseImplementorsMatching:aSelectorString |
|
3551 |
in:(aClass withAllSubclasses) |
|
3552 |
title:(self classResources |
|
3553 |
string:'implementors of: %1 (in and below %2)' |
|
3554 |
with:aSelectorString |
|
3555 |
with:aClass name) |
|
3556 |
||
3557 |
" |
|
3558 |
SystemBrowser browseImplementorsOf:#+ under:Integer |
|
3559 |
NewSystemBrowser browseImplementorsOf:#+ under:Integer |
|
3560 |
" |
|
3561 |
||
3562 |
"Created: / 9.12.1995 / 18:06:09 / cg" |
|
3563 |
"Modified: / 5.11.2001 / 17:30:15 / cg" |
|
3564 |
! |
|
3565 |
||
52 | 3566 |
browseImplementorsOf:aSelectorString |
3567 |
"launch a browser for all implementors of aSelector" |
|
3568 |
||
2623
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3569 |
^ self |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3570 |
browseImplementorsOf:aSelectorString |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3571 |
in:(Smalltalk allClasses) |
52 | 3572 |
|
3573 |
" |
|
3574 |
SystemBrowser browseImplementorsOf:#+ |
|
3360
2eab40d1a498
isMeta/soleInstance -> theNonMetaclass
Claus Gittinger <cg@exept.de>
parents:
3354
diff
changeset
|
3575 |
NewSystemBrowser browseImplementorsOf:#+ |
52 | 3576 |
" |
256 | 3577 |
|
3360
2eab40d1a498
isMeta/soleInstance -> theNonMetaclass
Claus Gittinger <cg@exept.de>
parents:
3354
diff
changeset
|
3578 |
"Created: / 9.12.1995 / 18:01:18 / cg" |
2eab40d1a498
isMeta/soleInstance -> theNonMetaclass
Claus Gittinger <cg@exept.de>
parents:
3354
diff
changeset
|
3579 |
"Modified: / 5.11.2001 / 17:31:11 / cg" |
666 | 3580 |
! |
3581 |
||
3582 |
browseImplementorsOf:aSelectorString in:aSetOfClasses |
|
3583 |
"launch a browser for all implementors of aSelector" |
|
3584 |
||
2623
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3585 |
^ self |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3586 |
browseImplementorsOf:aSelectorString |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3587 |
in:aSetOfClasses |
8704 | 3588 |
title:(self classResources string:'Implementors of: %1' with:aSelectorString allBold) |
666 | 3589 |
|
3590 |
" |
|
3591 |
SystemBrowser browseImplementorsOf:#+ in:(Number withAllSubclasses) |
|
3360
2eab40d1a498
isMeta/soleInstance -> theNonMetaclass
Claus Gittinger <cg@exept.de>
parents:
3354
diff
changeset
|
3592 |
NewSystemBrowser browseImplementorsOf:#+ in:(Number withAllSubclasses) |
666 | 3593 |
" |
3594 |
||
3360
2eab40d1a498
isMeta/soleInstance -> theNonMetaclass
Claus Gittinger <cg@exept.de>
parents:
3354
diff
changeset
|
3595 |
"Created: / 10.7.1996 / 10:20:59 / cg" |
2eab40d1a498
isMeta/soleInstance -> theNonMetaclass
Claus Gittinger <cg@exept.de>
parents:
3354
diff
changeset
|
3596 |
"Modified: / 5.11.2001 / 17:30:57 / cg" |
52 | 3597 |
! |
3598 |
||
2623
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3599 |
browseImplementorsOf:aSelectorString in:aSetOfClasses ignoreCase:ignoreCase |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3600 |
"launch a browser for all implementors of aSelector" |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3601 |
|
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3602 |
^ self |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3603 |
browseImplementorsOf:aSelectorString |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3604 |
in:aSetOfClasses |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3605 |
ignoreCase:ignoreCase |
6476 | 3606 |
title:(self classResources string:'Implementors of: %1' with:aSelectorString) |
2623
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3607 |
|
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3608 |
" |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3609 |
SystemBrowser browseImplementorsOf:#+ in:(Number withAllSubclasses) |
3360
2eab40d1a498
isMeta/soleInstance -> theNonMetaclass
Claus Gittinger <cg@exept.de>
parents:
3354
diff
changeset
|
3610 |
NewSystemBrowser browseImplementorsOf:#+ in:(Number withAllSubclasses) |
2623
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3611 |
" |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3612 |
|
3360
2eab40d1a498
isMeta/soleInstance -> theNonMetaclass
Claus Gittinger <cg@exept.de>
parents:
3354
diff
changeset
|
3613 |
"Created: / 10.7.1996 / 10:20:59 / cg" |
2eab40d1a498
isMeta/soleInstance -> theNonMetaclass
Claus Gittinger <cg@exept.de>
parents:
3354
diff
changeset
|
3614 |
"Modified: / 5.11.2001 / 17:30:43 / cg" |
2623
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3615 |
! |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3616 |
|
11271 | 3617 |
browseImplementorsOf:aSelectorString in:aCollectionOfClasses ignoreCase:ignoreCase match:doMatch title:titleArg |
3618 |
"launch a browser for all implementors of aSelector in |
|
16586 | 3619 |
the classes contained in aCollectionOfClasses and their metaclasses" |
11271 | 3620 |
|
3621 |
doMatch ifTrue:[ |
|
3622 |
self browseImplementorsOf:aSelectorString in:aCollectionOfClasses ignoreCase:ignoreCase title:titleArg |
|
3623 |
] ifFalse:[ |
|
3624 |
self browseImplementorsMatching:aSelectorString in:aCollectionOfClasses ignoreCase:ignoreCase title:titleArg |
|
3625 |
]. |
|
3626 |
||
3627 |
"Created: / 14-02-2012 / 13:55:23 / cg" |
|
3628 |
! |
|
3629 |
||
5256
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
3630 |
browseImplementorsOf:aSelectorString in:aCollectionOfClasses ignoreCase:ignoreCase title:titleArg |
36 | 3631 |
"launch a browser for all implementors of aSelector in |
16586 | 3632 |
the classes contained in aCollectionOfClasses and their metaclasses" |
36 | 3633 |
|
17180 | 3634 |
|list list2 rs selWithColon title top20 allSelectors choice but globalClass global globalName lcSelector| |
5256
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
3635 |
|
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
3636 |
title := titleArg. |
2642 | 3637 |
list := self |
15206 | 3638 |
findImplementors:aSelectorString |
2642 | 3639 |
in:aCollectionOfClasses |
15206 | 3640 |
ignoreCase:ignoreCase |
3641 |
match:(aSelectorString includesMatchCharacters and:[aSelectorString ~= '*']). |
|
45 | 3642 |
|
2642 | 3643 |
list size == 0 ifTrue:[ |
19130 | 3644 |
aSelectorString argumentCount == 0 ifTrue:[ |
5256
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
3645 |
selWithColon := aSelectorString , ':'. |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
3646 |
selWithColon knownAsSymbol ifTrue:[ |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
3647 |
list2 := self findImplementorsOf:selWithColon in:aCollectionOfClasses ignoreCase:ignoreCase. |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
3648 |
]. |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
3649 |
]. |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
3650 |
list2 size == 0 ifTrue:[ |
8678 | 3651 |
"/ self showNoneFound:title. |
3652 |
"/ ^ self |
|
17180 | 3653 |
lcSelector := aSelectorString asLowercase. |
3654 |
||
8688 | 3655 |
allSelectors := Set new. |
8678 | 3656 |
top20 := SortedCollection new. |
17180 | 3657 |
top20 |
3658 |
sortBlock:[:a :b | |
|
3659 |
|isPrefixOfA isPrefixOfB aDist bDist| |
|
3660 |
||
3661 |
isPrefixOfA := (a asLowercase startsWith:lcSelector). |
|
3662 |
isPrefixOfB := (b asLowercase startsWith:lcSelector). |
|
3663 |
(isPrefixOfA and:[isPrefixOfB not]) |
|
3664 |
or:[ |
|
3665 |
aDist := (a spellAgainst:aSelectorString). |
|
3666 |
bDist := (b spellAgainst:aSelectorString). |
|
3667 |
(isPrefixOfA and:[isPrefixOfB and:[aDist > bDist]]) |
|
3668 |
or:[ isPrefixOfB not and:[ aDist > bDist ]]] |
|
3669 |
]. |
|
8759 | 3670 |
Smalltalk allMethodsWithSelectorDo:[:eachMethod :eachSelector | |
17180 | 3671 |
((eachSelector asLowercase startsWith:lcSelector) or:[(eachSelector spellAgainst:aSelectorString) > 50]) ifTrue:[ |
8759 | 3672 |
(allSelectors includes:eachSelector) ifFalse:[ |
3673 |
allSelectors add:eachSelector. |
|
3674 |
top20 add:eachSelector. |
|
3675 |
top20 size > 20 ifTrue:[ top20 removeLast. allSelectors := top20 asSet ]. |
|
3676 |
] |
|
8678 | 3677 |
] |
3678 |
]. |
|
9685
629e1d789a2d
changed: #browseImplementorsOf:in:ignoreCase:title:
Claus Gittinger <cg@exept.de>
parents:
9660
diff
changeset
|
3679 |
top20 isEmpty ifTrue:[ |
629e1d789a2d
changed: #browseImplementorsOf:in:ignoreCase:title:
Claus Gittinger <cg@exept.de>
parents:
9660
diff
changeset
|
3680 |
Smalltalk allMethodsWithSelectorDo:[:eachMethod :eachSelector | |
629e1d789a2d
changed: #browseImplementorsOf:in:ignoreCase:title:
Claus Gittinger <cg@exept.de>
parents:
9660
diff
changeset
|
3681 |
(eachSelector asLowercase spellAgainst:lcSelector) > 50 ifTrue:[ |
629e1d789a2d
changed: #browseImplementorsOf:in:ignoreCase:title:
Claus Gittinger <cg@exept.de>
parents:
9660
diff
changeset
|
3682 |
(allSelectors includes:eachSelector) ifFalse:[ |
629e1d789a2d
changed: #browseImplementorsOf:in:ignoreCase:title:
Claus Gittinger <cg@exept.de>
parents:
9660
diff
changeset
|
3683 |
allSelectors add:eachSelector. |
629e1d789a2d
changed: #browseImplementorsOf:in:ignoreCase:title:
Claus Gittinger <cg@exept.de>
parents:
9660
diff
changeset
|
3684 |
top20 add:eachSelector. |
629e1d789a2d
changed: #browseImplementorsOf:in:ignoreCase:title:
Claus Gittinger <cg@exept.de>
parents:
9660
diff
changeset
|
3685 |
top20 size > 20 ifTrue:[ top20 removeLast. allSelectors := top20 asSet ]. |
629e1d789a2d
changed: #browseImplementorsOf:in:ignoreCase:title:
Claus Gittinger <cg@exept.de>
parents:
9660
diff
changeset
|
3686 |
] |
629e1d789a2d
changed: #browseImplementorsOf:in:ignoreCase:title:
Claus Gittinger <cg@exept.de>
parents:
9660
diff
changeset
|
3687 |
] |
629e1d789a2d
changed: #browseImplementorsOf:in:ignoreCase:title:
Claus Gittinger <cg@exept.de>
parents:
9660
diff
changeset
|
3688 |
]. |
629e1d789a2d
changed: #browseImplementorsOf:in:ignoreCase:title:
Claus Gittinger <cg@exept.de>
parents:
9660
diff
changeset
|
3689 |
]. |
15499 | 3690 |
|
3691 |
"/ for your convenience: look for a global class by that name, and offer browsing the class |
|
12621 | 3692 |
but := ''. |
13128 | 3693 |
(globalClass := Smalltalk classNamed:aSelectorString) notNil ifTrue:[ |
12575 | 3694 |
top20 := (OrderedCollection withAll:top20) addFirst:('>> Browse class ',aSelectorString,' <<'); yourself. |
12621 | 3695 |
but := '\But there exists a class by that name.'. |
13128 | 3696 |
] ifFalse:[ |
3697 |
(aSelectorString knownAsSymbol |
|
3698 |
and:[ (global := Smalltalk at:aSelectorString asSymbol) notNil ]) |
|
3699 |
ifTrue:[ |
|
3700 |
global isBehavior ifTrue:[ |
|
3701 |
top20 := (OrderedCollection withAll:top20) addFirst:('>> Browse alias ',aSelectorString,' <<'); yourself. |
|
3702 |
but := '\But there exists a global alias by that name.'. |
|
3703 |
globalClass := global |
|
3704 |
] ifFalse:[ |
|
3705 |
top20 := (OrderedCollection withAll:top20) addFirst:('>> Browse class of ',aSelectorString,' <<'); yourself. |
|
3706 |
but := '\But there exists a global by that name.'. |
|
3707 |
globalClass := global class. |
|
3708 |
] |
|
3709 |
]. |
|
12575 | 3710 |
]. |
15499 | 3711 |
"/ for your convenience: look for any namespace class by that name, and offer browsing the class |
3712 |
but isEmpty ifTrue:[ |
|
3713 |
globalName := Smalltalk keys |
|
3714 |
detect:[:nm | (nm includesString:'::') |
|
3715 |
and:[ (nm includesString:aSelectorString) |
|
3716 |
and:[ (nm endsWith:('::',aSelectorString)) ]]] |
|
3717 |
ifNone:nil. |
|
3718 |
globalName notNil ifTrue:[ |
|
3719 |
globalClass := Smalltalk at:globalName. |
|
3720 |
globalClass isBehavior ifTrue:[ |
|
3721 |
top20 := (OrderedCollection withAll:top20) addFirst:('>> Browse class ',globalClass name,' <<'); yourself. |
|
3722 |
but := '\But there exists a class in some namespace by that name.'. |
|
3723 |
]. |
|
3724 |
]. |
|
3725 |
]. |
|
3726 |
||
8678 | 3727 |
choice := Dialog |
18869 | 3728 |
choose:(title,(self resources string:' - none found.'),but,(self resources stringWithCRs:'\\Browse implementors of a similar selector or cancel:')) |
8678 | 3729 |
fromList:top20 |
3730 |
lines:10. |
|
13128 | 3731 |
|
8678 | 3732 |
choice notEmptyOrNil ifTrue:[ |
12575 | 3733 |
(choice startsWith:'>>') ifTrue:[ |
13128 | 3734 |
self openInClass:globalClass selector:nil. |
12575 | 3735 |
] ifFalse:[ |
3736 |
self browseImplementorsOf:choice in:aCollectionOfClasses ignoreCase:ignoreCase title:'Implementors of ',choice. |
|
3737 |
] |
|
8678 | 3738 |
]. |
5256
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
3739 |
^ nil |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
3740 |
]. |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
3741 |
rs := self classResources. |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
3742 |
(Dialog confirm:((rs string:title) , |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
3743 |
(rs string:'...\\... none found.') , |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
3744 |
(rs string:'\\But I found %1 implementor(s) of the "%2" message (with colon).\\Browse those ?' |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
3745 |
with:list2 size |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
3746 |
with:selWithColon allBold)) withCRs) ifFalse:[ |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
3747 |
^ nil |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
3748 |
]. |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
3749 |
list := list2. |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
3750 |
title := title , ':'. |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
3751 |
|
36 | 3752 |
]. |
2623
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3753 |
|
270 | 3754 |
^ self browseMethods:list asOrderedCollection title:title |
36 | 3755 |
|
3756 |
" |
|
3757 |
SystemBrowser browseImplementorsOf:#+ |
|
270 | 3758 |
in:(Array with:Number |
3759 |
with:Float |
|
3760 |
with:SmallInteger) |
|
3761 |
title:'some implementors of +' |
|
3360
2eab40d1a498
isMeta/soleInstance -> theNonMetaclass
Claus Gittinger <cg@exept.de>
parents:
3354
diff
changeset
|
3762 |
|
2eab40d1a498
isMeta/soleInstance -> theNonMetaclass
Claus Gittinger <cg@exept.de>
parents:
3354
diff
changeset
|
3763 |
NewSystemBrowser browseImplementorsOf:#+ |
2eab40d1a498
isMeta/soleInstance -> theNonMetaclass
Claus Gittinger <cg@exept.de>
parents:
3354
diff
changeset
|
3764 |
in:(Array with:Number |
2eab40d1a498
isMeta/soleInstance -> theNonMetaclass
Claus Gittinger <cg@exept.de>
parents:
3354
diff
changeset
|
3765 |
with:Float |
2eab40d1a498
isMeta/soleInstance -> theNonMetaclass
Claus Gittinger <cg@exept.de>
parents:
3354
diff
changeset
|
3766 |
with:SmallInteger) |
2eab40d1a498
isMeta/soleInstance -> theNonMetaclass
Claus Gittinger <cg@exept.de>
parents:
3354
diff
changeset
|
3767 |
title:'some implementors of +' |
36 | 3768 |
" |
132 | 3769 |
|
9685
629e1d789a2d
changed: #browseImplementorsOf:in:ignoreCase:title:
Claus Gittinger <cg@exept.de>
parents:
9660
diff
changeset
|
3770 |
"Modified: / 04-09-1995 / 17:33:39 / claus" |
629e1d789a2d
changed: #browseImplementorsOf:in:ignoreCase:title:
Claus Gittinger <cg@exept.de>
parents:
9660
diff
changeset
|
3771 |
"Modified: / 19-06-1996 / 14:19:02 / stefan" |
629e1d789a2d
changed: #browseImplementorsOf:in:ignoreCase:title:
Claus Gittinger <cg@exept.de>
parents:
9660
diff
changeset
|
3772 |
"Modified: / 15-01-2011 / 14:35:56 / cg" |
36 | 3773 |
! |
3774 |
||
2623
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3775 |
browseImplementorsOf:aSelectorString in:aCollectionOfClasses title:title |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3776 |
"launch a browser for all implementors of aSelector in |
16586 | 3777 |
the classes contained in aCollectionOfClasses and their metaclasses" |
2623
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3778 |
|
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3779 |
^ self |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3780 |
browseImplementorsOf:aSelectorString |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3781 |
in:aCollectionOfClasses |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3782 |
ignoreCase:false |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3783 |
title:title |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3784 |
! |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3785 |
|
52 | 3786 |
browseImplementorsOf:aSelectorString under:aClass |
3787 |
"launch a browser for all implementors of aSelector in aClass |
|
3788 |
and its subclasses" |
|
3789 |
||
2623
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3790 |
^ self |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3791 |
browseImplementorsOf:aSelectorString |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3792 |
in:(aClass withAllSubclasses) |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3793 |
title:(self classResources |
6476 | 3794 |
string:'Implementors of: %1 (in and below %2)' |
2623
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3795 |
with:aSelectorString |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3796 |
with:aClass name) |
52 | 3797 |
|
3798 |
" |
|
3799 |
SystemBrowser browseImplementorsOf:#+ under:Integer |
|
3360
2eab40d1a498
isMeta/soleInstance -> theNonMetaclass
Claus Gittinger <cg@exept.de>
parents:
3354
diff
changeset
|
3800 |
NewSystemBrowser browseImplementorsOf:#+ under:Integer |
52 | 3801 |
" |
256 | 3802 |
|
3360
2eab40d1a498
isMeta/soleInstance -> theNonMetaclass
Claus Gittinger <cg@exept.de>
parents:
3354
diff
changeset
|
3803 |
"Created: / 9.12.1995 / 18:06:09 / cg" |
2eab40d1a498
isMeta/soleInstance -> theNonMetaclass
Claus Gittinger <cg@exept.de>
parents:
3354
diff
changeset
|
3804 |
"Modified: / 5.11.2001 / 17:30:15 / cg" |
52 | 3805 |
! |
3806 |
||
3663 | 3807 |
browseImplementorsOfAny:setOfSelectors |
3808 |
"launch a browser for all implementors of aSelector" |
|
3809 |
||
3810 |
^ self |
|
3811 |
browseImplementorsOfAny:setOfSelectors |
|
3812 |
in:(Smalltalk allClasses) |
|
3813 |
||
3814 |
" |
|
3815 |
SystemBrowser browseImplementorsOfAny:#( #+ #- ) |
|
3816 |
NewSystemBrowser browseImplementorsOfAny:#( #+ #- ) |
|
3817 |
" |
|
3818 |
||
3819 |
"Created: / 9.12.1995 / 18:01:18 / cg" |
|
3820 |
"Modified: / 5.11.2001 / 17:31:11 / cg" |
|
3821 |
! |
|
3822 |
||
3823 |
browseImplementorsOfAny:setOfSelectors in:aSetOfClasses |
|
3824 |
"launch a browser for all implementors of aSelector" |
|
3825 |
||
8047
8bc319ff9ba7
better title in implementorsOfAny
Claus Gittinger <cg@exept.de>
parents:
7998
diff
changeset
|
3826 |
|title| |
8bc319ff9ba7
better title in implementorsOfAny
Claus Gittinger <cg@exept.de>
parents:
7998
diff
changeset
|
3827 |
|
8bc319ff9ba7
better title in implementorsOfAny
Claus Gittinger <cg@exept.de>
parents:
7998
diff
changeset
|
3828 |
setOfSelectors size == 1 ifTrue:[ |
8bc319ff9ba7
better title in implementorsOfAny
Claus Gittinger <cg@exept.de>
parents:
7998
diff
changeset
|
3829 |
title := self classResources |
8bc319ff9ba7
better title in implementorsOfAny
Claus Gittinger <cg@exept.de>
parents:
7998
diff
changeset
|
3830 |
string:'Implementors of %1' |
8bc319ff9ba7
better title in implementorsOfAny
Claus Gittinger <cg@exept.de>
parents:
7998
diff
changeset
|
3831 |
with:(setOfSelectors asOrderedCollection first). |
8bc319ff9ba7
better title in implementorsOfAny
Claus Gittinger <cg@exept.de>
parents:
7998
diff
changeset
|
3832 |
] ifFalse:[ |
8bc319ff9ba7
better title in implementorsOfAny
Claus Gittinger <cg@exept.de>
parents:
7998
diff
changeset
|
3833 |
setOfSelectors size == 2 ifTrue:[ |
8bc319ff9ba7
better title in implementorsOfAny
Claus Gittinger <cg@exept.de>
parents:
7998
diff
changeset
|
3834 |
title := self classResources |
8bc319ff9ba7
better title in implementorsOfAny
Claus Gittinger <cg@exept.de>
parents:
7998
diff
changeset
|
3835 |
string:'Implementors of %1 or %2' |
8bc319ff9ba7
better title in implementorsOfAny
Claus Gittinger <cg@exept.de>
parents:
7998
diff
changeset
|
3836 |
with:(setOfSelectors asOrderedCollection first) |
8bc319ff9ba7
better title in implementorsOfAny
Claus Gittinger <cg@exept.de>
parents:
7998
diff
changeset
|
3837 |
with:(setOfSelectors asOrderedCollection second). |
8bc319ff9ba7
better title in implementorsOfAny
Claus Gittinger <cg@exept.de>
parents:
7998
diff
changeset
|
3838 |
] ifFalse:[ |
8bc319ff9ba7
better title in implementorsOfAny
Claus Gittinger <cg@exept.de>
parents:
7998
diff
changeset
|
3839 |
title := self classResources string:'Implementors of some'. |
8bc319ff9ba7
better title in implementorsOfAny
Claus Gittinger <cg@exept.de>
parents:
7998
diff
changeset
|
3840 |
]. |
8bc319ff9ba7
better title in implementorsOfAny
Claus Gittinger <cg@exept.de>
parents:
7998
diff
changeset
|
3841 |
]. |
8bc319ff9ba7
better title in implementorsOfAny
Claus Gittinger <cg@exept.de>
parents:
7998
diff
changeset
|
3842 |
|
3663 | 3843 |
^ self |
3844 |
browseImplementorsOfAny:setOfSelectors |
|
3845 |
in:aSetOfClasses |
|
8047
8bc319ff9ba7
better title in implementorsOfAny
Claus Gittinger <cg@exept.de>
parents:
7998
diff
changeset
|
3846 |
title:title |
3663 | 3847 |
|
3848 |
" |
|
3849 |
SystemBrowser browseImplementorsOf:#+ in:(Number withAllSubclasses) |
|
3850 |
NewSystemBrowser browseImplementorsOf:#+ in:(Number withAllSubclasses) |
|
3851 |
" |
|
3852 |
||
3853 |
"Created: / 10.7.1996 / 10:20:59 / cg" |
|
3854 |
"Modified: / 5.11.2001 / 17:30:57 / cg" |
|
3855 |
! |
|
3856 |
||
3857 |
browseImplementorsOfAny:setOfSelectors in:aCollectionOfClasses ignoreCase:ignoreCase title:title |
|
3858 |
"launch a browser for all implementors of aSelector in |
|
16586 | 3859 |
the classes contained in aCollectionOfClasses and their metaclasses" |
3663 | 3860 |
|
3861 |
|list| |
|
3862 |
||
3863 |
list := self |
|
3864 |
findImplementorsOfAny:setOfSelectors |
|
3865 |
in:aCollectionOfClasses |
|
3866 |
ignoreCase:ignoreCase. |
|
3867 |
||
3868 |
list size == 0 ifTrue:[ |
|
3869 |
self showNoneFound:title. |
|
3870 |
^ nil |
|
3871 |
]. |
|
3872 |
||
3873 |
^ self browseMethods:list asOrderedCollection title:title |
|
3874 |
||
3875 |
" |
|
3876 |
SystemBrowser browseImplementorsOf:#+ |
|
3877 |
in:(Array with:Number |
|
3878 |
with:Float |
|
3879 |
with:SmallInteger) |
|
3880 |
title:'some implementors of +' |
|
3881 |
||
3882 |
NewSystemBrowser browseImplementorsOf:#+ |
|
3883 |
in:(Array with:Number |
|
3884 |
with:Float |
|
3885 |
with:SmallInteger) |
|
3886 |
title:'some implementors of +' |
|
3887 |
" |
|
3888 |
||
3889 |
"Modified: / 4.9.1995 / 17:33:39 / claus" |
|
3890 |
"Modified: / 19.6.1996 / 14:19:02 / stefan" |
|
3891 |
"Modified: / 5.11.2001 / 17:30:38 / cg" |
|
3892 |
! |
|
3893 |
||
3894 |
browseImplementorsOfAny:setOfSelectors in:aCollectionOfClasses title:title |
|
3895 |
"launch a browser for all implementors of aSelector in |
|
16586 | 3896 |
the classes contained in aCollectionOfClasses and their metaclasses" |
3663 | 3897 |
|
3898 |
^ self |
|
3899 |
browseImplementorsOfAny:setOfSelectors |
|
3900 |
in:aCollectionOfClasses |
|
3901 |
ignoreCase:false |
|
3902 |
title:title |
|
3903 |
! |
|
3904 |
||
203 | 3905 |
browseInstRefsTo:aString in:aCollectionOfClasses modificationsOnly:modsOnly |
3906 |
"launch a browser for all methods in aClass where the instVar named |
|
3907 |
aString is referenced; if modsOnly is true, browse only methods where the |
|
3908 |
instvar is modified" |
|
45 | 3909 |
|
203 | 3910 |
^ self browseRefsTo:aString classVars:false in:aCollectionOfClasses modificationsOnly:modsOnly |
36 | 3911 |
! |
3912 |
||
203 | 3913 |
browseInstRefsTo:varName in:aCollectionOfClasses modificationsOnly:modsOnly title:title |
3914 |
"launch a browser for all methods in aClass where the instVar named |
|
3915 |
varName is referenced; if modsOnly is true, browse only methods where the |
|
3916 |
instvar is modified" |
|
52 | 3917 |
|
203 | 3918 |
^ self browseRefsTo:varName classVars:false in:aCollectionOfClasses modificationsOnly:modsOnly title:title |
52 | 3919 |
! |
3920 |
||
203 | 3921 |
browseInstRefsTo:aString under:aClass modificationsOnly:modsOnly |
3922 |
"launch a browser for all methods in aClass and subclasses |
|
3923 |
where the instVar named aString is referenced; |
|
3924 |
if modsOnly is true, browse only methods where the instvar is modified" |
|
36 | 3925 |
|
203 | 3926 |
^ self browseInstRefsTo:aString in:(aClass withAllSubclasses) modificationsOnly:modsOnly |
36 | 3927 |
! |
3928 |
||
3929 |
browseReferendsOf:aGlobalName |
|
3930 |
"launch a browser for all methods referencing a global |
|
1367 | 3931 |
named aGlobalName. The argument may be a symbol, a string or |
3932 |
a matchPattern. |
|
36 | 3933 |
" |
3934 |
||
3935 |
^ self browseReferendsOf:aGlobalName warnIfNone:true |
|
3936 |
||
3937 |
" |
|
14944 | 3938 |
UserPreferences current systemBrowserClass browseReferendsOf:#Transcript |
3939 |
UserPreferences current systemBrowserClass browseReferendsOf:'Tr*' |
|
36 | 3940 |
" |
75 | 3941 |
|
1367 | 3942 |
"Modified: / 30.10.1997 / 23:45:52 / cg" |
36 | 3943 |
! |
3944 |
||
2409 | 3945 |
browseReferendsOf:aGlobalName ifNone:actionIfNone |
3946 |
"launch a browser for all methods referencing a global |
|
3947 |
named aGlobalName. |
|
3948 |
" |
|
3949 |
||
3950 |
^ self |
|
3951 |
browseReferendsOf:aGlobalName |
|
6476 | 3952 |
title:(self classResources string:'Users of: %1' with:aGlobalName) |
2409 | 3953 |
ifNone:actionIfNone |
3954 |
||
3955 |
"Modified: / 31.10.1997 / 15:42:05 / cg" |
|
3956 |
! |
|
3957 |
||
666 | 3958 |
browseReferendsOf:aGlobalName in:aSetOfClasses |
3959 |
"launch a browser for all methods referencing a global |
|
3960 |
named aGlobalName. |
|
3961 |
" |
|
3962 |
||
3963 |
^ self browseReferendsOf:aGlobalName in:aSetOfClasses warnIfNone:true |
|
3964 |
||
3965 |
" |
|
3966 |
Browser browseReferendsOf:#Transcript |
|
3967 |
" |
|
3968 |
||
3969 |
"Created: 10.7.1996 / 10:37:30 / cg" |
|
3970 |
! |
|
3971 |
||
3972 |
browseReferendsOf:aGlobalName in:aSetOfClasses warnIfNone:doWarn |
|
3973 |
"launch a browser for all methods referencing a global |
|
3974 |
named aGlobalName. |
|
3975 |
" |
|
3976 |
||
820
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
3977 |
|globalsPlainName idx| |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
3978 |
|
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
3979 |
globalsPlainName := aGlobalName. |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
3980 |
(idx := globalsPlainName lastIndexOf:$:) ~~ 0 ifTrue:[ |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
3981 |
globalsPlainName := globalsPlainName copyFrom:idx+1 |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
3982 |
]. |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
3983 |
|
666 | 3984 |
^ self browseForSymbol:aGlobalName |
3985 |
in:aSetOfClasses |
|
6476 | 3986 |
title:(self classResources string:'Users of: %1' with:aGlobalName) |
666 | 3987 |
warnIfNone:doWarn |
820
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
3988 |
searchFor:globalsPlainName |
666 | 3989 |
|
3990 |
"Created: 10.7.1996 / 10:37:02 / cg" |
|
820
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
3991 |
"Modified: 31.10.1996 / 14:56:38 / cg" |
666 | 3992 |
! |
3993 |
||
2409 | 3994 |
browseReferendsOf:aGlobalName title:title ifNone:actionIfNone |
17967 | 3995 |
"launch a browser for all methods referencing a global named aGlobalName. |
3996 |
If aGlobalName is inside a namespace (a private or namespace-global), |
|
3997 |
the search should be for a global named <namespace>::<aGlobalName>" |
|
9002 | 3998 |
|
3999 |
|searchBlock browser| |
|
4000 |
||
4001 |
searchBlock := self searchBlockForReferendsOf:aGlobalName. |
|
4002 |
browser := self |
|
4003 |
browseMethodsWhere:searchBlock |
|
4004 |
title:title |
|
4005 |
ifNone:[ |
|
4006 |
actionIfNone value. |
|
4007 |
^ nil |
|
4008 |
]. |
|
4009 |
||
2828 | 4010 |
browser isNil ifTrue:[ |
4011 |
actionIfNone value |
|
4012 |
] ifFalse:[ |
|
9010
fa5c1fef4aef
changed: #browseReferendsOf:title:ifNone:
Claus Gittinger <cg@exept.de>
parents:
9007
diff
changeset
|
4013 |
browser autoSearchVariable:aGlobalName. |
2828 | 4014 |
]. |
4015 |
^ browser |
|
9002 | 4016 |
|
4017 |
" |
|
4018 |
Tools::NewSystemBrowser browseReferendsOf:'SortedCollection' title:'foo' ifNone:[ self halt ] |
|
4019 |
" |
|
2409 | 4020 |
! |
4021 |
||
4022 |
browseReferendsOf:aGlobalName title:title warnIfNone:doWarn |
|
17967 | 4023 |
"launch a browser for all methods referencing a global named aGlobalName. |
4024 |
If aGlobalName is inside a namespace (a private or namespace-global), |
|
4025 |
the search should be for a global named <namespace>::<aGlobalName>" |
|
2409 | 4026 |
|
2414 | 4027 |
|b| |
4028 |
||
4029 |
doWarn ifTrue: [ |
|
4158 | 4030 |
b := [self showNoneFound:title] |
2414 | 4031 |
]. |
4032 |
||
2409 | 4033 |
^ self |
4034 |
browseReferendsOf:aGlobalName |
|
4035 |
title:title |
|
2414 | 4036 |
ifNone:b |
1367 | 4037 |
! |
4038 |
||
4039 |
browseReferendsOf:aGlobalName warnIfNone:doWarn |
|
17967 | 4040 |
"launch a browser for all methods referencing a global named aGlobalName. |
4041 |
If aGlobalName is inside a namespace (a private or namespace-global), |
|
4042 |
the search should be for a global named <namespace>::<aGlobalName>" |
|
1367 | 4043 |
|
4044 |
^ self |
|
4045 |
browseReferendsOf:aGlobalName |
|
6476 | 4046 |
title:(self classResources string:'Users of: %1' with:aGlobalName) |
1367 | 4047 |
warnIfNone:doWarn |
4048 |
||
4049 |
"Modified: / 31.10.1997 / 15:42:05 / cg" |
|
203 | 4050 |
! |
4051 |
||
4198
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
4052 |
browseReferendsOfUnboundGlobalsWithTitle:title ifNone:actionIfNone |
12844 | 4053 |
"launch a browser for all methods referencing an unbound global." |
4054 |
||
4055 |
|searchBlock browser| |
|
4198
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
4056 |
|
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
4057 |
searchBlock := [:cls :mthd :sel | |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
4058 |
|
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
4059 |
|mSource globals potentialNames| |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
4060 |
|
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
4061 |
"/ kludge: Lazy methods do not include symbols in the literal array - sigh |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
4062 |
mthd isLazyMethod ifTrue:[ |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
4063 |
mSource := mthd source. |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
4064 |
mSource notNil ifTrue:[ |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
4065 |
globals := mthd usedGlobals. |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
4066 |
]. |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
4067 |
] ifFalse:[ |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
4068 |
"/ try hard to avoid the usedGlobals - its expensive |
6640 | 4069 |
potentialNames := mthd literals select:[:lit | lit isSymbol and:[lit size > 0 and:[lit isUppercaseFirst]]]. |
4198
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
4070 |
potentialNames notEmpty ifTrue:[ |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
4071 |
potentialNames := potentialNames select:[:lit | (Smalltalk at:lit) isNil]. |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
4072 |
potentialNames notEmpty ifTrue:[ |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
4073 |
globals := mthd usedGlobals. |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
4074 |
] |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
4075 |
] |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
4076 |
]. |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
4077 |
globals notNil ifTrue:[ |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
4078 |
globals contains:[:aGlobalKey | (Smalltalk at:aGlobalKey asSymbol) isNil]. |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
4079 |
] ifFalse:[ |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
4080 |
false |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
4081 |
] |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
4082 |
]. |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
4083 |
|
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
4084 |
browser := self browseMethodsWhere:searchBlock title:title ifNone:[actionIfNone value. ^ nil]. |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
4085 |
browser isNil ifTrue:[ |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
4086 |
actionIfNone value |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
4087 |
]. |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
4088 |
^ browser |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
4089 |
! |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
4090 |
|
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
4091 |
browseReferendsOfUnboundGlobalsWithTitle:title warnIfNone:doWarn |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
4092 |
"launch a browser for all methods referencing an unbound global. |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
4093 |
" |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
4094 |
|
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
4095 |
|b| |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
4096 |
|
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
4097 |
doWarn ifTrue: [ |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
4098 |
b := [self showNoneFound:title] |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
4099 |
]. |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
4100 |
|
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
4101 |
^ self |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
4102 |
browseReferendsOfUnboundGlobalsWithTitle:title |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
4103 |
ifNone:b |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
4104 |
! |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
4105 |
|
203 | 4106 |
browseRefsTo:aString classVars:classVars in:aCollectionOfClasses modificationsOnly:modsOnly |
4107 |
"launch a browser for all methods in aClass where the instVar/classVar named |
|
4108 |
aString is referenced; if modsOnly is true, browse only methods where the |
|
4109 |
instvar is modified" |
|
4110 |
||
4111 |
|title| |
|
4112 |
||
4113 |
modsOnly ifTrue:[ |
|
6476 | 4114 |
title := 'Modifications of: %1' |
203 | 4115 |
] ifFalse:[ |
6476 | 4116 |
title := 'References to: %1 ' |
203 | 4117 |
]. |
4118 |
^ self |
|
256 | 4119 |
browseRefsTo:aString |
4120 |
classVars:classVars |
|
4121 |
in:aCollectionOfClasses |
|
4122 |
modificationsOnly:modsOnly |
|
4123 |
title:(self classResources string:title with:aString) |
|
4124 |
||
4125 |
"Created: 9.12.1995 / 18:07:05 / cg" |
|
4126 |
"Modified: 9.12.1995 / 18:11:49 / cg" |
|
203 | 4127 |
! |
4128 |
||
4129 |
browseRefsTo:varName classVars:classVars in:aCollectionOfClasses modificationsOnly:modsOnly title:title |
|
4130 |
"launch a browser for all methods in aClass where the instVar/classVar named |
|
4131 |
varName is referenced; if modsOnly is true, browse only methods where the |
|
4132 |
instvar is modified" |
|
4133 |
||
4134 |
|filter browser pattern| |
|
4135 |
||
4136 |
filter := self filterToSearchRefsTo:varName classVars:classVars modificationsOnly:modsOnly. |
|
2677 | 4137 |
browser := self browseMethodsIn:aCollectionOfClasses inst:true class:classVars where:filter title:title. |
203 | 4138 |
|
4139 |
browser notNil ifTrue:[ |
|
2677 | 4140 |
modsOnly ifTrue:[ |
4141 |
pattern := varName , ' :=' |
|
4142 |
] ifFalse:[ |
|
4143 |
pattern := varName |
|
4144 |
]. |
|
4145 |
browser autoSearch:pattern |
|
203 | 4146 |
]. |
4147 |
^ browser |
|
4148 |
! |
|
4149 |
||
3407 | 4150 |
browseSendersOf:aSelectorString |
4151 |
"launch a browser for all senders of aSelector" |
|
4152 |
||
4153 |
^ self browseAllCallsOn:aSelectorString |
|
4154 |
||
4155 |
" |
|
4156 |
SystemBrowser browseSendersOf:#+ |
|
7914 | 4157 |
UserPreferences current systemBrowserClass browseSendersOf:#+ |
3407 | 4158 |
" |
4159 |
||
4160 |
"Modified: / 10.7.1996 / 10:26:15 / cg" |
|
4161 |
"Created: / 13.11.2001 / 13:52:12 / cg" |
|
4162 |
! |
|
4163 |
||
256 | 4164 |
browseSuperCallsIn:aCollectionOfClasses title:title |
4165 |
"launch a browser for all super sends in aCollectionOfClasses" |
|
4166 |
||
742
2ef5e22d8983
code cleanup (unused vars eliminated)
Claus Gittinger <cg@exept.de>
parents:
675
diff
changeset
|
4167 |
|browser searchBlock| |
256 | 4168 |
|
4169 |
searchBlock := [:class :method :s | |
|
504 | 4170 |
|src parser| |
256 | 4171 |
|
504 | 4172 |
src := method source. |
15334 | 4173 |
(src notNil and:[ (src findString:'super') ~~ 0 ]) ifTrue:[ |
4174 |
parser := Parser |
|
2208
e077aa992f7a
check for nil source in #allCallsOn: (for methods where src in not available)
Claus Gittinger <cg@exept.de>
parents:
1937
diff
changeset
|
4175 |
parseMethod:src |
504 | 4176 |
in:class |
4177 |
ignoreErrors:true |
|
4178 |
ignoreWarnings:true. |
|
4179 |
||
7711 | 4180 |
(parser notNil and:[parser ~~ #Error and:[parser usesSuper]]) |
504 | 4181 |
] ifFalse:[ |
4182 |
false |
|
4183 |
] |
|
256 | 4184 |
]. |
4185 |
||
4186 |
browser := self browseMethodsIn:aCollectionOfClasses |
|
504 | 4187 |
where:searchBlock |
4188 |
title:title. |
|
256 | 4189 |
|
4190 |
browser notNil ifTrue:[ |
|
504 | 4191 |
browser autoSearch:'super' |
256 | 4192 |
]. |
4193 |
^ browser |
|
4194 |
||
504 | 4195 |
" |
4196 |
SystemBrowser |
|
4197 |
browseSuperCallsIn:(Array with:SortedCollection) |
|
4198 |
title:'superSends in SortedCollection' |
|
4199 |
" |
|
4200 |
||
7711 | 4201 |
"Created: / 23-11-1995 / 14:08:55 / cg" |
4202 |
"Modified: / 06-03-2007 / 14:00:12 / cg" |
|
256 | 4203 |
! |
4204 |
||
4205 |
browseSuperCallsUnder:aClass |
|
4206 |
"launch a browser for all supersends in aClass and subclasses" |
|
4207 |
||
4208 |
^ self browseSuperCallsIn:(aClass withAllSubclasses) |
|
6476 | 4209 |
title:(self classResources string:'Supersends (in and below %1)' with:aClass name) |
256 | 4210 |
|
4211 |
" |
|
4212 |
SystemBrowser browseSuperCallsUnder:Number |
|
4213 |
" |
|
4214 |
||
4215 |
"Created: 23.11.1995 / 12:06:06 / cg" |
|
4216 |
"Modified: 9.12.1995 / 18:11:59 / cg" |
|
4217 |
! |
|
4218 |
||
52 | 4219 |
browseUsesOf:aClass |
4220 |
|dict owners offsets |
|
4221 |
sz "{ Class: SmallInteger }" |
|
4222 |
n "{ Class: SmallInteger }" |
|
4223 |
removeSet newDict| |
|
4224 |
||
4225 |
owners := ObjectMemory whoReferencesInstancesOf:aClass. |
|
4226 |
||
4227 |
" |
|
4228 |
collect set of offsets in dict; key is class |
|
4229 |
" |
|
4230 |
dict := IdentityDictionary new. |
|
4231 |
owners do:[:someObject | |
|
4158 | 4232 |
|cls create| |
4233 |
||
4234 |
someObject isContext ifFalse:[ |
|
4235 |
" |
|
4236 |
someObject refers to an instance of aClass; |
|
4237 |
find out, which instVar(s) |
|
4238 |
" |
|
4239 |
cls := someObject class. |
|
4240 |
cls ~~ Array ifTrue:[ |
|
4241 |
n := cls instSize. |
|
4242 |
create := [|s| s := Set new. dict at:cls put:s. s]. |
|
4243 |
||
4244 |
1 to:n do:[:i | |
|
4245 |
|ref| |
|
4246 |
||
4247 |
ref := someObject instVarAt:i. |
|
4248 |
(ref isMemberOf:aClass) ifTrue:[ |
|
4249 |
offsets := dict at:cls ifAbsent:create. |
|
4250 |
offsets add:i. |
|
4251 |
] |
|
4252 |
]. |
|
4253 |
cls isVariable ifTrue:[ |
|
4254 |
cls isPointers ifTrue:[ |
|
4255 |
| idx "{ Class: SmallInteger }" | |
|
4256 |
||
4257 |
sz := someObject basicSize. |
|
4258 |
idx := 1. |
|
4259 |
[idx <= sz] whileTrue:[ |
|
4260 |
|ref| |
|
4261 |
||
4262 |
ref := someObject basicAt:idx. |
|
4263 |
(ref isMemberOf:aClass) ifTrue:[ |
|
4264 |
offsets := dict at:cls ifAbsent:create. |
|
4265 |
offsets add:0. |
|
4266 |
idx := sz |
|
4267 |
]. |
|
4268 |
idx := idx + 1 |
|
4269 |
] |
|
4270 |
] |
|
4271 |
] |
|
4272 |
] |
|
4273 |
] |
|
52 | 4274 |
]. |
4275 |
||
4276 |
" |
|
4277 |
merge with superclass refs |
|
4278 |
" |
|
4279 |
dict keysAndValuesDo:[:cls :set | |
|
4158 | 4280 |
cls allSuperclasses do:[:aSuperclass | |
4281 |
|superSet| |
|
4282 |
||
4283 |
superSet := dict at:aSuperclass ifAbsent:[]. |
|
4284 |
superSet notNil ifTrue:[ |
|
4285 |
superSet := dict at:aSuperclass. |
|
4286 |
removeSet := Set new. |
|
4287 |
set do:[:offset | |
|
4288 |
(superSet includes:offset) ifTrue:[ |
|
4289 |
removeSet add:offset |
|
4290 |
] |
|
4291 |
]. |
|
4292 |
set removeAll:removeSet |
|
4293 |
] |
|
4294 |
] |
|
52 | 4295 |
]. |
4296 |
||
4297 |
" |
|
4298 |
remove empty ones |
|
4299 |
" |
|
4300 |
removeSet := Set new. |
|
4301 |
dict keysAndValuesDo:[:cls :set | |
|
4158 | 4302 |
set isEmpty ifTrue:[ |
4303 |
removeSet add:cls |
|
4304 |
] |
|
52 | 4305 |
]. |
9334 | 4306 |
dict removeAllKeys:removeSet. |
52 | 4307 |
|
4308 |
" |
|
4309 |
replace the indices by real names |
|
4310 |
" |
|
4311 |
newDict := IdentityDictionary new. |
|
4312 |
dict keysAndValuesDo:[:cls :set | |
|
4158 | 4313 |
|newSet names| |
4314 |
||
4315 |
names := cls allInstVarNames. |
|
4316 |
newSet := set collect:[:index | |
|
4317 |
index == 0 ifTrue:['*indexed*'] ifFalse:[names at:index]. |
|
4318 |
]. |
|
4319 |
newDict at:cls put:newSet |
|
52 | 4320 |
]. |
4321 |
||
4322 |
newDict inspect |
|
4323 |
! |
|
4324 |
||
2736
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4325 |
filterToSearchRefsTo:varName classVars:classVars access:accessType |
7914 | 4326 |
"return a searchblock for variable references (obsolete)" |
4327 |
||
4328 |
^ self |
|
4329 |
filterToSearchRefsTo:varName |
|
4330 |
instVars:(classVars not) |
|
4331 |
classVars:classVars |
|
11934 | 4332 |
globals:false |
4333 |
poolVars:false |
|
7914 | 4334 |
access:accessType |
4335 |
! |
|
4336 |
||
4337 |
filterToSearchRefsTo:varName classVars:classVars modificationsOnly:modsOnly |
|
4338 |
"return a searchblock for variable references" |
|
4339 |
||
4340 |
^ self |
|
4341 |
filterToSearchRefsTo:varName |
|
4342 |
classVars:classVars |
|
4343 |
access:(modsOnly ifTrue:#write ifFalse:#readWrite) |
|
4344 |
! |
|
4345 |
||
4346 |
filterToSearchRefsTo:varName instVars:doInstVars classVars:doClassVars globals:doGlobals access:accessType |
|
2736
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4347 |
"return a searchblock for variable references" |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4348 |
|
11934 | 4349 |
^ self |
4350 |
filterToSearchRefsTo:varName instVars:doInstVars classVars:doClassVars globals:doGlobals |
|
4351 |
poolVars:false access:accessType |
|
4352 |
! |
|
4353 |
||
4354 |
filterToSearchRefsTo:varName instVars:doInstVars classVars:doClassVars globals:doGlobals poolVars:doPoolVars access:accessType |
|
4355 |
"return a searchblock for variable references" |
|
4356 |
||
4357 |
|searchBlock needMatch baseVarName| |
|
4358 |
||
4359 |
needMatch := varName includesMatchCharacters. |
|
4360 |
(varName includes:$:) ifTrue:[ |
|
4361 |
baseVarName := varName copyFrom:(varName lastIndexOf:$:)+1 |
|
4362 |
] ifFalse:[ |
|
4363 |
baseVarName := varName |
|
4364 |
]. |
|
2736
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4365 |
|
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4366 |
searchBlock := [:c :m :s | |
11934 | 4367 |
|src result parser vars instVars classVars poolVars globals| |
2736
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4368 |
|
7914 | 4369 |
result := false. |
4370 |
||
13525
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4371 |
"/ JV Following code is bad. It assumes that method is a Smalltalk method. |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4372 |
"/ But it may not, it could be JavaScript method, Java method or whatever fancy language |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4373 |
"/ method. Should be actually delegated to the method itself. |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4374 |
|
17596 | 4375 |
(m programmingLanguage isSmalltalk |
4376 |
or:[ m programmingLanguage isSTXJavaScript ]) ifTrue:[ |
|
13525
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4377 |
"/ For Smalltalk, use parser... |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4378 |
src := m source. |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4379 |
src notNil ifTrue:[ |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4380 |
needMatch ifFalse:[ |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4381 |
" |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4382 |
before doing a slow parse, quickly scan the |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4383 |
method's source for the variable's name ... |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4384 |
" |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4385 |
result := (src findString:baseVarName) ~~ 0. |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4386 |
] ifTrue:[ |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4387 |
result := true. |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4388 |
]. |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4389 |
result ifTrue:[ |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4390 |
result := false. |
17596 | 4391 |
parser := (m parserClass) |
13525
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4392 |
parseMethod:src |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4393 |
in:c |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4394 |
ignoreErrors:true |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4395 |
ignoreWarnings:true. |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4396 |
|
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4397 |
(parser notNil and:[parser ~~ #Error]) ifTrue:[ |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4398 |
vars := Set new. |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4399 |
doInstVars ifTrue:[ |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4400 |
accessType == #read ifTrue:[ |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4401 |
instVars := parser readInstVars |
2736
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4402 |
] ifFalse:[ |
13525
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4403 |
accessType == #write ifTrue:[ |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4404 |
instVars := parser modifiedInstVars |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4405 |
] ifFalse:[ |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4406 |
instVars := parser usedInstVars |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4407 |
] |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4408 |
]. |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4409 |
vars addAll:instVars. |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4410 |
]. |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4411 |
doClassVars ifTrue:[ |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4412 |
accessType == #read ifTrue:[ |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4413 |
classVars := parser readClassVars |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4414 |
] ifFalse:[ |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4415 |
accessType == #write ifTrue:[ |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4416 |
classVars := parser modifiedClassVars |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4417 |
] ifFalse:[ |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4418 |
classVars := parser usedClassVars |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4419 |
] |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4420 |
]. |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4421 |
vars addAll:classVars. |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4422 |
]. |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4423 |
doPoolVars ifTrue:[ |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4424 |
accessType == #read ifTrue:[ |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4425 |
poolVars := parser readPoolVars |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4426 |
] ifFalse:[ |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4427 |
accessType == #write ifTrue:[ |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4428 |
poolVars := parser modifiedPoolVars |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4429 |
] ifFalse:[ |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4430 |
poolVars := parser usedPoolVars |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4431 |
] |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4432 |
]. |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4433 |
vars addAll:poolVars. |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4434 |
]. |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4435 |
doGlobals ifTrue:[ |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4436 |
accessType == #read ifTrue:[ |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4437 |
globals := parser readGlobals |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4438 |
] ifFalse:[ |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4439 |
accessType == #write ifTrue:[ |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4440 |
globals := parser modifiedGlobals |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4441 |
] ifFalse:[ |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4442 |
globals := parser usedGlobals |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4443 |
] |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4444 |
]. |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4445 |
vars addAll:globals. |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4446 |
]. |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4447 |
vars size > 0 ifTrue:[ |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4448 |
needMatch ifTrue:[ |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4449 |
result := vars contains:[:cv | (varName match:cv)] |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4450 |
] ifFalse:[ |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4451 |
result := vars includes:varName |
2736
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4452 |
] |
13525
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4453 |
] |
7914 | 4454 |
]. |
13525
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4455 |
]. |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4456 |
]. |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4457 |
] ifFalse:[ |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4458 |
"/ For all other languages, ask method. |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4459 |
vars := Set new. |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4460 |
doInstVars ifTrue:[ |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4461 |
accessType == #read ifTrue:[ |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4462 |
instVars := m readInstVars |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4463 |
] ifFalse:[ |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4464 |
accessType == #write ifTrue:[ |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4465 |
instVars := m modifiedInstVars |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4466 |
] ifFalse:[ |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4467 |
instVars := m usedInstVars |
504 | 4468 |
] |
4469 |
]. |
|
13525
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4470 |
vars addAll:instVars. |
504 | 4471 |
]. |
13525
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4472 |
doClassVars ifTrue:[ |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4473 |
accessType == #read ifTrue:[ |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4474 |
classVars := m readClassVars |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4475 |
] ifFalse:[ |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4476 |
accessType == #write ifTrue:[ |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4477 |
classVars := m modifiedClassVars |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4478 |
] ifFalse:[ |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4479 |
classVars := m usedClassVars |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4480 |
] |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4481 |
]. |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4482 |
vars addAll:classVars. |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4483 |
]. |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4484 |
doPoolVars ifTrue:[ |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4485 |
accessType == #read ifTrue:[ |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4486 |
poolVars := m readPoolVars |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4487 |
] ifFalse:[ |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4488 |
accessType == #write ifTrue:[ |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4489 |
poolVars := m modifiedPoolVars |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4490 |
] ifFalse:[ |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4491 |
poolVars := m usedPoolVars |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4492 |
] |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4493 |
]. |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4494 |
vars addAll:poolVars. |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4495 |
]. |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4496 |
doGlobals ifTrue:[ |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4497 |
accessType == #read ifTrue:[ |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4498 |
globals := m readGlobals |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4499 |
] ifFalse:[ |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4500 |
accessType == #write ifTrue:[ |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4501 |
globals := m modifiedGlobals |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4502 |
] ifFalse:[ |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4503 |
globals := m usedGlobals |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4504 |
] |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4505 |
]. |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4506 |
vars addAll:globals. |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4507 |
]. |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4508 |
vars size > 0 ifTrue:[ |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4509 |
needMatch ifTrue:[ |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4510 |
result := vars contains:[:cv | (varName match:cv)] |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4511 |
] ifFalse:[ |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4512 |
result := vars includes:varName |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4513 |
] |
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4514 |
] |
504 | 4515 |
]. |
4516 |
Processor yield. |
|
4517 |
result |
|
36 | 4518 |
]. |
203 | 4519 |
^ searchBlock |
504 | 4520 |
|
13525
a8195f61d4f2
Fixes required by Java class browser
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13438
diff
changeset
|
4521 |
"Modified: / 06-09-2013 / 18:02:22 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
17596 | 4522 |
"Modified: / 23-07-2017 / 13:47:40 / cg" |
2642 | 4523 |
! |
4524 |
||
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
4525 |
findAnyResourceIn:aCollectionOfClasses |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
4526 |
"return a collection of all methods in aCollectionOfClasses containing any resource." |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
4527 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
4528 |
^ self findMethodsIn:aCollectionOfClasses where:[:c :m :sel | m hasResource ]. |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
4529 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
4530 |
" |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
4531 |
SystemBrowser findAnyResourceIn:(ApplicationModel withAllSubclasses) |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
4532 |
" |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
4533 |
! |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
4534 |
|
2736
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4535 |
findClassRefsTo:aString in:aCollectionOfClasses access:accessType |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4536 |
"return all methods in aCollectionOfClasses where the classVar named |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4537 |
aString is referenced; |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4538 |
if modsOnly is true, browse only methods where the classvar is modified" |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4539 |
|
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4540 |
^ self findRefsTo:aString classVars:true in:aCollectionOfClasses access:accessType |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4541 |
! |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4542 |
|
2677 | 4543 |
findClassRefsTo:aString in:aCollectionOfClasses modificationsOnly:modsOnly |
2728 | 4544 |
"return all methods in aCollectionOfClasses where the classVar named |
2677 | 4545 |
aString is referenced; |
4546 |
if modsOnly is true, browse only methods where the classvar is modified" |
|
4547 |
||
4548 |
^ self findRefsTo:aString classVars:true in:aCollectionOfClasses modificationsOnly:modsOnly |
|
4549 |
! |
|
4550 |
||
2736
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4551 |
findClassRefsTo:aString inClass:aClass access:accessType |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4552 |
"return all methods in aClass where the classVar named |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4553 |
aString is referenced; |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4554 |
if modsOnly is true, browse only methods where the classvar is modified" |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4555 |
|
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4556 |
^ self findRefsTo:aString classVars:true in:(Array with:aClass) access:accessType |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4557 |
! |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4558 |
|
2728 | 4559 |
findClassRefsTo:aString inClass:aClass modificationsOnly:modsOnly |
4560 |
"return all methods in aClass where the classVar named |
|
4561 |
aString is referenced; |
|
4562 |
if modsOnly is true, browse only methods where the classvar is modified" |
|
4563 |
||
4564 |
^ self findRefsTo:aString classVars:true in:(Array with:aClass) modificationsOnly:modsOnly |
|
4565 |
! |
|
4566 |
||
2736
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4567 |
findClassRefsTo:aString under:aClass access:accessType |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4568 |
"return all methods in aClass and subclasses |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4569 |
where the classVar named aString is referenced; |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4570 |
if modsOnly is true, browse only methods where the classvar is modified" |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4571 |
|
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4572 |
^ self findClassRefsTo:aString in:(aClass withAllSubclasses) access:accessType |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4573 |
! |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4574 |
|
2677 | 4575 |
findClassRefsTo:aString under:aClass modificationsOnly:modsOnly |
4576 |
"return all methods in aClass and subclasses |
|
4577 |
where the classVar named aString is referenced; |
|
4578 |
if modsOnly is true, browse only methods where the classvar is modified" |
|
4579 |
||
4580 |
^ self findClassRefsTo:aString in:(aClass withAllSubclasses) modificationsOnly:modsOnly |
|
4581 |
||
4582 |
! |
|
4583 |
||
5094 | 4584 |
findCode:aCodeString in:aCollectionOfClasses isMethod:isMethod |
5243 | 4585 |
"return a collection of all methods in aCollectionOfClasses |
5094 | 4586 |
containing a matching piece of code. |
4587 |
This may be slow, since source-code has to be scanned." |
|
4588 |
||
4589 |
|searchBlock| |
|
4590 |
||
9879 | 4591 |
searchBlock := self searchBlockForCode:aCodeString in:aCollectionOfClasses isMethod:isMethod. |
5226 | 4592 |
searchBlock isNil ifTrue:[ ^ nil]. |
5094 | 4593 |
^ self findMethodsIn:aCollectionOfClasses where:searchBlock. |
9879 | 4594 |
|
4595 |
"Modified: / 02-05-2011 / 13:25:15 / sr" |
|
5094 | 4596 |
! |
4597 |
||
5243 | 4598 |
findCode:aCodeString inMethods:aCollectionOfMethods isMethod:isMethod |
4599 |
"return a collection of all methods in aCollectionOfMethods |
|
4600 |
containing a matching piece of code." |
|
4601 |
||
4602 |
|searchBlock| |
|
4603 |
||
9879 | 4604 |
searchBlock := self searchBlockForCode:aCodeString in:(aCollectionOfMethods collect:[:each | each mclass]) isMethod:isMethod. |
5243 | 4605 |
searchBlock isNil ifTrue:[ ^ nil]. |
4606 |
^ aCollectionOfMethods select:[:m | searchBlock value:m mclass value:m value:m selector]. |
|
9879 | 4607 |
|
4608 |
"Modified: / 02-05-2011 / 13:25:39 / sr" |
|
5243 | 4609 |
! |
4610 |
||
9482 | 4611 |
findExceptionHandlersIn:aCollectionOfClasses |
4612 |
"return a collection of all methods in aCollectionOfClasses |
|
4613 |
containing an exception raiser. |
|
4614 |
This may be slow, since source-code has to be scanned." |
|
4615 |
||
4616 |
^ self findUsingParseTreeSearcher:(ParseTreeSearcher handlesException) in:aCollectionOfClasses |
|
4617 |
||
4618 |
"Modified: / 11-05-2010 / 16:18:55 / cg" |
|
4619 |
! |
|
4620 |
||
4621 |
findExceptionHandlersInMethods:aCollectionOfMethods |
|
4622 |
"return a collection of all methods in aCollectionOfClasses |
|
4623 |
containing an exception raiser. |
|
4624 |
This may be slow, since source-code has to be scanned." |
|
4625 |
||
4626 |
^ self findUsingParseTreeSearcher:(ParseTreeSearcher handlesException) inMethods:aCollectionOfMethods |
|
4627 |
||
4628 |
"Created: / 11-05-2010 / 16:20:48 / cg" |
|
4629 |
! |
|
4630 |
||
4631 |
findExceptionRaisersIn:aCollectionOfClasses |
|
4632 |
"return a collection of all methods in aCollectionOfClasses |
|
4633 |
containing an exception raiser. |
|
4634 |
This may be slow, since source-code has to be scanned." |
|
4635 |
||
4636 |
^ self findUsingParseTreeSearcher:(ParseTreeSearcher raisesException) in:aCollectionOfClasses |
|
4637 |
||
4638 |
"Modified: / 11-05-2010 / 16:18:48 / cg" |
|
4639 |
! |
|
4640 |
||
4641 |
findExceptionRaisersInMethods:aCollectionOfMethods |
|
4642 |
"return a collection of all methods in aCollectionOfClasses |
|
4643 |
containing an exception raiser. |
|
4644 |
This may be slow, since source-code has to be scanned." |
|
4645 |
||
4646 |
^ self findUsingParseTreeSearcher:(ParseTreeSearcher raisesException) inMethods:aCollectionOfMethods |
|
4647 |
||
4648 |
"Created: / 11-05-2010 / 16:20:36 / cg" |
|
4649 |
! |
|
4650 |
||
8129 | 4651 |
findHelpSpecMethodsWithString:aString in:aCollectionOfClasses ignoreCase:ignoreCase |
3314 | 4652 |
"return a collection of all help-spec methods in aCollectionOfClasses |
4653 |
containing a string in their source. |
|
4654 |
This may be slow, since source-code has to be scanned." |
|
8129 | 4655 |
|
4656 |
^ self |
|
4657 |
findSpecMethodsFor:#help |
|
4658 |
withString:aString |
|
4659 |
in:aCollectionOfClasses |
|
4660 |
ignoreCase:ignoreCase |
|
4661 |
! |
|
4662 |
||
4663 |
findHelpSpecMethodsWithString:aString in:aCollectionOfClasses ignoreCase:ignoreCase match:doMatch |
|
4664 |
"return a collection of all help-spec methods in aCollectionOfClasses |
|
4665 |
containing a string in their source. |
|
4666 |
This may be slow, since source-code has to be scanned." |
|
4667 |
||
4668 |
^ self |
|
4669 |
findSpecMethodsFor:#help |
|
4670 |
withString:aString |
|
4671 |
in:aCollectionOfClasses |
|
4672 |
ignoreCase:ignoreCase |
|
4673 |
match:doMatch |
|
3314 | 4674 |
! |
4675 |
||
4152
92e3975f1904
allow for non-matching search (searching for impl. of '*')
Claus Gittinger <cg@exept.de>
parents:
4150
diff
changeset
|
4676 |
findImplementors:aSelectorMatchString in:aCollectionOfClasses ignoreCase:ignoreCase match:doMatch |
3675 | 4677 |
"search for all implementors of aSelector in |
16586 | 4678 |
the classes contained in aCollectionOfClasses and their metaclasses. |
3675 | 4679 |
Return a collection of methods" |
4680 |
||
16597 | 4681 |
|lcSelector list compare testST testJava srchBlockST srchBlockJava collectionOfClasses| |
3675 | 4682 |
|
4683 |
list := IdentitySet new. |
|
6051 | 4684 |
aSelectorMatchString size == 0 ifTrue:[ ^ list ]. |
4685 |
||
16395 | 4686 |
(doMatch and:[aSelectorMatchString includesMatchCharacters]) ifTrue:[ |
4152
92e3975f1904
allow for non-matching search (searching for impl. of '*')
Claus Gittinger <cg@exept.de>
parents:
4150
diff
changeset
|
4687 |
compare := [:sel :search | sel match:search]. |
92e3975f1904
allow for non-matching search (searching for impl. of '*')
Claus Gittinger <cg@exept.de>
parents:
4150
diff
changeset
|
4688 |
] ifFalse:[ |
92e3975f1904
allow for non-matching search (searching for impl. of '*')
Claus Gittinger <cg@exept.de>
parents:
4150
diff
changeset
|
4689 |
compare := [:sel :search | sel = search]. |
92e3975f1904
allow for non-matching search (searching for impl. of '*')
Claus Gittinger <cg@exept.de>
parents:
4150
diff
changeset
|
4690 |
]. |
92e3975f1904
allow for non-matching search (searching for impl. of '*')
Claus Gittinger <cg@exept.de>
parents:
4150
diff
changeset
|
4691 |
|
3675 | 4692 |
ignoreCase == true ifTrue:[ |
4693 |
lcSelector := aSelectorMatchString asLowercase. |
|
4694 |
||
15075 | 4695 |
testST := [:mthdSelector :aMethod | (compare value:lcSelector value:mthdSelector asLowercase) ]. |
4696 |
testJava := [:mthdSelector :aMethod | (compare value:lcSelector value:aMethod name asLowercase) ]. |
|
3675 | 4697 |
] ifFalse:[ |
15075 | 4698 |
testST := [:mthdSelector :aMethod | (compare value:aSelectorMatchString value:mthdSelector) ]. |
4699 |
testJava := [:mthdSelector :aMethod | (compare value:aSelectorMatchString value:aMethod name) ]. |
|
3675 | 4700 |
]. |
4701 |
||
15075 | 4702 |
srchBlockST := [:mthdSelector :mthd | (testST value:mthdSelector value:mthd) ifTrue:[ list add:mthd]]. |
4703 |
srchBlockJava := [:mthdSelector :mthd | (testJava value:mthdSelector value:mthd) ifTrue:[ list add:mthd]]. |
|
11452 | 4704 |
|
16597 | 4705 |
(collectionOfClasses := aCollectionOfClasses) isNil ifTrue:[ |
4706 |
collectionOfClasses := Smalltalk allClasses |
|
4707 |
]. |
|
4708 |
collectionOfClasses do:[:aClass | |
|
11452 | 4709 |
|srchBlock| |
3675 | 4710 |
|
4711 |
aClass isObsolete ifFalse:[ |
|
11452 | 4712 |
srchBlock := aClass isJavaClass |
4713 |
ifTrue:[ srchBlockJava ] |
|
4714 |
ifFalse:[ srchBlockST ]. |
|
4715 |
||
3675 | 4716 |
aClass methodDictionary keysAndValuesDo:srchBlock. |
4717 |
aClass isMeta ifFalse:[ |
|
4718 |
aClass class methodDictionary keysAndValuesDo:srchBlock |
|
4719 |
] |
|
4720 |
] |
|
4721 |
]. |
|
4722 |
||
4723 |
^ list |
|
4724 |
||
4725 |
" |
|
11452 | 4726 |
SystemBrowser |
4727 |
findImplementorsOf:#+ |
|
4728 |
in: { Number . Float . SmallInteger } |
|
4729 |
ignoreCase: false |
|
16395 | 4730 |
|
4731 |
Time millisecondsToRun:[ |
|
4732 |
SystemBrowser |
|
4733 |
findImplementorsOf:#add: |
|
4734 |
in: (Smalltalk allClasses) |
|
4735 |
ignoreCase: false |
|
4736 |
] |
|
11452 | 4737 |
" |
4738 |
||
4739 |
"Modified (format): / 22-03-2012 / 07:28:50 / cg" |
|
3675 | 4740 |
! |
4741 |
||
6776
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
4742 |
findImplementors:aSelectorMatchString inMethods:aCollectionOfMethods ignoreCase:ignoreCase match:doMatch |
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
4743 |
"search for all implementors of aSelector in |
16395 | 4744 |
the classes contained in aCollectionOfClasses and their metaclasses. |
6776
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
4745 |
Return a collection of methods" |
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
4746 |
|
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
4747 |
|list compare testST testJava lcSelector| |
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
4748 |
|
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
4749 |
list := IdentitySet new. |
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
4750 |
aSelectorMatchString size == 0 ifTrue:[ ^ list ]. |
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
4751 |
|
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
4752 |
doMatch ifTrue:[ |
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
4753 |
compare := [:sel :search | sel match:search]. |
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
4754 |
] ifFalse:[ |
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
4755 |
compare := [:sel :search | sel = search]. |
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
4756 |
]. |
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
4757 |
|
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
4758 |
ignoreCase == true ifTrue:[ |
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
4759 |
lcSelector := aSelectorMatchString asLowercase. |
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
4760 |
|
15075 | 4761 |
testST := [:mthdSelector :aMethod | (compare value:lcSelector value:mthdSelector asLowercase) ]. |
4762 |
testJava := [:mthdSelector :aMethod | (compare value:lcSelector value:aMethod name asLowercase) ]. |
|
6776
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
4763 |
] ifFalse:[ |
15075 | 4764 |
testST := [:mthdSelector :aMethod | (compare value:aSelectorMatchString value:mthdSelector) ]. |
4765 |
testJava := [:mthdSelector :aMethod | (compare value:aSelectorMatchString value:aMethod name) ]. |
|
6776
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
4766 |
]. |
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
4767 |
|
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
4768 |
aCollectionOfMethods do:[:eachMethod | |
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
4769 |
|cls sel testBlock| |
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
4770 |
|
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
4771 |
cls := eachMethod mclass. |
7066 | 4772 |
(cls isNil or:[cls isObsolete]) ifFalse:[ |
6776
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
4773 |
cls isJavaClass ifTrue:[ |
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
4774 |
testBlock := testJava |
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
4775 |
] ifFalse:[ |
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
4776 |
testBlock := testST |
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
4777 |
]. |
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
4778 |
sel := eachMethod selector. |
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
4779 |
(testBlock value:sel value:eachMethod) ifTrue:[ |
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
4780 |
list add:eachMethod |
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
4781 |
]. |
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
4782 |
] |
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
4783 |
]. |
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
4784 |
|
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
4785 |
^ list |
7066 | 4786 |
|
4787 |
"Modified: / 29-08-2006 / 14:33:42 / cg" |
|
6776
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
4788 |
! |
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
4789 |
|
4152
92e3975f1904
allow for non-matching search (searching for impl. of '*')
Claus Gittinger <cg@exept.de>
parents:
4150
diff
changeset
|
4790 |
findImplementorsMatching:aSelectorMatchString in:aCollectionOfClasses ignoreCase:ignoreCase |
92e3975f1904
allow for non-matching search (searching for impl. of '*')
Claus Gittinger <cg@exept.de>
parents:
4150
diff
changeset
|
4791 |
"search for all implementors of aSelector in |
16586 | 4792 |
the classes contained in aCollectionOfClasses and their metaclasses. |
4152
92e3975f1904
allow for non-matching search (searching for impl. of '*')
Claus Gittinger <cg@exept.de>
parents:
4150
diff
changeset
|
4793 |
Return a collection of methods" |
92e3975f1904
allow for non-matching search (searching for impl. of '*')
Claus Gittinger <cg@exept.de>
parents:
4150
diff
changeset
|
4794 |
|
11452 | 4795 |
^ self |
4796 |
findImplementors:aSelectorMatchString |
|
4797 |
in:aCollectionOfClasses |
|
4798 |
ignoreCase:ignoreCase |
|
4799 |
match:true |
|
4800 |
||
4801 |
" |
|
4802 |
SystemBrowser |
|
4803 |
findImplementorsOf:#+ |
|
4804 |
in:{ Number . Float . SmallInteger } |
|
16443 | 4805 |
ignoreCase:false |
11452 | 4806 |
" |
4807 |
||
4808 |
"Modified (comment): / 22-03-2012 / 07:20:42 / cg" |
|
4152
92e3975f1904
allow for non-matching search (searching for impl. of '*')
Claus Gittinger <cg@exept.de>
parents:
4150
diff
changeset
|
4809 |
! |
92e3975f1904
allow for non-matching search (searching for impl. of '*')
Claus Gittinger <cg@exept.de>
parents:
4150
diff
changeset
|
4810 |
|
3675 | 4811 |
findImplementorsMatchingAny:aCollectionOfSelectors in:aCollectionOfClasses ignoreCase:ignoreCase |
4812 |
"search for all implementors of any in aCollectionOfSelectors in |
|
16586 | 4813 |
the classes contained in aCollectionOfClasses and their metaclasses. |
3675 | 4814 |
Return a collection of methods. |
4815 |
CAVEAT: searches multiple times (could be tuned alot if heavily used)" |
|
4816 |
||
6052 | 4817 |
^ aCollectionOfSelectors |
4818 |
collectAll:[:eachSelector | |
|
4819 |
self findImplementorsMatching:eachSelector |
|
4820 |
in:aCollectionOfClasses |
|
4821 |
ignoreCase:ignoreCase. |
|
4822 |
]. |
|
4823 |
||
4824 |
"/ |implementors| |
|
4825 |
"/ |
|
6051 | 4826 |
"/ implementors := IdentitySet new. |
4827 |
"/ aCollectionOfSelectors do:[:eachSelector | |
|
4828 |
"/ implementors addAll:(self findImplementorsMatching:eachSelector in:aCollectionOfClasses ignoreCase:ignoreCase). |
|
4829 |
"/ ]. |
|
6052 | 4830 |
"/ ^ implementors |
6051 | 4831 |
|
4832 |
" |
|
4833 |
self |
|
4834 |
findImplementorsMatchingAny:#( 'at*:' '*size') |
|
4835 |
in:(Smalltalk allClasses) |
|
4836 |
ignoreCase:true |
|
4837 |
" |
|
3675 | 4838 |
! |
4839 |
||
4152
92e3975f1904
allow for non-matching search (searching for impl. of '*')
Claus Gittinger <cg@exept.de>
parents:
4150
diff
changeset
|
4840 |
findImplementorsOf:aSelectorMatchString in:aCollectionOfClasses ignoreCase:ignoreCase |
2642 | 4841 |
"search for all implementors of aSelector in |
16586 | 4842 |
the classes contained in aCollectionOfClasses and their metaclasses. |
2642 | 4843 |
Return a collection of methods" |
4844 |
||
6480 | 4845 |
^ self |
4846 |
findImplementors:aSelectorMatchString |
|
4847 |
in:aCollectionOfClasses |
|
4848 |
ignoreCase:ignoreCase |
|
4849 |
match:false |
|
2642 | 4850 |
|
4851 |
" |
|
4852 |
SystemBrowser findImplementorsOf:#+ |
|
4152
92e3975f1904
allow for non-matching search (searching for impl. of '*')
Claus Gittinger <cg@exept.de>
parents:
4150
diff
changeset
|
4853 |
in:(Array with:Number |
92e3975f1904
allow for non-matching search (searching for impl. of '*')
Claus Gittinger <cg@exept.de>
parents:
4150
diff
changeset
|
4854 |
with:Float |
92e3975f1904
allow for non-matching search (searching for impl. of '*')
Claus Gittinger <cg@exept.de>
parents:
4150
diff
changeset
|
4855 |
with:SmallInteger) |
2642 | 4856 |
" |
4857 |
! |
|
4858 |
||
2811 | 4859 |
findImplementorsOfAny:aCollectionOfSelectors in:aCollectionOfClasses ignoreCase:ignoreCase |
4860 |
"search for all implementors of any in aCollectionOfSelectors in |
|
16586 | 4861 |
the classes contained in aCollectionOfClasses and their metaclasses. |
2811 | 4862 |
Return a collection of methods. |
4863 |
CAVEAT: searches multiple times (could be tuned alot if heavily used)" |
|
4864 |
||
6052 | 4865 |
^ aCollectionOfSelectors |
4866 |
collectAll:[:eachSelector | |
|
4867 |
self findImplementorsOf:eachSelector |
|
4868 |
in:aCollectionOfClasses |
|
4869 |
ignoreCase:ignoreCase. |
|
4870 |
]. |
|
4871 |
||
4872 |
"/ |implementors| |
|
4873 |
"/ |
|
4874 |
"/ implementors := IdentitySet new. |
|
4875 |
"/ aCollectionOfSelectors do:[:eachSelector | |
|
4876 |
"/ implementors addAll:(self findImplementorsOf:eachSelector in:aCollectionOfClasses ignoreCase:ignoreCase). |
|
4877 |
"/ ]. |
|
4878 |
"/ ^ implementors |
|
2811 | 4879 |
! |
4880 |
||
2741 | 4881 |
findInstRefsTo:aString in:aCollectionOfClasses access:accessType |
4882 |
"return all methods in aCollectionOfClasses where the instVar named |
|
4883 |
aString is referenced; |
|
4884 |
if modsOnly is true, browse only methods where the classvar is modified" |
|
4885 |
||
4886 |
^ self findRefsTo:aString classVars:false in:aCollectionOfClasses access:accessType |
|
4887 |
! |
|
4888 |
||
2677 | 4889 |
findInstRefsTo:aString in:aCollectionOfClasses modificationsOnly:modsOnly |
2728 | 4890 |
"return all methods in aCollectionOfClasses where the instVar named |
2677 | 4891 |
aString is referenced; if modsOnly is true, browse only methods where the |
4892 |
instvar is modified" |
|
4893 |
||
4894 |
^ self findRefsTo:aString classVars:false in:aCollectionOfClasses modificationsOnly:modsOnly |
|
4895 |
! |
|
4896 |
||
2736
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4897 |
findInstRefsTo:aString inClass:aClass access:accessType |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4898 |
"return all methods in aClass where the instVar named |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4899 |
aString is referenced; if modsOnly is true, browse only methods where the |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4900 |
instvar is modified" |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4901 |
|
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4902 |
^ self findRefsTo:aString classVars:false in:(Array with:aClass) access:accessType |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4903 |
! |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4904 |
|
2728 | 4905 |
findInstRefsTo:aString inClass:aClass modificationsOnly:modsOnly |
4906 |
"return all methods in aClass where the instVar named |
|
4907 |
aString is referenced; if modsOnly is true, browse only methods where the |
|
4908 |
instvar is modified" |
|
4909 |
||
4910 |
^ self findRefsTo:aString classVars:false in:(Array with:aClass) modificationsOnly:modsOnly |
|
4911 |
! |
|
4912 |
||
2741 | 4913 |
findInstRefsTo:aString under:aClass access:accessType |
4914 |
"return all methods in aClass and subclasses |
|
18705 | 4915 |
where the instVar named aString is referenced; |
2741 | 4916 |
if modsOnly is true, browse only methods where the classvar is modified" |
4917 |
||
18705 | 4918 |
^ self |
4919 |
findInstRefsTo:aString |
|
4920 |
in:(aClass withAllSubclasses) |
|
4921 |
access:accessType |
|
4922 |
||
4923 |
"Modified (comment): / 20-03-2019 / 17:11:47 / Claus Gittinger" |
|
2741 | 4924 |
! |
4925 |
||
2677 | 4926 |
findInstRefsTo:aString under:aClass modificationsOnly:modsOnly |
4927 |
"return all methods in aClass and subclasses |
|
4928 |
where the instVar named aString is referenced; |
|
4929 |
if modsOnly is true, browse only methods where the instvar is modified" |
|
4930 |
||
4931 |
^ self findInstRefsTo:aString in:(aClass withAllSubclasses) modificationsOnly:modsOnly |
|
4932 |
! |
|
4933 |
||
8129 | 4934 |
findMenuSpecMethodsWithString:aString in:aCollectionOfClasses ignoreCase:ignoreCase |
3314 | 4935 |
"return a collection of all menu-spec methods in aCollectionOfClasses |
4936 |
containing a string in their source. |
|
4937 |
This may be slow, since source-code has to be scanned." |
|
8129 | 4938 |
|
4939 |
^ self |
|
4940 |
findSpecMethodsFor:#menu |
|
4941 |
withString:aString |
|
4942 |
in:aCollectionOfClasses |
|
4943 |
ignoreCase:ignoreCase |
|
4944 |
! |
|
4945 |
||
4946 |
findMenuSpecMethodsWithString:aString in:aCollectionOfClasses ignoreCase:ignoreCase match:doMatch |
|
4947 |
"return a collection of all menu-spec methods in aCollectionOfClasses |
|
4948 |
containing a string in their source. |
|
4949 |
This may be slow, since source-code has to be scanned." |
|
4950 |
||
4951 |
^ self |
|
4952 |
findSpecMethodsFor:#menu |
|
4953 |
withString:aString |
|
4954 |
in:aCollectionOfClasses |
|
4955 |
ignoreCase:ignoreCase |
|
4956 |
match:doMatch |
|
3314 | 4957 |
! |
4958 |
||
11934 | 4959 |
findPoolVarRefsTo:aString inClass:aClass access:accessType |
4960 |
"return all methods in aClass where the pool variable named aString is referenced; |
|
4961 |
if modsOnly is true, browse only methods where the classvar is modified" |
|
4962 |
||
4963 |
|filter| |
|
4964 |
||
4965 |
filter := self |
|
4966 |
filterToSearchRefsTo:aString |
|
4967 |
instVars:false classVars:false globals:false poolVars:true |
|
4968 |
access:accessType. |
|
4969 |
||
4970 |
^ self findMethodsIn:(Array with:aClass) inst:true class:true where:filter. |
|
4971 |
! |
|
4972 |
||
2736
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4973 |
findRefsTo:varName classVars:classVars in:aCollectionOfClasses access:accessType |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4974 |
"return a list of all methods in aCollectionOfClasses where the instVar/classVar named |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4975 |
varName is referenced; |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4976 |
if modsOnly is true, browse only methods where the instvar is modified" |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4977 |
|
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4978 |
|filter| |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4979 |
|
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4980 |
filter := self filterToSearchRefsTo:varName classVars:classVars access:accessType. |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4981 |
^ self findMethodsIn:aCollectionOfClasses inst:true class:classVars where:filter. |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4982 |
|
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4983 |
" |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4984 |
self |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4985 |
findRefsTo:'x' |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4986 |
classVars:false |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4987 |
in:(Array with:Point) |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4988 |
modificationsOnly:true |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4989 |
" |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4990 |
! |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4991 |
|
2677 | 4992 |
findRefsTo:varName classVars:classVars in:aCollectionOfClasses modificationsOnly:modsOnly |
4993 |
"return a list of all methods in aCollectionOfClasses where the instVar/classVar named |
|
4994 |
varName is referenced; |
|
4995 |
if modsOnly is true, browse only methods where the instvar is modified" |
|
4996 |
||
4997 |
|filter| |
|
4998 |
||
4999 |
filter := self filterToSearchRefsTo:varName classVars:classVars modificationsOnly:modsOnly. |
|
5000 |
^ self findMethodsIn:aCollectionOfClasses inst:true class:classVars where:filter. |
|
5001 |
||
5002 |
" |
|
5003 |
self |
|
5004 |
findRefsTo:'x' |
|
5005 |
classVars:false |
|
5006 |
in:(Array with:Point) |
|
5007 |
modificationsOnly:true |
|
5008 |
" |
|
5009 |
! |
|
5010 |
||
2692 | 5011 |
findResource:aResourceSymbolOrCollectionOfSymbols in:aCollectionOfClasses |
5012 |
"return a collection of all methods in aCollectionOfClasses |
|
5013 |
containing a resource." |
|
5014 |
||
5015 |
|searchBlock| |
|
5016 |
||
5017 |
aResourceSymbolOrCollectionOfSymbols isSymbol ifTrue:[ |
|
5018 |
searchBlock := [:c :m :sel | |resources| |
|
5019 |
(resources := m resources) size > 0 |
|
5020 |
and:[resources includesKey:aResourceSymbolOrCollectionOfSymbols] |
|
5021 |
]. |
|
5022 |
] ifFalse:[ |
|
5023 |
searchBlock := [:c :m :sel | |resources| |
|
5024 |
(resources := m resources) size > 0 |
|
5025 |
and:[resources keys includesAny:aResourceSymbolOrCollectionOfSymbols] |
|
5026 |
]. |
|
5027 |
]. |
|
5028 |
||
5029 |
^ self findMethodsIn:aCollectionOfClasses where:searchBlock. |
|
5030 |
||
5031 |
" |
|
5032 |
SystemBrowser findResource:#image in:(ApplicationModel withAllSubclasses) |
|
5033 |
SystemBrowser findResource:#menu in:(ApplicationModel withAllSubclasses) |
|
5034 |
SystemBrowser findResource:#(menu programMenu) in:(ApplicationModel withAllSubclasses) |
|
5035 |
" |
|
5036 |
! |
|
5037 |
||
10188
95e82ec734ff
added: #findResource:match:ignoreCase:in:
Claus Gittinger <cg@exept.de>
parents:
10173
diff
changeset
|
5038 |
findResource:aStringOrEmpty match:doMatch ignoreCase:ignoreCase in:aCollectionOfClasses |
95e82ec734ff
added: #findResource:match:ignoreCase:in:
Claus Gittinger <cg@exept.de>
parents:
10173
diff
changeset
|
5039 |
"return a collection of all methods in aCollectionOfClasses containing a matching resource." |
95e82ec734ff
added: #findResource:match:ignoreCase:in:
Claus Gittinger <cg@exept.de>
parents:
10173
diff
changeset
|
5040 |
|
95e82ec734ff
added: #findResource:match:ignoreCase:in:
Claus Gittinger <cg@exept.de>
parents:
10173
diff
changeset
|
5041 |
|matchCheck lcSearchString| |
95e82ec734ff
added: #findResource:match:ignoreCase:in:
Claus Gittinger <cg@exept.de>
parents:
10173
diff
changeset
|
5042 |
|
95e82ec734ff
added: #findResource:match:ignoreCase:in:
Claus Gittinger <cg@exept.de>
parents:
10173
diff
changeset
|
5043 |
aStringOrEmpty isEmptyOrNil ifTrue:[ |
95e82ec734ff
added: #findResource:match:ignoreCase:in:
Claus Gittinger <cg@exept.de>
parents:
10173
diff
changeset
|
5044 |
matchCheck := [:aResourceName | true ] |
95e82ec734ff
added: #findResource:match:ignoreCase:in:
Claus Gittinger <cg@exept.de>
parents:
10173
diff
changeset
|
5045 |
] ifFalse:[ |
95e82ec734ff
added: #findResource:match:ignoreCase:in:
Claus Gittinger <cg@exept.de>
parents:
10173
diff
changeset
|
5046 |
doMatch ifTrue:[ |
13438 | 5047 |
matchCheck := [:aResourceName | aStringOrEmpty match:aResourceName caseSensitive:ignoreCase not] |
10188
95e82ec734ff
added: #findResource:match:ignoreCase:in:
Claus Gittinger <cg@exept.de>
parents:
10173
diff
changeset
|
5048 |
] ifFalse:[ |
95e82ec734ff
added: #findResource:match:ignoreCase:in:
Claus Gittinger <cg@exept.de>
parents:
10173
diff
changeset
|
5049 |
ignoreCase ifTrue:[ |
95e82ec734ff
added: #findResource:match:ignoreCase:in:
Claus Gittinger <cg@exept.de>
parents:
10173
diff
changeset
|
5050 |
lcSearchString := aStringOrEmpty asLowercase. |
95e82ec734ff
added: #findResource:match:ignoreCase:in:
Claus Gittinger <cg@exept.de>
parents:
10173
diff
changeset
|
5051 |
matchCheck := [:aResourceName | aResourceName asLowercase = lcSearchString] |
95e82ec734ff
added: #findResource:match:ignoreCase:in:
Claus Gittinger <cg@exept.de>
parents:
10173
diff
changeset
|
5052 |
] ifFalse:[ |
95e82ec734ff
added: #findResource:match:ignoreCase:in:
Claus Gittinger <cg@exept.de>
parents:
10173
diff
changeset
|
5053 |
matchCheck := [:aResourceName | aResourceName = aStringOrEmpty ] |
95e82ec734ff
added: #findResource:match:ignoreCase:in:
Claus Gittinger <cg@exept.de>
parents:
10173
diff
changeset
|
5054 |
] |
95e82ec734ff
added: #findResource:match:ignoreCase:in:
Claus Gittinger <cg@exept.de>
parents:
10173
diff
changeset
|
5055 |
]. |
95e82ec734ff
added: #findResource:match:ignoreCase:in:
Claus Gittinger <cg@exept.de>
parents:
10173
diff
changeset
|
5056 |
]. |
95e82ec734ff
added: #findResource:match:ignoreCase:in:
Claus Gittinger <cg@exept.de>
parents:
10173
diff
changeset
|
5057 |
|
95e82ec734ff
added: #findResource:match:ignoreCase:in:
Claus Gittinger <cg@exept.de>
parents:
10173
diff
changeset
|
5058 |
^ self |
95e82ec734ff
added: #findResource:match:ignoreCase:in:
Claus Gittinger <cg@exept.de>
parents:
10173
diff
changeset
|
5059 |
findMethodsIn:aCollectionOfClasses |
95e82ec734ff
added: #findResource:match:ignoreCase:in:
Claus Gittinger <cg@exept.de>
parents:
10173
diff
changeset
|
5060 |
where:[:c :m :sel | |
95e82ec734ff
added: #findResource:match:ignoreCase:in:
Claus Gittinger <cg@exept.de>
parents:
10173
diff
changeset
|
5061 |
m hasResource |
12073 | 5062 |
and:[m resources notNil and:[m resources keys contains:matchCheck]] |
10188
95e82ec734ff
added: #findResource:match:ignoreCase:in:
Claus Gittinger <cg@exept.de>
parents:
10173
diff
changeset
|
5063 |
]. |
95e82ec734ff
added: #findResource:match:ignoreCase:in:
Claus Gittinger <cg@exept.de>
parents:
10173
diff
changeset
|
5064 |
|
95e82ec734ff
added: #findResource:match:ignoreCase:in:
Claus Gittinger <cg@exept.de>
parents:
10173
diff
changeset
|
5065 |
" |
95e82ec734ff
added: #findResource:match:ignoreCase:in:
Claus Gittinger <cg@exept.de>
parents:
10173
diff
changeset
|
5066 |
SystemBrowser findResource:'*debug*' match:true ignoreCase:true in:(GenericException withAllSubclasses) |
95e82ec734ff
added: #findResource:match:ignoreCase:in:
Claus Gittinger <cg@exept.de>
parents:
10173
diff
changeset
|
5067 |
" |
95e82ec734ff
added: #findResource:match:ignoreCase:in:
Claus Gittinger <cg@exept.de>
parents:
10173
diff
changeset
|
5068 |
|
95e82ec734ff
added: #findResource:match:ignoreCase:in:
Claus Gittinger <cg@exept.de>
parents:
10173
diff
changeset
|
5069 |
"Created: / 06-07-2011 / 12:14:24 / cg" |
95e82ec734ff
added: #findResource:match:ignoreCase:in:
Claus Gittinger <cg@exept.de>
parents:
10173
diff
changeset
|
5070 |
! |
95e82ec734ff
added: #findResource:match:ignoreCase:in:
Claus Gittinger <cg@exept.de>
parents:
10173
diff
changeset
|
5071 |
|
16586 | 5072 |
findRespondersOfAll:aCollectionOfSelectors in:aCollectionOfClasses ignoreCase:ignoreCase |
5073 |
"search for all classes which respond to all of the selectors in aCollectionOfSelectors. |
|
5074 |
Search within the classes contained in aCollectionOfClasses and their metaclasses. |
|
5075 |
This will skip over unloaded classes. |
|
5076 |
Return a collection of classes." |
|
5077 |
||
5078 |
^ Smalltalk allClasses |
|
5079 |
select:[:cls | |
|
5080 |
cls isLoaded |
|
5081 |
and:[ aCollectionOfSelectors conform:[:sel | cls canUnderstand:sel]]]. |
|
5082 |
||
5083 |
" |
|
5084 |
to find classes which respond to both indexOf: and replaceFromIndex:toIndex:, |
|
5085 |
use: |
|
5086 |
SystemBrowser |
|
5087 |
findRespondersOfAll:#( indexOf: removeFromIndex:toIndex: ) |
|
5088 |
in:nil |
|
5089 |
ignoreCase:false |
|
5090 |
" |
|
5091 |
! |
|
5092 |
||
2642 | 5093 |
findSendersOf:aSelectorString in:aCollectionOfClasses ignoreCase:ignoreCase |
5094 |
"search for all senders of aSelector in |
|
16586 | 5095 |
the classes contained in aCollectionOfClasses and their metaclasses. |
2642 | 5096 |
Return a collection of methods" |
5097 |
||
4270 | 5098 |
^ self allCallsOn:aSelectorString in:aCollectionOfClasses ignoreCase:ignoreCase match:true |
2642 | 5099 |
|
5100 |
" |
|
5101 |
SystemBrowser findSendersOf:#+ |
|
5102 |
in:(Array with:Number |
|
5103 |
with:Float |
|
5104 |
with:SmallInteger) |
|
5105 |
ignoreCase:false |
|
5106 |
" |
|
4270 | 5107 |
! |
5108 |
||
5109 |
findSendersOf:aSelectorString in:aCollectionOfClasses ignoreCase:ignoreCase match:doMatch |
|
5110 |
"search for all senders of aSelector in |
|
16586 | 5111 |
the classes contained in aCollectionOfClasses and their metaclasses. |
4270 | 5112 |
Return a collection of methods" |
5113 |
||
5114 |
^ self allCallsOn:aSelectorString in:aCollectionOfClasses ignoreCase:ignoreCase match:doMatch |
|
5115 |
||
5116 |
" |
|
5117 |
SystemBrowser findSendersOf:#+ |
|
5118 |
in:(Array with:Number |
|
5119 |
with:Float |
|
5120 |
with:SmallInteger) |
|
5121 |
ignoreCase:false |
|
5122 |
" |
|
2675 | 5123 |
! |
5124 |
||
4235
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
5125 |
findSendersOf:aSelectorString inMethods:aCollectionOfMethods ignoreCase:ignoreCase |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
5126 |
"search for all senders of aSelector in aCollectionOfMethods. |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
5127 |
Return a collection of methods" |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
5128 |
|
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
5129 |
|searchBlock| |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
5130 |
|
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
5131 |
searchBlock := self searchBlockForAllCallsOn:aSelectorString ignoreCase:ignoreCase. |
9313
44795fcbf414
changed: #findSendersOf:inMethods:ignoreCase:
Claus Gittinger <cg@exept.de>
parents:
9312
diff
changeset
|
5132 |
searchBlock isNil ifTrue:[^ #() ]. |
4235
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
5133 |
^ aCollectionOfMethods select:[:m | searchBlock value:m mclass value:m value:m selector]. |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
5134 |
! |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
5135 |
|
4350 | 5136 |
findSendersOf:aSelectorString inMethods:aCollectionOfMethods ignoreCase:ignoreCase match:doMatch |
5137 |
"search for all senders of aSelector in aCollectionOfMethods. |
|
5138 |
Return a collection of methods" |
|
5139 |
||
5140 |
|searchBlock| |
|
5141 |
||
5142 |
searchBlock := self searchBlockForAllCallsOn:aSelectorString ignoreCase:ignoreCase match:doMatch. |
|
9312
71f84182390a
changed: #findSendersOf:inMethods:ignoreCase:match:
Claus Gittinger <cg@exept.de>
parents:
9189
diff
changeset
|
5143 |
searchBlock isNil ifTrue:[^ #() ]. |
4350 | 5144 |
^ aCollectionOfMethods select:[:m | searchBlock value:m mclass value:m value:m selector]. |
5145 |
! |
|
5146 |
||
17624 | 5147 |
findSendersOfAll:aCollectionOfSelectors in:aCollectionOfClasses ignoreCase:ignoreCase |
5148 |
"search for methods which send all selectors in aCollectionOfSelectors in |
|
5149 |
the classes contained in aCollectionOfClasses and their metaclasses. |
|
5150 |
Return a collection of methods." |
|
5151 |
||
5152 |
^ (self allCallsOn:(aCollectionOfSelectors first) |
|
5153 |
in:aCollectionOfClasses |
|
5154 |
ignoreCase:ignoreCase |
|
5155 |
match:false |
|
5156 |
) select:[:mthd | |
|
5157 |
mthd messagesSent includesAll:aCollectionOfSelectors |
|
5158 |
]. |
|
5159 |
||
5160 |
" |
|
5161 |
SystemBrowser |
|
5162 |
findSendersOfAll:#(#'+' #'-') |
|
5163 |
in:(Smalltalk allClasses) |
|
5164 |
ignoreCase:false |
|
5165 |
" |
|
5166 |
||
5167 |
"Created: / 24-08-2017 / 13:10:25 / cg" |
|
5168 |
! |
|
5169 |
||
2811 | 5170 |
findSendersOfAny:aCollectionOfSelectors in:aCollectionOfClasses ignoreCase:ignoreCase |
5171 |
"search for all senders of any selector in aCollectionOfSelectors in |
|
16586 | 5172 |
the classes contained in aCollectionOfClasses and their metaclasses. |
2811 | 5173 |
Return a collection of methods. |
19235 | 5174 |
CAVEAT: searches multiple times (could be tuned a lot if heavily used)" |
5175 |
||
5176 |
|setOfSenders| |
|
5177 |
||
5178 |
setOfSenders := Set new. |
|
5179 |
aCollectionOfSelectors do:[:eachSelector | |
|
5180 |
setOfSenders addAll:( |
|
5181 |
self allCallsOn:eachSelector in:aCollectionOfClasses |
|
5182 |
ignoreCase:ignoreCase match:false). |
|
5183 |
]. |
|
5184 |
^ setOfSenders |
|
6052 | 5185 |
|
5186 |
"/ |allSenders| |
|
5187 |
"/ |
|
5188 |
"/ allSenders := IdentitySet new. |
|
5189 |
"/ aCollectionOfSelectors do:[:eachSelector | |
|
5190 |
"/ allSenders addAll:(self allCallsOn:eachSelector in:aCollectionOfClasses ignoreCase:ignoreCase match:true) |
|
5191 |
"/ ]. |
|
5192 |
"/ ^ allSenders |
|
2811 | 5193 |
|
5194 |
" |
|
5195 |
SystemBrowser findSendersOfAny:#(#'+' #'-') |
|
5196 |
in:(Array with:Number |
|
5197 |
with:Float |
|
5198 |
with:SmallInteger) |
|
5199 |
ignoreCase:false |
|
5200 |
" |
|
5201 |
! |
|
5202 |
||
19026 | 5203 |
findSendersUsingReturnValueOf:aSelectorString in:aCollectionOfClasses ignoreCase:ignoreCase match:doMatch |
5204 |
"search for all senders of aSelector in |
|
5205 |
the classes contained in aCollectionOfClasses and their metaclasses. |
|
5206 |
Return a collection of methods" |
|
5207 |
||
5208 |
^ self allCallsUsingReturnValueOn:aSelectorString in:aCollectionOfClasses ignoreCase:ignoreCase match:doMatch |
|
5209 |
||
5210 |
" |
|
5211 |
SystemBrowser findSendersUsingReturnValueOf:#+ |
|
5212 |
in:(Array with:Number |
|
5213 |
with:Float |
|
5214 |
with:SmallInteger) |
|
5215 |
ignoreCase:false |
|
5216 |
" |
|
5217 |
! |
|
5218 |
||
3314 | 5219 |
findSpecMethodsFor:specSymbol withString:aString in:aCollectionOfClasses ignoreCase:ignoreCase |
5220 |
"return a collection of all specSymbol-spec methods in aCollectionOfClasses |
|
5221 |
containing a string in their source. |
|
5222 |
This may be slow, since source-code has to be scanned." |
|
5223 |
||
8129 | 5224 |
self |
5225 |
findSpecMethodsFor:specSymbol |
|
5226 |
withString:aString |
|
5227 |
in:aCollectionOfClasses |
|
18890 | 5228 |
ignoreCase:ignoreCase match:true |
8129 | 5229 |
! |
5230 |
||
5231 |
findSpecMethodsFor:specSymbol withString:aString in:aCollectionOfClasses ignoreCase:ignoreCase match:doMatch |
|
5232 |
"return a collection of all specSymbol-spec methods in aCollectionOfClasses |
|
5233 |
containing a string in their source. |
|
5234 |
This may be slow, since source-code has to be scanned." |
|
5235 |
||
5236 |
|searchBlock innerSearchBlock| |
|
5237 |
||
5238 |
innerSearchBlock := self searchBlockForString:aString ignoreCase:ignoreCase match:doMatch. |
|
5239 |
||
5240 |
searchBlock := [:c :m :sel | |
|
5241 |
|resources| |
|
3314 | 5242 |
|
5243 |
((resources := m resources) size > 0 |
|
18890 | 5244 |
and:[resources includesKey:specSymbol] |
5245 |
) ifTrue:[ |
|
8129 | 5246 |
innerSearchBlock value:c value:m value:sel |
3314 | 5247 |
] |
8129 | 5248 |
]. |
5249 |
||
3314 | 5250 |
^ self findMethodsIn:aCollectionOfClasses where:searchBlock. |
5251 |
! |
|
5252 |
||
8129 | 5253 |
findString:aString in:aCollectionOfClasses ignoreCase:ignoreCase |
5243 | 5254 |
"return a collection of all methods in aCollectionOfClasses |
2675 | 5255 |
containing a string in their source. |
5256 |
This may be slow, since source-code has to be scanned." |
|
8129 | 5257 |
|
5258 |
^ self |
|
5259 |
findString:aString |
|
5260 |
in:aCollectionOfClasses |
|
18890 | 5261 |
ignoreCase:ignoreCase match:true fullWordsOnly:false |
5262 |
resourceMethodsOnly:false |
|
8129 | 5263 |
|
5264 |
" |
|
5265 |
SystemBrowser findString:'should' in:(Array with:Object) ignoreCase:false |
|
4152
92e3975f1904
allow for non-matching search (searching for impl. of '*')
Claus Gittinger <cg@exept.de>
parents:
4150
diff
changeset
|
5266 |
" |
92e3975f1904
allow for non-matching search (searching for impl. of '*')
Claus Gittinger <cg@exept.de>
parents:
4150
diff
changeset
|
5267 |
! |
92e3975f1904
allow for non-matching search (searching for impl. of '*')
Claus Gittinger <cg@exept.de>
parents:
4150
diff
changeset
|
5268 |
|
92e3975f1904
allow for non-matching search (searching for impl. of '*')
Claus Gittinger <cg@exept.de>
parents:
4150
diff
changeset
|
5269 |
findString:aString in:aCollectionOfClasses ignoreCase:ignoreCase match:doMatch |
5243 | 5270 |
"return a collection of all methods in aCollectionOfClasses |
4152
92e3975f1904
allow for non-matching search (searching for impl. of '*')
Claus Gittinger <cg@exept.de>
parents:
4150
diff
changeset
|
5271 |
containing a string in their source. |
92e3975f1904
allow for non-matching search (searching for impl. of '*')
Claus Gittinger <cg@exept.de>
parents:
4150
diff
changeset
|
5272 |
This may be slow, since source-code has to be scanned." |
92e3975f1904
allow for non-matching search (searching for impl. of '*')
Claus Gittinger <cg@exept.de>
parents:
4150
diff
changeset
|
5273 |
|
18890 | 5274 |
^ self |
5275 |
findString:aString |
|
5276 |
in:aCollectionOfClasses |
|
5277 |
ignoreCase:ignoreCase match:doMatch fullWordsOnly:false |
|
5278 |
resourceMethodsOnly:false |
|
16691 | 5279 |
|
5280 |
" |
|
5281 |
SystemBrowser |
|
5282 |
findString:'should' |
|
5283 |
in:(Array with:Object) |
|
5284 |
ignoreCase:false |
|
5285 |
" |
|
5286 |
! |
|
5287 |
||
5288 |
findString:aString in:aCollectionOfClasses ignoreCase:ignoreCase match:doMatch fullWordsOnly:fullWordsOnly |
|
5289 |
"return a collection of all methods in aCollectionOfClasses |
|
5290 |
containing a string in their source. |
|
5291 |
This may be slow, since source-code has to be scanned." |
|
5292 |
||
18890 | 5293 |
^ self |
5294 |
findString:aString |
|
5295 |
in:aCollectionOfClasses |
|
5296 |
ignoreCase:ignoreCase match:doMatch fullWordsOnly:fullWordsOnly |
|
5297 |
resourceMethodsOnly:false |
|
5298 |
||
5299 |
" |
|
5300 |
SystemBrowser findString:'should' in:(Array with:Object) ignoreCase:false |
|
5301 |
" |
|
5302 |
! |
|
5303 |
||
5304 |
findString:aString in:aCollectionOfClasses ignoreCase:ignoreCase match:doMatch fullWordsOnly:fullWordsOnly resourceMethodsOnly:resourceMethodsOnly |
|
5305 |
"return a collection of all methods in aCollectionOfClasses |
|
5306 |
containing a string in their source. |
|
5307 |
This may be slow, since source-code has to be scanned." |
|
5308 |
||
4235
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
5309 |
|searchBlock| |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
5310 |
|
16691 | 5311 |
searchBlock := |
5312 |
self |
|
5313 |
searchBlockForString:aString |
|
18890 | 5314 |
ignoreCase:ignoreCase match:doMatch fullWordsOnly:fullWordsOnly |
5315 |
resourceMethodsOnly:resourceMethodsOnly. |
|
4235
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
5316 |
^ self findMethodsIn:aCollectionOfClasses where:searchBlock. |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
5317 |
|
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
5318 |
" |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
5319 |
SystemBrowser findString:'should' in:(Array with:Object) ignoreCase:false |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
5320 |
" |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
5321 |
! |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
5322 |
|
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
5323 |
findString:aString inMethods:aCollectionOfMethods ignoreCase:ignoreCase match:doMatch |
5243 | 5324 |
"return a collection of all methods in aCollectionOfClasses |
4235
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
5325 |
containing a string in their source. |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
5326 |
This may be slow, since source-code has to be scanned." |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
5327 |
|
18890 | 5328 |
^ self |
5329 |
findString:aString |
|
5330 |
inMethods:aCollectionOfMethods |
|
5331 |
ignoreCase:ignoreCase match:doMatch fullWordsOnly:false |
|
5332 |
resourceMethodsOnly:false |
|
16691 | 5333 |
! |
5334 |
||
5335 |
findString:aString inMethods:aCollectionOfMethods ignoreCase:ignoreCase match:doMatch fullWordsOnly:fullWordsOnly |
|
5336 |
"return a collection of all methods in aCollectionOfClasses |
|
5337 |
containing a string in their source. |
|
5338 |
This may be slow, since source-code has to be scanned." |
|
5339 |
||
18890 | 5340 |
^ self |
5341 |
findString:aString |
|
5342 |
inMethods:aCollectionOfMethods |
|
5343 |
ignoreCase:ignoreCase match:doMatch fullWordsOnly:fullWordsOnly |
|
5344 |
resourceMethodsOnly:false |
|
5345 |
! |
|
5346 |
||
5347 |
findString:aString inMethods:aCollectionOfMethods ignoreCase:ignoreCase match:doMatch fullWordsOnly:fullWordsOnly resourceMethodsOnly:resourceMethodsOnly |
|
5348 |
"return a collection of all methods in aCollectionOfClasses |
|
5349 |
containing a string in their source. |
|
5350 |
This may be slow, since source-code has to be scanned." |
|
5351 |
||
4235
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
5352 |
|searchBlock| |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
5353 |
|
18890 | 5354 |
searchBlock := self |
5355 |
searchBlockForString:aString |
|
5356 |
ignoreCase:ignoreCase match:doMatch fullWordsOnly:fullWordsOnly |
|
5357 |
resourceMethodsOnly:resourceMethodsOnly. |
|
4235
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
5358 |
^ aCollectionOfMethods select:[:m | searchBlock value:m mclass value:m value:m selector]. |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
5359 |
! |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
5360 |
|
18896 | 5361 |
findString:aString inMethods:aCollectionOfMethods ignoreCase:ignoreCase match:doMatch resourceMethodsOnly:resourceMethodsOnly |
5362 |
"return a collection of all methods in aCollectionOfClasses |
|
5363 |
containing a string in their source. |
|
5364 |
This may be slow, since source-code has to be scanned." |
|
5365 |
||
5366 |
^ self |
|
5367 |
findString:aString |
|
5368 |
inMethods:aCollectionOfMethods |
|
5369 |
ignoreCase:ignoreCase match:doMatch fullWordsOnly:false |
|
5370 |
resourceMethodsOnly:resourceMethodsOnly |
|
5371 |
! |
|
5372 |
||
5877 | 5373 |
findStringLiteral:aString in:aCollectionOfClasses ignoreCase:ignoreCase match:doMatch |
5374 |
"return a collection of all methods in aCollectionOfClasses |
|
5375 |
containing a string in any of their string-literals." |
|
5376 |
||
16691 | 5377 |
^ self |
18890 | 5378 |
findStringLiteral:aString |
5379 |
in:aCollectionOfClasses |
|
5380 |
ignoreCase:ignoreCase match:doMatch fullWordsOnly:false |
|
5381 |
resourceMethodsOnly:false |
|
16691 | 5382 |
|
5383 |
" |
|
5384 |
SystemBrowser findStringLiteral:'error' in:(Array with:Object) ignoreCase:true match:false |
|
5385 |
" |
|
5386 |
! |
|
5387 |
||
5388 |
findStringLiteral:aString in:aCollectionOfClasses ignoreCase:ignoreCase match:doMatch fullWordsOnly:fullWordsOnly |
|
5389 |
"return a collection of all methods in aCollectionOfClasses |
|
5390 |
containing a string in any of their string-literals." |
|
5391 |
||
18890 | 5392 |
^ self |
5393 |
findStringLiteral:aString |
|
5394 |
in:aCollectionOfClasses |
|
5395 |
ignoreCase:ignoreCase match:doMatch fullWordsOnly:fullWordsOnly |
|
5396 |
resourceMethodsOnly:false. |
|
5397 |
||
5398 |
" |
|
5399 |
SystemBrowser findStringLiteral:'error' in:(Array with:Object) ignoreCase:true match:false |
|
5400 |
" |
|
5401 |
! |
|
5402 |
||
5403 |
findStringLiteral:aString in:aCollectionOfClasses ignoreCase:ignoreCase match:doMatch fullWordsOnly:fullWordsOnly resourceMethodsOnly:resourceMethodsOnly |
|
5404 |
"return a collection of all methods in aCollectionOfClasses |
|
5405 |
containing a string in any of their string-literals." |
|
5406 |
||
5877 | 5407 |
|searchBlock| |
5408 |
||
18890 | 5409 |
searchBlock := self |
5410 |
searchBlockForStringLiteral:aString |
|
5411 |
ignoreCase:ignoreCase match:doMatch fullWordsOnly:fullWordsOnly |
|
5412 |
resourceMethodsOnly:resourceMethodsOnly. |
|
5877 | 5413 |
^ self findMethodsIn:aCollectionOfClasses where:searchBlock. |
5414 |
||
5415 |
" |
|
5416 |
SystemBrowser findStringLiteral:'error' in:(Array with:Object) ignoreCase:true match:false |
|
5417 |
" |
|
5418 |
! |
|
5419 |
||
5420 |
findStringLiteral:aString inMethods:aCollectionOfMethods ignoreCase:ignoreCase match:doMatch |
|
5421 |
"return a collection of all methods in aCollectionOfClasses |
|
5422 |
containing a string in any of their string-literals." |
|
5423 |
||
16691 | 5424 |
^ self |
5425 |
findStringLiteral:aString inMethods:aCollectionOfMethods |
|
5426 |
ignoreCase:ignoreCase match:doMatch fullWordsOnly:false |
|
18890 | 5427 |
resourceMethodsOnly:false |
16691 | 5428 |
! |
5429 |
||
5430 |
findStringLiteral:aString inMethods:aCollectionOfMethods ignoreCase:ignoreCase match:doMatch fullWordsOnly:fullWordsOnly |
|
5431 |
"return a collection of all methods in aCollectionOfClasses |
|
5432 |
containing a string in any of their string-literals." |
|
5433 |
||
18890 | 5434 |
^ self |
5435 |
findStringLiteral:aString inMethods:aCollectionOfMethods |
|
5436 |
ignoreCase:ignoreCase match:doMatch fullWordsOnly:fullWordsOnly |
|
5437 |
resourceMethodsOnly:false |
|
5438 |
! |
|
5439 |
||
5440 |
findStringLiteral:aString inMethods:aCollectionOfMethods ignoreCase:ignoreCase match:doMatch fullWordsOnly:fullWordsOnly resourceMethodsOnly:resourceMethodsOnly |
|
5441 |
"return a collection of all methods in aCollectionOfClasses |
|
5442 |
containing a string in any of their string-literals." |
|
5443 |
||
5877 | 5444 |
|searchBlock| |
5445 |
||
18890 | 5446 |
searchBlock := self |
5447 |
searchBlockForStringLiteral:aString |
|
5448 |
ignoreCase:ignoreCase |
|
5449 |
match:doMatch |
|
5450 |
fullWordsOnly:fullWordsOnly |
|
5451 |
resourceMethodsOnly:resourceMethodsOnly. |
|
5877 | 5452 |
^ aCollectionOfMethods select:[:m | searchBlock value:m mclass value:m value:m selector]. |
5453 |
! |
|
5454 |
||
9482 | 5455 |
findUsingParseTreeSearcher:searcher in:aCollectionOfClasses |
5456 |
"return a collection of all methods in aCollectionOfClasses |
|
5457 |
containing an exception raiser. |
|
5458 |
This may be slow, since source-code has to be scanned." |
|
5459 |
||
5460 |
|searchBlock| |
|
5461 |
||
5462 |
searchBlock := self searchBlockForParseTreeSearcher:searcher isMethod:false. |
|
5463 |
searchBlock isNil ifTrue:[ ^ nil]. |
|
5464 |
^ self findMethodsIn:aCollectionOfClasses where:searchBlock. |
|
5465 |
||
5466 |
"Created: / 11-05-2010 / 16:18:36 / cg" |
|
5467 |
! |
|
5468 |
||
5469 |
findUsingParseTreeSearcher:searcher inMethods:aCollectionOfMethods |
|
5470 |
"return a collection of all methods in aCollectionOfClasses |
|
5471 |
containing an exception raiser. |
|
5472 |
This may be slow, since source-code has to be scanned." |
|
5473 |
||
5474 |
|searchBlock| |
|
5475 |
||
5476 |
searchBlock := self searchBlockForParseTreeSearcher:searcher isMethod:false. |
|
5477 |
searchBlock isNil ifTrue:[ ^ nil]. |
|
5478 |
^ aCollectionOfMethods select:[:m | searchBlock value:m mclass value:m value:m selector]. |
|
5479 |
||
5480 |
"Created: / 11-05-2010 / 16:20:12 / cg" |
|
5481 |
! |
|
5482 |
||
18890 | 5483 |
resourceMethodSearchBlockFor:aStringSearchBlock |
5484 |
^ [:c :m :sel | |
|
5485 |
|resources| |
|
5486 |
||
5487 |
(m hasAnyResource:Method resourceTypes) ifTrue:[ |
|
5488 |
aStringSearchBlock value:c value:m value:sel |
|
5489 |
] ifFalse:[ |
|
5490 |
false |
|
5491 |
] |
|
5492 |
]. |
|
5493 |
! |
|
5494 |
||
4235
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
5495 |
searchBlockForAllCallsOn:aSelectorString ignoreCase:ignoreCase |
4270 | 5496 |
^ self searchBlockForAllCallsOn:aSelectorString ignoreCase:ignoreCase match:true |
5497 |
! |
|
5498 |
||
16337 | 5499 |
searchBlockForAllCallsOn:aSelectorString ignoreCase:ignoreCase match:doMatchArg |
5500 |
"return an optimized search block for the senders search. |
|
5501 |
Because this highly affects the speed of the senders-search in the browser, |
|
5502 |
specialized blocks are returned, depending on whether a selector-match or casesensitive |
|
5503 |
search is wanted |
|
5504 |
(these operations are executed a zillion times in an inner loop, |
|
5505 |
therefore, the speedup is noticable)" |
|
5506 |
||
16462 | 5507 |
|doMatch sel quickSearch idx| |
16337 | 5508 |
|
5509 |
doMatch := doMatchArg. |
|
5510 |
(doMatch and:[aSelectorString = '*']) ifTrue:[ |
|
5511 |
"a trivial block, which matches everything" |
|
5512 |
^ [:class :method :s | true]. |
|
5513 |
]. |
|
5514 |
||
5515 |
aSelectorString includesMatchCharacters ifFalse:[ |
|
5516 |
doMatch := false |
|
5517 |
]. |
|
5518 |
||
5519 |
(doMatch or:[ignoreCase]) ifTrue:[ |
|
8685
b39dc53c40ae
dont be too lazy in senders-search (do not return all accesses to
Claus Gittinger <cg@exept.de>
parents:
8678
diff
changeset
|
5520 |
"/ a matchString or ignoreCase - need string matching procedure |
4235
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
5521 |
|
16337 | 5522 |
quickSearch := aSelectorString. |
5523 |
(quickSearch startsWith:'*') ifTrue:[ |
|
5524 |
quickSearch := quickSearch copyButFirst |
|
5525 |
]. |
|
5526 |
(quickSearch endsWith:'*') ifTrue:[ |
|
5527 |
quickSearch := quickSearch copyButLast |
|
5528 |
]. |
|
16395 | 5529 |
|
5530 |
"/ for keyword selector searches, only look for the first KW-part in the quicksearch |
|
5531 |
"/ for matches, only look for substrings up to the first match character |
|
5532 |
(idx := quickSearch indexOfAny:'*#[:') ~~ 0 ifTrue:[ |
|
5533 |
quickSearch := quickSearch copyTo:idx-1. |
|
4235
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
5534 |
]. |
16395 | 5535 |
|
16337 | 5536 |
(ignoreCase and:[quickSearch includesMatchCharacters not]) ifTrue:[ |
5537 |
doMatch ifFalse:[ |
|
5538 |
^ [:class :methodArg :s | |
|
16462 | 5539 |
|method src inLiterals skip| |
16395 | 5540 |
|
5541 |
inLiterals := skip := false. |
|
16337 | 5542 |
method := methodArg originalMethodIfWrapped. |
5543 |
method isLazyMethod ifTrue:[ |
|
5544 |
src := method source. |
|
5545 |
(src notNil and:[src includesString:aSelectorString caseSensitive:false]) ifTrue:[ |
|
5546 |
method makeRealMethod. |
|
16395 | 5547 |
] ifFalse:[ |
5548 |
skip := true |
|
5549 |
]. |
|
5550 |
]. |
|
5551 |
skip ifFalse:[ |
|
16462 | 5552 |
inLiterals := |
5553 |
(method |
|
5554 |
literalsDetect:[:aLiteral| |
|
5555 |
(aLiteral isMemberOf:Symbol) |
|
5556 |
and:[(aLiteral sameAs:aSelectorString)]] |
|
5557 |
ifNone:nil) notNil |
|
16337 | 5558 |
]. |
5559 |
||
5560 |
inLiterals |
|
5561 |
and:[ |
|
5562 |
method messagesSent contains:[:msg | msg sameAs:aSelectorString ] |
|
5563 |
] |
|
5564 |
]. |
|
5565 |
]. |
|
5566 |
||
5567 |
^ [:class :methodArg :s | |
|
16462 | 5568 |
|method src inLiterals skip| |
16395 | 5569 |
|
5570 |
inLiterals := skip := false. |
|
16337 | 5571 |
method := methodArg originalMethodIfWrapped. |
5572 |
method isLazyMethod ifTrue:[ |
|
5573 |
src := method source. |
|
5574 |
(src notNil and:[src includesString:quickSearch caseSensitive:false]) ifTrue:[ |
|
5575 |
method makeRealMethod. |
|
16395 | 5576 |
] ifFalse:[ |
5577 |
skip := true |
|
5578 |
]. |
|
5579 |
]. |
|
5580 |
skip ifFalse:[ |
|
16462 | 5581 |
inLiterals := |
5582 |
(method |
|
5583 |
literalsDetect:[:aLiteral| |
|
5584 |
(aLiteral isMemberOf:Symbol) |
|
5585 |
and:[(aLiteral includesString:quickSearch caseSensitive:false) |
|
5586 |
and:[(aSelectorString match:aLiteral caseSensitive:false)]]] |
|
5587 |
ifNone:nil) notNil |
|
16337 | 5588 |
]. |
5589 |
||
5590 |
inLiterals |
|
5591 |
and:[ |
|
16462 | 5592 |
method messagesSent |
5593 |
contains:[:sel | aSelectorString match:aSelectorString caseSensitive:false] |
|
16337 | 5594 |
] |
5595 |
]. |
|
4235
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
5596 |
]. |
16337 | 5597 |
|
5598 |
(ignoreCase or:[quickSearch includesMatchCharacters]) ifFalse:[ |
|
5599 |
^ [:class :methodArg :s | |
|
16395 | 5600 |
|method src inLiterals skip| |
5601 |
||
5602 |
inLiterals := skip := false. |
|
16337 | 5603 |
method := methodArg originalMethodIfWrapped. |
5604 |
method isLazyMethod ifTrue:[ |
|
5605 |
src := method source. |
|
5606 |
(src notNil and:[src includesString:quickSearch]) ifTrue:[ |
|
5607 |
method makeRealMethod. |
|
16395 | 5608 |
] ifFalse:[ |
5609 |
skip := true |
|
5610 |
]. |
|
5611 |
]. |
|
5612 |
skip ifFalse:[ |
|
16462 | 5613 |
inLiterals := |
5614 |
(method |
|
5615 |
literalsDetect:[:aLiteral| |
|
5616 |
(aLiteral isMemberOf:Symbol) |
|
5617 |
and:[(aLiteral includesString:quickSearch) |
|
5618 |
and:[(aSelectorString match:aLiteral)]]] |
|
5619 |
ifNone:nil) notNil |
|
16337 | 5620 |
]. |
5621 |
inLiterals and:[ method messagesSent includes:aSelectorString] |
|
5622 |
]. |
|
5623 |
]. |
|
5624 |
^ [:class :methodArg :s | |
|
16395 | 5625 |
|method src inLiterals skip| |
16337 | 5626 |
|
5627 |
method := methodArg originalMethodIfWrapped. |
|
5628 |
"/ expensive search |
|
16395 | 5629 |
inLiterals := skip := false. |
16337 | 5630 |
method isLazyMethod ifTrue:[ |
5631 |
src := method source. |
|
5632 |
(src notNil and:[src includesMatchString:aSelectorString]) ifTrue:[ |
|
5633 |
method makeRealMethod. |
|
16395 | 5634 |
] ifFalse:[ |
5635 |
skip := true. |
|
5636 |
]. |
|
5637 |
]. |
|
5638 |
skip ifFalse:[ |
|
16462 | 5639 |
inLiterals := |
5640 |
(method literalsDetect:[:aLiteral| |
|
5641 |
(aLiteral isMemberOf:Symbol) |
|
5642 |
and:[ aSelectorString match:aLiteral asLowercase caseSensitive:ignoreCase not] |
|
5643 |
] ifNone:nil) notNil |
|
16337 | 5644 |
]. |
5645 |
inLiterals |
|
5646 |
and:[ |
|
5647 |
method messagesSent |
|
16395 | 5648 |
contains:[:anySelector | |
5649 |
aSelectorString match:anySelector caseSensitive:ignoreCase not |
|
5650 |
] |
|
16337 | 5651 |
] |
5652 |
]. |
|
5653 |
]. |
|
5654 |
||
5655 |
"/ no matchString and not ignoring case - can do it much faster |
|
5656 |
sel := aSelectorString asSymbolIfInterned. |
|
5657 |
sel isNil ifTrue:[ |
|
5658 |
^ nil "/ none |
|
5659 |
]. |
|
5660 |
||
5661 |
quickSearch := sel. |
|
16395 | 5662 |
"/ for keyword selector searches, only look for the first KW-part in the quicksearch |
5663 |
(idx := quickSearch indexOf:$:) ~~ 0 ifTrue:[ |
|
5664 |
quickSearch := quickSearch copyTo:idx-1. |
|
16337 | 5665 |
]. |
5666 |
||
5667 |
^ [:class :methodArg :s | |
|
5668 |
|method src| |
|
5669 |
||
5670 |
method := methodArg originalMethodIfWrapped. |
|
5671 |
method isLazyMethod ifTrue:[ |
|
5672 |
src := method source. |
|
5673 |
(src notNil and:[src includesString:quickSearch]) ifTrue:[ |
|
5674 |
method makeRealMethod. |
|
5675 |
method referencesLiteral: "sends:" sel. |
|
5676 |
] ifFalse:[ |
|
5677 |
false |
|
5678 |
] |
|
4235
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
5679 |
] ifFalse:[ |
17328 | 5680 |
method sendsSelector:sel |
4235
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
5681 |
] |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
5682 |
]. |
10416
82d17ccb68ad
changed: #searchBlockForAllCallsOn:ignoreCase:match:
Claus Gittinger <cg@exept.de>
parents:
10386
diff
changeset
|
5683 |
|
17328 | 5684 |
"Modified: / 05-02-2017 / 01:25:14 / cg" |
4235
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
5685 |
! |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
5686 |
|
19026 | 5687 |
searchBlockForAllCallsUsingReturnValueOn:aSelectorOrSelectorString ignoreCase:ignoreCase match:doMatchArg |
5688 |
"return an optimized search block for the senders which use the return value search." |
|
5689 |
||
5690 |
|sel senderSearchBlock searchBlock matcher| |
|
5691 |
||
5692 |
sel := aSelectorOrSelectorString asSymbolIfInterned. |
|
5693 |
sel isNil ifTrue:[ |
|
5694 |
Transcript showCR:'no such symbol - no senders, obviously'. |
|
5695 |
^ [:class :method :s | false]. |
|
5696 |
]. |
|
5697 |
||
5698 |
senderSearchBlock := self searchBlockForAllCallsOn:sel ignoreCase:ignoreCase match:doMatchArg. |
|
5699 |
||
5700 |
matcher := ParseTreeSearcher isUsingValueFromMessage:sel. |
|
5701 |
||
5702 |
"/ now wrap it |
|
5703 |
searchBlock := |
|
5704 |
[:class :method :s | |
|
5705 |
(senderSearchBlock value:class value:method value:s) |
|
5706 |
and:[ |
|
5707 |
ParseTreeSearcher matchMethod:method with:matcher |
|
5708 |
] |
|
5709 |
]. |
|
5710 |
^ searchBlock |
|
5711 |
! |
|
5712 |
||
9879 | 5713 |
searchBlockForCode:aCodeString in:aCollectionOfClasses isMethod:isMethod |
10546
174df6f8a170
changed: #searchBlockForCode:in:isMethod:
Claus Gittinger <cg@exept.de>
parents:
10416
diff
changeset
|
5714 |
"return a block to search for a piece of code. |
174df6f8a170
changed: #searchBlockForCode:in:isMethod:
Claus Gittinger <cg@exept.de>
parents:
10416
diff
changeset
|
5715 |
intelligent search: because parsing and the parseTree-match is a relatively |
174df6f8a170
changed: #searchBlockForCode:in:isMethod:
Claus Gittinger <cg@exept.de>
parents:
10416
diff
changeset
|
5716 |
expensive operation, we try hard to reduce the amount of searched methods by: |
174df6f8a170
changed: #searchBlockForCode:in:isMethod:
Claus Gittinger <cg@exept.de>
parents:
10416
diff
changeset
|
5717 |
- extracting sent messages from the pattern, and limiting the search to |
174df6f8a170
changed: #searchBlockForCode:in:isMethod:
Claus Gittinger <cg@exept.de>
parents:
10416
diff
changeset
|
5718 |
methods which also send all those messages, |
174df6f8a170
changed: #searchBlockForCode:in:isMethod:
Claus Gittinger <cg@exept.de>
parents:
10416
diff
changeset
|
5719 |
- extracting accessed globals from the pattern, and limiting the search to |
174df6f8a170
changed: #searchBlockForCode:in:isMethod:
Claus Gittinger <cg@exept.de>
parents:
10416
diff
changeset
|
5720 |
methods which also refer to those globals" |
5094 | 5721 |
|
11638
344d7d06f1d2
changed: #searchBlockForCode:in:isMethod:
Claus Gittinger <cg@exept.de>
parents:
11506
diff
changeset
|
5722 |
|errAction searchTree searcher globalVariablesUsed usedSymbols usedStrings |
9879 | 5723 |
sentMessages searchBlock foundMatch numMethodArgs methodSelector nameSpacesForGlobals| |
5256
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
5724 |
|
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
5725 |
"/self halt. |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
5726 |
"/rule := ParseTreeLintRule |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
5727 |
"/ createParseTreeRule: (Array with: aCodeString) |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
5728 |
"/ method: isMethod |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
5729 |
"/ name: 'Search for: ' , aCodeString. |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
5730 |
"/self halt. |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
5731 |
"/ |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
5732 |
"/ searchBlock := [:c :m :sel | |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
5733 |
"/ rslt := SmalllintChecker |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
5734 |
"/ runRule:rule |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
5735 |
"/ onEnvironment: (ClassEnvironment onEnvironment:(BrowserEnvironment new) classes:(Array with:c)). |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
5736 |
"/ |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
5737 |
"/ self halt. |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
5738 |
"/ ]. |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
5739 |
"/^ searchBlock. |
5226 | 5740 |
|
16597 | 5741 |
errAction := |
5742 |
[:errMsg :pos | |
|
18882 | 5743 |
Dialog warn:'Error during pattern parse: %1 (position %2)' |
5744 |
with:errMsg with:pos. |
|
16597 | 5745 |
^ nil |
5746 |
]. |
|
5094 | 5747 |
|
5748 |
isMethod ifTrue:[ |
|
5749 |
searchTree := RBParser |
|
5750 |
parseRewriteMethod:aCodeString |
|
5226 | 5751 |
onError: errAction. |
8281
67f0cd20adf0
method-code search tuned: filter by number of methodArgs, if known.
Claus Gittinger <cg@exept.de>
parents:
8158
diff
changeset
|
5752 |
numMethodArgs := searchTree arguments size. |
18900 | 5753 |
(searchTree selectorParts contains:[:part | part isPatternVariable]) ifFalse:[ |
5754 |
methodSelector := searchTree selector. |
|
5755 |
]. |
|
5094 | 5756 |
] ifFalse:[ |
5757 |
searchTree := RBParser |
|
5758 |
parseRewriteExpression:aCodeString |
|
5226 | 5759 |
onError: errAction. |
5094 | 5760 |
]. |
16529 | 5761 |
|
10546
174df6f8a170
changed: #searchBlockForCode:in:isMethod:
Claus Gittinger <cg@exept.de>
parents:
10416
diff
changeset
|
5762 |
"/ extract messages sent by the pattern |
6368 | 5763 |
Error handle:[:ex | |
12837 | 5764 |
self halt:'check this, please'. |
6368 | 5765 |
] do:[ |
6549 | 5766 |
sentMessages := searchTree sentMessages. |
5135 | 5767 |
]. |
6581 | 5768 |
|
9879 | 5769 |
nameSpacesForGlobals := Set with:Smalltalk. |
5770 |
aCollectionOfClasses do:[:eachClass | |
|
5771 |
nameSpacesForGlobals add:eachClass topNameSpace |
|
5772 |
]. |
|
5773 |
||
10546
174df6f8a170
changed: #searchBlockForCode:in:isMethod:
Claus Gittinger <cg@exept.de>
parents:
10416
diff
changeset
|
5774 |
"/ extract globals used by the pattern |
9879 | 5775 |
globalVariablesUsed := OrderedCollection new. |
5776 |
searchTree referencedVariables do:[:node | |
|
5777 |
|nm ns alternatives| |
|
5778 |
||
5779 |
node isPatternNode ifFalse:[ |
|
5780 |
nm := node name. |
|
5781 |
ns := nameSpacesForGlobals detect:[:ns | ns includesKey: nm asSymbol] ifNone:nil. |
|
5782 |
ns notNil ifTrue:[ |
|
5783 |
alternatives := OrderedCollection new. |
|
5784 |
nm asSymbolIfInterned notNil ifTrue:[ alternatives add: nm asSymbol ]. |
|
5785 |
('Smalltalk::',nm) asSymbolIfInterned notNil ifTrue:[ alternatives add: ('Smalltalk::',nm) asSymbol ]. |
|
5786 |
(ns name,'::',nm) asSymbolIfInterned notNil ifTrue:[ alternatives add: (ns name,'::',nm) asSymbol ]. |
|
5787 |
nm asSymbolIfInterned notNil ifTrue:[ alternatives add: nm asSymbol ]. |
|
5788 |
globalVariablesUsed add:alternatives |
|
5789 |
]. |
|
5790 |
] |
|
5791 |
]. |
|
5135 | 5792 |
|
10546
174df6f8a170
changed: #searchBlockForCode:in:isMethod:
Claus Gittinger <cg@exept.de>
parents:
10416
diff
changeset
|
5793 |
"/ sorry: |
174df6f8a170
changed: #searchBlockForCode:in:isMethod:
Claus Gittinger <cg@exept.de>
parents:
10416
diff
changeset
|
5794 |
"/ cannot use literals to speedup the search, because stc does not store |
12056 | 5795 |
"/ constants in the literal-array. However, we can do a string search on |
5796 |
"/ them, to avoid parsing. |
|
5797 |
usedSymbols := searchTree usedSymbols. |
|
5798 |
usedStrings := searchTree usedLiterals select:[:lit | lit isString]. |
|
7395 | 5799 |
|
5094 | 5800 |
searcher := ParseTreeSearcher new. |
5256
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
5801 |
isMethod ifTrue:[ |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
5802 |
searcher |
8281
67f0cd20adf0
method-code search tuned: filter by number of methodArgs, if known.
Claus Gittinger <cg@exept.de>
parents:
8158
diff
changeset
|
5803 |
matchesMethod:aCodeString |
5256
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
5804 |
do:[:aNode :answer | foundMatch := true]. |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
5805 |
] ifFalse:[ |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
5806 |
searcher |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
5807 |
matchesTree:searchTree |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
5808 |
do:[:aNode :answer | foundMatch := true]. |
6303 | 5809 |
]. |
16529 | 5810 |
searcher computeQuickSearchStrings. |
5094 | 5811 |
|
16597 | 5812 |
searchBlock := |
5813 |
[:c :m :sel | |
|
5814 |
|isSTCCompiled allSelectorsInLiteralArray allMessagesSent |
|
5815 |
allGlobalsReferenced allUsedSymbolsInLiteralArray allStringsInLiteralArray |
|
5816 |
allSent src rslt parseTree |
|
18900 | 5817 |
literalsInMethod skipMethod| |
16597 | 5818 |
|
5819 |
foundMatch := false. |
|
5820 |
||
18900 | 5821 |
"/ can speedup the search, |
5822 |
"/ by filtering for number of message-args or method selector first... |
|
5823 |
skipMethod := false. |
|
5824 |
isMethod ifTrue:[ |
|
5825 |
(numMethodArgs notNil and:[ numMethodArgs ~= m numArgs ]) ifTrue:[ skipMethod := true ]. |
|
5826 |
(methodSelector notNil and:[ methodSelector ~= sel ]) ifTrue:[ skipMethod := true ]. |
|
5827 |
]. |
|
5828 |
skipMethod ifFalse:[ |
|
16597 | 5829 |
m isLazyMethod ifTrue:[ |
5830 |
src := m source. |
|
5831 |
src notNil ifTrue:[ |
|
5832 |
m makeRealMethod. |
|
5833 |
]. |
|
5834 |
]. |
|
5835 |
"/ can speedup the search, by quickly filtering for sent messages... |
|
5836 |
literalsInMethod := m literals. |
|
5837 |
allSelectorsInLiteralArray := sentMessages isEmptyOrNil or:[ literalsInMethod includesAll:sentMessages ]. |
|
5838 |
allSelectorsInLiteralArray ifTrue:[ |
|
5839 |
"/ and used symbols/globals first... |
|
5840 |
allUsedSymbolsInLiteralArray := usedSymbols isEmptyOrNil or:[ literalsInMethod includesAll:usedSymbols ]. |
|
5841 |
allUsedSymbolsInLiteralArray ifTrue:[ |
|
16600 | 5842 |
"/ if ANY string is in match, ANY string must be in method (not true, but I am lazy) |
16597 | 5843 |
"/ that does not work for stc compiled code, because it does not put strings into the literal array |
5844 |
isSTCCompiled := m byteCode isNil. |
|
5845 |
isSTCCompiled ifTrue:[ |
|
5846 |
allStringsInLiteralArray := true. "/ stc-compiled: don't know |
|
5847 |
] ifFalse:[ |
|
5848 |
allStringsInLiteralArray := usedStrings isEmptyOrNil |
|
5849 |
or:[ literalsInMethod includesAll:usedStrings "literalsInMethod contains:[:lit | lit isString]" ]. |
|
5850 |
]. |
|
5851 |
allStringsInLiteralArray ifTrue:[ |
|
5852 |
allGlobalsReferenced := globalVariablesUsed conform:[:varNames | varNames contains:[:varName | m referencesGlobal:varName]]. |
|
5853 |
allGlobalsReferenced ifTrue:[ |
|
16600 | 5854 |
allMessagesSent := sentMessages isEmptyOrNil |
5855 |
or:[ m messagesSent includesAll:sentMessages ]. |
|
16597 | 5856 |
allMessagesSent ifTrue:[ |
16600 | 5857 |
src := m source. |
5858 |
src isNil ifTrue:[ |
|
19367 | 5859 |
('Browser [info]: no source for ' , m whoString "printString") infoPrintCR. |
16600 | 5860 |
] ifFalse:[ |
5861 |
isSTCCompiled ifTrue:[ |
|
5862 |
usedStrings notEmptyOrNil ifTrue:[ |
|
5863 |
"/ now that we have the source, scan the source for the literal strings, |
|
5864 |
"/ before doing a slow parse |
|
5865 |
allStringsInLiteralArray := usedStrings conform:[:eachString | src includesString:eachString]. |
|
5866 |
] |
|
5867 |
]. |
|
5868 |
allStringsInLiteralArray ifTrue:[ |
|
5869 |
(searcher canQuicklyReject:src) ifTrue:[ |
|
5870 |
"/ Transcript show:'qReject: '; showCR:m whoString. |
|
5871 |
] ifFalse:[ |
|
5872 |
"/ the rest is done by the slower RB-match process... |
|
5873 |
parseTree := |
|
5874 |
RBParser |
|
5875 |
parseSearchMethod:src |
|
5876 |
onError: [:str :pos | |
|
5877 |
"/ self halt. |
|
5878 |
Transcript show:'Error during search in '; showCR:m. |
|
5879 |
Transcript showCR:str. |
|
5880 |
Transcript showCR:pos. |
|
5881 |
nil |
|
5882 |
]. |
|
5883 |
||
5884 |
parseTree notNil ifTrue:[ |
|
5885 |
searcher executeTree:parseTree. |
|
5886 |
"/ notice: searcher sets foundMatch !! |
|
16597 | 5887 |
]. |
5888 |
]. |
|
16600 | 5889 |
]. |
5251
847d633792ce
tuned code search if global vars are involved
Claus Gittinger <cg@exept.de>
parents:
5243
diff
changeset
|
5890 |
] |
5135 | 5891 |
] |
6581 | 5892 |
] |
16597 | 5893 |
] |
5894 |
] |
|
5895 |
] |
|
5896 |
]. |
|
5897 |
foundMatch. |
|
5898 |
]. |
|
5094 | 5899 |
^ searchBlock. |
7395 | 5900 |
|
9879 | 5901 |
"Created: / 02-05-2011 / 13:25:01 / sr" |
11638
344d7d06f1d2
changed: #searchBlockForCode:in:isMethod:
Claus Gittinger <cg@exept.de>
parents:
11506
diff
changeset
|
5902 |
"Modified: / 20-07-2012 / 19:07:36 / cg" |
18900 | 5903 |
"Modified: / 15-07-2019 / 15:27:48 / Claus Gittinger" |
9879 | 5904 |
! |
5905 |
||
5906 |
searchBlockForCode:aCodeString isMethod:isMethod |
|
5907 |
"return a block to search for a piece of code (intelligent search)." |
|
5908 |
||
5909 |
^ self searchBlockForCode:aCodeString in:#() isMethod:isMethod |
|
5910 |
||
5911 |
"Modified: / 02-05-2011 / 13:26:18 / sr" |
|
5094 | 5912 |
! |
5913 |
||
9482 | 5914 |
searchBlockForParseTreeSearcher:searcher isMethod:isMethod |
5915 |
"return a block to search for a piece of code (intelligent search)." |
|
5916 |
||
5917 |
|errAction searchBlock foundMatch| |
|
5918 |
||
5919 |
errAction := [:str :pos | |
|
5920 |
Dialog warn:'Error during parse: ' , str , ' (position ' , pos printString , ')'. |
|
5921 |
^ nil |
|
5922 |
]. |
|
5923 |
||
5924 |
searchBlock := [:c :m :sel | |
|
9483
eead021c9729
changed: #searchBlockForParseTreeSearcher:isMethod:
Claus Gittinger <cg@exept.de>
parents:
9482
diff
changeset
|
5925 |
|src parseTree| |
9482 | 5926 |
|
5927 |
foundMatch := false. |
|
5928 |
||
5929 |
m isLazyMethod ifTrue:[ |
|
5930 |
src := m source. |
|
5931 |
src notNil ifTrue:[ |
|
5932 |
m makeRealMethod. |
|
5933 |
]. |
|
5934 |
]. |
|
5935 |
||
5936 |
src := m source. |
|
5937 |
src isNil ifTrue:[ |
|
19367 | 5938 |
('Browser [info]: no source for ' , m whoString "printString") infoPrintCR. |
9482 | 5939 |
] ifFalse:[ |
5940 |
parseTree := RBParser |
|
5941 |
parseSearchMethod:src |
|
5942 |
onError: [:str :pos | |
|
5943 |
Transcript show:'Error in '; showCR:m. |
|
5944 |
Transcript showCR:str. |
|
5945 |
Transcript showCR:pos. |
|
5946 |
nil]. |
|
5947 |
||
5948 |
parseTree notNil ifTrue:[ |
|
9483
eead021c9729
changed: #searchBlockForParseTreeSearcher:isMethod:
Claus Gittinger <cg@exept.de>
parents:
9482
diff
changeset
|
5949 |
foundMatch := searcher executeTree:parseTree initialAnswer:false. |
9482 | 5950 |
] |
5951 |
]. |
|
5952 |
foundMatch. |
|
5953 |
]. |
|
5954 |
||
5955 |
^ searchBlock. |
|
5956 |
||
5957 |
"Created: / 11-05-2010 / 16:14:25 / cg" |
|
9483
eead021c9729
changed: #searchBlockForParseTreeSearcher:isMethod:
Claus Gittinger <cg@exept.de>
parents:
9482
diff
changeset
|
5958 |
"Modified: / 11-05-2010 / 22:05:09 / cg" |
9482 | 5959 |
! |
5960 |
||
9002 | 5961 |
searchBlockForReferendsOf:aGlobalName |
5962 |
"return a block which searches for all methods which reference a global named aGlobalName, |
|
17967 | 5963 |
which may be a matchpattern. |
5964 |
If aGlobalName is inside a namespace (a private or namespace-global), |
|
5965 |
the name should be <namespace>::<aGlobalName>" |
|
9002 | 5966 |
|
12844 | 5967 |
|globalsPlainName idx sym1 sym2| |
9002 | 5968 |
|
5969 |
globalsPlainName := aGlobalName. |
|
5970 |
(idx := globalsPlainName lastIndexOf:$:) ~~ 0 ifTrue:[ |
|
5971 |
globalsPlainName := globalsPlainName copyFrom:idx+1. |
|
11964
8670bf08f225
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
11941
diff
changeset
|
5972 |
(globalsPlainName size == 0 or:[globalsPlainName = '*']) ifTrue:[ |
9002 | 5973 |
globalsPlainName := aGlobalName |
5974 |
] |
|
5975 |
]. |
|
5976 |
||
9660
e8b452501452
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
9578
diff
changeset
|
5977 |
"/ matchingGlobalNames := OrderedCollection new. |
9002 | 5978 |
|
5979 |
aGlobalName includesMatchCharacters ifFalse:[ |
|
10386
105f6c60ce2d
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
10346
diff
changeset
|
5980 |
sym1 := aGlobalName asSymbolIfInterned. |
105f6c60ce2d
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
10346
diff
changeset
|
5981 |
sym2 := globalsPlainName asSymbolIfInterned. |
105f6c60ce2d
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
10346
diff
changeset
|
5982 |
(sym1 isNil and:[ sym2 isNil ]) ifTrue:[ |
105f6c60ce2d
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
10346
diff
changeset
|
5983 |
^ [:cls :mthd :sel | false ]. |
105f6c60ce2d
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
10346
diff
changeset
|
5984 |
]. |
11964
8670bf08f225
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
11941
diff
changeset
|
5985 |
"/ if any is nil, search for the same |
8670bf08f225
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
11941
diff
changeset
|
5986 |
sym1 := sym1 ? sym2. |
8670bf08f225
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
11941
diff
changeset
|
5987 |
sym2 := sym2 ? sym1. |
10386
105f6c60ce2d
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
10346
diff
changeset
|
5988 |
|
9002 | 5989 |
^ [:cls :mthd :sel | |
10386
105f6c60ce2d
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
10346
diff
changeset
|
5990 |
|mSource ok m usedGlobals| |
105f6c60ce2d
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
10346
diff
changeset
|
5991 |
|
105f6c60ce2d
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
10346
diff
changeset
|
5992 |
ok := false. |
105f6c60ce2d
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
10346
diff
changeset
|
5993 |
"/ kludge: Lazy methods do not include symbols in the literal array - sigh |
105f6c60ce2d
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
10346
diff
changeset
|
5994 |
mthd isLazyMethod ifTrue:[ |
105f6c60ce2d
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
10346
diff
changeset
|
5995 |
mSource := mthd source. |
105f6c60ce2d
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
10346
diff
changeset
|
5996 |
(mSource notNil) ifTrue:[ |
11964
8670bf08f225
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
11941
diff
changeset
|
5997 |
(mSource includesString:(sym2)) ifTrue:[ |
8670bf08f225
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
11941
diff
changeset
|
5998 |
usedGlobals := mthd usedGlobals. |
8670bf08f225
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
11941
diff
changeset
|
5999 |
(usedGlobals includes:sym1) ifTrue:[ |
10386
105f6c60ce2d
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
10346
diff
changeset
|
6000 |
ok := true |
105f6c60ce2d
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
10346
diff
changeset
|
6001 |
] ifFalse:[ |
11964
8670bf08f225
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
11941
diff
changeset
|
6002 |
(sym1 ~= sym2 and:[usedGlobals includes:sym2]) ifTrue:[ |
9660
e8b452501452
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
9578
diff
changeset
|
6003 |
ok := true |
e8b452501452
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
9578
diff
changeset
|
6004 |
] |
e8b452501452
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
9578
diff
changeset
|
6005 |
] |
e8b452501452
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
9578
diff
changeset
|
6006 |
] |
9002 | 6007 |
] |
10386
105f6c60ce2d
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
10346
diff
changeset
|
6008 |
] ifFalse:[ |
13071 | 6009 |
m := mthd originalMethodIfWrapped. |
11964
8670bf08f225
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
11941
diff
changeset
|
6010 |
((m refersToLiteral:sym1) or:[ sym1 ~= sym2 and:[m refersToLiteral:sym2] ]) ifTrue:[ |
10386
105f6c60ce2d
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
10346
diff
changeset
|
6011 |
usedGlobals := m usedGlobals. |
11964
8670bf08f225
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
11941
diff
changeset
|
6012 |
ok := (usedGlobals includes:sym1) or:[ sym1 ~= sym2 and:[usedGlobals includes:sym2] ] |
10386
105f6c60ce2d
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
10346
diff
changeset
|
6013 |
]. |
105f6c60ce2d
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
10346
diff
changeset
|
6014 |
]. |
105f6c60ce2d
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
10346
diff
changeset
|
6015 |
ok |
9002 | 6016 |
]. |
6017 |
]. |
|
6018 |
||
6019 |
^ [:cls :mthd :sel | |
|
9660
e8b452501452
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
9578
diff
changeset
|
6020 |
|mSource usedGlobals global m| |
9002 | 6021 |
|
6022 |
"/ kludge: Lazy methods do not include symbols in the literal array - sigh |
|
6023 |
mthd isLazyMethod ifTrue:[ |
|
6024 |
mSource := mthd source. |
|
6025 |
mSource notNil ifTrue:[ |
|
6026 |
usedGlobals := mthd usedGlobals |
|
6027 |
] |
|
6028 |
] ifFalse:[ |
|
13071 | 6029 |
m := mthd originalMethodIfWrapped. |
9660
e8b452501452
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
9578
diff
changeset
|
6030 |
(m literals contains:[:lit | (aGlobalName match:lit) or:[globalsPlainName match:lit]]) ifTrue:[ |
e8b452501452
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
9578
diff
changeset
|
6031 |
usedGlobals := m usedGlobals |
9002 | 6032 |
]. |
6033 |
]. |
|
6034 |
usedGlobals notNil ifTrue:[ |
|
6035 |
global := usedGlobals detect:[:lit | aGlobalName match:lit] ifNone:nil. |
|
9660
e8b452501452
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
9578
diff
changeset
|
6036 |
global isNil ifTrue:[ |
e8b452501452
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
9578
diff
changeset
|
6037 |
global := usedGlobals detect:[:lit | globalsPlainName match:lit] ifNone:nil. |
e8b452501452
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
9578
diff
changeset
|
6038 |
]. |
e8b452501452
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
9578
diff
changeset
|
6039 |
"/ global notNil ifTrue:[ |
e8b452501452
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
9578
diff
changeset
|
6040 |
"/ matchingGlobalNames add:global. |
e8b452501452
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
9578
diff
changeset
|
6041 |
"/ ] |
9002 | 6042 |
]. |
6043 |
global notNil |
|
6044 |
]. |
|
9660
e8b452501452
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
9578
diff
changeset
|
6045 |
|
10386
105f6c60ce2d
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
10346
diff
changeset
|
6046 |
"Modified: / 24-07-2011 / 09:50:30 / cg" |
9002 | 6047 |
! |
6048 |
||
16451 | 6049 |
searchBlockForString:aString ignoreCase:ignoreCase match:doMatchArg |
5094 | 6050 |
"return a block to search for a string." |
4235
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
6051 |
|
16691 | 6052 |
^ self |
6053 |
searchBlockForString:aString |
|
6054 |
ignoreCase:ignoreCase |
|
6055 |
match:doMatchArg |
|
6056 |
fullWordsOnly:false |
|
18890 | 6057 |
resourceMethodsOnly:false |
16691 | 6058 |
|
6059 |
" |
|
6060 |
SystemBrowser |
|
6061 |
findString:'should' |
|
6062 |
in:(Array with:Object) |
|
6063 |
ignoreCase:false |
|
6064 |
" |
|
6065 |
! |
|
6066 |
||
6067 |
searchBlockForString:aString ignoreCase:ignoreCase match:doMatchArg fullWordsOnly:fullWordsOnly |
|
6068 |
"return a block to search for a string." |
|
6069 |
||
18890 | 6070 |
^ self |
6071 |
searchBlockForString:aString |
|
6072 |
ignoreCase:ignoreCase match:doMatchArg fullWordsOnly:fullWordsOnly |
|
6073 |
resourceMethodsOnly:false |
|
6074 |
||
6075 |
" |
|
6076 |
SystemBrowser findString:'should' in:(Array with:Object) ignoreCase:false |
|
6077 |
" |
|
6078 |
||
6079 |
"Modified: / 05-06-2019 / 17:02:24 / Claus Gittinger" |
|
6080 |
! |
|
6081 |
||
19234 | 6082 |
searchBlockForString:aStringArg ignoreCase:ignoreCase match:doMatchArg fullWordsOnly:fullWordsOnly resourceMethodsOnly:resourceMethodsOnly |
18890 | 6083 |
"return a block to search for a string." |
6084 |
||
19234 | 6085 |
|aString checkBlock lineCheckBlock pattern doMatch |
18982 | 6086 |
quickCheckString firstMatchIndex lastMatchIndex stringSearchBlock |
6087 |
caseSensitive| |
|
6088 |
||
19234 | 6089 |
aString := aStringArg asSingleByteStringIfPossible. |
6090 |
||
18982 | 6091 |
caseSensitive := ignoreCase not. |
16451 | 6092 |
|
6093 |
doMatch := doMatchArg. |
|
6094 |
aString includesMatchCharacters ifFalse:[ |
|
6095 |
doMatch := false. |
|
6096 |
]. |
|
6097 |
doMatch ifTrue:[ |
|
2675 | 6098 |
"a matchString" |
16468 | 6099 |
pattern := aString. |
6100 |
||
6101 |
firstMatchIndex := aString indexOfAny:'*#['. |
|
6102 |
lastMatchIndex := aString lastIndexOfAny:'*#['. |
|
6103 |
"/ which is longer - left or right part |
|
6104 |
firstMatchIndex-1 "nleft" > (aString size-lastMatchIndex) "nright" ifTrue:[ |
|
6105 |
"/ use left part as quickSearch |
|
6106 |
quickCheckString := aString copyTo:firstMatchIndex-1 |
|
6107 |
] ifFalse:[ |
|
6108 |
"/ use right part as quickSearch |
|
6109 |
quickCheckString := aString copyFrom:lastMatchIndex+1 |
|
6110 |
]. |
|
6111 |
||
16451 | 6112 |
aString first == $* ifFalse:[ |
6113 |
pattern := '*',pattern |
|
6114 |
]. |
|
6115 |
aString last == $* ifFalse:[ |
|
6116 |
pattern := pattern,'*' |
|
6117 |
]. |
|
16468 | 6118 |
"/ when doing a match, be careful to not match acrosss lines |
18982 | 6119 |
lineCheckBlock := [:line | pattern match:line caseSensitive:caseSensitive]. |
16468 | 6120 |
quickCheckString size > 1 ifTrue:[ |
16691 | 6121 |
checkBlock := [:src | |
18982 | 6122 |
(src includesString:quickCheckString caseSensitive:caseSensitive) |
16691 | 6123 |
and:[ (lineCheckBlock value:src) |
6124 |
and:[ src asStringCollection contains:lineCheckBlock ]]]. |
|
16468 | 6125 |
] ifFalse:[ |
6126 |
checkBlock := [:src | |
|
6127 |
(lineCheckBlock value:src) |
|
6128 |
and:[ src asStringCollection contains:lineCheckBlock ]]. |
|
6129 |
]. |
|
2675 | 6130 |
] ifFalse:[ |
18982 | 6131 |
"a regular string" |
6132 |
"/ because caseInsensitive searches are slower, |
|
6133 |
"/ check if we can also compare caseInsensitive (i.e. there are no letters in it) |
|
6134 |
(caseSensitive or:[aString conform:[:ch | ch isNationalLetter not]]) ifTrue:[ |
|
6135 |
checkBlock := [:src | |
|
6136 |
(src indexOfSubCollection:aString startingAt:1 ifAbsent:0 caseSensitive:true) ~~ 0 |
|
6137 |
] |
|
6138 |
] ifFalse:[ |
|
6139 |
checkBlock := [:src | |
|
6140 |
(src indexOfSubCollection:aString startingAt:1 ifAbsent:0 caseSensitive:false) ~~ 0 |
|
6141 |
] |
|
6142 |
]. |
|
19231 | 6143 |
"/ can fast skip over all non-Unicode source strings. |
6144 |
aString isUnicodeString ifTrue:[ |
|
6145 |
|inner| |
|
6146 |
inner := checkBlock. |
|
6147 |
checkBlock := [:src | src isUnicodeString and:[inner value:src]]. |
|
6148 |
]. |
|
2675 | 6149 |
]. |
16691 | 6150 |
|
18890 | 6151 |
stringSearchBlock := |
6152 |
[:cls :mthd :sel | |
|
6153 |
|src found idx1 reallyFound ch1 ch2| |
|
6154 |
||
6155 |
found := false. |
|
6156 |
src := mthd source. |
|
6157 |
src isNil ifTrue:[ |
|
19367 | 6158 |
('Browser [info]: no source for ' , mthd whoString "printString") infoPrintCR. |
18890 | 6159 |
] ifFalse:[ |
6160 |
found := checkBlock value:src. |
|
6161 |
(fullWordsOnly and:[found]) ifTrue:[ |
|
6162 |
self halt. |
|
6163 |
doMatch ifTrue:[ |
|
6164 |
||
6165 |
] ifFalse:[ |
|
6166 |
reallyFound := false. |
|
6167 |
idx1 := 0. |
|
6168 |
[ |
|
6169 |
reallyFound not |
|
6170 |
and:[ |
|
18982 | 6171 |
idx1 := src indexOfSubCollection:aString startingAt:idx1+1 ifAbsent:0 caseSensitive:caseSensitive. |
18890 | 6172 |
idx1 ~~ 0] |
6173 |
] whileTrue:[ |
|
6174 |
"/ see if it is a free-standing word |
|
6175 |
reallyFound := true. |
|
6176 |
idx1 > 1 ifTrue:[ |
|
6177 |
ch1 := src at:idx1-1. |
|
6178 |
(ch1 isLetterOrUnderline) ifTrue:[ reallyFound := false]. |
|
6179 |
]. |
|
6180 |
(idx1+aString size-1) < src size ifTrue:[ |
|
6181 |
ch2 := src at:idx1+aString size. |
|
6182 |
(ch2 isLetterOrUnderline) ifTrue:[ reallyFound := false]. |
|
6183 |
]. |
|
16691 | 6184 |
]. |
18890 | 6185 |
found := reallyFound |
6186 |
]. |
|
16691 | 6187 |
]. |
18890 | 6188 |
]. |
6189 |
found |
|
16691 | 6190 |
]. |
18890 | 6191 |
|
6192 |
resourceMethodsOnly ifTrue:[ |
|
6193 |
^ self resourceMethodSearchBlockFor:stringSearchBlock |
|
6194 |
]. |
|
6195 |
^ stringSearchBlock |
|
2675 | 6196 |
|
6197 |
" |
|
6198 |
SystemBrowser findString:'should' in:(Array with:Object) ignoreCase:false |
|
6199 |
" |
|
18807 | 6200 |
|
6201 |
"Modified: / 05-06-2019 / 17:02:24 / Claus Gittinger" |
|
4152
92e3975f1904
allow for non-matching search (searching for impl. of '*')
Claus Gittinger <cg@exept.de>
parents:
4150
diff
changeset
|
6202 |
! |
92e3975f1904
allow for non-matching search (searching for impl. of '*')
Claus Gittinger <cg@exept.de>
parents:
4150
diff
changeset
|
6203 |
|
16451 | 6204 |
searchBlockForStringLiteral:aString ignoreCase:ignoreCase match:doMatchArg |
5877 | 6205 |
"return a block to search for a string-literal." |
6206 |
||
16691 | 6207 |
^ self |
18890 | 6208 |
searchBlockForStringLiteral:aString |
6209 |
ignoreCase:ignoreCase match:doMatchArg fullWordsOnly:false |
|
6210 |
resourceMethodsOnly:false |
|
16691 | 6211 |
|
6212 |
" |
|
6213 |
SystemBrowser findStringLiteral:'error' in:(Array with:Object) ignoreCase:true match:true |
|
6214 |
SystemBrowser findStringLiteral:'error' in:(Array with:Object) ignoreCase:true match:false |
|
6215 |
SystemBrowser findStringLiteral:'error' in:(Array with:Object) ignoreCase:false match:true |
|
6216 |
SystemBrowser findStringLiteral:'error' in:(Array with:Object) ignoreCase:false match:false |
|
6217 |
" |
|
6218 |
! |
|
6219 |
||
6220 |
searchBlockForStringLiteral:aString ignoreCase:ignoreCase match:doMatchArg fullWordsOnly:fullWordsOnly |
|
6221 |
"return a block to search for a string-literal." |
|
6222 |
||
18890 | 6223 |
^ self |
6224 |
searchBlockForStringLiteral:aString |
|
6225 |
ignoreCase:ignoreCase match:doMatchArg fullWordsOnly:fullWordsOnly |
|
6226 |
resourceMethodsOnly:false |
|
6227 |
||
6228 |
" |
|
6229 |
SystemBrowser findStringLiteral:'error' in:(Array with:Object) ignoreCase:true match:true |
|
6230 |
SystemBrowser findStringLiteral:'error' in:(Array with:Object) ignoreCase:true match:false |
|
6231 |
SystemBrowser findStringLiteral:'error' in:(Array with:Object) ignoreCase:false match:true |
|
6232 |
SystemBrowser findStringLiteral:'error' in:(Array with:Object) ignoreCase:false match:false |
|
6233 |
" |
|
6234 |
||
6235 |
"Modified: / 20-04-2017 / 11:28:05 / stefan" |
|
6236 |
! |
|
6237 |
||
6238 |
searchBlockForStringLiteral:aString ignoreCase:ignoreCase match:doMatchArg fullWordsOnly:fullWordsOnly resourceMethodsOnly:resourceMethodsOnly |
|
6239 |
"return a block to search for a string-literal." |
|
6240 |
||
16468 | 6241 |
|pattern doMatch checkLiteral checkSource |
18890 | 6242 |
quickCheckString firstMatchIndex lastMatchIndex stringSearchBlock| |
6243 |
||
6244 |
aString isEmpty ifTrue:[ |
|
6245 |
stringSearchBlock := [:cls :mthd :sel | true ]. |
|
6246 |
] ifFalse:[ |
|
6247 |
doMatch := doMatchArg. |
|
6248 |
(aString includesMatchCharacters) ifFalse:[ |
|
6249 |
doMatch := false |
|
16451 | 6250 |
]. |
18890 | 6251 |
doMatch ifTrue:[ |
6252 |
"a matchString" |
|
6253 |
pattern := aString. |
|
6254 |
aString first == $* ifFalse:[ |
|
6255 |
pattern := '*',pattern |
|
6256 |
]. |
|
6257 |
aString last == $* ifFalse:[ |
|
6258 |
pattern := pattern,'*' |
|
6259 |
]. |
|
6260 |
checkLiteral := [:lit | pattern match:lit caseSensitive:ignoreCase not]. |
|
6261 |
firstMatchIndex := aString indexOfAny:'*#['. |
|
6262 |
lastMatchIndex := aString lastIndexOfAny:'*#['. |
|
6263 |
"/ which is longer - left or right part? |
|
6264 |
firstMatchIndex-1 "nleft" > (aString size-lastMatchIndex) "nright" ifTrue:[ |
|
6265 |
"/ use left part as quickSearch |
|
6266 |
quickCheckString := aString copyTo:firstMatchIndex-1 |
|
6267 |
] ifFalse:[ |
|
6268 |
"/ use right part as quickSearch |
|
6269 |
quickCheckString := aString copyFrom:lastMatchIndex+1 |
|
6270 |
]. |
|
6271 |
quickCheckString size > 1 ifTrue:[ |
|
6272 |
checkSource := [:src | src includesString:quickCheckString caseSensitive:ignoreCase not] |
|
6273 |
] ifFalse:[ |
|
6274 |
checkSource := [:src | true]. "/ not worth the effort |
|
6275 |
]. |
|
16462 | 6276 |
] ifFalse:[ |
18890 | 6277 |
ignoreCase ifTrue:[ |
6278 |
checkLiteral := [:lit | lit includesString:aString caseSensitive:true]. |
|
6279 |
checkSource := [:src | src includesString:aString caseSensitive:true]. |
|
16462 | 6280 |
] ifFalse:[ |
18890 | 6281 |
checkLiteral := [:lit | lit includesString:aString]. |
6282 |
checkSource := [:src | src includesString:aString]. |
|
16462 | 6283 |
]. |
6284 |
]. |
|
18890 | 6285 |
|
6286 |
stringSearchBlock := |
|
6287 |
[:cls :methodArg :sel | |
|
6288 |
"/ sorry: the following does not work, because stc does not place string-constants |
|
6289 |
"/ into the literals. |
|
6290 |
"/ (mthd literalsDetect:[:lit | |
|
6291 |
"/ lit isString |
|
6292 |
"/ and:[ lit isSymbol not |
|
6293 |
"/ and:[ checkLiteral value:lit ]] |
|
6294 |
"/ ] ifNone:[nil]) |
|
6295 |
"/ notNil |
|
6296 |
"/ so we must parse here (sigh) |
|
6297 |
||
6298 |
|method src skip tree found| |
|
6299 |
||
6300 |
skip := found := false. |
|
6301 |
method := methodArg originalMethodIfWrapped. |
|
6302 |
method isLazyMethod ifTrue:[ |
|
6303 |
src := method source. |
|
6304 |
(src notNil) ifTrue:[ |
|
6305 |
method makeRealMethod. |
|
6306 |
] ifFalse:[ |
|
6307 |
skip := true |
|
6308 |
]. |
|
6309 |
]. |
|
6310 |
skip ifFalse:[ |
|
6311 |
src := method source. |
|
6312 |
src isNil ifTrue:[ |
|
19367 | 6313 |
('Browser: [info]: no source for method: ',methodArg whoString "printString") errorPrintCR. |
18890 | 6314 |
]. |
6315 |
(src notNil and:[src includes:$']) ifTrue:[ "/ eliminates many |
|
6316 |
(checkSource value:src) ifTrue:[ |
|
6317 |
tree := cls parseTreeFor:sel. |
|
6318 |
"/ walk |
|
6319 |
found := |
|
6320 |
tree notNil |
|
6321 |
and:[tree usedLiterals contains:[:lit | |
|
6322 |
lit isString |
|
6323 |
and:[ lit isSymbol not |
|
6324 |
and:[ checkLiteral value:lit ]]]] |
|
6325 |
]. |
|
6326 |
]. |
|
6327 |
]. |
|
6328 |
found |
|
6329 |
]. |
|
6330 |
]. |
|
6331 |
||
6332 |
resourceMethodsOnly ifTrue:[ |
|
6333 |
^ self resourceMethodSearchBlockFor:stringSearchBlock |
|
6334 |
]. |
|
6335 |
^ stringSearchBlock |
|
5877 | 6336 |
|
6337 |
" |
|
6338 |
SystemBrowser findStringLiteral:'error' in:(Array with:Object) ignoreCase:true match:true |
|
6339 |
SystemBrowser findStringLiteral:'error' in:(Array with:Object) ignoreCase:true match:false |
|
6340 |
SystemBrowser findStringLiteral:'error' in:(Array with:Object) ignoreCase:false match:true |
|
6341 |
SystemBrowser findStringLiteral:'error' in:(Array with:Object) ignoreCase:false match:false |
|
6342 |
" |
|
17498 | 6343 |
|
6344 |
"Modified: / 20-04-2017 / 11:28:05 / stefan" |
|
11452 | 6345 |
! |
6346 |
||
6347 |
searchBlockForSymbol:aSymbol |
|
12866 | 6348 |
"return a matchblock to search for all methods referencing aSymbol. |
6349 |
false if no such symbol exists" |
|
11452 | 6350 |
|
6351 |
(aSymbol includesMatchCharacters) ifTrue:[ |
|
6352 |
"a matchString" |
|
6353 |
^ [:c :m :s | |
|
6354 |
(m literalsDetect:[:aLiteral| |
|
6355 |
(aLiteral isMemberOf:Symbol) |
|
6356 |
and:[aSymbol match:aLiteral] |
|
6357 |
] |
|
6358 |
ifNone:nil |
|
6359 |
) notNil |
|
6360 |
]. |
|
6361 |
] ifFalse:[ |
|
12866 | 6362 |
aSymbol asSymbolIfInterned isNil ifTrue:[ |
6363 |
^ false |
|
6364 |
]. |
|
11452 | 6365 |
^ [:c :m :s | |
6366 |
(m literalsDetect:[:aLiteral| |
|
6367 |
(aSymbol == aLiteral) |
|
6368 |
] |
|
6369 |
ifNone:nil |
|
6370 |
) notNil |
|
6371 |
]. |
|
6372 |
]. |
|
6373 |
||
6374 |
"Created: / 22-03-2012 / 06:56:51 / cg" |
|
203 | 6375 |
! ! |
6376 |
||
820
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
6377 |
!SystemBrowser class methodsFor:'startup'! |
36 | 6378 |
|
203 | 6379 |
browseAllSelect:aBlock |
6380 |
"launch a browser for all methods where aBlock returns true. |
|
996
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
6381 |
The block is called with 3 arguments, class, method and selector." |
203 | 6382 |
|
996
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
6383 |
^ self |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
6384 |
browseMethodsWhere:aBlock |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
6385 |
title:'selected messages' |
36 | 6386 |
|
53 | 6387 |
" |
203 | 6388 |
SystemBrowser browseAllSelect:[:aClass :aMethod :selector | selector numArgs == 3] |
53 | 6389 |
" |
996
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
6390 |
|
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
6391 |
"Modified: 24.1.1997 / 19:45:05 / cg" |
203 | 6392 |
! |
75 | 6393 |
|
203 | 6394 |
browseClass:aClass |
4490 | 6395 |
"launch a browser for aClass. |
6396 |
Notice: better go via Smalltalk browseClass:, which honors the tool-preferences" |
|
203 | 6397 |
|
6398 |
^ self |
|
996
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
6399 |
newWithLabel:aClass name |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
6400 |
setupSelector:#setupForClass: |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
6401 |
arg:aClass |
203 | 6402 |
|
996
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
6403 |
" |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
6404 |
SystemBrowser browseClass:Object |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
6405 |
" |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
6406 |
|
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
6407 |
"Modified: 24.1.1997 / 19:45:16 / cg" |
203 | 6408 |
! |
6409 |
||
6410 |
browseClass:aClass methodCategory:aCategory |
|
6411 |
"launch a browser for all methods under aCategory in aClass" |
|
6412 |
||
6413 |
^ self newWithLabel:(aClass name , ' ' , aCategory) |
|
996
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
6414 |
setupBlock:[:browser | browser setupForClass:aClass methodCategory:aCategory] |
203 | 6415 |
|
996
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
6416 |
" |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
6417 |
SystemBrowser browseClass:String methodCategory:'copying' |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
6418 |
" |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
6419 |
|
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
6420 |
"Modified: 24.1.1997 / 19:45:23 / cg" |
203 | 6421 |
! |
6422 |
||
6423 |
browseClass:aClass selector:selector |
|
4490 | 6424 |
"launch a browser for the method at selector in aClass." |
203 | 6425 |
|
6426 |
^ self |
|
4158 | 6427 |
newWithLabel:(aClass name , ' ' , selector , ' ' , selector) |
6428 |
setupBlock:[:newBrowser | newBrowser setupForClass:aClass selector:selector] |
|
203 | 6429 |
|
6430 |
" |
|
6431 |
SystemBrowser browseClass:Object selector:#printString |
|
16384 | 6432 |
Tools::NewSystemBrowser openInClass:Object selector:#printString |
203 | 6433 |
" |
36 | 6434 |
! |
6435 |
||
203 | 6436 |
browseClassCategory:aClassCategory |
6437 |
"launch a browser for all classes under aCategory" |
|
6438 |
||
6439 |
^ self |
|
996
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
6440 |
newWithLabel:aClassCategory |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
6441 |
setupSelector:#setupForClassCategory: |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
6442 |
arg:aClassCategory |
203 | 6443 |
|
996
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
6444 |
" |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
6445 |
SystemBrowser browseClassCategory:'Kernel-Objects' |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
6446 |
" |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
6447 |
|
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
6448 |
"Modified: 24.1.1997 / 19:45:32 / cg" |
203 | 6449 |
! |
6450 |
||
6451 |
browseClassHierarchy:aClass |
|
6452 |
"launch a browser for aClass and all its superclasses. |
|
6453 |
this is different from the fullProtocol browser." |
|
36 | 6454 |
|
203 | 6455 |
^ self |
4158 | 6456 |
newWithLabel:(aClass name , '-' , 'hierarchy') |
6457 |
setupSelector:#setupForClassHierarchy: |
|
6458 |
arg:aClass |
|
203 | 6459 |
|
6460 |
" |
|
6461 |
SystemBrowser browseClassHierarchy:Number |
|
6462 |
" |
|
6463 |
! |
|
6464 |
||
8702 | 6465 |
browseClasses:aList label:title |
203 | 6466 |
"launch a browser for all classes in aList" |
6467 |
||
6468 |
^ self |
|
576
62dc6c67d71c
show subclasses hierarchical (spawn subclasses)
Claus Gittinger <cg@exept.de>
parents:
573
diff
changeset
|
6469 |
newWithLabel:title |
62dc6c67d71c
show subclasses hierarchical (spawn subclasses)
Claus Gittinger <cg@exept.de>
parents:
573
diff
changeset
|
6470 |
setupBlock:[:b | b setupForClassList:aList sort:true] |
203 | 6471 |
|
6472 |
" |
|
6473 |
SystemBrowser browseClasses:(Array with:Object |
|
576
62dc6c67d71c
show subclasses hierarchical (spawn subclasses)
Claus Gittinger <cg@exept.de>
parents:
573
diff
changeset
|
6474 |
with:Float) |
62dc6c67d71c
show subclasses hierarchical (spawn subclasses)
Claus Gittinger <cg@exept.de>
parents:
573
diff
changeset
|
6475 |
title:'two classes' |
203 | 6476 |
" |
576
62dc6c67d71c
show subclasses hierarchical (spawn subclasses)
Claus Gittinger <cg@exept.de>
parents:
573
diff
changeset
|
6477 |
|
62dc6c67d71c
show subclasses hierarchical (spawn subclasses)
Claus Gittinger <cg@exept.de>
parents:
573
diff
changeset
|
6478 |
"Modified: 28.5.1996 / 13:52:25 / cg" |
62dc6c67d71c
show subclasses hierarchical (spawn subclasses)
Claus Gittinger <cg@exept.de>
parents:
573
diff
changeset
|
6479 |
! |
62dc6c67d71c
show subclasses hierarchical (spawn subclasses)
Claus Gittinger <cg@exept.de>
parents:
573
diff
changeset
|
6480 |
|
8702 | 6481 |
browseClasses:aList label:title sort:doSort |
576
62dc6c67d71c
show subclasses hierarchical (spawn subclasses)
Claus Gittinger <cg@exept.de>
parents:
573
diff
changeset
|
6482 |
"launch a browser for all classes in aList" |
62dc6c67d71c
show subclasses hierarchical (spawn subclasses)
Claus Gittinger <cg@exept.de>
parents:
573
diff
changeset
|
6483 |
|
62dc6c67d71c
show subclasses hierarchical (spawn subclasses)
Claus Gittinger <cg@exept.de>
parents:
573
diff
changeset
|
6484 |
^ self |
62dc6c67d71c
show subclasses hierarchical (spawn subclasses)
Claus Gittinger <cg@exept.de>
parents:
573
diff
changeset
|
6485 |
newWithLabel:title |
62dc6c67d71c
show subclasses hierarchical (spawn subclasses)
Claus Gittinger <cg@exept.de>
parents:
573
diff
changeset
|
6486 |
setupBlock:[:b | b setupForClassList:aList sort:doSort] |
62dc6c67d71c
show subclasses hierarchical (spawn subclasses)
Claus Gittinger <cg@exept.de>
parents:
573
diff
changeset
|
6487 |
|
62dc6c67d71c
show subclasses hierarchical (spawn subclasses)
Claus Gittinger <cg@exept.de>
parents:
573
diff
changeset
|
6488 |
" |
62dc6c67d71c
show subclasses hierarchical (spawn subclasses)
Claus Gittinger <cg@exept.de>
parents:
573
diff
changeset
|
6489 |
SystemBrowser browseClasses:(Array with:Object |
62dc6c67d71c
show subclasses hierarchical (spawn subclasses)
Claus Gittinger <cg@exept.de>
parents:
573
diff
changeset
|
6490 |
with:Float) |
62dc6c67d71c
show subclasses hierarchical (spawn subclasses)
Claus Gittinger <cg@exept.de>
parents:
573
diff
changeset
|
6491 |
title:'two classes' |
62dc6c67d71c
show subclasses hierarchical (spawn subclasses)
Claus Gittinger <cg@exept.de>
parents:
573
diff
changeset
|
6492 |
" |
62dc6c67d71c
show subclasses hierarchical (spawn subclasses)
Claus Gittinger <cg@exept.de>
parents:
573
diff
changeset
|
6493 |
|
62dc6c67d71c
show subclasses hierarchical (spawn subclasses)
Claus Gittinger <cg@exept.de>
parents:
573
diff
changeset
|
6494 |
"Created: 28.5.1996 / 13:52:09 / cg" |
52 | 6495 |
! |
6496 |
||
8702 | 6497 |
browseClasses:aList title:title |
6498 |
<resource: #obsolete> |
|
6499 |
"launch a browser for all classes in aList" |
|
6500 |
||
6501 |
self obsoleteMethodWarning. |
|
6502 |
^ self browseClasses:aList label:title |
|
6503 |
! |
|
6504 |
||
6505 |
browseClasses:aList title:title sort:doSort |
|
6506 |
<resource: #obsolete> |
|
6507 |
"launch a browser for all classes in aList" |
|
6508 |
||
6509 |
self obsoleteMethodWarning. |
|
6510 |
^ self browseClasses:aList label:title sort:doSort |
|
6511 |
||
6512 |
"Created: 28.5.1996 / 13:52:09 / cg" |
|
6513 |
! |
|
6514 |
||
203 | 6515 |
browseFullClassProtocol:aClass |
6516 |
"launch a browser for aClasses full protocol. |
|
6517 |
This is different from hierarchy browsing." |
|
6518 |
||
6519 |
^ self |
|
4158 | 6520 |
newWithLabel:(aClass name , '-' , 'full protocol') |
6521 |
setupSelector:#setupForFullClassProtocol: |
|
6522 |
arg:aClass |
|
203 | 6523 |
|
6524 |
" |
|
6525 |
SystemBrowser browseFullClassProtocol:Number |
|
6526 |
" |
|
6527 |
! |
|
36 | 6528 |
|
203 | 6529 |
browseFullClasses |
6530 |
"launch a browser showing all methods at once" |
|
6531 |
||
6532 |
^ self |
|
4158 | 6533 |
newWithLabel:'Full Class Browser' |
6534 |
setupBlock:[:newBrowser | newBrowser setupForFullClass] |
|
36 | 6535 |
|
203 | 6536 |
"SystemBrowser browseFullClasses" |
6537 |
! |
|
6538 |
||
6539 |
browseInstMethodsFrom:aClass where:aBlock title:title |
|
6540 |
"launch a browser for all instance methods in aClass and all subclasses |
|
6541 |
where aBlock evaluates to true" |
|
36 | 6542 |
|
996
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
6543 |
^ self |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
6544 |
browseMethodsIn:(aClass withAllSubclasses) |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
6545 |
inst:true |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
6546 |
class:false |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
6547 |
where:aBlock |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
6548 |
title:title |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
6549 |
|
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
6550 |
"Modified: 24.1.1997 / 19:44:45 / cg" |
203 | 6551 |
! |
6552 |
||
6553 |
browseInstMethodsIn:aCollectionOfClasses where:aBlock title:title |
|
6554 |
"launch a browser for all instance methods of all classes in |
|
6555 |
aCollectionOfClasses where aBlock evaluates to true" |
|
6556 |
||
996
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
6557 |
^ self |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
6558 |
browseMethodsIn:aCollectionOfClasses |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
6559 |
inst:true class:false |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
6560 |
where:aBlock title:title |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
6561 |
|
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
6562 |
"Modified: 24.1.1997 / 19:43:41 / cg" |
203 | 6563 |
! |
36 | 6564 |
|
203 | 6565 |
browseInstMethodsOf:aClass where:aBlock title:title |
6566 |
"launch a browser for all instance methods in aClass |
|
6567 |
where aBlock evaluates to true" |
|
6568 |
||
996
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
6569 |
^ self |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
6570 |
browseMethodsIn:(Array with:aClass) |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
6571 |
inst:true |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
6572 |
class:false |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
6573 |
where:aBlock title:title |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
6574 |
|
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
6575 |
"Modified: 24.1.1997 / 19:43:50 / cg" |
203 | 6576 |
! |
6577 |
||
16384 | 6578 |
browseMethod:aMethod |
6579 |
"launch a single-method browser." |
|
6580 |
||
6581 |
^ self browseMethods:{ aMethod } |
|
6582 |
||
6583 |
" |
|
6584 |
self browseMethod:(Array compiledMethodAt:#at:) |
|
6585 |
Tools::NewSystemBrowser browseMethod:(Array compiledMethodAt:#at:) |
|
6586 |
" |
|
6587 |
! |
|
6588 |
||
203 | 6589 |
browseMethodCategory:aCategory |
6590 |
"launch a browser for all methods where category = aCategory" |
|
6591 |
||
6592 |
|searchBlock| |
|
6593 |
||
6594 |
aCategory includesMatchCharacters ifTrue:[ |
|
2822
8127e7726fdd
changes for environment browsing
Claus Gittinger <cg@exept.de>
parents:
2818
diff
changeset
|
6595 |
searchBlock := [:c :m :s | aCategory match:m category]. |
53 | 6596 |
] ifFalse:[ |
2822
8127e7726fdd
changes for environment browsing
Claus Gittinger <cg@exept.de>
parents:
2818
diff
changeset
|
6597 |
searchBlock := [:c :m :s | m category = aCategory] |
53 | 6598 |
]. |
6599 |
||
2822
8127e7726fdd
changes for environment browsing
Claus Gittinger <cg@exept.de>
parents:
2818
diff
changeset
|
6600 |
^ self browseMethodsWhere:searchBlock title:('all methods with category of ' , aCategory) |
203 | 6601 |
|
6602 |
" |
|
6603 |
SystemBrowser browseMethodCategory:'printing & storing' |
|
6604 |
SystemBrowser browseMethodCategory:'print*' |
|
6605 |
" |
|
6606 |
! |
|
6607 |
||
3666 | 6608 |
browseMethods:aListOfMethods |
6609 |
"launch a multi-method browser." |
|
6610 |
||
16384 | 6611 |
|title| |
6612 |
||
6613 |
aListOfMethods size == 1 ifTrue:[ |
|
6614 |
title := aListOfMethods first whoString |
|
6615 |
] ifFalse:[ |
|
6616 |
title := 'some methods' |
|
6617 |
]. |
|
6618 |
^ self browseMethods:aListOfMethods title:title |
|
6619 |
||
6620 |
" |
|
6621 |
self |
|
6622 |
browseMethods:(Array with:(Array compiledMethodAt:#at:)) |
|
6623 |
||
3666 | 6624 |
self |
6625 |
browseMethods:(Array with:(Array compiledMethodAt:#at:) |
|
6626 |
with:(OrderedCollection compiledMethodAt:#at:)) |
|
6627 |
||
6628 |
self |
|
6629 |
browseMethods:(Array with:(Array compiledMethodAt:#at:) |
|
6630 |
with:(Array compiledMethodAt:#at:put:)) |
|
6631 |
" |
|
6632 |
! |
|
6633 |
||
203 | 6634 |
browseMethods:aList title:aString |
6635 |
"launch a browser for an explicit list of class/selectors. |
|
279
062022b53f22
allow browseMethods to be passed a collection of methodObjects (in addition to strings)
Claus Gittinger <cg@exept.de>
parents:
270
diff
changeset
|
6636 |
Each entry in the list can be either a method, or a string |
062022b53f22
allow browseMethods to be passed a collection of methodObjects (in addition to strings)
Claus Gittinger <cg@exept.de>
parents:
270
diff
changeset
|
6637 |
consisting of the classes name and the selector, separated by spaces. |
634
24a678f81829
Change the name of a classes Metaclass from e.g. "SmallIntegerclass" to
Stefan Vogel <sv@exept.de>
parents:
620
diff
changeset
|
6638 |
For class methods, the string ' class' must be appended to the classname." |
279
062022b53f22
allow browseMethods to be passed a collection of methodObjects (in addition to strings)
Claus Gittinger <cg@exept.de>
parents:
270
diff
changeset
|
6639 |
|
1919
0652e55065f9
added sort option to #browserMethods:
Claus Gittinger <cg@exept.de>
parents:
1703
diff
changeset
|
6640 |
^ self |
0652e55065f9
added sort option to #browserMethods:
Claus Gittinger <cg@exept.de>
parents:
1703
diff
changeset
|
6641 |
browseMethods:aList |
0652e55065f9
added sort option to #browserMethods:
Claus Gittinger <cg@exept.de>
parents:
1703
diff
changeset
|
6642 |
title:aString |
0652e55065f9
added sort option to #browserMethods:
Claus Gittinger <cg@exept.de>
parents:
1703
diff
changeset
|
6643 |
sort:true |
0652e55065f9
added sort option to #browserMethods:
Claus Gittinger <cg@exept.de>
parents:
1703
diff
changeset
|
6644 |
|
0652e55065f9
added sort option to #browserMethods:
Claus Gittinger <cg@exept.de>
parents:
1703
diff
changeset
|
6645 |
|
0652e55065f9
added sort option to #browserMethods:
Claus Gittinger <cg@exept.de>
parents:
1703
diff
changeset
|
6646 |
" |
0652e55065f9
added sort option to #browserMethods:
Claus Gittinger <cg@exept.de>
parents:
1703
diff
changeset
|
6647 |
SystemBrowser |
0652e55065f9
added sort option to #browserMethods:
Claus Gittinger <cg@exept.de>
parents:
1703
diff
changeset
|
6648 |
browseMethods:#('Object printOn:' 'Collection add:') |
0652e55065f9
added sort option to #browserMethods:
Claus Gittinger <cg@exept.de>
parents:
1703
diff
changeset
|
6649 |
title:'some methods' |
0652e55065f9
added sort option to #browserMethods:
Claus Gittinger <cg@exept.de>
parents:
1703
diff
changeset
|
6650 |
|
0652e55065f9
added sort option to #browserMethods:
Claus Gittinger <cg@exept.de>
parents:
1703
diff
changeset
|
6651 |
SystemBrowser |
0652e55065f9
added sort option to #browserMethods:
Claus Gittinger <cg@exept.de>
parents:
1703
diff
changeset
|
6652 |
browseMethods:#('Behavior new:' 'Setclass new:') |
0652e55065f9
added sort option to #browserMethods:
Claus Gittinger <cg@exept.de>
parents:
1703
diff
changeset
|
6653 |
title:'some new: methods' |
0652e55065f9
added sort option to #browserMethods:
Claus Gittinger <cg@exept.de>
parents:
1703
diff
changeset
|
6654 |
|
0652e55065f9
added sort option to #browserMethods:
Claus Gittinger <cg@exept.de>
parents:
1703
diff
changeset
|
6655 |
SystemBrowser |
0652e55065f9
added sort option to #browserMethods:
Claus Gittinger <cg@exept.de>
parents:
1703
diff
changeset
|
6656 |
browseMethods:(Array with:(Object compiledMethodAt:#printOn:) |
0652e55065f9
added sort option to #browserMethods:
Claus Gittinger <cg@exept.de>
parents:
1703
diff
changeset
|
6657 |
with:(Collection compiledMethodAt:#add:) |
0652e55065f9
added sort option to #browserMethods:
Claus Gittinger <cg@exept.de>
parents:
1703
diff
changeset
|
6658 |
with:(Object class compiledMethodAt:#initialize)) |
0652e55065f9
added sort option to #browserMethods:
Claus Gittinger <cg@exept.de>
parents:
1703
diff
changeset
|
6659 |
title:'some methods' |
0652e55065f9
added sort option to #browserMethods:
Claus Gittinger <cg@exept.de>
parents:
1703
diff
changeset
|
6660 |
|
0652e55065f9
added sort option to #browserMethods:
Claus Gittinger <cg@exept.de>
parents:
1703
diff
changeset
|
6661 |
" |
0652e55065f9
added sort option to #browserMethods:
Claus Gittinger <cg@exept.de>
parents:
1703
diff
changeset
|
6662 |
|
0652e55065f9
added sort option to #browserMethods:
Claus Gittinger <cg@exept.de>
parents:
1703
diff
changeset
|
6663 |
"Modified: 1.11.1996 / 16:30:17 / cg" |
0652e55065f9
added sort option to #browserMethods:
Claus Gittinger <cg@exept.de>
parents:
1703
diff
changeset
|
6664 |
! |
0652e55065f9
added sort option to #browserMethods:
Claus Gittinger <cg@exept.de>
parents:
1703
diff
changeset
|
6665 |
|
0652e55065f9
added sort option to #browserMethods:
Claus Gittinger <cg@exept.de>
parents:
1703
diff
changeset
|
6666 |
browseMethods:aList title:aString sort:doSort |
0652e55065f9
added sort option to #browserMethods:
Claus Gittinger <cg@exept.de>
parents:
1703
diff
changeset
|
6667 |
"launch a browser for an explicit list of class/selectors. |
0652e55065f9
added sort option to #browserMethods:
Claus Gittinger <cg@exept.de>
parents:
1703
diff
changeset
|
6668 |
Each entry in the list can be either a method, or a string |
0652e55065f9
added sort option to #browserMethods:
Claus Gittinger <cg@exept.de>
parents:
1703
diff
changeset
|
6669 |
consisting of the classes name and the selector, separated by spaces. |
0652e55065f9
added sort option to #browserMethods:
Claus Gittinger <cg@exept.de>
parents:
1703
diff
changeset
|
6670 |
For class methods, the string ' class' must be appended to the classname." |
0652e55065f9
added sort option to #browserMethods:
Claus Gittinger <cg@exept.de>
parents:
1703
diff
changeset
|
6671 |
|
279
062022b53f22
allow browseMethods to be passed a collection of methodObjects (in addition to strings)
Claus Gittinger <cg@exept.de>
parents:
270
diff
changeset
|
6672 |
|l| |
203 | 6673 |
|
6674 |
(aList size == 0) ifTrue:[ |
|
279
062022b53f22
allow browseMethods to be passed a collection of methodObjects (in addition to strings)
Claus Gittinger <cg@exept.de>
parents:
270
diff
changeset
|
6675 |
self showNoneFound:aString. |
062022b53f22
allow browseMethods to be passed a collection of methodObjects (in addition to strings)
Claus Gittinger <cg@exept.de>
parents:
270
diff
changeset
|
6676 |
^ nil |
203 | 6677 |
]. |
279
062022b53f22
allow browseMethods to be passed a collection of methodObjects (in addition to strings)
Claus Gittinger <cg@exept.de>
parents:
270
diff
changeset
|
6678 |
l := aList asOrderedCollection. |
062022b53f22
allow browseMethods to be passed a collection of methodObjects (in addition to strings)
Claus Gittinger <cg@exept.de>
parents:
270
diff
changeset
|
6679 |
l := l collect:[:entry | |
15513 | 6680 |
|cls clsName| |
279
062022b53f22
allow browseMethods to be passed a collection of methodObjects (in addition to strings)
Claus Gittinger <cg@exept.de>
parents:
270
diff
changeset
|
6681 |
|
062022b53f22
allow browseMethods to be passed a collection of methodObjects (in addition to strings)
Claus Gittinger <cg@exept.de>
parents:
270
diff
changeset
|
6682 |
entry isString ifTrue:[ |
062022b53f22
allow browseMethods to be passed a collection of methodObjects (in addition to strings)
Claus Gittinger <cg@exept.de>
parents:
270
diff
changeset
|
6683 |
entry |
062022b53f22
allow browseMethods to be passed a collection of methodObjects (in addition to strings)
Claus Gittinger <cg@exept.de>
parents:
270
diff
changeset
|
6684 |
] ifFalse:[ |
2822
8127e7726fdd
changes for environment browsing
Claus Gittinger <cg@exept.de>
parents:
2818
diff
changeset
|
6685 |
cls := entry mclass. |
8127e7726fdd
changes for environment browsing
Claus Gittinger <cg@exept.de>
parents:
2818
diff
changeset
|
6686 |
cls isNil ifTrue:[ |
1031 | 6687 |
'??? unbound' |
6688 |
] ifFalse:[ |
|
2822
8127e7726fdd
changes for environment browsing
Claus Gittinger <cg@exept.de>
parents:
2818
diff
changeset
|
6689 |
cls isJavaClass ifTrue:[ |
8127e7726fdd
changes for environment browsing
Claus Gittinger <cg@exept.de>
parents:
2818
diff
changeset
|
6690 |
clsName := 'JAVA::' , cls fullName |
1937
fc541342f2db
more support for java code (implementors)
Claus Gittinger <cg@exept.de>
parents:
1931
diff
changeset
|
6691 |
] ifFalse:[ |
2822
8127e7726fdd
changes for environment browsing
Claus Gittinger <cg@exept.de>
parents:
2818
diff
changeset
|
6692 |
clsName := cls name |
8127e7726fdd
changes for environment browsing
Claus Gittinger <cg@exept.de>
parents:
2818
diff
changeset
|
6693 |
]. |
7915 | 6694 |
(cls selectorAtMethod:entry) isNil ifTrue:[ |
6695 |
clsName |
|
6696 |
, ' ' |
|
6697 |
, '???' |
|
6698 |
] ifFalse:[ |
|
6699 |
clsName |
|
6700 |
, ' ' |
|
6701 |
, (entry printStringForBrowserWithSelector:(cls selectorAtMethod:entry) inClass:cls) |
|
6702 |
] |
|
1031 | 6703 |
] |
279
062022b53f22
allow browseMethods to be passed a collection of methodObjects (in addition to strings)
Claus Gittinger <cg@exept.de>
parents:
270
diff
changeset
|
6704 |
] |
062022b53f22
allow browseMethods to be passed a collection of methodObjects (in addition to strings)
Claus Gittinger <cg@exept.de>
parents:
270
diff
changeset
|
6705 |
]. |
062022b53f22
allow browseMethods to be passed a collection of methodObjects (in addition to strings)
Claus Gittinger <cg@exept.de>
parents:
270
diff
changeset
|
6706 |
|
1919
0652e55065f9
added sort option to #browserMethods:
Claus Gittinger <cg@exept.de>
parents:
1703
diff
changeset
|
6707 |
doSort ifTrue:[l sort]. |
1937
fc541342f2db
more support for java code (implementors)
Claus Gittinger <cg@exept.de>
parents:
1931
diff
changeset
|
6708 |
|
203 | 6709 |
^ self |
279
062022b53f22
allow browseMethods to be passed a collection of methodObjects (in addition to strings)
Claus Gittinger <cg@exept.de>
parents:
270
diff
changeset
|
6710 |
newWithLabel:aString |
062022b53f22
allow browseMethods to be passed a collection of methodObjects (in addition to strings)
Claus Gittinger <cg@exept.de>
parents:
270
diff
changeset
|
6711 |
setupSelector:#setupForList: |
062022b53f22
allow browseMethods to be passed a collection of methodObjects (in addition to strings)
Claus Gittinger <cg@exept.de>
parents:
270
diff
changeset
|
6712 |
arg:l |
53 | 6713 |
|
203 | 6714 |
" |
6715 |
SystemBrowser |
|
279
062022b53f22
allow browseMethods to be passed a collection of methodObjects (in addition to strings)
Claus Gittinger <cg@exept.de>
parents:
270
diff
changeset
|
6716 |
browseMethods:#('Object printOn:' 'Collection add:') |
062022b53f22
allow browseMethods to be passed a collection of methodObjects (in addition to strings)
Claus Gittinger <cg@exept.de>
parents:
270
diff
changeset
|
6717 |
title:'some methods' |
062022b53f22
allow browseMethods to be passed a collection of methodObjects (in addition to strings)
Claus Gittinger <cg@exept.de>
parents:
270
diff
changeset
|
6718 |
|
062022b53f22
allow browseMethods to be passed a collection of methodObjects (in addition to strings)
Claus Gittinger <cg@exept.de>
parents:
270
diff
changeset
|
6719 |
SystemBrowser |
062022b53f22
allow browseMethods to be passed a collection of methodObjects (in addition to strings)
Claus Gittinger <cg@exept.de>
parents:
270
diff
changeset
|
6720 |
browseMethods:#('Behavior new:' 'Setclass new:') |
062022b53f22
allow browseMethods to be passed a collection of methodObjects (in addition to strings)
Claus Gittinger <cg@exept.de>
parents:
270
diff
changeset
|
6721 |
title:'some new: methods' |
062022b53f22
allow browseMethods to be passed a collection of methodObjects (in addition to strings)
Claus Gittinger <cg@exept.de>
parents:
270
diff
changeset
|
6722 |
|
062022b53f22
allow browseMethods to be passed a collection of methodObjects (in addition to strings)
Claus Gittinger <cg@exept.de>
parents:
270
diff
changeset
|
6723 |
SystemBrowser |
062022b53f22
allow browseMethods to be passed a collection of methodObjects (in addition to strings)
Claus Gittinger <cg@exept.de>
parents:
270
diff
changeset
|
6724 |
browseMethods:(Array with:(Object compiledMethodAt:#printOn:) |
062022b53f22
allow browseMethods to be passed a collection of methodObjects (in addition to strings)
Claus Gittinger <cg@exept.de>
parents:
270
diff
changeset
|
6725 |
with:(Collection compiledMethodAt:#add:) |
062022b53f22
allow browseMethods to be passed a collection of methodObjects (in addition to strings)
Claus Gittinger <cg@exept.de>
parents:
270
diff
changeset
|
6726 |
with:(Object class compiledMethodAt:#initialize)) |
062022b53f22
allow browseMethods to be passed a collection of methodObjects (in addition to strings)
Claus Gittinger <cg@exept.de>
parents:
270
diff
changeset
|
6727 |
title:'some methods' |
062022b53f22
allow browseMethods to be passed a collection of methodObjects (in addition to strings)
Claus Gittinger <cg@exept.de>
parents:
270
diff
changeset
|
6728 |
|
203 | 6729 |
" |
279
062022b53f22
allow browseMethods to be passed a collection of methodObjects (in addition to strings)
Claus Gittinger <cg@exept.de>
parents:
270
diff
changeset
|
6730 |
|
7711 | 6731 |
"Modified: / 17-06-1996 / 17:07:46 / stefan" |
6732 |
"Modified: / 05-03-2007 / 16:25:25 / cg" |
|
2826 | 6733 |
! |
53 | 6734 |
|
203 | 6735 |
browseMethodsFrom:aClass where:aBlock title:title |
6736 |
"launch a browser for all instance- and classmethods in aClass |
|
6737 |
and all its subclasses where aBlock evaluates to true. |
|
6738 |
The block is called with 3 arguments, class, method and seelctor." |
|
6739 |
||
996
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
6740 |
^ self |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
6741 |
browseMethodsIn:(aClass withAllSubclasses) |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
6742 |
where:aBlock |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
6743 |
title:title |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
6744 |
|
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
6745 |
"Modified: 24.1.1997 / 19:44:00 / cg" |
203 | 6746 |
! |
6747 |
||
6748 |
browseMethodsIn:aCollectionOfClasses inst:wantInst class:wantClass where:aBlock title:title |
|
6749 |
"launch a browser for all instance- (if wantInst is true) and/or |
|
6750 |
classmethods (if wantClass is true) from classes in aCollectionOfClasses, |
|
6751 |
where aBlock evaluates to true. |
|
270 | 6752 |
The block is called with 3 arguments, class, method and selector." |
203 | 6753 |
|
6754 |
|list| |
|
53 | 6755 |
|
6756 |
" |
|
203 | 6757 |
since this may take a long time, lower my priority ... |
53 | 6758 |
" |
2295
4e05198e7dd8
execute BG tasks at a prio range, to ensure progress.
Claus Gittinger <cg@exept.de>
parents:
2208
diff
changeset
|
6759 |
Processor activeProcess |
4e05198e7dd8
execute BG tasks at a prio range, to ensure progress.
Claus Gittinger <cg@exept.de>
parents:
2208
diff
changeset
|
6760 |
withPriority:Processor activePriority-1 to:Processor activePriority |
4e05198e7dd8
execute BG tasks at a prio range, to ensure progress.
Claus Gittinger <cg@exept.de>
parents:
2208
diff
changeset
|
6761 |
do:[ |
2675 | 6762 |
list := self findMethodsIn:aCollectionOfClasses inst:wantInst class:wantClass where:aBlock |
203 | 6763 |
]. |
6764 |
^ self browseMethods:list title:title |
|
53 | 6765 |
! |
6766 |
||
3780 | 6767 |
browseMethodsIn:aCollectionOfClasses inst:wantInst class:wantClass where:aBlock title:title ifNone:warnBlock |
6768 |
"launch a browser for all instance- (if wantInst is true) and/or |
|
6769 |
classmethods (if wantClass is true) from classes in aCollectionOfClasses, |
|
6770 |
where aBlock evaluates to true. |
|
6771 |
The block is called with 3 arguments, class, method and selector." |
|
6772 |
||
6773 |
|list| |
|
6774 |
||
6775 |
" |
|
6776 |
since this may take a long time, lower my priority ... |
|
6777 |
" |
|
6778 |
Processor activeProcess |
|
6779 |
withPriority:Processor activePriority-1 to:Processor activePriority |
|
6780 |
do:[ |
|
6781 |
list := self findMethodsIn:aCollectionOfClasses inst:wantInst class:wantClass where:aBlock. |
|
6782 |
list size == 0 ifTrue:[warnBlock value]. |
|
6783 |
]. |
|
6784 |
^ self browseMethods:list title:title |
|
6785 |
! |
|
6786 |
||
203 | 6787 |
browseMethodsIn:aCollectionOfClasses where:aBlock title:title |
6788 |
"launch a browser for all instance- and classmethods from |
|
6789 |
all classes in aCollectionOfClasses where aBlock evaluates to true. |
|
6790 |
The block is called with 3 arguments, class, method and seelctor." |
|
53 | 6791 |
|
996
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
6792 |
^ self |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
6793 |
browseMethodsIn:aCollectionOfClasses |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
6794 |
inst:true |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
6795 |
class:true |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
6796 |
where:aBlock |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
6797 |
title:title |
75 | 6798 |
|
996
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
6799 |
"Modified: 24.1.1997 / 19:44:17 / cg" |
36 | 6800 |
! |
6801 |
||
3780 | 6802 |
browseMethodsIn:aCollectionOfClasses where:aBlock title:title ifNone:warnBlock |
6803 |
"launch a browser for all instance- and classmethods from |
|
6804 |
all classes in aCollectionOfClasses where aBlock evaluates to true. |
|
6805 |
The block is called with 3 arguments, class, method and seelctor." |
|
6806 |
||
6807 |
^ self |
|
6808 |
browseMethodsIn:aCollectionOfClasses |
|
6809 |
inst:true |
|
6810 |
class:true |
|
6811 |
where:aBlock |
|
6812 |
title:title |
|
6813 |
ifNone:warnBlock |
|
6814 |
||
6815 |
"Modified: 24.1.1997 / 19:44:17 / cg" |
|
6816 |
! |
|
6817 |
||
203 | 6818 |
browseMethodsOf:aClass where:aBlock title:title |
6819 |
"launch a browser for all instance- and classmethods in aClass |
|
6820 |
where aBlock evaluates to true. |
|
6821 |
The block is called with 3 arguments, class, method and seelctor." |
|
93 | 6822 |
|
203 | 6823 |
^ self browseMethodsIn:(Array with:aClass) where:aBlock title:title |
93 | 6824 |
! |
6825 |
||
203 | 6826 |
browseMethodsWhere:aBlock title:title |
6827 |
"launch a browser for all methods where aBlock returns true. |
|
6828 |
The block is called with 3 arguments, class, method and seelctor." |
|
6829 |
||
996
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
6830 |
^ self |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
6831 |
browseMethodsIn:(Smalltalk allClasses) |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
6832 |
where:aBlock |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
6833 |
title:title |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
6834 |
|
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
6835 |
"Modified: 24.1.1997 / 19:44:30 / cg" |
2675 | 6836 |
! |
6837 |
||
3780 | 6838 |
browseMethodsWhere:aBlock title:title ifNone:warnBlock |
6839 |
"launch a browser for all methods where aBlock returns true. |
|
6840 |
The block is called with 3 arguments, class, method and seelctor." |
|
6841 |
||
6842 |
^ self |
|
6843 |
browseMethodsIn:(Smalltalk allClasses) |
|
6844 |
where:aBlock |
|
6845 |
title:title |
|
6846 |
ifNone:warnBlock |
|
6847 |
||
6848 |
"Modified: 24.1.1997 / 19:44:30 / cg" |
|
6849 |
! |
|
6850 |
||
2675 | 6851 |
findMethodsIn:aCollectionOfClasses inst:wantInst class:wantClass where:aBlock |
6852 |
"return all instance- (if wantInst is true) and/or classmethods (if wantClass is true) |
|
6853 |
from classes in aCollectionOfClasses, where aBlock evaluates to true." |
|
6854 |
||
16449 | 6855 |
|list checkedClasses checkBlock nClasses |
6856 |
nClassesDone oldPercentage newPercentage nClassesSinceLastPercentage bulkSize| |
|
2675 | 6857 |
|
6858 |
checkedClasses := IdentitySet new. |
|
6859 |
list := OrderedCollection new. |
|
6860 |
||
6861 |
checkBlock := [:cls | |
|
6862 |
(checkedClasses includes:cls) ifFalse:[ |
|
8554
441ea25ad1fd
Do not complain about obsolete classes which are unloaded when searching
Stefan Vogel <sv@exept.de>
parents:
8505
diff
changeset
|
6863 |
(cls isObsolete and:[cls isLoaded]) ifTrue:[ |
17466 | 6864 |
Logger debug:'Browser method search: skipping obsolete class: %1' with:cls displayString |
2675 | 6865 |
] ifFalse:[ |
11941
55fec250ed02
changed: #findMethodsIn:inst:class:where:
Claus Gittinger <cg@exept.de>
parents:
11934
diff
changeset
|
6866 |
aBlock numArgs == 1 ifTrue:[ |
55fec250ed02
changed: #findMethodsIn:inst:class:where:
Claus Gittinger <cg@exept.de>
parents:
11934
diff
changeset
|
6867 |
cls methodDictionary keysAndValuesDo:[:sel :method | |
55fec250ed02
changed: #findMethodsIn:inst:class:where:
Claus Gittinger <cg@exept.de>
parents:
11934
diff
changeset
|
6868 |
(aBlock value:method) ifTrue:[ |
55fec250ed02
changed: #findMethodsIn:inst:class:where:
Claus Gittinger <cg@exept.de>
parents:
11934
diff
changeset
|
6869 |
list add:method "/ (cls name , ' ' , sel) |
55fec250ed02
changed: #findMethodsIn:inst:class:where:
Claus Gittinger <cg@exept.de>
parents:
11934
diff
changeset
|
6870 |
] |
55fec250ed02
changed: #findMethodsIn:inst:class:where:
Claus Gittinger <cg@exept.de>
parents:
11934
diff
changeset
|
6871 |
]. |
55fec250ed02
changed: #findMethodsIn:inst:class:where:
Claus Gittinger <cg@exept.de>
parents:
11934
diff
changeset
|
6872 |
] ifFalse:[ |
55fec250ed02
changed: #findMethodsIn:inst:class:where:
Claus Gittinger <cg@exept.de>
parents:
11934
diff
changeset
|
6873 |
cls methodDictionary keysAndValuesDo:[:sel :method | |
55fec250ed02
changed: #findMethodsIn:inst:class:where:
Claus Gittinger <cg@exept.de>
parents:
11934
diff
changeset
|
6874 |
(aBlock value:cls value:method value:sel) ifTrue:[ |
55fec250ed02
changed: #findMethodsIn:inst:class:where:
Claus Gittinger <cg@exept.de>
parents:
11934
diff
changeset
|
6875 |
list add:method "/ (cls name , ' ' , sel) |
55fec250ed02
changed: #findMethodsIn:inst:class:where:
Claus Gittinger <cg@exept.de>
parents:
11934
diff
changeset
|
6876 |
] |
55fec250ed02
changed: #findMethodsIn:inst:class:where:
Claus Gittinger <cg@exept.de>
parents:
11934
diff
changeset
|
6877 |
]. |
2675 | 6878 |
]. |
6879 |
checkedClasses add:cls. |
|
6880 |
] |
|
6881 |
] |
|
6882 |
]. |
|
6883 |
||
11506
bc0fc32fd733
changed: #findMethodsIn:inst:class:where:
Claus Gittinger <cg@exept.de>
parents:
11452
diff
changeset
|
6884 |
nClasses := aCollectionOfClasses size. |
bc0fc32fd733
changed: #findMethodsIn:inst:class:where:
Claus Gittinger <cg@exept.de>
parents:
11452
diff
changeset
|
6885 |
nClassesDone := 0. |
16238 | 6886 |
oldPercentage := 0. |
16449 | 6887 |
nClassesSinceLastPercentage := 0. |
6888 |
bulkSize := (nClasses // 30) max:10. "/ roughly every 3%. |
|
16238 | 6889 |
|
2675 | 6890 |
aCollectionOfClasses do:[:aClass | |
3008 | 6891 |
(aClass notNil and:[aClass isObsolete not]) ifTrue:[ |
16449 | 6892 |
nClassesSinceLastPercentage := nClassesSinceLastPercentage + 1. |
6893 |
||
2675 | 6894 |
" |
6895 |
output disabled - it slows down things too much (when searching for |
|
6896 |
implementors or senders) |
|
6897 |
" |
|
6898 |
wantInst ifTrue:[ |
|
6899 |
"/ Transcript show:'searching '; show:aClass name; showCR:' ...'; endEntry. |
|
6900 |
checkBlock value:aClass |
|
6901 |
]. |
|
6902 |
wantClass ifTrue:[ |
|
6903 |
"/ Transcript show:'searching '; show:aClass class name; showCR:' ...'; endEntry. |
|
6904 |
checkBlock value:(aClass class) |
|
6905 |
]. |
|
16449 | 6906 |
nClassesSinceLastPercentage > bulkSize ifTrue:[ |
11506
bc0fc32fd733
changed: #findMethodsIn:inst:class:where:
Claus Gittinger <cg@exept.de>
parents:
11452
diff
changeset
|
6907 |
"/ Processor yield |
16238 | 6908 |
newPercentage := nClassesDone * 100 // nClasses. |
6909 |
newPercentage ~= oldPercentage ifTrue:[ |
|
17440 | 6910 |
ProgressNotification progressPercentage:newPercentage statusInfo:('%1 found' bindWith:list size). |
16238 | 6911 |
oldPercentage := newPercentage. |
6912 |
]. |
|
16449 | 6913 |
nClassesSinceLastPercentage := 0. |
11506
bc0fc32fd733
changed: #findMethodsIn:inst:class:where:
Claus Gittinger <cg@exept.de>
parents:
11452
diff
changeset
|
6914 |
]. |
bc0fc32fd733
changed: #findMethodsIn:inst:class:where:
Claus Gittinger <cg@exept.de>
parents:
11452
diff
changeset
|
6915 |
]. |
bc0fc32fd733
changed: #findMethodsIn:inst:class:where:
Claus Gittinger <cg@exept.de>
parents:
11452
diff
changeset
|
6916 |
nClassesDone := nClassesDone + 1. |
2675 | 6917 |
]. |
6918 |
^ list |
|
11506
bc0fc32fd733
changed: #findMethodsIn:inst:class:where:
Claus Gittinger <cg@exept.de>
parents:
11452
diff
changeset
|
6919 |
|
17466 | 6920 |
"Modified: / 14-03-2017 / 12:05:57 / cg" |
2675 | 6921 |
! |
6922 |
||
6923 |
findMethodsIn:aCollectionOfClasses where:aBlock |
|
6924 |
"return all instance- and classmethods |
|
6925 |
from classes in aCollectionOfClasses, where aBlock evaluates to true." |
|
6926 |
||
6927 |
^ self |
|
6928 |
findMethodsIn:aCollectionOfClasses |
|
6929 |
inst:true |
|
6930 |
class:true |
|
6931 |
where:aBlock |
|
203 | 6932 |
! ! |
93 | 6933 |
|
820
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
6934 |
!SystemBrowser class methodsFor:'startup with query'! |
203 | 6935 |
|
6936 |
askThenBrowseClass |
|
6937 |
self getClassThenPerform:#browseClass: |
|
6938 |
||
6939 |
" |
|
6940 |
SystemBrowser askThenBrowseClass |
|
13028 | 6941 |
Tools::NewSystemBrowser askThenBrowseClass |
203 | 6942 |
" |
93 | 6943 |
! |
6944 |
||
203 | 6945 |
askThenBrowseClassHierarchy |
6946 |
self getClassThenPerform:#browseClassHierarchy: |
|
36 | 6947 |
|
203 | 6948 |
" |
6949 |
SystemBrowser askThenBrowseClassHierarchy |
|
13028 | 6950 |
Tools::NewSystemBrowser askThenBrowseClassHierarchy |
203 | 6951 |
" |
36 | 6952 |
! |
6953 |
||
203 | 6954 |
askThenBrowseFullClassProtocol |
6955 |
self getClassThenPerform:#browseFullClassProtocol: |
|
36 | 6956 |
|
203 | 6957 |
" |
6958 |
SystemBrowser askThenBrowseFullClassProtocol |
|
13028 | 6959 |
Tools::NewSystemBrowser askThenBrowseFullClassProtocol |
6960 |
" |
|
36 | 6961 |
! ! |
6962 |
||
2813 | 6963 |
!SystemBrowser class methodsFor:'utilities'! |
6964 |
||
13028 | 6965 |
askForClass |
13032 | 6966 |
^ self askForClassWithFilter:nil |
13028 | 6967 |
|
6968 |
" |
|
6969 |
Tools::NewSystemBrowser askForClass |
|
6970 |
" |
|
6971 |
! |
|
6972 |
||
6973 |
askForClassName |
|
13032 | 6974 |
^ self askForClassNameWithFilter:nil |
6975 |
||
6976 |
" |
|
6977 |
Tools::NewSystemBrowser askForClassName |
|
6978 |
" |
|
6979 |
! |
|
6980 |
||
6981 |
askForClassNameWithFilter:filterOrNil |
|
13028 | 6982 |
self |
6983 |
askForClassToSearch:nil |
|
6984 |
single:true |
|
6985 |
msgTail:'' |
|
6986 |
resources:(self classResources) |
|
13032 | 6987 |
filter:filterOrNil |
13028 | 6988 |
forBrowser:nil |
6989 |
thenDo:[:className :single :doWhat | |
|
6990 |
^ className |
|
6991 |
]. |
|
6992 |
^ nil |
|
6993 |
||
6994 |
" |
|
6995 |
Tools::NewSystemBrowser askForClassName |
|
6996 |
" |
|
6997 |
! |
|
6998 |
||
13032 | 6999 |
askForClassToSearch:doWhatByDefault single:singleClass msgTail:msgTail resources:resourcesOrNil filter:filterOrNil forBrowser:aBrowserOrNil thenDo:aBlock |
13028 | 7000 |
"utility common code for both opening a new browser on a class and |
7001 |
to search for a class in an existing browser. |
|
7002 |
If singleClass is true, a single class will be asked for and browsed, |
|
7003 |
otherwise, a match pattern is allowed and a multi-class browser is opened. |
|
7004 |
Moved from instance protocol for better reusability." |
|
7005 |
||
7006 |
|box boxLabel title okText className canFind doWhat classNameHolder updateList |
|
7007 |
allClasses classNamesInChangeSet |
|
7008 |
allNames allFullNames initialShortNames initialFullNames |
|
7009 |
colorizedFullNames colorizedShortNames |
|
7010 |
resources check showingWhatLabel showFullNameHolder genShortNameListEntry| |
|
7011 |
||
7012 |
resources := resourcesOrNil ? self classResources. |
|
7013 |
showFullNameHolder := (LastClassSearchBoxShowedFullName ? false) asValue. |
|
7014 |
||
7015 |
doWhat := doWhatByDefault. |
|
7016 |
canFind := false. |
|
7017 |
||
7018 |
title := ''. |
|
7019 |
boxLabel := (resources string:'Select a class'). |
|
7020 |
okText := 'OK'. |
|
7021 |
||
7022 |
genShortNameListEntry := |
|
7023 |
[:cls | |
|
7024 |
|ns| |
|
13035 | 7025 |
|
13028 | 7026 |
cls isNil ifTrue:[ |
7027 |
nil |
|
7028 |
] ifFalse:[ |
|
13035 | 7029 |
(filterOrNil notNil and:[ (filterOrNil value:cls) not]) ifTrue:[ |
7030 |
nil |
|
7031 |
] ifFalse:[ |
|
7032 |
ns := cls topNameSpace name. |
|
7033 |
ns = 'Smalltalk' |
|
7034 |
ifTrue:[ ns := '' ] |
|
7035 |
ifFalse:[ns := ' (in ',ns,')']. |
|
7036 |
cls nameWithoutNameSpacePrefix,ns |
|
7037 |
] |
|
13028 | 7038 |
]. |
7039 |
]. |
|
7040 |
||
7041 |
classNamesInChangeSet := ChangeSet current changedClasses |
|
13035 | 7042 |
select: (filterOrNil ? [:cls | true]) |
7043 |
thenCollect:[:each | each theNonMetaclass name]. |
|
13028 | 7044 |
|
7045 |
initialFullNames := self visitedClassNamesHistory. |
|
13035 | 7046 |
(filterOrNil notNil) ifTrue:[ |
7047 |
initialFullNames := initialFullNames select:[:nm | filterOrNil value:(Smalltalk at:nm)]. |
|
7048 |
]. |
|
13028 | 7049 |
initialShortNames := initialFullNames collect:[:nm | genShortNameListEntry value:(Smalltalk at:nm)] thenSelect:[:nm | nm notNil]. |
7050 |
||
7051 |
colorizedFullNames := initialFullNames collect:[:clsName | |
|
7052 |
(classNamesInChangeSet includes:clsName) ifTrue:[ |
|
7053 |
clsName asText emphasisAllAdd:(UserPreferences current emphasisForChangedCode) |
|
7054 |
] ifFalse:[ |
|
7055 |
clsName |
|
7056 |
]. |
|
7057 |
]. |
|
7058 |
||
7059 |
colorizedShortNames := initialShortNames with:initialFullNames collect:[:shortName :clsName | |
|
7060 |
(classNamesInChangeSet includes:clsName) ifTrue:[ |
|
7061 |
shortName asText emphasisAllAdd:(UserPreferences current emphasisForChangedCode) |
|
7062 |
] ifFalse:[ |
|
7063 |
shortName |
|
7064 |
]. |
|
7065 |
]. |
|
7066 |
||
13046 | 7067 |
title := (resources string:title) , msgTail , '.\' , (resources string:'(TAB to complete; matchPattern allowed - "*" for all):'). |
13028 | 7068 |
|
7069 |
box := self |
|
7070 |
enterBoxForClassWithCodeSelectionTitle:title withCRs |
|
7071 |
withList:(showFullNameHolder value ifTrue:[colorizedFullNames] ifFalse:[colorizedShortNames]) |
|
7072 |
okText:okText |
|
7073 |
forBrowser:nil. |
|
7074 |
||
7075 |
box label:boxLabel. |
|
7076 |
||
7077 |
allClasses := Smalltalk allClasses copyAsOrderedCollection. |
|
13032 | 7078 |
filterOrNil notNil ifTrue:[ |
7079 |
allClasses := allClasses select: filterOrNil |
|
7080 |
]. |
|
13028 | 7081 |
|
7082 |
allNames := (allClasses |
|
7083 |
collect:[:cls | |
|
7084 |
|ns nm| |
|
7085 |
||
7086 |
ns := cls topNameSpace name. |
|
7087 |
ns = 'Smalltalk' |
|
7088 |
ifTrue:[ ns := '' ] |
|
7089 |
ifFalse:[ns := ' (in ',ns,')']. |
|
7090 |
cls isNameSpace ifTrue:[ |
|
7091 |
nm := cls nameWithoutNameSpacePrefix,ns,' (Namespace)' |
|
7092 |
] ifFalse:[ |
|
7093 |
nm := cls nameWithoutNameSpacePrefix,ns |
|
7094 |
]. |
|
7095 |
(classNamesInChangeSet includes:cls name) ifTrue:[ |
|
7096 |
nm asText emphasisAllAdd:(UserPreferences current emphasisForChangedCode) |
|
7097 |
] ifFalse:[ |
|
7098 |
nm |
|
7099 |
]. |
|
7100 |
]) sortWith:allClasses; yourself. |
|
7101 |
||
7102 |
allFullNames := (allClasses |
|
7103 |
collect:[:cls | |
|
7104 |
|nm| |
|
7105 |
||
7106 |
nm := cls name. |
|
7107 |
(classNamesInChangeSet includes:cls name) ifTrue:[ |
|
7108 |
nm asText emphasisAllAdd:(UserPreferences current emphasisForChangedCode) |
|
7109 |
] ifFalse:[ |
|
7110 |
nm |
|
7111 |
]. |
|
7112 |
]) sortWith:allClasses; yourself. |
|
7113 |
||
7114 |
updateList := [ |
|
7115 |
|nameToSearch list namesStarting namesIncluding lcName nameList| |
|
7116 |
||
7117 |
(nameToSearch := classNameHolder value withoutSeparators) isEmpty ifTrue:[ |
|
7118 |
showingWhatLabel label:(resources string:'Recently visited:'). |
|
7119 |
list := (showFullNameHolder value ifTrue:[colorizedFullNames] ifFalse:[colorizedShortNames]). |
|
7120 |
] ifFalse:[ |
|
7121 |
showingWhatLabel label:(resources string:'Matching classes:'). |
|
7122 |
nameList := showFullNameHolder value |
|
7123 |
ifTrue:[ allFullNames ] |
|
7124 |
ifFalse:[ allNames ]. |
|
7125 |
||
7126 |
lcName := nameToSearch asLowercase. |
|
7127 |
(lcName includesString:'::') ifTrue:[ |
|
7128 |
list := OrderedCollection new. |
|
7129 |
allClasses doWithIndex:[:cls :idx | |
|
7130 |
|isIncluded| |
|
7131 |
||
7132 |
(nameToSearch includesMatchCharacters) ifTrue:[ |
|
7133 |
isIncluded := (lcName match:cls name asLowercase) |
|
7134 |
] ifFalse:[ |
|
7135 |
isIncluded := (cls name includesString:lcName caseSensitive:false) |
|
7136 |
]. |
|
7137 |
isIncluded ifTrue:[ |
|
7138 |
list add:(nameList at:idx) |
|
7139 |
]. |
|
7140 |
]. |
|
7141 |
] ifFalse:[ |
|
7142 |
(nameToSearch includesMatchCharacters) ifTrue:[ |
|
7143 |
list := nameList select:[:nm | lcName match:nm asLowercase] |
|
7144 |
] ifFalse:[ |
|
7145 |
namesIncluding := nameList |
|
7146 |
select:[:nm | |
|
7147 |
"/ nm asLowercase startsWith:lcName |
|
7148 |
nm asLowercase includesString:lcName caseSensitive:false |
|
7149 |
]. |
|
7150 |
namesStarting := namesIncluding select:[:nm | nm asLowercase startsWith:lcName]. |
|
7151 |
list := namesStarting , {nil} , (namesIncluding \ namesStarting). |
|
7152 |
] |
|
7153 |
] |
|
7154 |
]. |
|
7155 |
box listView |
|
7156 |
list:list; |
|
7157 |
scrollToLine:((list findFirst:[:line | (line ? '') startsWith:lcName]) max:1) |
|
7158 |
]. |
|
7159 |
||
7160 |
classNameHolder := '' asValue. |
|
7161 |
box enterField |
|
7162 |
model:classNameHolder; |
|
7163 |
immediateAccept:true. |
|
7164 |
classNameHolder onChangeEvaluate:updateList. |
|
7165 |
||
7166 |
box entryCompletionBlock:(DoWhatIMeanSupport classNameEntryCompletionBlock). |
|
7167 |
box action:[:aString | className := aString]. |
|
7168 |
||
7169 |
box panelView |
|
7170 |
addSubView:(showingWhatLabel := (Label label:(resources string:'Recently visited:')) adjust:#left) before:nil; |
|
7171 |
addSubView:(check := CheckBox label:(resources string:'Show Full Name (do not strip off Namespace)') model:showFullNameHolder) before:nil. |
|
7172 |
showFullNameHolder onChangeEvaluate:updateList. |
|
7173 |
box enterField origin:(0 @ check corner y). |
|
7174 |
box listView origin:(0 @ check corner y). |
|
7175 |
||
7176 |
box extent:(400 @ 350). |
|
7177 |
box open. |
|
7178 |
||
7179 |
className isEmptyOrNil ifTrue:[^ nil "cancel"]. |
|
7180 |
||
7181 |
LastClassSearchBoxShowedFullName := showFullNameHolder value. |
|
7182 |
||
7183 |
(className endsWith:$) ) ifTrue:[ |
|
7184 |
(className indexOfSubCollection:'(in ') == 0 ifTrue:[ |
|
7185 |
"/ a namespace |
|
7186 |
className := (className copyTo:(className indexOfSubCollection:'(Name')-1) withoutSeparators |
|
7187 |
] ifFalse:[ |
|
7188 |
className := ((className copyFrom:(className indexOfSubCollection:'(in ')+4) |
|
7189 |
copyButLast:1) |
|
7190 |
, '::' , className asCollectionOfWords first |
|
7191 |
]. |
|
7192 |
]. |
|
7193 |
||
7194 |
aBlock notNil ifTrue:[aBlock value:className optionalArgument:singleClass and:doWhat]. |
|
7195 |
^ className |
|
7196 |
||
7197 |
"Modified: / 23-07-2012 / 11:00:22 / cg" |
|
7198 |
! |
|
7199 |
||
13032 | 7200 |
askForClassWithFilter:filterOrNil |
7201 |
|className| |
|
7202 |
||
7203 |
className := self askForClassNameWithFilter:filterOrNil. |
|
7204 |
className notEmptyOrNil ifTrue:[ |
|
7205 |
^ Smalltalk classNamed:className |
|
7206 |
]. |
|
7207 |
^ nil |
|
7208 |
||
7209 |
" |
|
7210 |
Tools::NewSystemBrowser askForClass |
|
7211 |
" |
|
7212 |
! |
|
7213 |
||
3833 | 7214 |
classWithNameSimilarTo:className |
7215 |
"helper for class-name entry; finds a class by name tolerant w.r.t. case" |
|
7216 |
||
4924
0d39bbc7203e
better search-class heuristics
Claus Gittinger <cg@exept.de>
parents:
4921
diff
changeset
|
7217 |
|allMatchingClasses| |
0d39bbc7203e
better search-class heuristics
Claus Gittinger <cg@exept.de>
parents:
4921
diff
changeset
|
7218 |
|
0d39bbc7203e
better search-class heuristics
Claus Gittinger <cg@exept.de>
parents:
4921
diff
changeset
|
7219 |
allMatchingClasses := self classesWithNameSimilarTo:className. |
0d39bbc7203e
better search-class heuristics
Claus Gittinger <cg@exept.de>
parents:
4921
diff
changeset
|
7220 |
^ allMatchingClasses firstIfEmpty:nil |
0d39bbc7203e
better search-class heuristics
Claus Gittinger <cg@exept.de>
parents:
4921
diff
changeset
|
7221 |
! |
0d39bbc7203e
better search-class heuristics
Claus Gittinger <cg@exept.de>
parents:
4921
diff
changeset
|
7222 |
|
0d39bbc7203e
better search-class heuristics
Claus Gittinger <cg@exept.de>
parents:
4921
diff
changeset
|
7223 |
classesWithNameSimilarTo:className |
0d39bbc7203e
better search-class heuristics
Claus Gittinger <cg@exept.de>
parents:
4921
diff
changeset
|
7224 |
"helper for class-name entry; finds a class by name tolerant w.r.t. case" |
0d39bbc7203e
better search-class heuristics
Claus Gittinger <cg@exept.de>
parents:
4921
diff
changeset
|
7225 |
|
6944 | 7226 |
^ self classesWithNameSimilarTo:className from:nil |
7227 |
||
7228 |
"Modified: / 22-08-2006 / 13:22:41 / cg" |
|
7229 |
! |
|
7230 |
||
7231 |
classesWithNameSimilarTo:className from:aNameSpaceOrNil |
|
7232 |
"helper for class-name entry; finds classes with a name similar to the argument, className" |
|
7233 |
||
7234 |
|nm lcName class allClasses triedDetectors triedMatchers allMatchingClasses |
|
7235 |
prefNameSpaceOrNil prefLcNameSpace| |
|
7236 |
||
7237 |
prefNameSpaceOrNil := (aNameSpaceOrNil == Smalltalk) ifTrue:[ nil ] ifFalse:[aNameSpaceOrNil]. |
|
3833 | 7238 |
|
12747 | 7239 |
nm := className withoutPrefix:'Smalltalk::'. |
3833 | 7240 |
|
6944 | 7241 |
prefNameSpaceOrNil notNil ifTrue:[ |
7242 |
class := prefNameSpaceOrNil at:nm asSymbol. |
|
7243 |
class isBehavior ifTrue:[^ Array with:class]. "/ a direct hit |
|
7244 |
prefLcNameSpace := prefNameSpaceOrNil name asLowercase. |
|
7245 |
]. |
|
3833 | 7246 |
class := Smalltalk at:nm asSymbol. |
4924
0d39bbc7203e
better search-class heuristics
Claus Gittinger <cg@exept.de>
parents:
4921
diff
changeset
|
7247 |
class isBehavior ifTrue:[^ Array with:class]. "/ a direct hit |
3833 | 7248 |
|
7249 |
lcName := className asLowercase. |
|
4924
0d39bbc7203e
better search-class heuristics
Claus Gittinger <cg@exept.de>
parents:
4921
diff
changeset
|
7250 |
|
3833 | 7251 |
allClasses := Smalltalk allClasses. |
4806 | 7252 |
|
6134 | 7253 |
triedDetectors := OrderedCollection new. |
7254 |
triedDetectors add:[:cls | cls name asLowercase = lcName]. |
|
7255 |
||
7256 |
triedDetectors do:[:eachTry | |
|
7257 |
|class| |
|
7258 |
||
7259 |
class := allClasses detect:eachTry ifNone:nil. |
|
7260 |
class notNil ifTrue:[^ Array with:class]. |
|
7261 |
]. |
|
7262 |
||
4806 | 7263 |
triedMatchers := OrderedCollection new. |
5018
2fe02eac49c5
better classesWithNameSimilarTo
Claus Gittinger <cg@exept.de>
parents:
4924
diff
changeset
|
7264 |
triedMatchers add:[:cls | cls nameWithoutPrefix asLowercase = lcName]. |
2fe02eac49c5
better classesWithNameSimilarTo
Claus Gittinger <cg@exept.de>
parents:
4924
diff
changeset
|
7265 |
triedMatchers add:[:cls | cls nameWithoutNameSpacePrefix asLowercase = lcName]. |
4924
0d39bbc7203e
better search-class heuristics
Claus Gittinger <cg@exept.de>
parents:
4921
diff
changeset
|
7266 |
|
4806 | 7267 |
triedMatchers add:[:cls | cls name asLowercase startsWith:lcName]. |
7268 |
triedMatchers add:[:cls | cls nameWithoutNameSpacePrefix asLowercase startsWith:lcName]. |
|
7269 |
triedMatchers add:[:cls | cls nameWithoutPrefix asLowercase startsWith:lcName]. |
|
7270 |
triedMatchers add:[:cls | cls nameWithoutPrefix asLowercase includesString:lcName]. |
|
6134 | 7271 |
triedMatchers add:[:cls | cls name asLowercase includesString:lcName]. |
4924
0d39bbc7203e
better search-class heuristics
Claus Gittinger <cg@exept.de>
parents:
4921
diff
changeset
|
7272 |
|
0d39bbc7203e
better search-class heuristics
Claus Gittinger <cg@exept.de>
parents:
4921
diff
changeset
|
7273 |
allMatchingClasses := IdentitySet new. |
0d39bbc7203e
better search-class heuristics
Claus Gittinger <cg@exept.de>
parents:
4921
diff
changeset
|
7274 |
triedMatchers do:[:eachTry | |
0d39bbc7203e
better search-class heuristics
Claus Gittinger <cg@exept.de>
parents:
4921
diff
changeset
|
7275 |
|matchingClasses| |
0d39bbc7203e
better search-class heuristics
Claus Gittinger <cg@exept.de>
parents:
4921
diff
changeset
|
7276 |
|
0d39bbc7203e
better search-class heuristics
Claus Gittinger <cg@exept.de>
parents:
4921
diff
changeset
|
7277 |
matchingClasses := allClasses select:eachTry. |
6944 | 7278 |
"/ matchingClasses size == 1 ifTrue:[^ matchingClasses]. |
4924
0d39bbc7203e
better search-class heuristics
Claus Gittinger <cg@exept.de>
parents:
4921
diff
changeset
|
7279 |
allMatchingClasses addAll:matchingClasses. |
0d39bbc7203e
better search-class heuristics
Claus Gittinger <cg@exept.de>
parents:
4921
diff
changeset
|
7280 |
]. |
0d39bbc7203e
better search-class heuristics
Claus Gittinger <cg@exept.de>
parents:
4921
diff
changeset
|
7281 |
allMatchingClasses isEmpty ifTrue:[^ #()]. |
0d39bbc7203e
better search-class heuristics
Claus Gittinger <cg@exept.de>
parents:
4921
diff
changeset
|
7282 |
|
0d39bbc7203e
better search-class heuristics
Claus Gittinger <cg@exept.de>
parents:
4921
diff
changeset
|
7283 |
allMatchingClasses := allMatchingClasses asOrderedCollection. |
6944 | 7284 |
allMatchingClasses |
7285 |
sort:[:a :b | |
|
7286 |
|lcNameA lcNameB da db distA distB | |
|
7287 |
||
7288 |
lcNameA := a name asLowercase. |
|
7289 |
lcNameB := b name asLowercase. |
|
7290 |
prefNameSpaceOrNil notNil ifTrue:[ |
|
7291 |
a nameSpace == prefNameSpaceOrNil ifTrue:[ |
|
7292 |
lcNameA := a nameWithoutNameSpacePrefix asLowercase. |
|
7293 |
]. |
|
7294 |
b nameSpace == prefNameSpaceOrNil ifTrue:[ |
|
7295 |
lcNameB := b nameWithoutNameSpacePrefix asLowercase. |
|
7296 |
]. |
|
7297 |
]. |
|
7298 |
||
7299 |
distA := da := lcName levenshteinTo:lcNameA. |
|
7300 |
distB := db := lcName levenshteinTo:lcNameB. |
|
7301 |
"prefer prefixes (i.e. classes whose name starts with what we search for)" |
|
7302 |
||
7303 |
(lcNameA startsWith:lcName) ifTrue:[ |
|
7304 |
distB := distB * 2 |
|
7305 |
]. |
|
7306 |
(lcNameB startsWith:lcName) ifTrue:[ |
|
7307 |
distA := distA * 2 |
|
7308 |
]. |
|
7309 |
distA < distB |
|
7310 |
]. |
|
4924
0d39bbc7203e
better search-class heuristics
Claus Gittinger <cg@exept.de>
parents:
4921
diff
changeset
|
7311 |
^ allMatchingClasses. |
6546 | 7312 |
|
7313 |
" |
|
6678 | 7314 |
self classesWithNameSimilarTo:'NewSystemBrowser' |
7315 |
self classesWithNameSimilarTo:'Moose::MSEAbstractOperator' |
|
6546 | 7316 |
" |
6944 | 7317 |
|
7318 |
"Created: / 22-08-2006 / 13:22:48 / cg" |
|
7319 |
"Modified: / 22-08-2006 / 14:53:38 / cg" |
|
3833 | 7320 |
! |
7321 |
||
13028 | 7322 |
enterBoxForClassWithCodeSelectionTitle:title withList:listOrNil okText:okText forBrowser:aBrowserOrNil |
7323 |
"convenient method: setup an enterBox with initial text taken |
|
17605 | 7324 |
from the codeview's selection." |
13028 | 7325 |
|
7326 |
|sel box initialText superclass currentClass |
|
7327 |
methods someMethod offeredClass anyClose closeName s usedGlobals list| |
|
7328 |
||
7329 |
list := listOrNil. |
|
7330 |
||
7331 |
aBrowserOrNil notNil ifTrue:[ |
|
7332 |
currentClass := aBrowserOrNil theSingleSelectedClass. |
|
7333 |
||
7334 |
sel := aBrowserOrNil selectionInCodeView. |
|
7335 |
sel notNil ifTrue:[ |
|
7336 |
aBrowserOrNil selectedNamespacesValue doWithExit:[:eachNs :exit | |
|
7337 |
s := eachNs , '::' , sel asSymbol. |
|
7338 |
(s knownAsSymbol |
|
7339 |
and:[(Smalltalk at:s asSymbol) isBehavior]) ifTrue:[ |
|
7340 |
"/ a private class of current ... |
|
7341 |
sel := eachNs , '::' , sel asSymbol. |
|
7342 |
exit value:nil. |
|
7343 |
]. |
|
7344 |
]. |
|
7345 |
(sel knownAsSymbol and:[currentClass notNil |
|
7346 |
and:[(currentClass theNonMetaclass privateClassesAt:sel asSymbol) notNil]]) ifTrue:[ |
|
7347 |
"/ a private class of current ... |
|
7348 |
sel := (currentClass theNonMetaclass privateClassesAt:sel asSymbol) name |
|
7349 |
] ifFalse:[ |
|
7350 |
(sel knownAsSymbol and:[(Smalltalk at:sel asSymbol) isBehavior]) ifFalse:[ |
|
7351 |
"/ ignore it, if there is no class-name which comes close. |
|
7352 |
anyClose := false. |
|
7353 |
Smalltalk keysAndValuesDo:[:aGlobalName :aGlobal| |
|
7354 |
aGlobal isBehavior ifTrue:[ |
|
7355 |
aGlobal isMeta ifFalse:[ |
|
7356 |
aGlobal name == aGlobalName ifTrue:[ |
|
7357 |
((aGlobalName startsWith:sel) |
|
7358 |
or:[(sel startsWith:aGlobalName)]) ifTrue:[ |
|
7359 |
closeName isNil ifTrue:[closeName := aGlobalName]. |
|
7360 |
anyClose := true. |
|
7361 |
] |
|
7362 |
] |
|
7363 |
] |
|
7364 |
] |
|
7365 |
]. |
|
7366 |
anyClose ifFalse:[ |
|
7367 |
sel := nil |
|
7368 |
] ifTrue:[ |
|
7369 |
sel := closeName |
|
7370 |
] |
|
7371 |
] |
|
7372 |
] |
|
7373 |
]. |
|
7374 |
||
7375 |
sel notNil ifTrue:[ |
|
7376 |
initialText := sel asString withoutSeparators |
|
7377 |
] ifFalse:[ |
|
7378 |
aBrowserOrNil codeAspect == SyntaxHighlighter codeAspectMethod ifTrue:[ |
|
7379 |
methods := aBrowserOrNil selectedMethodsValue. |
|
7380 |
methods size > 0 ifTrue:[ |
|
7381 |
someMethod := methods first. |
|
7382 |
usedGlobals := someMethod usedGlobals collect:[:eachVar | eachVar asSymbol]. |
|
7383 |
usedGlobals := usedGlobals select:[:eachVar | (Smalltalk at:eachVar) isBehavior]. |
|
7384 |
usedGlobals size > 0 ifTrue:[ |
|
7385 |
list := list reject:[:each | usedGlobals includes:each ]. |
|
7386 |
list := usedGlobals asOrderedCollection sort , list. |
|
7387 |
offeredClass := Smalltalk at:usedGlobals first |
|
7388 |
] ifFalse:[ |
|
7389 |
offeredClass := someMethod mclass |
|
7390 |
] |
|
7391 |
] |
|
7392 |
] ifFalse:[ |
|
7393 |
(aBrowserOrNil navigationState isVersionDiffBrowser |
|
7394 |
or:[aBrowserOrNil navigationState isClassDocumentationBrowser]) ifTrue:[ |
|
7395 |
offeredClass := currentClass. |
|
7396 |
(offeredClass notNil and:[offeredClass isPrivate]) ifTrue:[ |
|
7397 |
offeredClass := offeredClass owningClass |
|
7398 |
] |
|
7399 |
] ifFalse:[ |
|
7400 |
(currentClass notNil |
|
7401 |
and:[(superclass := currentClass superclass) notNil]) ifTrue:[ |
|
7402 |
offeredClass := superclass |
|
7403 |
] |
|
7404 |
] |
|
7405 |
]. |
|
7406 |
offeredClass notNil ifTrue:[ |
|
7407 |
initialText := offeredClass theNonMetaclass name |
|
7408 |
] |
|
7409 |
]. |
|
7410 |
]. |
|
7411 |
||
7412 |
box := self |
|
7413 |
enterBoxTitle:(self classResources string:title) |
|
7414 |
withList:list |
|
7415 |
okText:(self classResources string:okText). |
|
7416 |
||
7417 |
initialText notNil ifTrue:[ |
|
7418 |
box initialText:initialText |
|
7419 |
]. |
|
7420 |
^ box |
|
7421 |
||
7422 |
"Created: / 13-02-2000 / 20:56:18 / cg" |
|
7423 |
"Modified: / 27-07-2012 / 22:18:34 / cg" |
|
17605 | 7424 |
"Modified (comment): / 27-07-2017 / 12:58:02 / cg" |
13028 | 7425 |
! |
7426 |
||
7427 |
enterBoxTitle:title withList:aListOrNil okText:okText |
|
7428 |
"convenient method: setup enterBox" |
|
7429 |
||
7430 |
|box rsrcs| |
|
7431 |
||
7432 |
aListOrNil notNil ifTrue:[ |
|
7433 |
box := ListSelectionBox new. |
|
7434 |
"/ box := EnterBoxWithList new. |
|
7435 |
box list:aListOrNil. |
|
7436 |
] ifFalse:[ |
|
7437 |
box := EnterBox new. |
|
7438 |
]. |
|
7439 |
rsrcs := self classResources. |
|
7440 |
box title:(rsrcs string:title) okText:(rsrcs string:okText). |
|
7441 |
^ box |
|
7442 |
||
7443 |
" |
|
7444 |
self enterBoxTitle:'bla' withList:#('a' 'b' 'c') okText:'gaga' |
|
7445 |
" |
|
7446 |
||
7447 |
"Created: / 13.2.2000 / 20:53:53 / cg" |
|
7448 |
"Modified: / 1.3.2000 / 11:15:09 / cg" |
|
7449 |
! |
|
7450 |
||
2813 | 7451 |
extractClassAndSelectorFrom:aString into:aBlock |
7452 |
"given a string which can be either 'class>>sel' or |
|
7453 |
'class sel', extract className and selector, and call aBlock with |
|
7454 |
the result. |
|
7455 |
Useful to open browser on a method as selected in some documentation." |
|
7456 |
||
7457 |
|sel clsName isMeta sep s| |
|
7458 |
||
7459 |
sel := aString. |
|
7460 |
sel notNil ifTrue:[ |
|
7461 |
sel := sel asString withoutSeparators. |
|
7462 |
('*>>*' match:sel) ifTrue:[ |
|
7463 |
sep := $> |
|
7464 |
] ifFalse:[ |
|
19235 | 7465 |
('*ยป*' match:sel) ifTrue:[ |
7466 |
sep := $ยป |
|
16529 | 7467 |
] ifFalse:[ |
7468 |
('* *' match:sel) ifTrue:[ |
|
7469 |
sep := Character space |
|
7470 |
] |
|
7471 |
]. |
|
2813 | 7472 |
]. |
7473 |
sep notNil ifTrue:[ |
|
7474 |
" |
|
7475 |
extract class/sel from selection |
|
7476 |
" |
|
7477 |
s := ReadStream on:sel. |
|
16529 | 7478 |
clsName := (s upTo:sep) withoutSeparators. |
2813 | 7479 |
[s peek == sep] whileTrue:[s next]. |
16529 | 7480 |
sel := (s upToEnd) withoutSeparators. |
2813 | 7481 |
|
7482 |
(clsName endsWith:' class') ifTrue:[ |
|
7483 |
isMeta := true. |
|
12713
7cccc4a7733c
Changed usage of deprecated #copyWithoutLast: to #copyButLast:
Stefan Vogel <sv@exept.de>
parents:
12631
diff
changeset
|
7484 |
clsName := clsName copyButLast:6 "copyTo:(clsName size - 5)" |
2813 | 7485 |
] ifFalse:[ |
7486 |
isMeta := false |
|
7487 |
]. |
|
7488 |
] |
|
7489 |
]. |
|
7490 |
aBlock value:clsName value:sel value:isMeta |
|
7491 |
||
7492 |
"Modified: / 17.6.1996 / 16:52:14 / stefan" |
|
7493 |
"Created: / 6.2.2000 / 00:51:51 / cg" |
|
7494 |
"Modified: / 6.2.2000 / 00:56:43 / cg" |
|
7495 |
! |
|
7496 |
||
7497 |
extractSelectorFrom:aString |
|
7498 |
"given an arbitrary string, try to extract a useful selector. |
|
7499 |
Useful to open browser on a selected code fragment." |
|
7500 |
||
16529 | 7501 |
|s sel sel2 t idx| |
7502 |
||
7503 |
aString isEmptyOrNil ifTrue:[^ nil]. |
|
7504 |
||
19235 | 7505 |
(idx := aString indexOf:$ยป) ~~ 0 ifTrue:[ |
16529 | 7506 |
s := (aString copyFrom:idx+1) withoutSeparators. |
7507 |
s isEmpty ifTrue:[^ nil]. |
|
7508 |
] ifFalse:[ |
|
7509 |
s := aString asString string withoutSeparators. |
|
7510 |
]. |
|
15976 | 7511 |
sel := s asSymbolIfInterned. |
7512 |
sel isNil ifTrue:[ |
|
7513 |
sel := s. |
|
7514 |
] ifFalse:[ |
|
7515 |
(sel endsWith:$:) ifTrue:[ |
|
7516 |
^ sel. |
|
7517 |
]. |
|
6705 | 7518 |
]. |
7519 |
||
2813 | 7520 |
t := Parser selectorInExpression:sel. |
7521 |
t notNil ifTrue:[ |
|
7522 |
sel := t |
|
7523 |
]. |
|
16529 | 7524 |
(sel = s or:[sel isNil or:[t == #'>>']]) ifTrue:[ |
16863 | 7525 |
"oops - that's probably not what we want here ..." |
2813 | 7526 |
self extractClassAndSelectorFrom:s into:[:c :s :m | |
7527 |
sel := s |
|
7528 |
] |
|
7529 |
]. |
|
15976 | 7530 |
s := sel asSymbolIfInterned. |
7531 |
s notNil ifTrue:[ |
|
7532 |
^ s. |
|
7533 |
]. |
|
7534 |
||
7535 |
(sel startsWith:$#) ifTrue:[ |
|
7536 |
sel2 := sel copyFrom:2. |
|
18317 | 7537 |
((sel2 startsWith:$') and:[(sel2 endsWith:$') and:[sel2 size > 2]]) ifTrue:[ |
15976 | 7538 |
sel2 := (sel2 copyFrom:2) copyButLast:1 |
7539 |
]. |
|
7540 |
(sel2 := sel2 asSymbolIfInterned) notNil ifTrue:[ |
|
7541 |
^ sel2. |
|
8047
8bc319ff9ba7
better title in implementorsOfAny
Claus Gittinger <cg@exept.de>
parents:
7998
diff
changeset
|
7542 |
]. |
8bc319ff9ba7
better title in implementorsOfAny
Claus Gittinger <cg@exept.de>
parents:
7998
diff
changeset
|
7543 |
]. |
8bc319ff9ba7
better title in implementorsOfAny
Claus Gittinger <cg@exept.de>
parents:
7998
diff
changeset
|
7544 |
|
2813 | 7545 |
^ sel |
7546 |
||
7547 |
" |
|
7548 |
self extractSelectorFrom:'at:put:' |
|
7549 |
self extractSelectorFrom:'#at:put:' |
|
15976 | 7550 |
self extractSelectorFrom:'#''at:put:''' |
2813 | 7551 |
self extractSelectorFrom:'at:something put:someValue' |
7552 |
self extractSelectorFrom:'self at:something put:someValue' |
|
7553 |
self extractSelectorFrom:'(self at:something put:someValue)' |
|
7554 |
self extractSelectorFrom:'[self at:something put:someValue] value' |
|
19235 | 7555 |
self extractSelectorFrom:'Array ยป at:put:' |
2813 | 7556 |
self extractSelectorFrom:'Array>>at:put:' |
15976 | 7557 |
self extractSelectorFrom:'Array>>#at:put:' |
7558 |
self extractSelectorFrom:'Array>>#''at:put:''' |
|
2813 | 7559 |
" |
7560 |
||
18317 | 7561 |
"Created: / 06-02-2000 / 00:49:44 / cg" |
7562 |
"Modified: / 04-08-2018 / 16:54:20 / Claus Gittinger" |
|
6560
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
7563 |
! |
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
7564 |
|
13028 | 7565 |
getClassThenPerform:aSelector |
18615
eb18306788b0
Fix usage of unser var "resources"
Stefan Vogel <sv@exept.de>
parents:
18614
diff
changeset
|
7566 |
|classNameEntered classEntered enterBox resources| |
13028 | 7567 |
|
7568 |
"/ new Code: |
|
7569 |
classNameEntered := self askForClassName. |
|
7570 |
||
18615
eb18306788b0
Fix usage of unser var "resources"
Stefan Vogel <sv@exept.de>
parents:
18614
diff
changeset
|
7571 |
resources := self classResources. |
eb18306788b0
Fix usage of unser var "resources"
Stefan Vogel <sv@exept.de>
parents:
18614
diff
changeset
|
7572 |
|
eb18306788b0
Fix usage of unser var "resources"
Stefan Vogel <sv@exept.de>
parents:
18614
diff
changeset
|
7573 |
"/ old Code: |
13028 | 7574 |
"/ |
7575 |
"/ enterBox := EnterBox title:(self classResources stringWithCRs:'Browse which class:'). |
|
7576 |
"/ enterBox okText:(resources string:'Browse'). |
|
7577 |
"/ enterBox entryCompletionBlock:(DoWhatIMeanSupport classNameEntryCompletionBlock). |
|
7578 |
"/ enterBox action:[:className | classNameEntered := className]. |
|
7579 |
"/ enterBox showAtPointer. |
|
7580 |
"/ |
|
7581 |
classNameEntered notEmptyOrNil ifTrue:[ |
|
7582 |
classEntered := Smalltalk classNamed:classNameEntered. |
|
7583 |
classEntered isNil ifTrue:[ |
|
7584 |
self warn:(resources string:'No such class'). |
|
7585 |
] ifFalse:[ |
|
7586 |
self perform:aSelector with:classEntered |
|
7587 |
] |
|
7588 |
]. |
|
7589 |
||
7590 |
" |
|
7591 |
SystemBrowser getClassThenPerform:#browseClass: |
|
7592 |
" |
|
7593 |
||
7594 |
"Modified: / 10-08-2006 / 12:54:20 / cg" |
|
7595 |
! |
|
7596 |
||
6560
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
7597 |
resourceEditorClassFor:aResource |
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
7598 |
"resources are from a methods resource-info; |
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
7599 |
return an appropriate editor class." |
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
7600 |
|
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
7601 |
(aResource == #canvas) ifTrue:[ |
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
7602 |
^ UIPainter |
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
7603 |
]. |
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
7604 |
(aResource == #menu) ifTrue:[ |
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
7605 |
^ MenuEditor |
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
7606 |
]. |
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
7607 |
((aResource == #image) or:[aResource == #fileImage]) ifTrue:[ |
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
7608 |
^ ImageEditor |
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
7609 |
]. |
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
7610 |
(aResource == #help) ifTrue:[ |
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
7611 |
^ UIHelpTool |
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
7612 |
]. |
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
7613 |
(aResource == #tableColumns) ifTrue:[ |
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
7614 |
^ DataSetBuilder |
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
7615 |
]. |
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
7616 |
(aResource == #tabList) ifTrue:[ |
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
7617 |
^ TabListEditor |
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
7618 |
]. |
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
7619 |
(aResource == #hierarchicalList) ifTrue:[ |
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
7620 |
^ HierarchicalListEditor |
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
7621 |
]. |
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
7622 |
^ nil |
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
7623 |
! |
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
7624 |
|
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
7625 |
resourceEditorClassForResources:resources |
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
7626 |
"resources are from a methods resource-info; |
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
7627 |
return an appropriate editor class." |
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
7628 |
|
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
7629 |
resources keysDo:[:eachResource | |
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
7630 |
|editor| |
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
7631 |
|
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
7632 |
editor := self resourceEditorClassFor:eachResource. |
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
7633 |
editor notNil ifTrue:[ ^ editor]. |
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
7634 |
]. |
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
7635 |
^ nil |
2813 | 7636 |
! ! |
7637 |
||
3131
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
7638 |
!SystemBrowser::BrowserHistoryEntry methodsFor:'accessing'! |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
7639 |
|
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
7640 |
className |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
7641 |
"return the value of the instance variable 'className' (automatically generated)" |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
7642 |
|
13947 | 7643 |
^ className ? '*anonymous*' |
3131
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
7644 |
! |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
7645 |
|
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
7646 |
className:something |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
7647 |
"set the value of the instance variable 'className' (automatically generated)" |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
7648 |
|
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
7649 |
className := something. |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
7650 |
! |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
7651 |
|
3151 | 7652 |
className:classNameArg meta:metaArg selector:selectorArg |
7653 |
className := classNameArg. |
|
7654 |
meta := metaArg. |
|
7655 |
selector := selectorArg. |
|
7656 |
! |
|
7657 |
||
10048
9e92f3285051
changed: #instVarOverlayXmlSpec
Claus Gittinger <cg@exept.de>
parents:
9879
diff
changeset
|
7658 |
icon |
9e92f3285051
changed: #instVarOverlayXmlSpec
Claus Gittinger <cg@exept.de>
parents:
9879
diff
changeset
|
7659 |
|
9e92f3285051
changed: #instVarOverlayXmlSpec
Claus Gittinger <cg@exept.de>
parents:
9879
diff
changeset
|
7660 |
^nil |
9e92f3285051
changed: #instVarOverlayXmlSpec
Claus Gittinger <cg@exept.de>
parents:
9879
diff
changeset
|
7661 |
|
9e92f3285051
changed: #instVarOverlayXmlSpec
Claus Gittinger <cg@exept.de>
parents:
9879
diff
changeset
|
7662 |
"Created: / 05-05-2011 / 23:57:48 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
9e92f3285051
changed: #instVarOverlayXmlSpec
Claus Gittinger <cg@exept.de>
parents:
9879
diff
changeset
|
7663 |
! |
9e92f3285051
changed: #instVarOverlayXmlSpec
Claus Gittinger <cg@exept.de>
parents:
9879
diff
changeset
|
7664 |
|
9e92f3285051
changed: #instVarOverlayXmlSpec
Claus Gittinger <cg@exept.de>
parents:
9879
diff
changeset
|
7665 |
label |
9e92f3285051
changed: #instVarOverlayXmlSpec
Claus Gittinger <cg@exept.de>
parents:
9879
diff
changeset
|
7666 |
|
9e92f3285051
changed: #instVarOverlayXmlSpec
Claus Gittinger <cg@exept.de>
parents:
9879
diff
changeset
|
7667 |
^self displayString |
9e92f3285051
changed: #instVarOverlayXmlSpec
Claus Gittinger <cg@exept.de>
parents:
9879
diff
changeset
|
7668 |
|
9e92f3285051
changed: #instVarOverlayXmlSpec
Claus Gittinger <cg@exept.de>
parents:
9879
diff
changeset
|
7669 |
"Created: / 05-05-2011 / 23:57:42 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
9e92f3285051
changed: #instVarOverlayXmlSpec
Claus Gittinger <cg@exept.de>
parents:
9879
diff
changeset
|
7670 |
! |
9e92f3285051
changed: #instVarOverlayXmlSpec
Claus Gittinger <cg@exept.de>
parents:
9879
diff
changeset
|
7671 |
|
3131
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
7672 |
meta |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
7673 |
"return the value of the instance variable 'meta' (automatically generated)" |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
7674 |
|
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
7675 |
^ meta |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
7676 |
! |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
7677 |
|
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
7678 |
meta:something |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
7679 |
"set the value of the instance variable 'meta' (automatically generated)" |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
7680 |
|
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
7681 |
meta := something. |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
7682 |
! |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
7683 |
|
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
7684 |
selector |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
7685 |
"return the value of the instance variable 'selector' (automatically generated)" |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
7686 |
|
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
7687 |
^ selector |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
7688 |
! |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
7689 |
|
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
7690 |
selector:something |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
7691 |
"set the value of the instance variable 'selector' (automatically generated)" |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
7692 |
|
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
7693 |
selector := something. |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
7694 |
! |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
7695 |
|
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
7696 |
theClass |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
7697 |
^ Smalltalk at:className asSymbol |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
7698 |
! ! |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
7699 |
|
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
7700 |
!SystemBrowser::BrowserHistoryEntry methodsFor:'comparing'! |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
7701 |
|
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
7702 |
= anEntry |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
7703 |
^ className = anEntry className |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
7704 |
and:[meta = anEntry meta |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
7705 |
and:[selector = anEntry selector]] |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
7706 |
! ! |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
7707 |
|
10048
9e92f3285051
changed: #instVarOverlayXmlSpec
Claus Gittinger <cg@exept.de>
parents:
9879
diff
changeset
|
7708 |
!SystemBrowser::BrowserHistoryEntry methodsFor:'displaying'! |
9e92f3285051
changed: #instVarOverlayXmlSpec
Claus Gittinger <cg@exept.de>
parents:
9879
diff
changeset
|
7709 |
|
13319
93eadba89fa6
Refactor to implement #displayOn:aGcOrStream instead of #displayString
Stefan Vogel <sv@exept.de>
parents:
13128
diff
changeset
|
7710 |
displayOn:aGCOrStream |
13820 | 7711 |
| cls name | |
13319
93eadba89fa6
Refactor to implement #displayOn:aGcOrStream instead of #displayString
Stefan Vogel <sv@exept.de>
parents:
13128
diff
changeset
|
7712 |
|
93eadba89fa6
Refactor to implement #displayOn:aGcOrStream instead of #displayString
Stefan Vogel <sv@exept.de>
parents:
13128
diff
changeset
|
7713 |
"/ what a kludge - Dolphin and Squeak mean: printOn: a stream; |
17432 | 7714 |
"/ old ST80 means: draw-yourself on a GC. |
13319
93eadba89fa6
Refactor to implement #displayOn:aGcOrStream instead of #displayString
Stefan Vogel <sv@exept.de>
parents:
13128
diff
changeset
|
7715 |
(aGCOrStream isStream) ifFalse:[ |
93eadba89fa6
Refactor to implement #displayOn:aGcOrStream instead of #displayString
Stefan Vogel <sv@exept.de>
parents:
13128
diff
changeset
|
7716 |
^ super displayOn:aGCOrStream |
93eadba89fa6
Refactor to implement #displayOn:aGcOrStream instead of #displayString
Stefan Vogel <sv@exept.de>
parents:
13128
diff
changeset
|
7717 |
]. |
93eadba89fa6
Refactor to implement #displayOn:aGcOrStream instead of #displayString
Stefan Vogel <sv@exept.de>
parents:
13128
diff
changeset
|
7718 |
|
13820 | 7719 |
cls := self theClass. |
7720 |
name := cls notNil ifTrue:[cls nameInBrowser] ifFalse:[className]. |
|
7721 |
name printOn:aGCOrStream. |
|
13319
93eadba89fa6
Refactor to implement #displayOn:aGcOrStream instead of #displayString
Stefan Vogel <sv@exept.de>
parents:
13128
diff
changeset
|
7722 |
meta ifTrue:[ |
16037 | 7723 |
"/ aGCOrStream emphasis:#bold. |
7724 |
aGCOrStream nextPutAll:' class'. |
|
7725 |
"/ aGCOrStream emphasis:nil. |
|
13319
93eadba89fa6
Refactor to implement #displayOn:aGcOrStream instead of #displayString
Stefan Vogel <sv@exept.de>
parents:
13128
diff
changeset
|
7726 |
]. |
93eadba89fa6
Refactor to implement #displayOn:aGcOrStream instead of #displayString
Stefan Vogel <sv@exept.de>
parents:
13128
diff
changeset
|
7727 |
selector notNil ifTrue:[ |
93eadba89fa6
Refactor to implement #displayOn:aGcOrStream instead of #displayString
Stefan Vogel <sv@exept.de>
parents:
13128
diff
changeset
|
7728 |
aGCOrStream |
19235 | 7729 |
nextPutAll:' ยป '; |
17543 | 7730 |
bold; |
16037 | 7731 |
nextPutAll:selector; |
17543 | 7732 |
normal. |
13319
93eadba89fa6
Refactor to implement #displayOn:aGcOrStream instead of #displayString
Stefan Vogel <sv@exept.de>
parents:
13128
diff
changeset
|
7733 |
]. |
10048
9e92f3285051
changed: #instVarOverlayXmlSpec
Claus Gittinger <cg@exept.de>
parents:
9879
diff
changeset
|
7734 |
|
9e92f3285051
changed: #instVarOverlayXmlSpec
Claus Gittinger <cg@exept.de>
parents:
9879
diff
changeset
|
7735 |
"Created: / 15-04-2010 / 13:47:58 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
13820 | 7736 |
"Modified: / 14-10-2013 / 12:18:42 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
17543 | 7737 |
"Modified: / 20-06-2017 / 08:59:26 / cg" |
10048
9e92f3285051
changed: #instVarOverlayXmlSpec
Claus Gittinger <cg@exept.de>
parents:
9879
diff
changeset
|
7738 |
! ! |
9e92f3285051
changed: #instVarOverlayXmlSpec
Claus Gittinger <cg@exept.de>
parents:
9879
diff
changeset
|
7739 |
|
820
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
7740 |
!SystemBrowser class methodsFor:'documentation'! |
93 | 7741 |
|
12822 | 7742 |
version |
15831 | 7743 |
^ '$Header$' |
12822 | 7744 |
! |
7745 |
||
8851 | 7746 |
version_CVS |
15831 | 7747 |
^ '$Header$' |
10048
9e92f3285051
changed: #instVarOverlayXmlSpec
Claus Gittinger <cg@exept.de>
parents:
9879
diff
changeset
|
7748 |
! |
9e92f3285051
changed: #instVarOverlayXmlSpec
Claus Gittinger <cg@exept.de>
parents:
9879
diff
changeset
|
7749 |
|
9e92f3285051
changed: #instVarOverlayXmlSpec
Claus Gittinger <cg@exept.de>
parents:
9879
diff
changeset
|
7750 |
version_SVN |
15831 | 7751 |
^ '$Id$' |
36 | 7752 |
! ! |
4112 | 7753 |
|
12475 | 7754 |
|
203 | 7755 |
SystemBrowser initialize! |