author | Claus Gittinger <cg@exept.de> |
Wed, 31 Jul 2019 17:40:43 +0200 | |
changeset 18956 | 2331d73715c7 |
parent 18117 | a0e33e7fe5cd |
child 19086 | 42dc8d271fe9 |
permissions | -rw-r--r-- |
10000 | 1 |
" |
10096 | 2 |
Copyright (c) 2007-2010 Jan Vrany, SWING Research Group, Czech Technical University in Prague |
3 |
Copyright (c) 2009-2010 eXept Software AG |
|
10000 | 4 |
|
10096 | 5 |
Permission is hereby granted, free of charge, to any person |
6 |
obtaining a copy of this software and associated documentation |
|
7 |
files (the 'Software'), to deal in the Software without |
|
8 |
restriction, including without limitation the rights to use, |
|
9 |
copy, modify, merge, publish, distribute, sublicense, and/or sell |
|
10 |
copies of the Software, and to permit persons to whom the |
|
11 |
Software is furnished to do so, subject to the following |
|
12 |
conditions: |
|
13 |
||
14 |
The above copyright notice and this permission notice shall be |
|
15 |
included in all copies or substantial portions of the Software. |
|
16 |
||
17 |
THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND, |
|
18 |
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES |
|
19 |
OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND |
|
20 |
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT |
|
21 |
HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, |
|
22 |
WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING |
|
23 |
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR |
|
24 |
OTHER DEALINGS IN THE SOFTWARE. |
|
10000 | 25 |
" |
26 |
"{ Package: 'stx:libtool' }" |
|
27 |
||
28 |
"{ NameSpace: Tools }" |
|
29 |
||
30 |
BrowserList subclass:#LintRuleList |
|
31 |
instanceVariableNames:'listHolder filterHolder modeHolder listSelection listView |
|
32 |
initialSelectionHolder' |
|
14978 | 33 |
classVariableNames:'LastNameFilter' |
10000 | 34 |
poolDictionaries:'' |
35 |
category:'Interface-Lint' |
|
36 |
! |
|
37 |
||
38 |
HierarchicalItem subclass:#ListEntry |
|
39 |
instanceVariableNames:'x rule application' |
|
40 |
classVariableNames:'' |
|
41 |
poolDictionaries:'' |
|
42 |
privateIn:LintRuleList |
|
43 |
! |
|
44 |
||
45 |
!LintRuleList class methodsFor:'documentation'! |
|
46 |
||
47 |
copyright |
|
48 |
" |
|
10096 | 49 |
Copyright (c) 2007-2010 Jan Vrany, SWING Research Group, Czech Technical University in Prague |
50 |
Copyright (c) 2009-2010 eXept Software AG |
|
51 |
||
52 |
Permission is hereby granted, free of charge, to any person |
|
53 |
obtaining a copy of this software and associated documentation |
|
54 |
files (the 'Software'), to deal in the Software without |
|
55 |
restriction, including without limitation the rights to use, |
|
56 |
copy, modify, merge, publish, distribute, sublicense, and/or sell |
|
57 |
copies of the Software, and to permit persons to whom the |
|
58 |
Software is furnished to do so, subject to the following |
|
59 |
conditions: |
|
10000 | 60 |
|
10096 | 61 |
The above copyright notice and this permission notice shall be |
62 |
included in all copies or substantial portions of the Software. |
|
63 |
||
64 |
THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND, |
|
65 |
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES |
|
66 |
OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND |
|
67 |
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT |
|
68 |
HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, |
|
69 |
WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING |
|
70 |
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR |
|
71 |
OTHER DEALINGS IN THE SOFTWARE. |
|
10000 | 72 |
" |
14754
7905f58cb037
Do now allow ruleset editing in ruleset selection dialog.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14671
diff
changeset
|
73 |
! |
7905f58cb037
Do now allow ruleset editing in ruleset selection dialog.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14671
diff
changeset
|
74 |
|
7905f58cb037
Do now allow ruleset editing in ruleset selection dialog.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14671
diff
changeset
|
75 |
documentation |
7905f58cb037
Do now allow ruleset editing in ruleset selection dialog.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14671
diff
changeset
|
76 |
" |
17298 | 77 |
Embeddable list to display a set of SmallLint rules. |
78 |
(this is embedded in the browser when showing lint check outcomes) |
|
14754
7905f58cb037
Do now allow ruleset editing in ruleset selection dialog.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14671
diff
changeset
|
79 |
|
7905f58cb037
Do now allow ruleset editing in ruleset selection dialog.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14671
diff
changeset
|
80 |
Supports 3 modes (controlled by modeHolder) |
7905f58cb037
Do now allow ruleset editing in ruleset selection dialog.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14671
diff
changeset
|
81 |
#display - only display given set of rules. |
7905f58cb037
Do now allow ruleset editing in ruleset selection dialog.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14671
diff
changeset
|
82 |
#displaySelection - display set of rules and indicate which one is selected |
7905f58cb037
Do now allow ruleset editing in ruleset selection dialog.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14671
diff
changeset
|
83 |
by check mark. Does NOT ALLOW to change selection |
7905f58cb037
Do now allow ruleset editing in ruleset selection dialog.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14671
diff
changeset
|
84 |
(add remove tools) |
7905f58cb037
Do now allow ruleset editing in ruleset selection dialog.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14671
diff
changeset
|
85 |
#select - display set of rules and DO ALLOW to change the selection |
7905f58cb037
Do now allow ruleset editing in ruleset selection dialog.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14671
diff
changeset
|
86 |
(add / remove rules) by clicking to check icon |
7905f58cb037
Do now allow ruleset editing in ruleset selection dialog.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14671
diff
changeset
|
87 |
|
7905f58cb037
Do now allow ruleset editing in ruleset selection dialog.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14671
diff
changeset
|
88 |
[author:] |
7905f58cb037
Do now allow ruleset editing in ruleset selection dialog.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14671
diff
changeset
|
89 |
Jan Vrany <jan.vrany@fit.cvut.cz> |
7905f58cb037
Do now allow ruleset editing in ruleset selection dialog.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14671
diff
changeset
|
90 |
|
7905f58cb037
Do now allow ruleset editing in ruleset selection dialog.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14671
diff
changeset
|
91 |
[instance variables:] |
7905f58cb037
Do now allow ruleset editing in ruleset selection dialog.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14671
diff
changeset
|
92 |
|
7905f58cb037
Do now allow ruleset editing in ruleset selection dialog.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14671
diff
changeset
|
93 |
[class variables:] |
7905f58cb037
Do now allow ruleset editing in ruleset selection dialog.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14671
diff
changeset
|
94 |
|
7905f58cb037
Do now allow ruleset editing in ruleset selection dialog.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14671
diff
changeset
|
95 |
[see also:] |
7905f58cb037
Do now allow ruleset editing in ruleset selection dialog.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14671
diff
changeset
|
96 |
|
7905f58cb037
Do now allow ruleset editing in ruleset selection dialog.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14671
diff
changeset
|
97 |
" |
7905f58cb037
Do now allow ruleset editing in ruleset selection dialog.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14671
diff
changeset
|
98 |
! |
7905f58cb037
Do now allow ruleset editing in ruleset selection dialog.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14671
diff
changeset
|
99 |
|
7905f58cb037
Do now allow ruleset editing in ruleset selection dialog.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14671
diff
changeset
|
100 |
examples |
7905f58cb037
Do now allow ruleset editing in ruleset selection dialog.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14671
diff
changeset
|
101 |
" |
7905f58cb037
Do now allow ruleset editing in ruleset selection dialog.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14671
diff
changeset
|
102 |
Starting the application: |
7905f58cb037
Do now allow ruleset editing in ruleset selection dialog.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14671
diff
changeset
|
103 |
[exBegin] |
7905f58cb037
Do now allow ruleset editing in ruleset selection dialog.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14671
diff
changeset
|
104 |
Tools::LintRuleList open |
7905f58cb037
Do now allow ruleset editing in ruleset selection dialog.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14671
diff
changeset
|
105 |
|
7905f58cb037
Do now allow ruleset editing in ruleset selection dialog.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14671
diff
changeset
|
106 |
[exEnd] |
7905f58cb037
Do now allow ruleset editing in ruleset selection dialog.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14671
diff
changeset
|
107 |
|
7905f58cb037
Do now allow ruleset editing in ruleset selection dialog.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14671
diff
changeset
|
108 |
more examples to be added: |
7905f58cb037
Do now allow ruleset editing in ruleset selection dialog.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14671
diff
changeset
|
109 |
[exBegin] |
7905f58cb037
Do now allow ruleset editing in ruleset selection dialog.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14671
diff
changeset
|
110 |
... add code fragment for |
7905f58cb037
Do now allow ruleset editing in ruleset selection dialog.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14671
diff
changeset
|
111 |
... executable example here ... |
7905f58cb037
Do now allow ruleset editing in ruleset selection dialog.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14671
diff
changeset
|
112 |
[exEnd] |
7905f58cb037
Do now allow ruleset editing in ruleset selection dialog.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14671
diff
changeset
|
113 |
" |
10000 | 114 |
! ! |
115 |
||
116 |
!LintRuleList class methodsFor:'interface specs'! |
|
117 |
||
118 |
windowSpec |
|
119 |
"This resource specification was automatically generated |
|
120 |
by the UIPainter of ST/X." |
|
121 |
||
122 |
"Do not manually edit this!! If it is corrupted, |
|
123 |
the UIPainter may not be able to read the specification." |
|
124 |
||
125 |
" |
|
126 |
UIPainter new openOnClass:Tools::LintRuleList andSelector:#windowSpec |
|
127 |
Tools::LintRuleList new openInterface:#windowSpec |
|
128 |
Tools::LintRuleList open |
|
129 |
" |
|
130 |
||
131 |
<resource: #canvas> |
|
132 |
||
133 |
^ |
|
16589 | 134 |
#(FullSpec |
135 |
name: windowSpec |
|
136 |
window: |
|
137 |
(WindowSpec |
|
138 |
label: 'SmallLintRuleList' |
|
139 |
name: 'SmallLintRuleList' |
|
140 |
min: (Point 10 10) |
|
141 |
bounds: (Rectangle 0 0 300 300) |
|
142 |
) |
|
143 |
component: |
|
144 |
(SpecCollection |
|
145 |
collection: ( |
|
146 |
(InputFieldSpec |
|
147 |
name: 'RuleFilter' |
|
148 |
layout: (LayoutFrame 0 0 0 0 0 1 28 0) |
|
149 |
model: filterHolder |
|
150 |
immediateAccept: true |
|
151 |
acceptOnReturn: true |
|
152 |
acceptOnTab: true |
|
153 |
acceptOnPointerLeave: true |
|
154 |
emptyFieldReplacementText: 'Search...' |
|
10000 | 155 |
) |
16589 | 156 |
(SelectionInListModelViewSpec |
157 |
name: 'RuleList' |
|
158 |
layout: (LayoutFrame 0 0 28 0 0 1 0 1) |
|
159 |
model: listSelection |
|
160 |
menu: menuHolder |
|
161 |
hasHorizontalScrollBar: true |
|
162 |
hasVerticalScrollBar: true |
|
163 |
listModel: listHolder |
|
164 |
multipleSelectOk: true |
|
165 |
useIndex: false |
|
166 |
highlightMode: line |
|
167 |
postBuildCallback: postBuildList: |
|
168 |
) |
|
169 |
) |
|
170 |
||
171 |
) |
|
172 |
) |
|
10000 | 173 |
! ! |
174 |
||
175 |
!LintRuleList class methodsFor:'menu specs'! |
|
176 |
||
177 |
menu |
|
178 |
"This resource specification was automatically generated |
|
179 |
by the MenuEditor of ST/X." |
|
180 |
||
181 |
"Do not manually edit this!! If it is corrupted, |
|
182 |
the MenuEditor may not be able to read the specification." |
|
183 |
||
11381 | 184 |
|
10000 | 185 |
" |
11381 | 186 |
MenuEditor new openOnClass:Tools::LintRuleList andSelector:#menu |
187 |
(Menu new fromLiteralArrayEncoding:(Tools::LintRuleList menu)) startUp |
|
10000 | 188 |
" |
189 |
||
190 |
<resource: #menu> |
|
191 |
||
192 |
^ |
|
193 |
#(Menu |
|
194 |
( |
|
195 |
(MenuItem |
|
16438 | 196 |
label: 'Run this Rule Again' |
197 |
itemValue: runRuleAgain |
|
198 |
) |
|
199 |
(MenuItem |
|
10000 | 200 |
label: '-' |
201 |
) |
|
202 |
(MenuItem |
|
16438 | 203 |
label: 'Inspect Rule' |
204 |
itemValue: menuInspectRule |
|
205 |
) |
|
206 |
(MenuItem |
|
207 |
label: 'Browse Rule Class' |
|
208 |
itemValue: menuBrowseRuleClass |
|
10000 | 209 |
) |
210 |
) |
|
211 |
nil |
|
212 |
nil |
|
213 |
) |
|
214 |
! ! |
|
215 |
||
216 |
!LintRuleList class methodsFor:'plugIn spec'! |
|
217 |
||
218 |
aspectSelectors |
|
219 |
"This resource specification was automatically generated |
|
220 |
by the UIPainter of ST/X." |
|
221 |
||
222 |
"Do not manually edit this. If it is corrupted, |
|
223 |
the UIPainter may not be able to read the specification." |
|
224 |
||
225 |
"Return a description of exported aspects; |
|
226 |
these can be connected to aspects of an embedding application |
|
227 |
(if this app is embedded in a subCanvas)." |
|
228 |
||
229 |
^ #( |
|
16589 | 230 |
#environmentHolder |
10000 | 231 |
#inGeneratorHolder |
13798 | 232 |
#listSelection |
10000 | 233 |
#modeHolder |
234 |
#outGeneratorHolder |
|
235 |
#selectionHolder |
|
236 |
). |
|
237 |
||
238 |
! ! |
|
239 |
||
240 |
!LintRuleList methodsFor:'accessing'! |
|
241 |
||
242 |
mode |
|
243 |
||
244 |
^self modeHolder value |
|
245 |
||
17361 | 246 |
"Created: / 25-08-2010 / 11:33:51 / Jan Vrany" |
10000 | 247 |
! |
248 |
||
249 |
selection |
|
250 |
||
251 |
| sel | |
|
252 |
sel := self selectionHolder value. |
|
253 |
sel ifNil:[sel := Set new]. |
|
254 |
^sel |
|
255 |
||
17361 | 256 |
"Created: / 25-08-2010 / 13:26:58 / Jan Vrany" |
10000 | 257 |
! |
258 |
||
259 |
selection: aCollectionOrNil |
|
260 |
||
261 |
| sel | |
|
262 |
sel := aCollectionOrNil |
|
263 |
ifNil:[Set new] |
|
264 |
ifNotNil:[aCollectionOrNil asSet]. |
|
265 |
||
13798 | 266 |
self selectionHolder value: sel. |
10000 | 267 |
|
17361 | 268 |
"Created: / 25-08-2010 / 13:28:43 / Jan Vrany" |
269 |
"Modified: / 25-08-2010 / 15:29:35 / Jan Vrany" |
|
13798 | 270 |
"Modified: / 27-02-2013 / 23:33:36 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
10000 | 271 |
! ! |
272 |
||
273 |
!LintRuleList methodsFor:'aspects'! |
|
274 |
||
275 |
filterHolder |
|
276 |
"return/create the 'filterHolder' value holder (automatically generated)" |
|
277 |
||
278 |
filterHolder isNil ifTrue:[ |
|
14978 | 279 |
filterHolder := LastNameFilter asValue. |
10000 | 280 |
filterHolder addDependent:self. |
281 |
]. |
|
282 |
^ filterHolder |
|
283 |
! |
|
284 |
||
285 |
filterHolder:something |
|
286 |
"set the 'filterHolder' value holder (automatically generated)" |
|
287 |
||
288 |
|oldValue newValue| |
|
289 |
||
290 |
filterHolder notNil ifTrue:[ |
|
291 |
oldValue := filterHolder value. |
|
292 |
filterHolder removeDependent:self. |
|
293 |
]. |
|
294 |
filterHolder := something. |
|
295 |
filterHolder notNil ifTrue:[ |
|
296 |
filterHolder addDependent:self. |
|
297 |
]. |
|
298 |
newValue := filterHolder value. |
|
299 |
oldValue ~~ newValue ifTrue:[ |
|
300 |
self update:#value with:newValue from:filterHolder. |
|
301 |
]. |
|
302 |
! |
|
303 |
||
304 |
listHolder |
|
305 |
"return/create the 'ruleList' value holder (automatically generated)" |
|
306 |
||
307 |
listHolder isNil ifTrue:[ |
|
308 |
listHolder := ValueHolder new. |
|
309 |
]. |
|
310 |
^ listHolder |
|
311 |
! |
|
312 |
||
313 |
listSelection |
|
314 |
"return/create the 'listSelection' value holder (automatically generated)" |
|
315 |
||
316 |
listSelection isNil ifTrue:[ |
|
317 |
listSelection := ValueHolder new. |
|
318 |
listSelection addDependent:self. |
|
319 |
]. |
|
320 |
^ listSelection |
|
321 |
! |
|
322 |
||
323 |
listSelection:something |
|
324 |
"set the 'listSelection' value holder (automatically generated)" |
|
325 |
||
326 |
|oldValue newValue| |
|
327 |
||
328 |
listSelection notNil ifTrue:[ |
|
329 |
oldValue := listSelection value. |
|
330 |
listSelection removeDependent:self. |
|
331 |
]. |
|
332 |
listSelection := something. |
|
333 |
listSelection notNil ifTrue:[ |
|
334 |
listSelection addDependent:self. |
|
335 |
]. |
|
336 |
newValue := listSelection value. |
|
337 |
oldValue ~~ newValue ifTrue:[ |
|
338 |
self update:#value with:newValue from:listSelection. |
|
339 |
]. |
|
340 |
! |
|
341 |
||
342 |
modeHolder |
|
16438 | 343 |
"the mode - can run in select or in display modes. |
344 |
select is to choose a set of rules; |
|
345 |
display for presentation of results (in a browser). |
|
346 |
See documentation for details" |
|
347 |
||
348 |
modeHolder isNil ifTrue:[ |
|
349 |
modeHolder := ValueHolder with: #display |
|
350 |
]. |
|
10000 | 351 |
^modeHolder |
352 |
||
353 |
"Modified: / 15-04-2010 / 20:56:36 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
354 |
! |
|
355 |
||
356 |
modeHolder:aValueModel |
|
16438 | 357 |
"the mode - can run in select or in display modes. |
358 |
select is to choose a set of rules; |
|
359 |
display for presentation of results (in a browser). |
|
360 |
See documentation for details" |
|
361 |
||
10000 | 362 |
modeHolder := aValueModel. |
363 |
! |
|
364 |
||
365 |
selectedLintRules |
|
366 |
^ self selectionHolder |
|
367 |
||
368 |
"Created: / 02-02-2010 / 20:43:39 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
369 |
! |
|
370 |
||
371 |
selectedLintRules: anObject |
|
372 |
^ self selectionHolder: anObject |
|
373 |
||
374 |
"Created: / 02-02-2010 / 20:43:52 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
375 |
! ! |
|
376 |
||
377 |
!LintRuleList methodsFor:'change & update'! |
|
378 |
||
379 |
delayedUpdate:something with:aParameter from:changedObject |
|
380 |
"Invoked when an object that I depend upon sends a change notification." |
|
381 |
||
382 |
changedObject == filterHolder ifTrue:[ |
|
14978 | 383 |
LastNameFilter := filterHolder value. |
10000 | 384 |
self updateList. |
385 |
^ self. |
|
386 |
]. |
|
387 |
||
388 |
(changedObject == listSelection) ifTrue:[ |
|
389 |
listValid ifFalse:[ |
|
390 |
self updateList. |
|
391 |
]. |
|
392 |
^ self selectionChanged |
|
393 |
]. |
|
394 |
||
10499 | 395 |
(changedObject == selectionHolder) ifTrue:[ |
13798 | 396 |
listView notNil ifTrue:[ |
397 |
listView invalidate |
|
398 |
]. |
|
10499 | 399 |
^self. |
400 |
]. |
|
401 |
||
402 |
||
10000 | 403 |
super delayedUpdate:something with:aParameter from:changedObject |
404 |
||
17361 | 405 |
"Created: / 26-08-2010 / 11:43:33 / Jan Vrany" |
13798 | 406 |
"Modified: / 27-02-2013 / 23:40:02 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
10499 | 407 |
! |
408 |
||
409 |
selectionChanged |
|
410 |
||
16426 | 411 |
| selection newSelection | |
14169
d983f6273b6d
Fixed LintRileList>>selectionChanged so it works both in browser and in dialog. Bit hacky.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14165
diff
changeset
|
412 |
|
d983f6273b6d
Fixed LintRileList>>selectionChanged so it works both in browser and in dialog. Bit hacky.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14165
diff
changeset
|
413 |
super selectionChanged. |
14786
6761e919308a
Bugfix in selection handling.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14755
diff
changeset
|
414 |
self mode == #display ifTrue:[ |
14169
d983f6273b6d
Fixed LintRileList>>selectionChanged so it works both in browser and in dialog. Bit hacky.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14165
diff
changeset
|
415 |
selection := self listSelection value. |
d983f6273b6d
Fixed LintRileList>>selectionChanged so it works both in browser and in dialog. Bit hacky.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14165
diff
changeset
|
416 |
selection isEmptyOrNil ifTrue:[ |
16426 | 417 |
newSelection := selection |
14169
d983f6273b6d
Fixed LintRileList>>selectionChanged so it works both in browser and in dialog. Bit hacky.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14165
diff
changeset
|
418 |
] ifFalse:[ |
16426 | 419 |
newSelection := selection collect:[:entry|entry rule] |
14169
d983f6273b6d
Fixed LintRileList>>selectionChanged so it works both in browser and in dialog. Bit hacky.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14165
diff
changeset
|
420 |
]. |
16426 | 421 |
self selectionHolder value: newSelection. |
14855 | 422 |
"/ listView invalidate |
14169
d983f6273b6d
Fixed LintRileList>>selectionChanged so it works both in browser and in dialog. Bit hacky.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14165
diff
changeset
|
423 |
]. |
10499 | 424 |
|
425 |
"Created: / 05-08-2011 / 00:10:45 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
14786
6761e919308a
Bugfix in selection handling.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14755
diff
changeset
|
426 |
"Modified: / 17-10-2014 / 00:01:21 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
10000 | 427 |
! ! |
428 |
||
429 |
!LintRuleList methodsFor:'event processing'! |
|
430 |
||
431 |
buttonPress:button x:x y:y view:aView |
|
432 |
||
433 |
| itemIndex item | |
|
434 |
||
16438 | 435 |
(button == 1 and:[self modeHolder value == #select]) ifFalse:[ |
436 |
^ aView buttonPress:button x:x y:y |
|
437 |
]. |
|
10000 | 438 |
|
439 |
itemIndex := aView yVisibleToLineNr:y. |
|
14755 | 440 |
itemIndex isNil ifTrue:[^self]. |
10000 | 441 |
itemIndex == 0 ifTrue:[^self]. |
442 |
itemIndex > aView list size ifTrue:[^self]. |
|
443 |
item := aView list at: itemIndex. |
|
444 |
||
445 |
((aView left + x) between: (item x) and: (item x + 16)) |
|
446 |
ifFalse:[^aView buttonPress:button x:x y:y]. |
|
447 |
||
448 |
item checked: item checked not. |
|
449 |
aView invalidate |
|
450 |
||
451 |
"Created: / 08-12-2009 / 14:12:38 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
14755 | 452 |
"Modified: / 13-10-2014 / 18:38:06 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
10000 | 453 |
! |
454 |
||
455 |
handlesButtonPress:button inView:aView |
|
14923
7c189a24693c
class: Tools::LintRuleList
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14855
diff
changeset
|
456 |
^ listView == aView |
7c189a24693c
class: Tools::LintRuleList
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14855
diff
changeset
|
457 |
and:[ button == 1 |
7c189a24693c
class: Tools::LintRuleList
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14855
diff
changeset
|
458 |
and:[ self modeHolder value == #select ] ] |
10000 | 459 |
|
460 |
"Created: / 08-12-2009 / 14:08:49 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
14923
7c189a24693c
class: Tools::LintRuleList
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14855
diff
changeset
|
461 |
"Modified: / 27-11-2014 / 09:18:42 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
10000 | 462 |
! ! |
463 |
||
464 |
!LintRuleList methodsFor:'generators'! |
|
465 |
||
466 |
makeGenerator |
|
467 |
||
16426 | 468 |
self modeHolder value == #display ifTrue:[ |
469 |
^ Iterator |
|
470 |
on: [:whatToDo| |
|
471 |
self listSelection value ? #() do:[:each| |
|
16875 | 472 |
"/ classes removed (in the meanwhile), but still referenced by name in the lintResults |
473 |
"/ may lead to nil being enumerated here... |
|
474 |
each failedClasses nonNilElementsDo:whatToDo |
|
16426 | 475 |
] |
476 |
] |
|
477 |
]. |
|
478 |
^ Iterator |
|
479 |
on: [:whatToDo| |
|
480 |
self selection do:[:rule| whatToDo value: rule] |
|
481 |
]. |
|
10000 | 482 |
|
483 |
"Modified: / 16-04-2010 / 12:13:08 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
17361 | 484 |
"Modified: / 25-08-2010 / 13:39:51 / Jan Vrany" |
10000 | 485 |
! ! |
486 |
||
487 |
!LintRuleList methodsFor:'hooks'! |
|
488 |
||
489 |
commonPostOpen |
|
12035 | 490 |
super commonPostOpen. |
10000 | 491 |
self updateOutputGenerator. |
492 |
||
493 |
"Created: / 16-04-2010 / 11:53:34 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
494 |
! |
|
495 |
||
496 |
postBuildList: aView |
|
18117 | 497 |
"I want to see the events of the list" |
10000 | 498 |
|
499 |
listView := aView scrolledView. |
|
500 |
listView delegate: self. |
|
501 |
||
502 |
"Created: / 08-12-2009 / 14:10:24 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
503 |
! ! |
|
504 |
||
505 |
!LintRuleList methodsFor:'initialization'! |
|
506 |
||
507 |
initialize |
|
14033
a8387e4a0a78
Refactoring of NavigatorModel's environment.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13798
diff
changeset
|
508 |
| menu | |
10000 | 509 |
|
510 |
super initialize. |
|
16438 | 511 |
|
512 |
menuHolder := |
|
513 |
[ |
|
514 |
menu := self menuFor: #menu. |
|
515 |
menu isArray ifTrue:[ menu := Menu decodeFromLiteralArray: menu ]. |
|
516 |
menu |
|
517 |
]. |
|
518 |
||
14855 | 519 |
"/ self selection: Set new. |
10000 | 520 |
|
17361 | 521 |
"Modified: / 25-08-2010 / 15:24:45 / Jan Vrany" |
14033
a8387e4a0a78
Refactoring of NavigatorModel's environment.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13798
diff
changeset
|
522 |
"Modified: / 24-02-2014 / 12:00:12 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
10000 | 523 |
! ! |
524 |
||
525 |
!LintRuleList methodsFor:'menu actions'! |
|
526 |
||
16438 | 527 |
menuBrowseRuleClass |
528 |
| selection | |
|
10000 | 529 |
|
16438 | 530 |
selection := self listSelection value. |
531 |
selection size = 1 ifTrue:[selection anyOne rule class browse]. |
|
532 |
selection size > 1 ifTrue:[SystemBrowser |
|
533 |
browseClasses:(selection collect:[:e|e rule class]) |
|
534 |
label:'Rule classes']. |
|
535 |
! |
|
536 |
||
537 |
menuInspectRule |
|
10000 | 538 |
| selection | |
16438 | 539 |
|
10000 | 540 |
selection := self listSelection value. |
541 |
selection size = 1 ifTrue:[selection anyOne rule inspect]. |
|
542 |
selection size > 1 ifTrue:[(selection collect:[:e|e rule]) inspect]. |
|
16438 | 543 |
! |
10000 | 544 |
|
16438 | 545 |
runRuleAgain |
546 |
self selectedLintRules value do:[:eachRule | |
|
547 |
eachRule run. |
|
548 |
]. |
|
16442 | 549 |
"/ self updateList. |
550 |
self updateOutputGenerator |
|
10000 | 551 |
! ! |
552 |
||
553 |
!LintRuleList methodsFor:'private'! |
|
554 |
||
555 |
listEntryFor: anRBLintRule |
|
556 |
||
557 |
| entry | |
|
558 |
entry := ListEntry new |
|
559 |
rule: anRBLintRule; |
|
560 |
application: self; |
|
561 |
expand; |
|
562 |
yourself. |
|
563 |
^entry |
|
564 |
||
565 |
"Created: / 15-04-2010 / 18:59:16 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
17361 | 566 |
"Modified: / 25-08-2010 / 14:15:46 / Jan Vrany" |
10000 | 567 |
! |
568 |
||
569 |
makeDependent |
|
570 |
||
571 |
"nothing to do" |
|
572 |
||
573 |
"Created: / 02-02-2010 / 20:23:31 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
574 |
! |
|
575 |
||
576 |
makeIndependent |
|
577 |
||
578 |
"nothing to do" |
|
579 |
||
580 |
"Created: / 02-02-2010 / 20:23:54 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
581 |
! |
|
582 |
||
583 |
rules: rules includes: rule |
|
584 |
||
585 |
^rules contains: |
|
586 |
[:each| |
|
587 |
each class == rule class and: |
|
588 |
[each name = rule name]] |
|
589 |
||
17361 | 590 |
"Created: / 26-08-2010 / 12:04:04 / Jan Vrany" |
10000 | 591 |
! |
592 |
||
14855 | 593 |
setListValid:aBoolean |
14945 | 594 |
"/ listValid ifTrue:[ |
595 |
"/ aBoolean ifFalse:[self halt]. |
|
596 |
"/ ]. |
|
14855 | 597 |
listValid := aBoolean. |
598 |
! |
|
599 |
||
10000 | 600 |
updateList |
601 |
|generator filterS newList| |
|
602 |
||
603 |
generator := self inGeneratorHolder value. |
|
604 |
filterS := self filterHolder value. |
|
10455 | 605 |
filterS notEmptyOrNil ifTrue:[ |
606 |
(filterS startsWith: $*) ifFalse:[filterS := '*' , filterS]. |
|
607 |
(filterS endsWith: $*) ifFalse:[filterS := filterS , '*'] |
|
608 |
]. |
|
609 |
(generator isNil and:[self mode == #display]) ifTrue:[ |
|
610 |
generator := RBCompositeLintRule allRules flattened |
|
611 |
]. |
|
10000 | 612 |
newList := OrderedCollection new. |
613 |
generator do:[:rule | |
|
10455 | 614 |
rule flattened do: [:rule| |
14667 | 615 |
(filterS isEmptyOrNil |
17009 | 616 |
or:[(rule name matches: filterS caseSensitive:false) |
617 |
or:[rule class name matches: filterS caseSensitive:false]]) |
|
10455 | 618 |
ifTrue:[ |
619 |
newList add: (self listEntryFor:rule) |
|
620 |
] |
|
621 |
] |
|
622 |
]. |
|
16872 | 623 |
newList |
624 |
sort:[:a :b | |
|
625 |
|sevA sevB| |
|
626 |
||
627 |
sevA := a rule severityAsInteger. |
|
628 |
sevB := b rule severityAsInteger. |
|
629 |
(sevA > sevB) |
|
630 |
or:[ (sevA == sevB) and:[a rule name < b rule name]]. |
|
631 |
]. |
|
632 |
"/ newList sort:[:a :b | a name < b name]. |
|
10000 | 633 |
self listHolder value:newList. |
14855 | 634 |
self setListValid:true. |
10000 | 635 |
|
636 |
"Modified: / 22-07-2009 / 15:58:39 / Jan Vrany <vranyj1@fel.cvut.cz>" |
|
17361 | 637 |
"Modified: / 25-08-2010 / 13:35:58 / Jan Vrany" |
11381 | 638 |
"Modified: / 07-03-2012 / 18:06:50 / cg" |
14786
6761e919308a
Bugfix in selection handling.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14755
diff
changeset
|
639 |
"Modified: / 16-10-2014 / 23:57:51 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
10000 | 640 |
! ! |
641 |
||
10499 | 642 |
!LintRuleList methodsFor:'queries'! |
643 |
||
644 |
supportsSearch |
|
645 |
||
646 |
^false |
|
647 |
||
648 |
"Created: / 04-08-2011 / 23:04:39 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
649 |
! ! |
|
650 |
||
10000 | 651 |
!LintRuleList methodsFor:'selection'! |
652 |
||
653 |
selectionAdd: rule |
|
654 |
||
655 |
self selection: |
|
656 |
(self selection addAll: rule flattened; yourself) |
|
657 |
||
17361 | 658 |
"Created: / 25-08-2010 / 13:34:57 / Jan Vrany" |
10000 | 659 |
! |
660 |
||
661 |
selectionIncludes: rule |
|
662 |
||
663 |
^self rules: self selection includes: rule |
|
664 |
||
17361 | 665 |
"Created: / 25-08-2010 / 13:30:14 / Jan Vrany" |
666 |
"Modified: / 26-08-2010 / 12:04:19 / Jan Vrany" |
|
10000 | 667 |
! |
668 |
||
669 |
selectionRemove: rule |
|
670 |
||
671 |
| sel rules | |
|
672 |
sel := self selection. |
|
673 |
rules := rule flattened. |
|
674 |
sel := sel reject: |
|
675 |
[:each|self rules: rules includes: each]. |
|
676 |
self selection: sel |
|
677 |
||
17361 | 678 |
"Created: / 25-08-2010 / 13:35:08 / Jan Vrany" |
679 |
"Modified: / 26-08-2010 / 12:05:06 / Jan Vrany" |
|
10000 | 680 |
! ! |
681 |
||
682 |
!LintRuleList::ListEntry class methodsFor:'instance creation'! |
|
683 |
||
684 |
change: aChange |
|
685 |
||
686 |
^self new change: aChange |
|
687 |
||
688 |
"Created: / 24-07-2009 / 22:43:41 / Jan Vrany <vranyj1@fel.cvut.cz>" |
|
689 |
! |
|
690 |
||
691 |
change: aChange application: anApplicationModel |
|
692 |
||
693 |
^self new change: aChange; application: anApplicationModel |
|
694 |
||
695 |
"Created: / 05-12-2009 / 14:16:33 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
696 |
! |
|
697 |
||
698 |
change: aChange parent: aChangeList |
|
699 |
||
700 |
^self new change: aChange; parent: aChangeList |
|
701 |
||
702 |
"Created: / 25-07-2009 / 23:33:00 / Jan Vrany <vranyj1@fel.cvut.cz>" |
|
703 |
! ! |
|
704 |
||
705 |
!LintRuleList::ListEntry methodsFor:'accessing'! |
|
706 |
||
707 |
application |
|
14169
d983f6273b6d
Fixed LintRileList>>selectionChanged so it works both in browser and in dialog. Bit hacky.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14165
diff
changeset
|
708 |
^ application notNil ifTrue:[application] ifFalse:[super application] |
10000 | 709 |
|
14169
d983f6273b6d
Fixed LintRileList>>selectionChanged so it works both in browser and in dialog. Bit hacky.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14165
diff
changeset
|
710 |
"Modified: / 28-03-2014 / 10:36:35 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
10000 | 711 |
! |
712 |
||
713 |
application:anApplicationModel |
|
714 |
application := anApplicationModel. |
|
715 |
! |
|
716 |
||
717 |
checked |
|
718 |
||
719 |
^rule isComposite |
|
720 |
ifTrue:[self children anySatisfy:[:each|each checked]] |
|
721 |
ifFalse:[self application selectionIncludes: rule] |
|
722 |
||
723 |
"Modified: / 15-04-2010 / 20:59:52 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
17361 | 724 |
"Modified: / 25-08-2010 / 13:29:33 / Jan Vrany" |
10000 | 725 |
! |
726 |
||
727 |
checked:aBoolean |
|
728 |
||
729 |
| app | |
|
730 |
app := self application. |
|
731 |
aBoolean |
|
732 |
ifTrue: [app selectionAdd: rule] |
|
733 |
ifFalse:[app selectionRemove: rule] |
|
734 |
||
735 |
"Modified: / 15-04-2010 / 19:06:15 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
17361 | 736 |
"Modified: / 25-08-2010 / 13:35:29 / Jan Vrany" |
10000 | 737 |
! |
738 |
||
739 |
checkedRule |
|
740 |
||
741 |
self checked ifFalse:[^nil]. |
|
742 |
||
743 |
rule isComposite |
|
744 |
ifTrue: |
|
745 |
[^rule copy |
|
746 |
rules: (self children |
|
747 |
collect:[:entry|entry checkedRule] |
|
748 |
thenReject:[:rule|rule isNil]); |
|
749 |
yourself] |
|
750 |
ifFalse: |
|
751 |
[^rule] |
|
752 |
||
753 |
"Created: / 16-04-2010 / 12:06:28 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
754 |
! |
|
755 |
||
756 |
children |
|
14671 | 757 |
children ifNil:[ |
758 |
rule isComposite ifTrue: [ |
|
759 |
| app | |
|
760 |
||
761 |
app := self application. |
|
762 |
children := rule rules collect:[:eachRule | (app listEntryFor:eachRule) parent:self] |
|
763 |
] ifFalse: [ |
|
764 |
children := #() |
|
765 |
] |
|
766 |
]. |
|
10000 | 767 |
|
768 |
^ children |
|
769 |
||
770 |
"Created: / 25-07-2009 / 23:32:39 / Jan Vrany <vranyj1@fel.cvut.cz>" |
|
771 |
"Modified: / 15-04-2010 / 20:40:06 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
772 |
! |
|
773 |
||
774 |
failedClasses |
|
775 |
||
776 |
^rule failedClasses |
|
777 |
||
778 |
"Created: / 15-04-2010 / 19:10:55 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
779 |
! |
|
780 |
||
781 |
failedMethods |
|
782 |
||
783 |
^rule failedMethods |
|
784 |
||
785 |
"Created: / 15-04-2010 / 19:10:51 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
786 |
! |
|
787 |
||
788 |
failedMethodsInAnyOf: classes meta: meta |
|
789 |
||
790 |
^rule failedMethodsInAnyOf: classes meta: meta |
|
791 |
||
792 |
"Created: / 15-04-2010 / 19:11:35 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
793 |
! |
|
794 |
||
795 |
label |
|
16872 | 796 |
|s severity| |
797 |
||
798 |
s := rule displayString. |
|
799 |
(severity := rule severity) == #warning ifTrue:[ |
|
800 |
^ s withColor:Color orange. |
|
801 |
]. |
|
802 |
severity == #error ifTrue:[ |
|
803 |
^ s withColor:Color red. |
|
804 |
]. |
|
805 |
severity == #information ifFalse:[ |
|
806 |
self halt. |
|
807 |
]. |
|
808 |
^ s |
|
10000 | 809 |
|
810 |
"Modified: / 15-04-2010 / 18:44:25 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
811 |
! |
|
812 |
||
813 |
name |
|
814 |
||
815 |
^rule name |
|
816 |
||
817 |
"Created: / 15-04-2010 / 19:12:19 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
818 |
! |
|
819 |
||
820 |
rationale |
|
11315 | 821 |
^ rule rationaleWithAnchor |
10000 | 822 |
|
823 |
"Created: / 15-04-2010 / 19:10:20 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
11315 | 824 |
"Modified: / 01-03-2012 / 20:58:50 / cg" |
10000 | 825 |
! |
826 |
||
11317 | 827 |
rationaleWithAnchor |
828 |
^ rule rationaleWithAnchor |
|
829 |
||
830 |
"Created: / 15-04-2010 / 19:10:20 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
831 |
"Modified: / 01-03-2012 / 20:58:50 / cg" |
|
832 |
"Created: / 02-03-2012 / 01:04:40 / cg" |
|
833 |
! |
|
834 |
||
10000 | 835 |
rule |
836 |
^ rule |
|
837 |
! |
|
838 |
||
839 |
rule:anRBLintRule |
|
840 |
rule := anRBLintRule. |
|
841 |
! |
|
842 |
||
843 |
x |
|
844 |
^ x ? 0 |
|
845 |
||
846 |
"Modified: / 15-04-2010 / 20:48:50 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
847 |
! ! |
|
848 |
||
849 |
!LintRuleList::ListEntry methodsFor:'displaying'! |
|
850 |
||
851 |
displayLabel:aLabel h:lH on:aGC x:newX y:y h:h |
|
16872 | 852 |
self displayLabel:aLabel h:lH on:aGC x:newX y:y h:h isHighlightedAsSelected:false |
10000 | 853 |
! |
854 |
||
15151 | 855 |
displayLabel:aLabel h:lH on:aGC x:newX y:y h:h isHighlightedAsSelected:isHighlightedAsSelected |
856 |
| cx icon app mode | |
|
857 |
||
858 |
cx := x := newX. |
|
859 |
app := self application. |
|
860 |
mode := app mode. |
|
861 |
mode ~~ #display ifTrue:[ |
|
862 |
mode == #select ifTrue:[ |
|
863 |
icon := self checked |
|
864 |
ifTrue:[app class checkedIcon] |
|
865 |
ifFalse:[app class uncheckedIcon]. |
|
866 |
] ifFalse:[ |
|
867 |
icon := self checked |
|
868 |
ifTrue:[app class checkedIconDisabled] |
|
869 |
ifFalse:[app class uncheckedIconDisabled]. |
|
870 |
]. |
|
871 |
icon displayOn: aGC x: cx y: y + (h / 2) - (icon height / 2). |
|
872 |
cx := cx + 22."experimental value - this looks good" |
|
873 |
]. |
|
874 |
||
875 |
super displayLabel:aLabel h:lH on:aGC x:cx y:y h:h isHighlightedAsSelected:isHighlightedAsSelected |
|
876 |
||
877 |
"Modified (format): / 07-03-2012 / 20:08:02 / cg" |
|
878 |
"Modified: / 08-10-2014 / 22:56:33 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
879 |
! |
|
880 |
||
13320
3dd1b4cb9c39
Refactor to implement #displayOn:aGcOrStream instead of #displayString
Stefan Vogel <sv@exept.de>
parents:
12035
diff
changeset
|
881 |
displayOn:aGCOrStream |
10000 | 882 |
|
13320
3dd1b4cb9c39
Refactor to implement #displayOn:aGcOrStream instead of #displayString
Stefan Vogel <sv@exept.de>
parents:
12035
diff
changeset
|
883 |
"/ what a kludge - Dolphin and Squeak mean: printOn: a stream; |
17429 | 884 |
"/ old ST80 means: draw-yourself on a GC. |
13320
3dd1b4cb9c39
Refactor to implement #displayOn:aGcOrStream instead of #displayString
Stefan Vogel <sv@exept.de>
parents:
12035
diff
changeset
|
885 |
(aGCOrStream isStream) ifFalse:[ |
3dd1b4cb9c39
Refactor to implement #displayOn:aGcOrStream instead of #displayString
Stefan Vogel <sv@exept.de>
parents:
12035
diff
changeset
|
886 |
^ super displayOn:aGCOrStream |
3dd1b4cb9c39
Refactor to implement #displayOn:aGcOrStream instead of #displayString
Stefan Vogel <sv@exept.de>
parents:
12035
diff
changeset
|
887 |
]. |
3dd1b4cb9c39
Refactor to implement #displayOn:aGcOrStream instead of #displayString
Stefan Vogel <sv@exept.de>
parents:
12035
diff
changeset
|
888 |
|
13798 | 889 |
rule displayOn:aGCOrStream |
10000 | 890 |
|
891 |
"Created: / 15-04-2010 / 19:13:06 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
13798 | 892 |
"Modified: / 29-11-2013 / 12:59:23 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
17429 | 893 |
"Modified (comment): / 22-02-2017 / 16:49:46 / cg" |
10000 | 894 |
! ! |
895 |
||
896 |
!LintRuleList class methodsFor:'documentation'! |
|
897 |
||
11300
b9accf9080e4
better rationale (link to class)
Claus Gittinger <cg@exept.de>
parents:
11297
diff
changeset
|
898 |
version |
16426 | 899 |
^ '$Header$' |
11300
b9accf9080e4
better rationale (link to class)
Claus Gittinger <cg@exept.de>
parents:
11297
diff
changeset
|
900 |
! |
b9accf9080e4
better rationale (link to class)
Claus Gittinger <cg@exept.de>
parents:
11297
diff
changeset
|
901 |
|
10000 | 902 |
version_CVS |
16426 | 903 |
^ '$Header$' |
10000 | 904 |
! |
905 |
||
906 |
version_SVN |
|
16426 | 907 |
^ '$Id$' |
10000 | 908 |
! ! |
13320
3dd1b4cb9c39
Refactor to implement #displayOn:aGcOrStream instead of #displayString
Stefan Vogel <sv@exept.de>
parents:
12035
diff
changeset
|
909 |