author | Claus Gittinger <cg@exept.de> |
Wed, 11 Oct 2000 09:44:07 +0200 | |
changeset 5661 | 53b7fca35f27 |
parent 5637 | d6ea7c5dcaf9 |
child 5712 | c723e5d4cd83 |
permissions | -rw-r--r-- |
3347 | 1 |
" |
2 |
COPYRIGHT (c) 1998 by eXept Software AG |
|
3 |
All Rights Reserved |
|
4 |
||
5 |
This software is furnished under a license and may be used |
|
6 |
only in accordance with the terms of that license and with the |
|
7 |
inclusion of the above copyright notice. This software may not |
|
8 |
be provided or otherwise made available to, or used by, any |
|
9 |
other person. No title to or ownership of the software is |
|
10 |
hereby transferred. |
|
11 |
" |
|
12 |
||
13 |
||
5516 | 14 |
"{ Package: 'stx:libbasic' }" |
15 |
||
3347 | 16 |
IdentityDictionary subclass:#UserPreferences |
17 |
instanceVariableNames:'' |
|
4317
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
18 |
classVariableNames:'CurrentPreferences DefaultPreferences' |
3347 | 19 |
poolDictionaries:'' |
20 |
category:'System-Support' |
|
21 |
! |
|
22 |
||
23 |
!UserPreferences class methodsFor:'documentation'! |
|
24 |
||
25 |
copyright |
|
26 |
" |
|
27 |
COPYRIGHT (c) 1998 by eXept Software AG |
|
28 |
All Rights Reserved |
|
29 |
||
30 |
This software is furnished under a license and may be used |
|
31 |
only in accordance with the terms of that license and with the |
|
32 |
inclusion of the above copyright notice. This software may not |
|
33 |
be provided or otherwise made available to, or used by, any |
|
34 |
other person. No title to or ownership of the software is |
|
35 |
hereby transferred. |
|
36 |
" |
|
37 |
||
38 |
! |
|
39 |
||
40 |
documentation |
|
41 |
" |
|
4582
31cbce168a1d
return false for nonexisting keys
Claus Gittinger <cg@exept.de>
parents:
4580
diff
changeset
|
42 |
A Dictionary for user preference values. |
31cbce168a1d
return false for nonexisting keys
Claus Gittinger <cg@exept.de>
parents:
4580
diff
changeset
|
43 |
For non-existing keys, either a defaultValue (false), |
31cbce168a1d
return false for nonexisting keys
Claus Gittinger <cg@exept.de>
parents:
4580
diff
changeset
|
44 |
or the value from a defaultDictionary is returned. |
3353 | 45 |
|
3359 | 46 |
This will eventually keep track of ALL user preferences. |
47 |
(which are currently spread over the system). |
|
48 |
For now, only a few preferences are found here - but this |
|
49 |
will change over time. |
|
4582
31cbce168a1d
return false for nonexisting keys
Claus Gittinger <cg@exept.de>
parents:
4580
diff
changeset
|
50 |
|
31cbce168a1d
return false for nonexisting keys
Claus Gittinger <cg@exept.de>
parents:
4580
diff
changeset
|
51 |
UserPreferences current at:#foo |
3347 | 52 |
" |
53 |
! ! |
|
54 |
||
4317
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
55 |
!UserPreferences class methodsFor:'initialization'! |
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
56 |
|
4580 | 57 |
initializeDefaultPreferences |
4317
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
58 |
DefaultPreferences := self new. |
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
59 |
|
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
60 |
#( |
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
61 |
#useNewChangesBrowser false |
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
62 |
#useNewInspector false |
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
63 |
|
5236 | 64 |
#autoFormatting false |
4317
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
65 |
#syntaxColoring true |
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
66 |
#fullSelectorCheck false |
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
67 |
|
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
68 |
#defaultSyntaxColor (Color black) |
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
69 |
#defaultSyntaxEmphasis normal |
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
70 |
|
4343 | 71 |
#errorColor (Color red) |
72 |
||
4317
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
73 |
#commentColor (Color 12.5 12.5 100) |
5114 | 74 |
#commentEmphasis normal |
4317
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
75 |
|
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
76 |
#methodSelectorEmphasis bold |
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
77 |
#selectorEmphasis bold |
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
78 |
#unimplementedSelectorColor (Color red) |
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
79 |
#unimplementedSelectorEmphasis normal |
4326
9b1d4f1bf719
inserted badIdentifierColor & emphasis
Claus Gittinger <cg@exept.de>
parents:
4320
diff
changeset
|
80 |
|
4335
b301d2c92490
underwave red for bad identifiers
Claus Gittinger <cg@exept.de>
parents:
4331
diff
changeset
|
81 |
"/ I prefer red-underwave over red identifier ... |
b301d2c92490
underwave red for bad identifiers
Claus Gittinger <cg@exept.de>
parents:
4331
diff
changeset
|
82 |
"/ #badIdentifierColor (Color red) |
4317
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
83 |
|
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
84 |
#constantColor (Color 25 0 0) |
4330
a90c5a801fdf
added #showClockInLauncher setting
Claus Gittinger <cg@exept.de>
parents:
4327
diff
changeset
|
85 |
|
a90c5a801fdf
added #showClockInLauncher setting
Claus Gittinger <cg@exept.de>
parents:
4327
diff
changeset
|
86 |
#showClockInLauncher true |
4317
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
87 |
) pairWiseDo:[:k :v | |
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
88 |
DefaultPreferences at:k put:v decodeAsLiteralArray. |
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
89 |
]. |
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
90 |
|
4335
b301d2c92490
underwave red for bad identifiers
Claus Gittinger <cg@exept.de>
parents:
4331
diff
changeset
|
91 |
"/ I prefer red-underwave over red identifier ... |
b301d2c92490
underwave red for bad identifiers
Claus Gittinger <cg@exept.de>
parents:
4331
diff
changeset
|
92 |
DefaultPreferences at:#badIdentifierEmphasis put:(Array with:#underwave with:(#underlineColor->Color red)). |
b301d2c92490
underwave red for bad identifiers
Claus Gittinger <cg@exept.de>
parents:
4331
diff
changeset
|
93 |
|
4317
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
94 |
" |
4580 | 95 |
self initializeDefaultPreferences |
4317
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
96 |
" |
4335
b301d2c92490
underwave red for bad identifiers
Claus Gittinger <cg@exept.de>
parents:
4331
diff
changeset
|
97 |
|
5236 | 98 |
"Modified: / 4.2.2000 / 20:06:53 / cg" |
4317
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
99 |
! ! |
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
100 |
|
3347 | 101 |
!UserPreferences class methodsFor:'accessing'! |
102 |
||
103 |
current |
|
104 |
CurrentPreferences isNil ifTrue:[ |
|
4330
a90c5a801fdf
added #showClockInLauncher setting
Claus Gittinger <cg@exept.de>
parents:
4327
diff
changeset
|
105 |
CurrentPreferences := self new. |
4580 | 106 |
CurrentPreferences declareAllFrom:(self default). |
3347 | 107 |
]. |
108 |
^ CurrentPreferences. |
|
109 |
||
110 |
"Created: / 31.3.1998 / 13:43:03 / cg" |
|
3364 | 111 |
! |
112 |
||
4318 | 113 |
default |
4580 | 114 |
DefaultPreferences isNil ifTrue:[ |
4582
31cbce168a1d
return false for nonexisting keys
Claus Gittinger <cg@exept.de>
parents:
4580
diff
changeset
|
115 |
self initializeDefaultPreferences |
4580 | 116 |
]. |
4318 | 117 |
^ DefaultPreferences. |
118 |
||
4582
31cbce168a1d
return false for nonexisting keys
Claus Gittinger <cg@exept.de>
parents:
4580
diff
changeset
|
119 |
" |
31cbce168a1d
return false for nonexisting keys
Claus Gittinger <cg@exept.de>
parents:
4580
diff
changeset
|
120 |
DefaultPreferences := nil. |
31cbce168a1d
return false for nonexisting keys
Claus Gittinger <cg@exept.de>
parents:
4580
diff
changeset
|
121 |
" |
4318 | 122 |
! |
123 |
||
3364 | 124 |
reset |
125 |
"resets the CurrentPreferences to its default values" |
|
126 |
||
127 |
CurrentPreferences := nil |
|
128 |
! |
|
129 |
||
4342
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
130 |
syntaxColorKeys |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
131 |
"returns the keys of syntax color items" |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
132 |
|
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
133 |
^#( |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
134 |
argumentIdentifierColor |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
135 |
argumentIdentifierEmphasis |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
136 |
booleanConstantColor |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
137 |
booleanConstantEmphasis |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
138 |
bracketColor |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
139 |
bracketEmphasis |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
140 |
classVariableIdentifierColor |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
141 |
classVariableIdentifierEmphasis |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
142 |
constantColor |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
143 |
constantEmphasis |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
144 |
commentColor |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
145 |
commentEmphasis |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
146 |
defaultSyntaxColor |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
147 |
defaultSyntaxEmphasis |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
148 |
errorColor |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
149 |
globalIdentifierColor |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
150 |
globalIdentifierEmphasis |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
151 |
globalClassIdentifierColor |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
152 |
globalClassIdentifierEmphasis |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
153 |
hereColor |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
154 |
hereEmphasis |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
155 |
identifierColor |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
156 |
identifierEmphasis |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
157 |
instVarIdentifierColor |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
158 |
instVarIdentifierEmphasis |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
159 |
localIdentifierColor |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
160 |
localIdentifierEmphasis |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
161 |
methodSelectorColor |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
162 |
methodSelectorEmphasis |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
163 |
returnColor |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
164 |
returnEmphasis |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
165 |
selectorColor |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
166 |
selectorEmphasis |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
167 |
selfColor |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
168 |
selfEmphasis |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
169 |
stringColor |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
170 |
stringEmphasis |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
171 |
superColor |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
172 |
superEmphasis |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
173 |
symbolColor |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
174 |
symbolEmphasis |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
175 |
thisContextColor |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
176 |
thisContextEmphasis |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
177 |
unknownIdentifierColor |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
178 |
unknownIdentifierEmphasis |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
179 |
unimplementedSelectorColor |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
180 |
unimplementedSelectorEmphasis |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
181 |
) |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
182 |
|
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
183 |
"Modified: / 5.1.1980 / 00:48:09 / cg" |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
184 |
! |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
185 |
|
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
186 |
syntaxColorNames |
3364 | 187 |
"returns the syntax colors for the settings in the launcher" |
188 |
||
4319 | 189 |
"/ warning, the strings below are presented to the user |
190 |
"/ as the syntax-color boxes comboList - however, they are |
|
191 |
"/ also used (without separators) as key into myself. |
|
192 |
"/ Therefore, do not change the strings below. |
|
193 |
"/ I know - this is bad coding .... |
|
194 |
||
3364 | 195 |
^#( |
196 |
'Argument Identifier Color' |
|
197 |
'Boolean Constant Color' |
|
198 |
'Bracket Color' |
|
4320 | 199 |
'Class Variable Identifier Color' |
3364 | 200 |
'Constant Color' |
201 |
'Comment Color' |
|
202 |
'Global Identifier Color' |
|
4024
3a223c79e41c
added extra globalClassIdentifierColor & emphasis
Claus Gittinger <cg@exept.de>
parents:
4023
diff
changeset
|
203 |
'Global Class Identifier Color' |
3364 | 204 |
'Here Color' |
205 |
'Identifier Color' |
|
3377 | 206 |
'InstVar Identifier Color' |
3364 | 207 |
'Local Identifier Color' |
208 |
'Method Selector Color' |
|
4076 | 209 |
'Return Color' |
3364 | 210 |
'Selector Color' |
211 |
'Self Color' |
|
212 |
'String Color' |
|
213 |
'Super Color' |
|
214 |
'Symbol Color' |
|
215 |
'This Context Color' |
|
216 |
'Unknown Identifier Color' |
|
4319 | 217 |
'Unimplemented Selector Color' |
3377 | 218 |
) |
3364 | 219 |
|
4076 | 220 |
"Modified: / 5.1.1980 / 00:48:09 / cg" |
3347 | 221 |
! ! |
222 |
||
5236 | 223 |
!UserPreferences methodsFor:'accessing-pref''d tools'! |
3883 | 224 |
|
225 |
changesBrowserClass |
|
226 |
self useNewChangesBrowser ifTrue:[ |
|
227 |
^ NewChangesBrowser |
|
228 |
]. |
|
229 |
^ ChangesBrowser |
|
230 |
||
231 |
"Created: / 17.10.1998 / 14:37:46 / cg" |
|
5535 | 232 |
! |
233 |
||
5541 | 234 |
inspectorClass |
235 |
self useNewInspector ifTrue:[ |
|
236 |
^ NewInspector::NewInspectorView |
|
237 |
]. |
|
238 |
^ InspectorView |
|
239 |
! |
|
240 |
||
5535 | 241 |
systemBrowserClass |
242 |
self useNewSystemBrowser ifTrue:[ |
|
243 |
^ NewSystemBrowser |
|
244 |
]. |
|
245 |
^ SystemBrowser |
|
5536 | 246 |
! |
247 |
||
248 |
useNewChangesBrowser |
|
249 |
"using new or old change browser" |
|
250 |
||
251 |
^ self at:#useNewChangesBrowser ifAbsentPut:false |
|
252 |
||
253 |
"Modified: / 13.10.1998 / 15:53:05 / cg" |
|
254 |
! |
|
255 |
||
256 |
useNewChangesBrowser:aBoolean |
|
257 |
"using new or old changeBrowser" |
|
258 |
||
5541 | 259 |
aBoolean ifTrue:[ |
5661 | 260 |
NewChangesBrowser isNil ifTrue:[ |
261 |
'UserPreferences [warning]: no NewChangesBrowser class in system' infoPrintCR. |
|
262 |
^ self |
|
263 |
]. |
|
5541 | 264 |
NewChangesBrowser autoload |
265 |
]. |
|
5536 | 266 |
^ self at:#useNewChangesBrowser put:aBoolean |
267 |
||
268 |
" |
|
269 |
UserPreferences current useNewChangesBrowser |
|
270 |
" |
|
271 |
||
272 |
"Modified: / 13.10.1998 / 15:53:21 / cg" |
|
273 |
! |
|
274 |
||
275 |
useNewInspector |
|
276 |
"using new or old inspector" |
|
277 |
||
278 |
^ self at:#useNewInspector ifAbsentPut:false |
|
279 |
||
280 |
" |
|
281 |
UserPreferences current useNewInspector |
|
282 |
" |
|
283 |
||
284 |
"Modified: / 17.10.1998 / 14:45:12 / cg" |
|
285 |
! |
|
286 |
||
287 |
useNewInspector:aBoolean |
|
288 |
"using new or old inspector" |
|
289 |
||
5541 | 290 |
aBoolean ifTrue:[ |
5661 | 291 |
NewInspector::NewInspectorView isNil ifTrue:[ |
292 |
'UserPreferences [warning]: no NewInspector class in system' infoPrintCR. |
|
293 |
^ self |
|
294 |
]. |
|
5541 | 295 |
NewInspector::NewInspectorView autoload |
296 |
]. |
|
5536 | 297 |
^ self at:#useNewInspector put:aBoolean |
298 |
||
299 |
" |
|
300 |
UserPreferences current useNewInspector |
|
301 |
" |
|
302 |
! |
|
303 |
||
304 |
useNewSystemBrowser |
|
305 |
"using new or old system browser" |
|
306 |
||
307 |
^ self at:#useNewSystemBrowser ifAbsentPut:false |
|
308 |
||
309 |
"Modified: / 13.10.1998 / 15:53:05 / cg" |
|
310 |
! |
|
311 |
||
312 |
useNewSystemBrowser:aBoolean |
|
313 |
"using new or old systemBrowser" |
|
314 |
||
5541 | 315 |
aBoolean ifTrue:[ |
5637 | 316 |
NewSystemBrowser isNil ifTrue:[ |
317 |
'UserPreferences [warning]: no NewSystemBrowser class in system' infoPrintCR. |
|
318 |
^ self. |
|
319 |
]. |
|
5541 | 320 |
NewSystemBrowser autoload |
321 |
]. |
|
5536 | 322 |
^ self at:#useNewSystemBrowser put:aBoolean |
323 |
||
324 |
" |
|
5541 | 325 |
UserPreferences current useNewSystemBrowser:true |
5536 | 326 |
" |
327 |
||
328 |
"Modified: / 13.10.1998 / 15:53:21 / cg" |
|
329 |
! |
|
330 |
||
331 |
useNewVersionDiffBrowser |
|
332 |
"using new or old version diff viewer" |
|
333 |
||
334 |
^ self at:#useNewVersionDiffBrowser ifAbsentPut:false |
|
335 |
||
336 |
"Modified: / 13.10.1998 / 15:53:05 / cg" |
|
337 |
! |
|
338 |
||
339 |
useNewVersionDiffBrowser:aBoolean |
|
340 |
"using new or old useNewVersionDiffBrowser" |
|
341 |
||
5541 | 342 |
aBoolean ifTrue:[ |
5661 | 343 |
VersionDiffBrowser isNil ifTrue:[ |
344 |
'UserPreferences [warning]: no VersionDiffBrowser class in system' infoPrintCR. |
|
345 |
^ self |
|
346 |
]. |
|
5541 | 347 |
VersionDiffBrowser autoload |
348 |
]. |
|
5536 | 349 |
^ self at:#useNewVersionDiffBrowser put:aBoolean |
350 |
||
351 |
" |
|
352 |
UserPreferences current useNewVersionDiffBrowser |
|
353 |
" |
|
354 |
||
355 |
"Modified: / 13.10.1998 / 15:53:21 / cg" |
|
356 |
! |
|
357 |
||
358 |
versionDiffViewerClass |
|
359 |
self useNewVersionDiffBrowser ifTrue:[ |
|
360 |
^ VersionDiffBrowser |
|
361 |
]. |
|
362 |
^ DiffTextView |
|
3883 | 363 |
! ! |
364 |
||
5236 | 365 |
!UserPreferences methodsFor:'accessing-prefs'! |
366 |
||
367 |
autoFormatting |
|
368 |
"return the flag which controls automatic formatting of code (in some browsers) |
|
369 |
Notice, the regular browser does not (yet) do automatic formating." |
|
370 |
||
371 |
^ self at:#autoFormatting ifAbsentPut:false |
|
372 |
||
373 |
" |
|
374 |
UserPreferences current autoFormatting |
|
375 |
" |
|
376 |
||
377 |
"Created: / 4.2.2000 / 20:08:08 / cg" |
|
378 |
"Modified: / 5.2.2000 / 15:38:33 / cg" |
|
379 |
! |
|
380 |
||
381 |
autoFormatting:aBoolean |
|
382 |
"turn on/off automatic formatting of code (in some browsers); |
|
383 |
Notice, the regular browser does not (yet) do automatic formating." |
|
384 |
||
385 |
^ self at:#autoFormatting put:aBoolean |
|
386 |
||
387 |
" |
|
388 |
UserPreferences current autoFormatting:true |
|
389 |
UserPreferences current autoFormatting:false |
|
390 |
" |
|
391 |
||
392 |
"Created: / 4.2.2000 / 20:08:26 / cg" |
|
393 |
"Modified: / 5.2.2000 / 15:38:20 / cg" |
|
394 |
! |
|
3358 | 395 |
|
5071 | 396 |
beepEnabled |
397 |
"return the flag which controls the beeper" |
|
398 |
||
399 |
^ self at:#beepEnabled ifAbsentPut:true |
|
400 |
||
401 |
" |
|
402 |
UserPreferences current beepEnabled |
|
403 |
" |
|
404 |
||
405 |
"Modified: / 11.9.1998 / 00:09:59 / cg" |
|
406 |
"Created: / 3.12.1999 / 17:09:49 / ps" |
|
407 |
! |
|
408 |
||
409 |
beepEnabled:aBoolean |
|
410 |
"set/clear the flag which controls the beeper" |
|
411 |
||
412 |
^ self at:#beepEnabled put:aBoolean |
|
413 |
||
414 |
" |
|
415 |
UserPreferences current beepEnabled:false |
|
416 |
" |
|
417 |
||
418 |
"Modified: / 11.9.1998 / 00:09:59 / cg" |
|
419 |
"Created: / 3.12.1999 / 17:10:27 / ps" |
|
420 |
! |
|
421 |
||
4075
816898d4922c
added #focusFollowsMouse setting
Claus Gittinger <cg@exept.de>
parents:
4024
diff
changeset
|
422 |
focusFollowsMouse |
816898d4922c
added #focusFollowsMouse setting
Claus Gittinger <cg@exept.de>
parents:
4024
diff
changeset
|
423 |
"return the flag which controls if the keyboard focus should |
816898d4922c
added #focusFollowsMouse setting
Claus Gittinger <cg@exept.de>
parents:
4024
diff
changeset
|
424 |
follow the mouse (as in X) - as opposed to click mode (as in MS-win). |
816898d4922c
added #focusFollowsMouse setting
Claus Gittinger <cg@exept.de>
parents:
4024
diff
changeset
|
425 |
This only affects certain widgets (EditFields, EditTextViews and SelectionInListViews). |
816898d4922c
added #focusFollowsMouse setting
Claus Gittinger <cg@exept.de>
parents:
4024
diff
changeset
|
426 |
The returned value has 3 states: true/false and nil, which means: as defined in styleSheet." |
816898d4922c
added #focusFollowsMouse setting
Claus Gittinger <cg@exept.de>
parents:
4024
diff
changeset
|
427 |
|
816898d4922c
added #focusFollowsMouse setting
Claus Gittinger <cg@exept.de>
parents:
4024
diff
changeset
|
428 |
^ self at:#focusFollowsMouse ifAbsent:nil |
816898d4922c
added #focusFollowsMouse setting
Claus Gittinger <cg@exept.de>
parents:
4024
diff
changeset
|
429 |
|
816898d4922c
added #focusFollowsMouse setting
Claus Gittinger <cg@exept.de>
parents:
4024
diff
changeset
|
430 |
" |
816898d4922c
added #focusFollowsMouse setting
Claus Gittinger <cg@exept.de>
parents:
4024
diff
changeset
|
431 |
UserPreferences current focusFollowsMouse |
816898d4922c
added #focusFollowsMouse setting
Claus Gittinger <cg@exept.de>
parents:
4024
diff
changeset
|
432 |
" |
816898d4922c
added #focusFollowsMouse setting
Claus Gittinger <cg@exept.de>
parents:
4024
diff
changeset
|
433 |
|
816898d4922c
added #focusFollowsMouse setting
Claus Gittinger <cg@exept.de>
parents:
4024
diff
changeset
|
434 |
"Modified: / 11.9.1998 / 00:09:59 / cg" |
816898d4922c
added #focusFollowsMouse setting
Claus Gittinger <cg@exept.de>
parents:
4024
diff
changeset
|
435 |
! |
816898d4922c
added #focusFollowsMouse setting
Claus Gittinger <cg@exept.de>
parents:
4024
diff
changeset
|
436 |
|
816898d4922c
added #focusFollowsMouse setting
Claus Gittinger <cg@exept.de>
parents:
4024
diff
changeset
|
437 |
focusFollowsMouse:aBooleanOrNil |
4121 | 438 |
"set/clear the flag which controls if the keyboard focus should |
4075
816898d4922c
added #focusFollowsMouse setting
Claus Gittinger <cg@exept.de>
parents:
4024
diff
changeset
|
439 |
follow the mouse (as in X) - as opposed to click mode (as in MS-win). |
816898d4922c
added #focusFollowsMouse setting
Claus Gittinger <cg@exept.de>
parents:
4024
diff
changeset
|
440 |
This only affects certain widgets (EditFields, EditTextViews and SelectionInListViews). |
816898d4922c
added #focusFollowsMouse setting
Claus Gittinger <cg@exept.de>
parents:
4024
diff
changeset
|
441 |
Allowed are: true/false and nil, which means: as defined in styleSheet." |
816898d4922c
added #focusFollowsMouse setting
Claus Gittinger <cg@exept.de>
parents:
4024
diff
changeset
|
442 |
|
816898d4922c
added #focusFollowsMouse setting
Claus Gittinger <cg@exept.de>
parents:
4024
diff
changeset
|
443 |
^ self at:#focusFollowsMouse put:aBooleanOrNil |
816898d4922c
added #focusFollowsMouse setting
Claus Gittinger <cg@exept.de>
parents:
4024
diff
changeset
|
444 |
|
816898d4922c
added #focusFollowsMouse setting
Claus Gittinger <cg@exept.de>
parents:
4024
diff
changeset
|
445 |
" |
4121 | 446 |
UserPreferences current focusFollowsMouse:true |
447 |
UserPreferences current focusFollowsMouse:false |
|
4075
816898d4922c
added #focusFollowsMouse setting
Claus Gittinger <cg@exept.de>
parents:
4024
diff
changeset
|
448 |
UserPreferences current focusFollowsMouse |
816898d4922c
added #focusFollowsMouse setting
Claus Gittinger <cg@exept.de>
parents:
4024
diff
changeset
|
449 |
" |
816898d4922c
added #focusFollowsMouse setting
Claus Gittinger <cg@exept.de>
parents:
4024
diff
changeset
|
450 |
|
816898d4922c
added #focusFollowsMouse setting
Claus Gittinger <cg@exept.de>
parents:
4024
diff
changeset
|
451 |
"Modified: / 11.9.1998 / 00:09:59 / cg" |
816898d4922c
added #focusFollowsMouse setting
Claus Gittinger <cg@exept.de>
parents:
4024
diff
changeset
|
452 |
! |
816898d4922c
added #focusFollowsMouse setting
Claus Gittinger <cg@exept.de>
parents:
4024
diff
changeset
|
453 |
|
4396
951890a68aba
added functionKeySequences (no need for a global)
Claus Gittinger <cg@exept.de>
parents:
4344
diff
changeset
|
454 |
functionKeySequences |
951890a68aba
added functionKeySequences (no need for a global)
Claus Gittinger <cg@exept.de>
parents:
4344
diff
changeset
|
455 |
"return the collection of function-key macros. |
951890a68aba
added functionKeySequences (no need for a global)
Claus Gittinger <cg@exept.de>
parents:
4344
diff
changeset
|
456 |
Thats a dictionary, which assigns code to F-keys" |
951890a68aba
added functionKeySequences (no need for a global)
Claus Gittinger <cg@exept.de>
parents:
4344
diff
changeset
|
457 |
|
951890a68aba
added functionKeySequences (no need for a global)
Claus Gittinger <cg@exept.de>
parents:
4344
diff
changeset
|
458 |
^ self at:#functionKeySequences ifAbsentPut:[Dictionary new] |
951890a68aba
added functionKeySequences (no need for a global)
Claus Gittinger <cg@exept.de>
parents:
4344
diff
changeset
|
459 |
|
951890a68aba
added functionKeySequences (no need for a global)
Claus Gittinger <cg@exept.de>
parents:
4344
diff
changeset
|
460 |
" |
951890a68aba
added functionKeySequences (no need for a global)
Claus Gittinger <cg@exept.de>
parents:
4344
diff
changeset
|
461 |
UserPreferences current functionKeySequences |
951890a68aba
added functionKeySequences (no need for a global)
Claus Gittinger <cg@exept.de>
parents:
4344
diff
changeset
|
462 |
" |
951890a68aba
added functionKeySequences (no need for a global)
Claus Gittinger <cg@exept.de>
parents:
4344
diff
changeset
|
463 |
|
951890a68aba
added functionKeySequences (no need for a global)
Claus Gittinger <cg@exept.de>
parents:
4344
diff
changeset
|
464 |
"Modified: / 11.9.1998 / 00:09:59 / cg" |
951890a68aba
added functionKeySequences (no need for a global)
Claus Gittinger <cg@exept.de>
parents:
4344
diff
changeset
|
465 |
! |
951890a68aba
added functionKeySequences (no need for a global)
Claus Gittinger <cg@exept.de>
parents:
4344
diff
changeset
|
466 |
|
4684
45fe4b0a22b0
moved variablePanelOpaqueResize setting to userprefs.
Claus Gittinger <cg@exept.de>
parents:
4628
diff
changeset
|
467 |
opaqueVariablePanelResizing |
45fe4b0a22b0
moved variablePanelOpaqueResize setting to userprefs.
Claus Gittinger <cg@exept.de>
parents:
4628
diff
changeset
|
468 |
"return the flag which controls if variable panel resizing should be done |
45fe4b0a22b0
moved variablePanelOpaqueResize setting to userprefs.
Claus Gittinger <cg@exept.de>
parents:
4628
diff
changeset
|
469 |
animated (opaque)" |
45fe4b0a22b0
moved variablePanelOpaqueResize setting to userprefs.
Claus Gittinger <cg@exept.de>
parents:
4628
diff
changeset
|
470 |
|
45fe4b0a22b0
moved variablePanelOpaqueResize setting to userprefs.
Claus Gittinger <cg@exept.de>
parents:
4628
diff
changeset
|
471 |
^ self at:#opaqueVariablePanelResizing ifAbsentPut:false |
45fe4b0a22b0
moved variablePanelOpaqueResize setting to userprefs.
Claus Gittinger <cg@exept.de>
parents:
4628
diff
changeset
|
472 |
|
45fe4b0a22b0
moved variablePanelOpaqueResize setting to userprefs.
Claus Gittinger <cg@exept.de>
parents:
4628
diff
changeset
|
473 |
" |
45fe4b0a22b0
moved variablePanelOpaqueResize setting to userprefs.
Claus Gittinger <cg@exept.de>
parents:
4628
diff
changeset
|
474 |
UserPreferences current opaqueVariablePanelResizing |
45fe4b0a22b0
moved variablePanelOpaqueResize setting to userprefs.
Claus Gittinger <cg@exept.de>
parents:
4628
diff
changeset
|
475 |
" |
45fe4b0a22b0
moved variablePanelOpaqueResize setting to userprefs.
Claus Gittinger <cg@exept.de>
parents:
4628
diff
changeset
|
476 |
|
45fe4b0a22b0
moved variablePanelOpaqueResize setting to userprefs.
Claus Gittinger <cg@exept.de>
parents:
4628
diff
changeset
|
477 |
"Modified: / 11.9.1998 / 00:09:59 / cg" |
45fe4b0a22b0
moved variablePanelOpaqueResize setting to userprefs.
Claus Gittinger <cg@exept.de>
parents:
4628
diff
changeset
|
478 |
|
45fe4b0a22b0
moved variablePanelOpaqueResize setting to userprefs.
Claus Gittinger <cg@exept.de>
parents:
4628
diff
changeset
|
479 |
! |
45fe4b0a22b0
moved variablePanelOpaqueResize setting to userprefs.
Claus Gittinger <cg@exept.de>
parents:
4628
diff
changeset
|
480 |
|
45fe4b0a22b0
moved variablePanelOpaqueResize setting to userprefs.
Claus Gittinger <cg@exept.de>
parents:
4628
diff
changeset
|
481 |
opaqueVariablePanelResizing:aBoolean |
45fe4b0a22b0
moved variablePanelOpaqueResize setting to userprefs.
Claus Gittinger <cg@exept.de>
parents:
4628
diff
changeset
|
482 |
"change the flag which controls if variable panel resizing should be done |
45fe4b0a22b0
moved variablePanelOpaqueResize setting to userprefs.
Claus Gittinger <cg@exept.de>
parents:
4628
diff
changeset
|
483 |
animated (opaque)" |
45fe4b0a22b0
moved variablePanelOpaqueResize setting to userprefs.
Claus Gittinger <cg@exept.de>
parents:
4628
diff
changeset
|
484 |
|
45fe4b0a22b0
moved variablePanelOpaqueResize setting to userprefs.
Claus Gittinger <cg@exept.de>
parents:
4628
diff
changeset
|
485 |
^ self at:#opaqueVariablePanelResizing put:aBoolean |
45fe4b0a22b0
moved variablePanelOpaqueResize setting to userprefs.
Claus Gittinger <cg@exept.de>
parents:
4628
diff
changeset
|
486 |
|
45fe4b0a22b0
moved variablePanelOpaqueResize setting to userprefs.
Claus Gittinger <cg@exept.de>
parents:
4628
diff
changeset
|
487 |
" |
45fe4b0a22b0
moved variablePanelOpaqueResize setting to userprefs.
Claus Gittinger <cg@exept.de>
parents:
4628
diff
changeset
|
488 |
UserPreferences current opaqueVariablePanelResizing:true |
45fe4b0a22b0
moved variablePanelOpaqueResize setting to userprefs.
Claus Gittinger <cg@exept.de>
parents:
4628
diff
changeset
|
489 |
" |
45fe4b0a22b0
moved variablePanelOpaqueResize setting to userprefs.
Claus Gittinger <cg@exept.de>
parents:
4628
diff
changeset
|
490 |
|
45fe4b0a22b0
moved variablePanelOpaqueResize setting to userprefs.
Claus Gittinger <cg@exept.de>
parents:
4628
diff
changeset
|
491 |
"Modified: / 11.9.1998 / 00:09:59 / cg" |
45fe4b0a22b0
moved variablePanelOpaqueResize setting to userprefs.
Claus Gittinger <cg@exept.de>
parents:
4628
diff
changeset
|
492 |
! |
45fe4b0a22b0
moved variablePanelOpaqueResize setting to userprefs.
Claus Gittinger <cg@exept.de>
parents:
4628
diff
changeset
|
493 |
|
4330
a90c5a801fdf
added #showClockInLauncher setting
Claus Gittinger <cg@exept.de>
parents:
4327
diff
changeset
|
494 |
showClockInLauncher |
a90c5a801fdf
added #showClockInLauncher setting
Claus Gittinger <cg@exept.de>
parents:
4327
diff
changeset
|
495 |
"return the flag which controls if a clock is shown in the launcher" |
a90c5a801fdf
added #showClockInLauncher setting
Claus Gittinger <cg@exept.de>
parents:
4327
diff
changeset
|
496 |
|
a90c5a801fdf
added #showClockInLauncher setting
Claus Gittinger <cg@exept.de>
parents:
4327
diff
changeset
|
497 |
^ self at:#showClockInLauncher ifAbsentPut:false |
a90c5a801fdf
added #showClockInLauncher setting
Claus Gittinger <cg@exept.de>
parents:
4327
diff
changeset
|
498 |
|
a90c5a801fdf
added #showClockInLauncher setting
Claus Gittinger <cg@exept.de>
parents:
4327
diff
changeset
|
499 |
" |
a90c5a801fdf
added #showClockInLauncher setting
Claus Gittinger <cg@exept.de>
parents:
4327
diff
changeset
|
500 |
UserPreferences current showClockInLauncher |
a90c5a801fdf
added #showClockInLauncher setting
Claus Gittinger <cg@exept.de>
parents:
4327
diff
changeset
|
501 |
" |
a90c5a801fdf
added #showClockInLauncher setting
Claus Gittinger <cg@exept.de>
parents:
4327
diff
changeset
|
502 |
|
a90c5a801fdf
added #showClockInLauncher setting
Claus Gittinger <cg@exept.de>
parents:
4327
diff
changeset
|
503 |
"Modified: / 11.9.1998 / 00:09:59 / cg" |
a90c5a801fdf
added #showClockInLauncher setting
Claus Gittinger <cg@exept.de>
parents:
4327
diff
changeset
|
504 |
! |
a90c5a801fdf
added #showClockInLauncher setting
Claus Gittinger <cg@exept.de>
parents:
4327
diff
changeset
|
505 |
|
4331 | 506 |
showClockInLauncher:aBooleanOrNil |
507 |
"set/clear the flag which controls if a clock is shown in the launcher" |
|
508 |
||
509 |
^ self at:#showClockInLauncher put:aBooleanOrNil |
|
510 |
||
511 |
" |
|
512 |
UserPreferences current showClockInLauncher:false. |
|
513 |
NewLauncher open. |
|
514 |
||
515 |
UserPreferences current showClockInLauncher:true. |
|
516 |
NewLauncher open. |
|
517 |
" |
|
518 |
||
519 |
"Modified: / 11.9.1998 / 00:09:59 / cg" |
|
520 |
! |
|
521 |
||
3347 | 522 |
syntaxColoring |
3360 | 523 |
"return the flag which controls syntax coloring (in the browsers)" |
524 |
||
3827
d3dd75b5ced3
syntax coloring is on by default;
Claus Gittinger <cg@exept.de>
parents:
3409
diff
changeset
|
525 |
^ self at:#syntaxColoring ifAbsentPut:true |
3347 | 526 |
|
527 |
" |
|
528 |
UserPreferences current syntaxColoring |
|
529 |
" |
|
530 |
||
3827
d3dd75b5ced3
syntax coloring is on by default;
Claus Gittinger <cg@exept.de>
parents:
3409
diff
changeset
|
531 |
"Modified: / 11.9.1998 / 00:09:59 / cg" |
3347 | 532 |
! |
533 |
||
534 |
syntaxColoring:aBoolean |
|
3360 | 535 |
"turn on/off syntaxColoring (in the browsers)." |
536 |
||
3347 | 537 |
^ self at:#syntaxColoring put:aBoolean |
538 |
||
3357 | 539 |
" |
540 |
UserPreferences current syntaxColoring:true |
|
541 |
UserPreferences current syntaxColoring:false |
|
542 |
" |
|
543 |
||
3347 | 544 |
"Created: / 31.3.1998 / 13:44:00 / cg" |
3360 | 545 |
"Modified: / 1.4.1998 / 13:23:03 / cg" |
546 |
! ! |
|
547 |
||
5236 | 548 |
!UserPreferences methodsFor:'accessing-syntaxColoring prefs'! |
3360 | 549 |
|
550 |
argumentIdentifierColor |
|
551 |
"the color used for argument identifiers; |
|
552 |
If syntaxColoring is turned on." |
|
553 |
||
554 |
^ self at:#argumentIdentifierColor ifAbsentPut:[self identifierColor] |
|
555 |
||
556 |
"Created: / 31.3.1998 / 15:08:20 / cg" |
|
557 |
"Modified: / 1.4.1998 / 13:19:58 / cg" |
|
558 |
! |
|
559 |
||
560 |
argumentIdentifierEmphasis |
|
561 |
"the emphasis used for argument identifiers; |
|
562 |
If syntaxColoring is turned on." |
|
563 |
||
564 |
^ self at:#argumentIdentifierEmphasis ifAbsentPut:[self identifierEmphasis] |
|
565 |
||
566 |
"Created: / 31.3.1998 / 15:16:40 / cg" |
|
567 |
"Modified: / 1.4.1998 / 13:19:55 / cg" |
|
568 |
! |
|
569 |
||
4326
9b1d4f1bf719
inserted badIdentifierColor & emphasis
Claus Gittinger <cg@exept.de>
parents:
4320
diff
changeset
|
570 |
badIdentifierColor |
9b1d4f1bf719
inserted badIdentifierColor & emphasis
Claus Gittinger <cg@exept.de>
parents:
4320
diff
changeset
|
571 |
"the color used for illegal identifiers; |
9b1d4f1bf719
inserted badIdentifierColor & emphasis
Claus Gittinger <cg@exept.de>
parents:
4320
diff
changeset
|
572 |
If syntaxColoring is turned on." |
9b1d4f1bf719
inserted badIdentifierColor & emphasis
Claus Gittinger <cg@exept.de>
parents:
4320
diff
changeset
|
573 |
|
4336 | 574 |
^ self at:#badIdentifierColor ifAbsentPut:[self identifierColor] |
4326
9b1d4f1bf719
inserted badIdentifierColor & emphasis
Claus Gittinger <cg@exept.de>
parents:
4320
diff
changeset
|
575 |
|
9b1d4f1bf719
inserted badIdentifierColor & emphasis
Claus Gittinger <cg@exept.de>
parents:
4320
diff
changeset
|
576 |
! |
9b1d4f1bf719
inserted badIdentifierColor & emphasis
Claus Gittinger <cg@exept.de>
parents:
4320
diff
changeset
|
577 |
|
9b1d4f1bf719
inserted badIdentifierColor & emphasis
Claus Gittinger <cg@exept.de>
parents:
4320
diff
changeset
|
578 |
badIdentifierEmphasis |
9b1d4f1bf719
inserted badIdentifierColor & emphasis
Claus Gittinger <cg@exept.de>
parents:
4320
diff
changeset
|
579 |
"the emphasis used for illegal identifiers; |
9b1d4f1bf719
inserted badIdentifierColor & emphasis
Claus Gittinger <cg@exept.de>
parents:
4320
diff
changeset
|
580 |
If syntaxColoring is turned on." |
9b1d4f1bf719
inserted badIdentifierColor & emphasis
Claus Gittinger <cg@exept.de>
parents:
4320
diff
changeset
|
581 |
|
4628 | 582 |
^ self at:#badIdentifierEmphasis ifAbsentPut:[UserPreferences default at:#badIdentifierEmphasis] |
4326
9b1d4f1bf719
inserted badIdentifierColor & emphasis
Claus Gittinger <cg@exept.de>
parents:
4320
diff
changeset
|
583 |
|
4335
b301d2c92490
underwave red for bad identifiers
Claus Gittinger <cg@exept.de>
parents:
4331
diff
changeset
|
584 |
"Modified: / 7.7.1999 / 00:30:00 / cg" |
4326
9b1d4f1bf719
inserted badIdentifierColor & emphasis
Claus Gittinger <cg@exept.de>
parents:
4320
diff
changeset
|
585 |
! |
9b1d4f1bf719
inserted badIdentifierColor & emphasis
Claus Gittinger <cg@exept.de>
parents:
4320
diff
changeset
|
586 |
|
3360 | 587 |
booleanConstantColor |
588 |
"the color used for boolean constants; |
|
589 |
If syntaxColoring is turned on." |
|
590 |
||
591 |
^ self at:#booleanConstantColor ifAbsentPut:[self constantColor] |
|
592 |
||
593 |
"Created: / 31.3.1998 / 18:12:06 / cg" |
|
594 |
"Modified: / 1.4.1998 / 13:20:07 / cg" |
|
595 |
! |
|
596 |
||
597 |
booleanConstantEmphasis |
|
598 |
"the emphasis used for boolean constants; |
|
599 |
If syntaxColoring is turned on." |
|
600 |
||
601 |
^ self at:#booleanConstantEmphasis ifAbsentPut:[self constantEmphasis] |
|
602 |
||
603 |
"Created: / 31.3.1998 / 18:12:46 / cg" |
|
604 |
"Modified: / 1.4.1998 / 13:26:01 / cg" |
|
605 |
! |
|
606 |
||
3361 | 607 |
bracketColor |
608 |
"the color used for brackets; |
|
609 |
If syntaxColoring is turned on." |
|
610 |
||
4317
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
611 |
^ self at:#bracketColor ifAbsentPut:[self defaultSyntaxColor] |
3361 | 612 |
|
613 |
" |
|
614 |
self current at:#bracketColor put:Color red. |
|
615 |
self current at:#bracketEmphasis put:#bold |
|
4317
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
616 |
|
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
617 |
self current bracketColor |
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
618 |
self current bracketEmphasis |
3361 | 619 |
" |
620 |
||
621 |
"Created: / 31.3.1998 / 19:11:38 / cg" |
|
622 |
"Modified: / 1.4.1998 / 13:22:33 / cg" |
|
623 |
! |
|
624 |
||
625 |
bracketEmphasis |
|
626 |
"the emphasis used for brackets; |
|
627 |
If syntaxColoring is turned on." |
|
628 |
||
4317
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
629 |
^ self at:#bracketEmphasis ifAbsentPut:[self defaultSyntaxEmphasis] |
3361 | 630 |
|
631 |
" |
|
632 |
self current at:#bracketEmphasis put:#bold |
|
4317
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
633 |
self current bracketEmphasis |
3361 | 634 |
" |
635 |
||
636 |
"Created: / 31.3.1998 / 19:11:38 / cg" |
|
637 |
"Modified: / 1.4.1998 / 13:22:33 / cg" |
|
638 |
! |
|
639 |
||
4320 | 640 |
classVariableIdentifierColor |
641 |
"the color used for classVar/classInstVar identifiers |
|
642 |
If syntaxColoring is turned on." |
|
643 |
||
644 |
^ self at:#classVariableIdentifierColor ifAbsentPut:[self globalIdentifierColor] |
|
645 |
||
646 |
"Modified: / 1.4.1998 / 13:20:47 / cg" |
|
647 |
"Created: / 4.3.1999 / 12:50:31 / cg" |
|
648 |
! |
|
649 |
||
650 |
classVariableIdentifierEmphasis |
|
651 |
"the color used for classVar/classInstVar identifiers |
|
652 |
If syntaxColoring is turned on." |
|
653 |
||
654 |
^ self at:#classVariableIdentifierEmphasis ifAbsentPut:[self globalIdentifierEmphasis] |
|
655 |
||
656 |
"Modified: / 1.4.1998 / 13:20:47 / cg" |
|
657 |
"Created: / 4.3.1999 / 12:50:31 / cg" |
|
658 |
! |
|
659 |
||
3360 | 660 |
commentColor |
661 |
"the color used for comments; |
|
662 |
If syntaxColoring is turned on." |
|
663 |
||
4628 | 664 |
^ self at:#commentColor ifAbsentPut:[UserPreferences default at:#commentColor] |
3360 | 665 |
|
666 |
"Created: / 31.3.1998 / 15:10:23 / cg" |
|
3832 | 667 |
"Modified: / 11.9.1998 / 19:24:04 / cg" |
3360 | 668 |
! |
669 |
||
670 |
commentEmphasis |
|
671 |
"the emphasis used for comments; |
|
672 |
If syntaxColoring is turned on." |
|
673 |
||
4628 | 674 |
^ self at:#commentEmphasis ifAbsentPut:[UserPreferences default at:#commentEmphasis] |
3360 | 675 |
|
676 |
"Created: / 31.3.1998 / 15:09:59 / cg" |
|
677 |
"Modified: / 1.4.1998 / 13:25:53 / cg" |
|
678 |
! |
|
679 |
||
5258 | 680 |
commentEmphasisAndColor |
681 |
^ Text addEmphasis:(self commentEmphasis) to:(#color->self commentColor). |
|
682 |
||
683 |
||
684 |
! |
|
685 |
||
3360 | 686 |
constantColor |
687 |
"the color used for constants; |
|
688 |
If syntaxColoring is turned on." |
|
689 |
||
4628 | 690 |
^ self at:#constantColor ifAbsentPut:[UserPreferences default at:#constantColor] |
3360 | 691 |
|
692 |
"Created: / 31.3.1998 / 18:13:15 / cg" |
|
693 |
"Modified: / 1.4.1998 / 13:20:37 / cg" |
|
694 |
! |
|
695 |
||
696 |
constantEmphasis |
|
697 |
"the emphasis used for constants; |
|
698 |
If syntaxColoring is turned on." |
|
699 |
||
700 |
^ self at:#constantEmphasis ifAbsentPut:[self identifierEmphasis] |
|
701 |
||
702 |
"Created: / 31.3.1998 / 18:13:23 / cg" |
|
703 |
"Modified: / 1.4.1998 / 13:25:43 / cg" |
|
704 |
! |
|
705 |
||
4317
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
706 |
defaultSyntaxColor |
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
707 |
"the color used for anything else; |
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
708 |
If syntaxColoring is turned on." |
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
709 |
|
4628 | 710 |
^ self at:#defaultSyntaxColor ifAbsentPut:[UserPreferences default at:#defaultSyntaxColor] |
4317
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
711 |
|
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
712 |
! |
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
713 |
|
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
714 |
defaultSyntaxEmphasis |
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
715 |
"the emphasis used for anything else; |
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
716 |
If syntaxColoring is turned on." |
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
717 |
|
4628 | 718 |
^ self at:#defaultSyntaxEmphasis ifAbsentPut:[UserPreferences default at:#defaultSyntaxEmphasis] |
4317
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
719 |
|
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
720 |
! |
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
721 |
|
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
722 |
doesNotUnderstand:aMessage |
4580 | 723 |
|k def| |
4317
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
724 |
|
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
725 |
k := aMessage selector. |
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
726 |
(self includesKey:k) ifTrue:[ |
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
727 |
^ self at:k |
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
728 |
]. |
4582
31cbce168a1d
return false for nonexisting keys
Claus Gittinger <cg@exept.de>
parents:
4580
diff
changeset
|
729 |
((def := self class default) includesKey:k) ifTrue:[ |
31cbce168a1d
return false for nonexisting keys
Claus Gittinger <cg@exept.de>
parents:
4580
diff
changeset
|
730 |
^ def at:k |
4317
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
731 |
]. |
4583 | 732 |
aMessage selector numArgs == 0 ifTrue:[ |
733 |
^ self defaultValue |
|
734 |
]. |
|
4317
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
735 |
^ super doesNotUnderstand:aMessage |
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
736 |
! |
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
737 |
|
4341 | 738 |
errorColor |
739 |
"the color used for illegal identifiers; |
|
740 |
If syntaxColoring is turned on." |
|
741 |
||
4628 | 742 |
^ self at:#errorColor ifAbsentPut:[UserPreferences default at:#errorColor] |
4341 | 743 |
|
744 |
! |
|
745 |
||
4306 | 746 |
fullSelectorCheck |
747 |
"with fullSelector check, selectors are searched immediately for |
|
748 |
being implemented in the system. This may not be useful on slow machines" |
|
749 |
||
4628 | 750 |
^ self at:#fullSelectorCheck ifAbsentPut:[UserPreferences default at:#fullSelectorCheck] |
4306 | 751 |
|
752 |
"Created: / 31.3.1998 / 15:09:41 / cg" |
|
753 |
"Modified: / 1.4.1998 / 13:25:06 / cg" |
|
754 |
! |
|
755 |
||
4023 | 756 |
globalClassIdentifierColor |
757 |
"the color used for global identifiers which are known to be classes; |
|
758 |
If syntaxColoring is turned on." |
|
759 |
||
760 |
^ self at:#globalClassIdentifierColor ifAbsentPut:[self globalIdentifierColor] |
|
761 |
||
762 |
"Modified: / 1.4.1998 / 13:20:47 / cg" |
|
763 |
"Created: / 4.3.1999 / 12:50:31 / cg" |
|
764 |
! |
|
765 |
||
766 |
globalClassIdentifierEmphasis |
|
767 |
"the emphasis used for global variable identifiers which are known to be classes; |
|
768 |
If syntaxColoring is turned on." |
|
769 |
||
770 |
^ self at:#globalClassIdentifierEmphasis ifAbsentPut:[self globalIdentifierEmphasis] |
|
771 |
||
772 |
"Modified: / 1.4.1998 / 13:25:31 / cg" |
|
773 |
"Created: / 4.3.1999 / 12:51:00 / cg" |
|
774 |
! |
|
775 |
||
3360 | 776 |
globalIdentifierColor |
777 |
"the color used for global identifiers; |
|
778 |
If syntaxColoring is turned on." |
|
779 |
||
780 |
^ self at:#globalIdentifierColor ifAbsentPut:[self identifierColor] |
|
781 |
||
782 |
"Created: / 31.3.1998 / 15:18:49 / cg" |
|
783 |
"Modified: / 1.4.1998 / 13:20:47 / cg" |
|
784 |
! |
|
785 |
||
786 |
globalIdentifierEmphasis |
|
787 |
"the emphasis used for global variable identifiers; |
|
788 |
If syntaxColoring is turned on." |
|
789 |
||
790 |
^ self at:#globalIdentifierEmphasis ifAbsentPut:[self identifierEmphasis] |
|
791 |
||
792 |
"Created: / 31.3.1998 / 15:18:29 / cg" |
|
793 |
"Modified: / 1.4.1998 / 13:25:31 / cg" |
|
794 |
! |
|
795 |
||
796 |
hereColor |
|
797 |
"the color used for the here pseudoVariable; |
|
798 |
If syntaxColoring is turned on." |
|
799 |
||
4317
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
800 |
^ self at:#hereColor ifAbsentPut:[self selfColor] |
3360 | 801 |
|
802 |
"Created: / 31.3.1998 / 17:38:09 / cg" |
|
803 |
"Modified: / 1.4.1998 / 13:20:57 / cg" |
|
804 |
! |
|
805 |
||
806 |
hereEmphasis |
|
807 |
"the emphasis used for the hre special variable; |
|
808 |
If syntaxColoring is turned on." |
|
809 |
||
4317
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
810 |
^ self at:#hereEmphasis ifAbsentPut:[self selfEmphasis] |
3360 | 811 |
|
812 |
"Created: / 31.3.1998 / 17:35:13 / cg" |
|
813 |
"Modified: / 1.4.1998 / 13:25:17 / cg" |
|
814 |
! |
|
815 |
||
816 |
identifierColor |
|
817 |
"the color used for other identifiers; |
|
818 |
If syntaxColoring is turned on." |
|
819 |
||
4317
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
820 |
^ self at:#identifierColor ifAbsentPut:[self defaultSyntaxColor] |
3360 | 821 |
|
3362 | 822 |
" |
823 |
UserPreferences current at:#identifierColor put:Color green darkened darkened. |
|
824 |
UserPreferences current at:#identifierColor put:Color black. |
|
825 |
" |
|
826 |
||
3360 | 827 |
"Created: / 31.3.1998 / 17:35:55 / cg" |
3362 | 828 |
"Modified: / 2.4.1998 / 10:39:42 / cg" |
3360 | 829 |
! |
830 |
||
831 |
identifierEmphasis |
|
832 |
"the emphasis used for other identifiers; |
|
833 |
If syntaxColoring is turned on." |
|
834 |
||
4317
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
835 |
^ self at:#identifierEmphasis ifAbsentPut:[self defaultSyntaxEmphasis] |
3360 | 836 |
|
837 |
"Created: / 31.3.1998 / 15:09:41 / cg" |
|
838 |
"Modified: / 1.4.1998 / 13:25:06 / cg" |
|
839 |
! |
|
840 |
||
3378 | 841 |
instVarIdentifierColor |
3377 | 842 |
"the color used for instance variable identifiers; |
843 |
If syntaxColoring is turned on." |
|
844 |
||
3378 | 845 |
^ self at:#instVarIdentifierColor ifAbsentPut:[self identifierColor] |
3377 | 846 |
|
847 |
" |
|
3378 | 848 |
UserPreferences current at:#instVarIdentifierColor put:Color green darkened. |
849 |
UserPreferences current at:#instVarIdentifierColor put:Color black. |
|
850 |
UserPreferences current instVarIdentifierColor |
|
3377 | 851 |
" |
852 |
||
853 |
"Created: / 16.4.1998 / 18:31:29 / cg" |
|
3378 | 854 |
"Modified: / 16.4.1998 / 18:57:06 / cg" |
3377 | 855 |
! |
856 |
||
3378 | 857 |
instVarIdentifierEmphasis |
3377 | 858 |
"the emphais used for instance variable identifiers; |
859 |
If syntaxColoring is turned on." |
|
860 |
||
3378 | 861 |
^ self at:#instVarIdentifierEmphasis ifAbsentPut:[self identifierEmphasis] |
3377 | 862 |
|
863 |
"Modified: / 1.4.1998 / 13:24:42 / cg" |
|
3378 | 864 |
"Created: / 16.4.1998 / 18:40:05 / cg" |
3377 | 865 |
! |
866 |
||
3360 | 867 |
localIdentifierColor |
868 |
"the color used for local variable identifiers; |
|
869 |
If syntaxColoring is turned on." |
|
870 |
||
871 |
^ self at:#localIdentifierColor ifAbsentPut:[self identifierColor] |
|
872 |
||
3362 | 873 |
" |
874 |
UserPreferences current at:#localIdentifierColor put:Color green darkened. |
|
875 |
UserPreferences current at:#localIdentifierColor put:Color black. |
|
876 |
" |
|
877 |
||
3360 | 878 |
"Created: / 31.3.1998 / 15:18:07 / cg" |
3362 | 879 |
"Modified: / 2.4.1998 / 10:40:05 / cg" |
3360 | 880 |
! |
881 |
||
882 |
localIdentifierEmphasis |
|
883 |
"the emphais used for local variable identifiers; |
|
884 |
If syntaxColoring is turned on." |
|
885 |
||
886 |
^ self at:#localIdentifierEmphasis ifAbsentPut:[self identifierEmphasis] |
|
887 |
||
888 |
"Created: / 31.3.1998 / 15:16:56 / cg" |
|
889 |
"Modified: / 1.4.1998 / 13:24:42 / cg" |
|
890 |
! |
|
891 |
||
892 |
methodSelectorColor |
|
893 |
"the color used for a methods selector pattern; |
|
894 |
If syntaxColoring is turned on." |
|
895 |
||
4317
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
896 |
^ self at:#methodSelectorColor ifAbsentPut:[self defaultSyntaxColor] |
3360 | 897 |
|
898 |
"Created: / 31.3.1998 / 15:11:24 / cg" |
|
899 |
"Modified: / 1.4.1998 / 13:24:26 / cg" |
|
900 |
! |
|
901 |
||
902 |
methodSelectorEmphasis |
|
903 |
"the emphasis used for a methods selector pattern; |
|
904 |
If syntaxColoring is turned on." |
|
905 |
||
4628 | 906 |
^ self at:#methodSelectorEmphasis ifAbsentPut:[UserPreferences default at:#methodSelectorEmphasis] |
3360 | 907 |
|
908 |
"Created: / 31.3.1998 / 15:11:16 / cg" |
|
909 |
"Modified: / 1.4.1998 / 13:24:20 / cg" |
|
910 |
! |
|
911 |
||
4076 | 912 |
returnColor |
913 |
"the color used for the return expression; |
|
914 |
If syntaxColoring is turned on." |
|
915 |
||
4317
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
916 |
^ self at:#returnColor ifAbsentPut:[self defaultSyntaxColor] |
4076 | 917 |
|
918 |
"Modified: / 5.1.1980 / 00:43:52 / cg" |
|
919 |
! |
|
920 |
||
921 |
returnEmphasis |
|
922 |
"the emphasis used for returns; |
|
923 |
If syntaxColoring is turned on." |
|
924 |
||
4317
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
925 |
^ self at:#returnEmphasis ifAbsentPut:[self defaultSyntaxEmphasis] |
4076 | 926 |
|
927 |
"Created: / 5.1.1980 / 00:43:39 / cg" |
|
928 |
! |
|
929 |
||
3360 | 930 |
selectorColor |
931 |
"the color used for message selectors; |
|
932 |
If syntaxColoring is turned on." |
|
933 |
||
4317
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
934 |
^ self at:#selectorColor ifAbsentPut:[self defaultSyntaxColor] |
3360 | 935 |
|
936 |
"Created: / 31.3.1998 / 15:19:19 / cg" |
|
937 |
"Modified: / 1.4.1998 / 13:24:04 / cg" |
|
938 |
! |
|
939 |
||
940 |
selectorEmphasis |
|
941 |
"the emphasis used for message selectors; |
|
942 |
If syntaxColoring is turned on." |
|
943 |
||
4628 | 944 |
^ self at:#selectorEmphasis ifAbsentPut:[UserPreferences default at:#selectorEmphasis] |
3360 | 945 |
|
946 |
"Created: / 31.3.1998 / 15:19:09 / cg" |
|
947 |
"Modified: / 1.4.1998 / 13:23:59 / cg" |
|
948 |
! |
|
949 |
||
950 |
selfColor |
|
951 |
"the color used for the self pseudoVariable; |
|
952 |
If syntaxColoring is turned on." |
|
953 |
||
954 |
^ self at:#selfColor ifAbsentPut:[self identifierColor] |
|
955 |
||
956 |
"Created: / 31.3.1998 / 17:35:45 / cg" |
|
957 |
"Modified: / 1.4.1998 / 13:21:07 / cg" |
|
958 |
! |
|
959 |
||
960 |
selfEmphasis |
|
961 |
"the emphasis used for the self pseudoVariable; |
|
962 |
If syntaxColoring is turned on." |
|
963 |
||
964 |
^ self at:#selfEmphasis ifAbsentPut:[self identifierEmphasis] |
|
965 |
||
966 |
"Created: / 31.3.1998 / 17:34:57 / cg" |
|
967 |
"Modified: / 1.4.1998 / 13:21:51 / cg" |
|
968 |
! |
|
969 |
||
970 |
stringColor |
|
971 |
"the color used for string constants; |
|
972 |
If syntaxColoring is turned on." |
|
973 |
||
974 |
^ self at:#stringColor ifAbsentPut:[self constantColor] |
|
975 |
||
976 |
"Created: / 31.3.1998 / 15:19:50 / cg" |
|
977 |
"Modified: / 1.4.1998 / 13:22:06 / cg" |
|
978 |
! |
|
979 |
||
980 |
stringEmphasis |
|
981 |
"the emphasis used for string constants; |
|
982 |
If syntaxColoring is turned on." |
|
983 |
||
984 |
^ self at:#stringEmphasis ifAbsentPut:[self constantEmphasis] |
|
985 |
||
986 |
"Created: / 31.3.1998 / 15:19:09 / cg" |
|
987 |
"Modified: / 1.4.1998 / 13:22:00 / cg" |
|
988 |
! |
|
989 |
||
990 |
superColor |
|
991 |
"the color used for the super pseudoVariable; |
|
992 |
If syntaxColoring is turned on." |
|
993 |
||
4317
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
994 |
^ self at:#superColor ifAbsentPut:[self selfColor] |
3360 | 995 |
|
996 |
"Created: / 31.3.1998 / 17:37:56 / cg" |
|
997 |
"Modified: / 1.4.1998 / 13:21:15 / cg" |
|
998 |
! |
|
999 |
||
1000 |
superEmphasis |
|
1001 |
"the emphasis used for the super pseudoVariable; |
|
1002 |
If syntaxColoring is turned on." |
|
1003 |
||
4317
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
1004 |
^ self at:#superEmphasis ifAbsentPut:[self selfEmphasis] |
3360 | 1005 |
|
1006 |
"Created: / 31.3.1998 / 17:35:08 / cg" |
|
1007 |
"Modified: / 1.4.1998 / 13:21:41 / cg" |
|
1008 |
! |
|
1009 |
||
1010 |
symbolColor |
|
1011 |
"the color used for symbol constants; |
|
1012 |
If syntaxColoring is turned on." |
|
1013 |
||
1014 |
^ self at:#symbolColor ifAbsentPut:[self constantColor] |
|
1015 |
||
1016 |
"Created: / 1.4.1998 / 12:57:35 / cg" |
|
1017 |
"Modified: / 1.4.1998 / 13:22:16 / cg" |
|
1018 |
! |
|
1019 |
||
1020 |
symbolEmphasis |
|
1021 |
"the emphasis used for symbol constants; |
|
1022 |
If syntaxColoring is turned on." |
|
1023 |
||
1024 |
^ self at:#symbolEmphasis ifAbsentPut:[self constantEmphasis] |
|
1025 |
||
1026 |
"Created: / 1.4.1998 / 12:57:43 / cg" |
|
1027 |
"Modified: / 1.4.1998 / 13:23:43 / cg" |
|
3352 | 1028 |
! |
1029 |
||
1030 |
thisContextColor |
|
3360 | 1031 |
"the color used for the thisContext pseudoVariable; |
1032 |
If syntaxColoring is turned on." |
|
1033 |
||
3355 | 1034 |
^ self at:#thisContextColor ifAbsentPut:[self identifierColor] |
3352 | 1035 |
|
1036 |
"Created: / 31.3.1998 / 17:37:49 / cg" |
|
3360 | 1037 |
"Modified: / 1.4.1998 / 13:21:24 / cg" |
3352 | 1038 |
! |
1039 |
||
1040 |
thisContextEmphasis |
|
3360 | 1041 |
"the emphasis used for the thisContext pseudoVariable; |
1042 |
If syntaxColoring is turned on." |
|
1043 |
||
3355 | 1044 |
^ self at:#thisContextEmphasis ifAbsentPut:[self identifierEmphasis] |
3352 | 1045 |
|
1046 |
"Created: / 31.3.1998 / 17:35:27 / cg" |
|
3360 | 1047 |
"Modified: / 1.4.1998 / 13:21:30 / cg" |
3354 | 1048 |
! |
1049 |
||
4316
c3934d0d1e3e
added unimplementedSelector emphasis&colors
Claus Gittinger <cg@exept.de>
parents:
4306
diff
changeset
|
1050 |
unimplementedSelectorColor |
c3934d0d1e3e
added unimplementedSelector emphasis&colors
Claus Gittinger <cg@exept.de>
parents:
4306
diff
changeset
|
1051 |
"the color used for bad message selectors; |
c3934d0d1e3e
added unimplementedSelector emphasis&colors
Claus Gittinger <cg@exept.de>
parents:
4306
diff
changeset
|
1052 |
If syntaxColoring is turned on." |
c3934d0d1e3e
added unimplementedSelector emphasis&colors
Claus Gittinger <cg@exept.de>
parents:
4306
diff
changeset
|
1053 |
|
4628 | 1054 |
^ self at:#unimplementedSelectorColor ifAbsentPut:[UserPreferences default at:#unimplementedSelectorColor] |
4316
c3934d0d1e3e
added unimplementedSelector emphasis&colors
Claus Gittinger <cg@exept.de>
parents:
4306
diff
changeset
|
1055 |
! |
c3934d0d1e3e
added unimplementedSelector emphasis&colors
Claus Gittinger <cg@exept.de>
parents:
4306
diff
changeset
|
1056 |
|
c3934d0d1e3e
added unimplementedSelector emphasis&colors
Claus Gittinger <cg@exept.de>
parents:
4306
diff
changeset
|
1057 |
unimplementedSelectorEmphasis |
c3934d0d1e3e
added unimplementedSelector emphasis&colors
Claus Gittinger <cg@exept.de>
parents:
4306
diff
changeset
|
1058 |
"the emphasis used for bad message selectors; |
c3934d0d1e3e
added unimplementedSelector emphasis&colors
Claus Gittinger <cg@exept.de>
parents:
4306
diff
changeset
|
1059 |
If syntaxColoring is turned on." |
c3934d0d1e3e
added unimplementedSelector emphasis&colors
Claus Gittinger <cg@exept.de>
parents:
4306
diff
changeset
|
1060 |
|
4628 | 1061 |
^ self at:#unimplementedSelectorEmphasis ifAbsentPut:[UserPreferences default at:#unimplementedSelectorEmphasis] |
4316
c3934d0d1e3e
added unimplementedSelector emphasis&colors
Claus Gittinger <cg@exept.de>
parents:
4306
diff
changeset
|
1062 |
|
c3934d0d1e3e
added unimplementedSelector emphasis&colors
Claus Gittinger <cg@exept.de>
parents:
4306
diff
changeset
|
1063 |
"Created: / 31.3.1998 / 15:19:09 / cg" |
c3934d0d1e3e
added unimplementedSelector emphasis&colors
Claus Gittinger <cg@exept.de>
parents:
4306
diff
changeset
|
1064 |
"Modified: / 1.4.1998 / 13:23:59 / cg" |
c3934d0d1e3e
added unimplementedSelector emphasis&colors
Claus Gittinger <cg@exept.de>
parents:
4306
diff
changeset
|
1065 |
! |
c3934d0d1e3e
added unimplementedSelector emphasis&colors
Claus Gittinger <cg@exept.de>
parents:
4306
diff
changeset
|
1066 |
|
3354 | 1067 |
unknownIdentifierColor |
3360 | 1068 |
"the color used for unknown identifiers; |
1069 |
If syntaxColoring is turned on." |
|
1070 |
||
4326
9b1d4f1bf719
inserted badIdentifierColor & emphasis
Claus Gittinger <cg@exept.de>
parents:
4320
diff
changeset
|
1071 |
^ self at:#unknownIdentifierColor ifAbsentPut:[self badIdentifierColor] |
3354 | 1072 |
|
3361 | 1073 |
" |
1074 |
self current at:#unknownIdentifierColor put:Color red. |
|
1075 |
self current at:#unknownIdentifierEmphasis put:#bold |
|
4317
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
1076 |
|
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
1077 |
self current unknownIdentifierColor |
aba88adaf752
concentrated defaults into #initialize method.
Claus Gittinger <cg@exept.de>
parents:
4316
diff
changeset
|
1078 |
self current unknownIdentifierEmphasis |
3361 | 1079 |
" |
1080 |
||
3354 | 1081 |
"Created: / 31.3.1998 / 19:11:38 / cg" |
3360 | 1082 |
"Modified: / 1.4.1998 / 13:22:33 / cg" |
3354 | 1083 |
! |
1084 |
||
1085 |
unknownIdentifierEmphasis |
|
3360 | 1086 |
"the emphasis used for unknown identifiers; |
1087 |
If syntaxColoring is turned on." |
|
1088 |
||
4326
9b1d4f1bf719
inserted badIdentifierColor & emphasis
Claus Gittinger <cg@exept.de>
parents:
4320
diff
changeset
|
1089 |
^ self at:#unknownIdentifierEmphasis ifAbsentPut:[self badIdentifierEmphasis] |
3354 | 1090 |
|
1091 |
"Created: / 31.3.1998 / 19:11:55 / cg" |
|
3360 | 1092 |
"Modified: / 1.4.1998 / 13:22:45 / cg" |
3347 | 1093 |
! ! |
1094 |
||
4342
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
1095 |
!UserPreferences methodsFor:'default settings'! |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
1096 |
|
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
1097 |
resetSyntaxColors |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
1098 |
"resets the colors in the CurrentPreferences to their default values" |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
1099 |
|
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
1100 |
self class syntaxColorKeys do:[:k | self removeKey:k ifAbsent:nil]. |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
1101 |
|
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
1102 |
|
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
1103 |
! |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
1104 |
|
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
1105 |
resetSyntaxColorsAllBlackExceptBadIDs |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
1106 |
"resets the colors in the CurrentPreferences to no-color mode, |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
1107 |
except for bad identifiers, which are underwaved." |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
1108 |
|
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
1109 |
self class syntaxColorKeys do:[:k | self removeKey:k ifAbsent:nil]. |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
1110 |
self at:#badIdentifierEmphasis put:(Array with:#underwave with:(#underlineColor->Color red)). |
4344 | 1111 |
self at:#errorColor put:Color black. |
4342
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
1112 |
self at:#commentColor put:Color black. |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
1113 |
self at:#constantColor put:Color black. |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
1114 |
self at:#methodSelectorEmphasis put:#normal. |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
1115 |
self at:#selectorEmphasis put:#normal. |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
1116 |
|
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
1117 |
! |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
1118 |
|
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
1119 |
resetSyntaxColorsGreenComments |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
1120 |
"resets the colors in the CurrentPreferences to alternative default values |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
1121 |
(with green comments)" |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
1122 |
|
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
1123 |
self class syntaxColorKeys do:[:k | self removeKey:k ifAbsent:nil]. |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
1124 |
self at:#commentColor put:(Color green darkened). |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
1125 |
|
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
1126 |
! ! |
f2bbfcd2f072
added some default color settings
Claus Gittinger <cg@exept.de>
parents:
4341
diff
changeset
|
1127 |
|
4582
31cbce168a1d
return false for nonexisting keys
Claus Gittinger <cg@exept.de>
parents:
4580
diff
changeset
|
1128 |
!UserPreferences methodsFor:'default value'! |
31cbce168a1d
return false for nonexisting keys
Claus Gittinger <cg@exept.de>
parents:
4580
diff
changeset
|
1129 |
|
4583 | 1130 |
defaultValue |
1131 |
"the defaultValue for non-existing keys" |
|
1132 |
||
1133 |
^ false |
|
1134 |
! |
|
1135 |
||
4582
31cbce168a1d
return false for nonexisting keys
Claus Gittinger <cg@exept.de>
parents:
4580
diff
changeset
|
1136 |
errorKeyNotFound:aKey |
31cbce168a1d
return false for nonexisting keys
Claus Gittinger <cg@exept.de>
parents:
4580
diff
changeset
|
1137 |
"for any non-existing key, false is returned" |
31cbce168a1d
return false for nonexisting keys
Claus Gittinger <cg@exept.de>
parents:
4580
diff
changeset
|
1138 |
|
4583 | 1139 |
^ self defaultValue |
4582
31cbce168a1d
return false for nonexisting keys
Claus Gittinger <cg@exept.de>
parents:
4580
diff
changeset
|
1140 |
! ! |
31cbce168a1d
return false for nonexisting keys
Claus Gittinger <cg@exept.de>
parents:
4580
diff
changeset
|
1141 |
|
3347 | 1142 |
!UserPreferences class methodsFor:'documentation'! |
1143 |
||
1144 |
version |
|
5661 | 1145 |
^ '$Header: /cvs/stx/stx/libbasic/UserPreferences.st,v 1.59 2000-10-11 07:44:07 cg Exp $' |
3347 | 1146 |
! ! |