author | Claus Gittinger <cg@exept.de> |
Mon, 02 Mar 2009 17:19:16 +0100 | |
changeset 3848 | 93776dd41280 |
parent 3841 | f8cc80f595ce |
child 3853 | ee85bd42eb22 |
permissions | -rw-r--r-- |
0 | 1 |
" |
5 | 2 |
COPYRIGHT (c) 1991 by Claus Gittinger |
59 | 3 |
All Rights Reserved |
0 | 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 |
" |
|
2275 | 12 |
"{ Package: 'stx:libwidg' }" |
13 |
||
77 | 14 |
DialogBox subclass:#FontPanel |
2878 | 15 |
instanceVariableNames:'previewField listOfEncodings familyList faceList sizeList |
16 |
revertButton currentFamily currentFace currentStyle |
|
3832 | 17 |
currentFaceAndStyle currentSize sizeUnit currentEncoding |
18 |
selectedFont nameLabel encodingFilter encodingLabel filter |
|
3841 | 19 |
encoding sizeLabelHolder pixelPointSwitch' |
251
25f76efaa547
oops - dont pass a collection of numbers to the size-view
Claus Gittinger <cg@exept.de>
parents:
243
diff
changeset
|
20 |
classVariableNames:'' |
25f76efaa547
oops - dont pass a collection of numbers to the size-view
Claus Gittinger <cg@exept.de>
parents:
243
diff
changeset
|
21 |
poolDictionaries:'' |
25f76efaa547
oops - dont pass a collection of numbers to the size-view
Claus Gittinger <cg@exept.de>
parents:
243
diff
changeset
|
22 |
category:'Views-DialogBoxes' |
0 | 23 |
! |
24 |
||
1185
3b8bd5ea8d62
action block is evaluated with a fontDescription
Claus Gittinger <cg@exept.de>
parents:
797
diff
changeset
|
25 |
!FontPanel class methodsFor:'documentation'! |
77 | 26 |
|
197 | 27 |
copyright |
28 |
" |
|
29 |
COPYRIGHT (c) 1991 by Claus Gittinger |
|
30 |
All Rights Reserved |
|
31 |
||
32 |
This software is furnished under a license and may be used |
|
33 |
only in accordance with the terms of that license and with the |
|
34 |
inclusion of the above copyright notice. This software may not |
|
35 |
be provided or otherwise made available to, or used by, any |
|
36 |
other person. No title to or ownership of the software is |
|
37 |
hereby transferred. |
|
38 |
" |
|
39 |
||
40 |
||
77 | 41 |
! |
42 |
||
43 |
documentation |
|
44 |
" |
|
45 |
this class implements a font chooser. |
|
46 |
||
2826 | 47 |
Notice: |
48 |
this is a very old dialog; |
|
49 |
it was written before the UI-framework was available and is completely |
|
50 |
setup manually (initialize method). |
|
51 |
Therefore, it desperately asks to be rewritten using the UIPainter... |
|
52 |
||
595 | 53 |
[author:] |
54 |
Claus Gittinger |
|
55 |
||
56 |
[see also:] |
|
57 |
Font FontDescription |
|
58 |
View Dialog |
|
59 |
" |
|
60 |
! |
|
61 |
||
62 |
examples |
|
63 |
" |
|
64 |
very simple: |
|
65 |
[exBegin] |
|
66 |
|font| |
|
67 |
||
68 |
font := FontPanel fontFromUser. |
|
655 | 69 |
Transcript showCR:font |
595 | 70 |
[exEnd] |
71 |
||
72 |
||
73 |
with initial font: |
|
74 |
[exBegin] |
|
75 |
|font| |
|
76 |
||
77 |
font := FontPanel |
|
78 |
fontFromUserInitial:(Font |
|
79 |
family:'courier' |
|
80 |
size:12). |
|
655 | 81 |
Transcript showCR:font |
595 | 82 |
[exEnd] |
83 |
||
84 |
||
85 |
with initial font & title: |
|
86 |
[exBegin] |
|
87 |
|font| |
|
88 |
||
89 |
font := FontPanel |
|
90 |
fontFromUserInitial:(Font |
|
91 |
family:'courier' |
|
92 |
size:12) |
|
93 |
title:'select a fooBar font'. |
|
655 | 94 |
Transcript showCR:font |
595 | 95 |
[exEnd] |
96 |
||
97 |
||
98 |
full setup; setting a filter to only present iso fonts |
|
99 |
and callBack action: |
|
100 |
[exBegin] |
|
0 | 101 |
|
585 | 102 |
|panel| |
77 | 103 |
|
585 | 104 |
panel := FontPanel new. |
595 | 105 |
panel label:'hi there - which iso font ?'. |
106 |
panel filter:[:fd | fd encoding notNil |
|
107 |
and:[fd encoding startsWith:'iso']]. |
|
108 |
panel action:[:family :face :style :size | |
|
655 | 109 |
Transcript showCR:'family:' , family. |
110 |
Transcript showCR:'face:' , face. |
|
111 |
Transcript showCR:'style:' , style. |
|
112 |
Transcript showCR:'size:' , size printString. |
|
595 | 113 |
]. |
114 |
panel open |
|
115 |
[exEnd] |
|
77 | 116 |
" |
117 |
! ! |
|
0 | 118 |
|
1185
3b8bd5ea8d62
action block is evaluated with a fontDescription
Claus Gittinger <cg@exept.de>
parents:
797
diff
changeset
|
119 |
!FontPanel class methodsFor:'defaults'! |
0 | 120 |
|
2930
576e73803b46
correct display of non-unicode, non-8859 encoded fonts
Claus Gittinger <cg@exept.de>
parents:
2921
diff
changeset
|
121 |
defaultAsciiSampleString |
576e73803b46
correct display of non-unicode, non-8859 encoded fonts
Claus Gittinger <cg@exept.de>
parents:
2921
diff
changeset
|
122 |
^ (self sampleStringWithAllLetters) , ' |
576e73803b46
correct display of non-unicode, non-8859 encoded fonts
Claus Gittinger <cg@exept.de>
parents:
2921
diff
changeset
|
123 |
|
576e73803b46
correct display of non-unicode, non-8859 encoded fonts
Claus Gittinger <cg@exept.de>
parents:
2921
diff
changeset
|
124 |
ABCDEFGHIJKLMNOPQRSTUVWXYZ |
576e73803b46
correct display of non-unicode, non-8859 encoded fonts
Claus Gittinger <cg@exept.de>
parents:
2921
diff
changeset
|
125 |
abcdefghijklmnopqrstuvwxyz |
576e73803b46
correct display of non-unicode, non-8859 encoded fonts
Claus Gittinger <cg@exept.de>
parents:
2921
diff
changeset
|
126 |
1234567890 !!@#$%^&*(){}[]:"~;,./<>? |
576e73803b46
correct display of non-unicode, non-8859 encoded fonts
Claus Gittinger <cg@exept.de>
parents:
2921
diff
changeset
|
127 |
' |
576e73803b46
correct display of non-unicode, non-8859 encoded fonts
Claus Gittinger <cg@exept.de>
parents:
2921
diff
changeset
|
128 |
! |
576e73803b46
correct display of non-unicode, non-8859 encoded fonts
Claus Gittinger <cg@exept.de>
parents:
2921
diff
changeset
|
129 |
|
197 | 130 |
defaultExtent |
571 | 131 |
"return the default extent of my instances. |
132 |
The value returned here is usually ignored, and |
|
133 |
the value from preferredExtent taken instead." |
|
134 |
||
2842 | 135 |
^ (Screen current pixelPerMillimeter * (150 @ 100)) rounded |
571 | 136 |
|
137 |
"Modified: 22.4.1996 / 23:36:19 / cg" |
|
197 | 138 |
! |
139 |
||
2860 | 140 |
defaultJIS0201SampleString |
141 |
"return the sample jis preview text" |
|
142 |
||
2930
576e73803b46
correct display of non-unicode, non-8859 encoded fonts
Claus Gittinger <cg@exept.de>
parents:
2921
diff
changeset
|
143 |
^ (self defaultLatin1SampleString). |
2860 | 144 |
! |
145 |
||
382 | 146 |
defaultJISSampleString |
595 | 147 |
"return the sample jis preview text" |
148 |
||
2930
576e73803b46
correct display of non-unicode, non-8859 encoded fonts
Claus Gittinger <cg@exept.de>
parents:
2921
diff
changeset
|
149 |
^ |
2888 | 150 |
'The quick brown fox |
2930
576e73803b46
correct display of non-unicode, non-8859 encoded fonts
Claus Gittinger <cg@exept.de>
parents:
2921
diff
changeset
|
151 |
jumps over the lazy dog. |
2860 | 152 |
|
2939 | 153 |
' , #(16r65E5 16r672C 16r8A9E) asUnicodeString |
382 | 154 |
! |
155 |
||
2847 | 156 |
defaultLatin1SampleString |
157 |
"return the sample latin1 preview text" |
|
158 |
||
2935 | 159 |
^ (self defaultAsciiSampleString) , 'äöüÄÖÜßéèêå©' |
2847 | 160 |
! |
161 |
||
2899 | 162 |
defaultSampleStringForEncoding:enc |
2930
576e73803b46
correct display of non-unicode, non-8859 encoded fonts
Claus Gittinger <cg@exept.de>
parents:
2921
diff
changeset
|
163 |
|string lines| |
576e73803b46
correct display of non-unicode, non-8859 encoded fonts
Claus Gittinger <cg@exept.de>
parents:
2921
diff
changeset
|
164 |
|
2899 | 165 |
enc notNil ifTrue:[ |
166 |
((enc startsWith:'unicode') or:[enc startsWith:'iso10646-']) ifTrue:[ |
|
167 |
^ self defaultUnicodeSampleString. |
|
168 |
]. |
|
169 |
(enc startsWith:'ms-ansi') ifTrue:[ |
|
170 |
^ self defaultUnicodeSampleString. |
|
171 |
]. |
|
2930
576e73803b46
correct display of non-unicode, non-8859 encoded fonts
Claus Gittinger <cg@exept.de>
parents:
2921
diff
changeset
|
172 |
|
576e73803b46
correct display of non-unicode, non-8859 encoded fonts
Claus Gittinger <cg@exept.de>
parents:
2921
diff
changeset
|
173 |
(enc startsWith:'jis') ifTrue:[ |
576e73803b46
correct display of non-unicode, non-8859 encoded fonts
Claus Gittinger <cg@exept.de>
parents:
2921
diff
changeset
|
174 |
(enc includesString:'0201') ifTrue:[ |
576e73803b46
correct display of non-unicode, non-8859 encoded fonts
Claus Gittinger <cg@exept.de>
parents:
2921
diff
changeset
|
175 |
string := self defaultJIS0201SampleString |
576e73803b46
correct display of non-unicode, non-8859 encoded fonts
Claus Gittinger <cg@exept.de>
parents:
2921
diff
changeset
|
176 |
] ifFalse:[ |
576e73803b46
correct display of non-unicode, non-8859 encoded fonts
Claus Gittinger <cg@exept.de>
parents:
2921
diff
changeset
|
177 |
string := self defaultJISSampleString |
576e73803b46
correct display of non-unicode, non-8859 encoded fonts
Claus Gittinger <cg@exept.de>
parents:
2921
diff
changeset
|
178 |
] |
576e73803b46
correct display of non-unicode, non-8859 encoded fonts
Claus Gittinger <cg@exept.de>
parents:
2921
diff
changeset
|
179 |
] ifFalse:[ |
576e73803b46
correct display of non-unicode, non-8859 encoded fonts
Claus Gittinger <cg@exept.de>
parents:
2921
diff
changeset
|
180 |
] |
2899 | 181 |
]. |
2930
576e73803b46
correct display of non-unicode, non-8859 encoded fonts
Claus Gittinger <cg@exept.de>
parents:
2921
diff
changeset
|
182 |
string isNil ifTrue:[ |
576e73803b46
correct display of non-unicode, non-8859 encoded fonts
Claus Gittinger <cg@exept.de>
parents:
2921
diff
changeset
|
183 |
string := self defaultLatin1SampleString. |
576e73803b46
correct display of non-unicode, non-8859 encoded fonts
Claus Gittinger <cg@exept.de>
parents:
2921
diff
changeset
|
184 |
]. |
576e73803b46
correct display of non-unicode, non-8859 encoded fonts
Claus Gittinger <cg@exept.de>
parents:
2921
diff
changeset
|
185 |
lines := string asStringCollection. |
3481
a1fbc8d2494d
Catch CharacterEncoderError instead of Error
Stefan Vogel <sv@exept.de>
parents:
3475
diff
changeset
|
186 |
[ |
2930
576e73803b46
correct display of non-unicode, non-8859 encoded fonts
Claus Gittinger <cg@exept.de>
parents:
2921
diff
changeset
|
187 |
lines := lines encodeFrom:#unicode into:enc |
3481
a1fbc8d2494d
Catch CharacterEncoderError instead of Error
Stefan Vogel <sv@exept.de>
parents:
3475
diff
changeset
|
188 |
] on:CharacterEncoderError do:[:ex| |
a1fbc8d2494d
Catch CharacterEncoderError instead of Error
Stefan Vogel <sv@exept.de>
parents:
3475
diff
changeset
|
189 |
"substitute a default value for codes that cannot be represented |
a1fbc8d2494d
Catch CharacterEncoderError instead of Error
Stefan Vogel <sv@exept.de>
parents:
3475
diff
changeset
|
190 |
in the new character set" |
a1fbc8d2494d
Catch CharacterEncoderError instead of Error
Stefan Vogel <sv@exept.de>
parents:
3475
diff
changeset
|
191 |
ex proceedWith:ex defaultValue. |
2930
576e73803b46
correct display of non-unicode, non-8859 encoded fonts
Claus Gittinger <cg@exept.de>
parents:
2921
diff
changeset
|
192 |
]. |
3481
a1fbc8d2494d
Catch CharacterEncoderError instead of Error
Stefan Vogel <sv@exept.de>
parents:
3475
diff
changeset
|
193 |
|
2930
576e73803b46
correct display of non-unicode, non-8859 encoded fonts
Claus Gittinger <cg@exept.de>
parents:
2921
diff
changeset
|
194 |
^ lines. |
2899 | 195 |
! |
196 |
||
2847 | 197 |
defaultUnicodeSampleString |
198 |
"return the sample unicode preview text" |
|
595 | 199 |
|
2275 | 200 |
|t| |
201 |
||
2930
576e73803b46
correct display of non-unicode, non-8859 encoded fonts
Claus Gittinger <cg@exept.de>
parents:
2921
diff
changeset
|
202 |
t := (self defaultAsciiSampleString) , ' |
2935 | 203 |
diaresis: äöüÄÖÜß |
204 |
accent: éèêåÅ |
|
3187 | 205 |
special:' , |
206 |
#(16r20AC) asUnicodeString , ' |
|
2939 | 207 |
cyrillic: ' , |
208 |
#(16r440 16r443 16r441 16r441 16r43A 16r438 16r439 16r20 16r44F 16r437 16r44B 16r43A) asUnicodeString , ' |
|
2933 | 209 |
greek: ' , |
2939 | 210 |
#(16r395 16r3BB 16r3BB 16r3B7 16r3BD 16r3B9 16r3BA 16r3AC) asUnicodeString , |
2933 | 211 |
' |
212 |
japanese: ' , |
|
2939 | 213 |
#(16r65E5 16r672C 16r8A9E) asUnicodeString , |
2933 | 214 |
' |
215 |
'. |
|
2276 | 216 |
^ t |
2933 | 217 |
|
218 |
"Modified: 29.4.1996 / 09:46:19 / cg" |
|
2930
576e73803b46
correct display of non-unicode, non-8859 encoded fonts
Claus Gittinger <cg@exept.de>
parents:
2921
diff
changeset
|
219 |
! |
576e73803b46
correct display of non-unicode, non-8859 encoded fonts
Claus Gittinger <cg@exept.de>
parents:
2921
diff
changeset
|
220 |
|
576e73803b46
correct display of non-unicode, non-8859 encoded fonts
Claus Gittinger <cg@exept.de>
parents:
2921
diff
changeset
|
221 |
sampleStringWithAllLetters |
576e73803b46
correct display of non-unicode, non-8859 encoded fonts
Claus Gittinger <cg@exept.de>
parents:
2921
diff
changeset
|
222 |
^ (self classResources at:'CHARSET_TEST_SENTENCE' ifAbsent:'The quick brown fox jumps over the lazy dog') withCRs |
0 | 223 |
! ! |
224 |
||
2852 | 225 |
!FontPanel class methodsFor:'menu specs'! |
226 |
||
227 |
previewMenu |
|
228 |
"This resource specification was automatically generated |
|
229 |
by the MenuEditor of ST/X." |
|
230 |
||
231 |
"Do not manually edit this!! If it is corrupted, |
|
232 |
the MenuEditor may not be able to read the specification." |
|
233 |
||
234 |
" |
|
235 |
MenuEditor new openOnClass:FontPanel andSelector:#previewMenu |
|
236 |
(Menu new fromLiteralArrayEncoding:(FontPanel previewMenu)) startUp |
|
237 |
" |
|
238 |
||
239 |
<resource: #menu> |
|
240 |
||
241 |
^ |
|
242 |
#(Menu |
|
243 |
( |
|
244 |
(MenuItem |
|
245 |
label: 'Copy' |
|
246 |
itemValue: previewCopySelection |
|
247 |
translateLabel: true |
|
248 |
) |
|
249 |
(MenuItem |
|
250 |
label: '-' |
|
251 |
) |
|
252 |
(MenuItem |
|
253 |
label: 'Show Character Set' |
|
254 |
itemValue: previewShowCharacterSet |
|
255 |
translateLabel: true |
|
3405
9a03bc64e285
dont offer special-character display in menu, if its not available.
Claus Gittinger <cg@exept.de>
parents:
3274
diff
changeset
|
256 |
isVisible: characterSetViewClassAvailable |
2852 | 257 |
) |
2875 | 258 |
(MenuItem |
259 |
label: 'Show Character Set (Using xfd)' |
|
260 |
itemValue: previewShowCharacterSetUsingXFD |
|
261 |
translateLabel: true |
|
3405
9a03bc64e285
dont offer special-character display in menu, if its not available.
Claus Gittinger <cg@exept.de>
parents:
3274
diff
changeset
|
262 |
isVisible: osIsUNIX |
2875 | 263 |
) |
2935 | 264 |
(MenuItem |
265 |
label: '-' |
|
3405
9a03bc64e285
dont offer special-character display in menu, if its not available.
Claus Gittinger <cg@exept.de>
parents:
3274
diff
changeset
|
266 |
isVisible: characterSetViewClassAvailableOrOSIsUNIX |
2935 | 267 |
) |
268 |
(MenuItem |
|
269 |
label: 'Inspect Font' |
|
270 |
itemValue: previewInspectFont |
|
271 |
translateLabel: true |
|
272 |
) |
|
3604 | 273 |
(MenuItem |
274 |
label: 'Copy Fontname' |
|
275 |
itemValue: copyFontName |
|
276 |
translateLabel: true |
|
277 |
) |
|
2852 | 278 |
) |
279 |
nil |
|
280 |
nil |
|
281 |
) |
|
3405
9a03bc64e285
dont offer special-character display in menu, if its not available.
Claus Gittinger <cg@exept.de>
parents:
3274
diff
changeset
|
282 |
|
9a03bc64e285
dont offer special-character display in menu, if its not available.
Claus Gittinger <cg@exept.de>
parents:
3274
diff
changeset
|
283 |
"Modified: / 11-10-2006 / 21:51:02 / cg" |
2852 | 284 |
! ! |
285 |
||
1185
3b8bd5ea8d62
action block is evaluated with a fontDescription
Claus Gittinger <cg@exept.de>
parents:
797
diff
changeset
|
286 |
!FontPanel class methodsFor:'startup'! |
0 | 287 |
|
288 |
fontFromUser |
|
77 | 289 |
"open a fontPanel and return the selected font, or nil |
290 |
if abort is pressed" |
|
291 |
||
3740 | 292 |
^ self |
293 |
fontFromUserInitial:nil |
|
294 |
title:nil |
|
295 |
filter:nil |
|
296 |
encoding:nil |
|
297 |
enabled:true |
|
410 | 298 |
|
299 |
" |
|
300 |
FontPanel fontFromUser |
|
301 |
" |
|
302 |
||
303 |
"Modified: 27.2.1996 / 00:51:59 / cg" |
|
304 |
! |
|
305 |
||
306 |
fontFromUserInitial:aFont |
|
595 | 307 |
"open a fontPanel showing aFont initially, |
308 |
and return the selected font, or nil if abort is pressed" |
|
410 | 309 |
|
3740 | 310 |
^ self |
311 |
fontFromUserInitial:aFont |
|
312 |
title:nil |
|
313 |
filter:nil |
|
314 |
encoding:nil |
|
315 |
enabled:true |
|
413 | 316 |
|
317 |
" |
|
318 |
FontPanel fontFromUserInitial:(Font family:'courier' size:12) |
|
3740 | 319 |
FontPanel fontFromUserInitial:MenuPanel defaultFont |
413 | 320 |
" |
321 |
! |
|
322 |
||
323 |
fontFromUserInitial:aFont title:someTitle |
|
595 | 324 |
"open a fontPanel with title and return the selected font, |
325 |
or nil if abort is pressed" |
|
413 | 326 |
|
3740 | 327 |
^ self |
328 |
fontFromUserInitial:aFont |
|
329 |
title:someTitle |
|
330 |
filter:nil |
|
331 |
encoding:nil |
|
332 |
enabled:true |
|
415 | 333 |
|
334 |
" |
|
335 |
FontPanel fontFromUserInitial:(Font family:'courier' size:12) title:'select some font' |
|
336 |
" |
|
337 |
||
338 |
"Created: 27.2.1996 / 00:59:46 / cg" |
|
595 | 339 |
"Modified: 29.4.1996 / 09:45:34 / cg" |
415 | 340 |
! |
341 |
||
2849 | 342 |
fontFromUserInitial:initialFont title:someTitle filter:aFilterBlock |
595 | 343 |
"open a fontPanel with title and font-filter |
344 |
and return the selected font, or nil if abort is pressed" |
|
415 | 345 |
|
3740 | 346 |
^ self |
347 |
fontFromUserInitial:initialFont |
|
348 |
title:someTitle |
|
349 |
filter:aFilterBlock |
|
350 |
encoding:nil |
|
351 |
enabled:true |
|
2887 | 352 |
|
353 |
" |
|
354 |
FontPanel fontFromUserInitial:(Font family:'courier' size:12) title:'select some font' |
|
355 |
" |
|
356 |
||
357 |
"Created: 27.2.1996 / 00:59:46 / cg" |
|
358 |
"Modified: 10.4.1997 / 09:53:03 / cg" |
|
359 |
! |
|
360 |
||
361 |
fontFromUserInitial:initialFont title:someTitle filter:aFilterBlock encoding:encoding |
|
362 |
"open a fontPanel with title and font-filter |
|
363 |
and return the selected font, or nil if abort is pressed" |
|
364 |
||
3740 | 365 |
^ self |
366 |
fontFromUserInitial:initialFont |
|
367 |
title:someTitle |
|
368 |
filter:aFilterBlock |
|
369 |
encoding:encoding |
|
370 |
enabled:true |
|
371 |
||
372 |
" |
|
373 |
FontPanel fontFromUserInitial:(Font family:'courier' size:12) title:'select some font' |
|
374 |
" |
|
375 |
! |
|
376 |
||
377 |
fontFromUserInitial:initialFont title:someTitle filter:aFilterBlock encoding:encoding enabled:enabled |
|
378 |
"open a fontPanel with title and font-filter |
|
379 |
and return the selected font, or nil if abort is pressed" |
|
380 |
||
1185
3b8bd5ea8d62
action block is evaluated with a fontDescription
Claus Gittinger <cg@exept.de>
parents:
797
diff
changeset
|
381 |
|fontPanel selectedFont| |
77 | 382 |
|
3817 | 383 |
fontPanel := self new. |
415 | 384 |
fontPanel filter:aFilterBlock. |
413 | 385 |
someTitle notNil ifTrue:[ |
386 |
fontPanel label:someTitle |
|
387 |
]. |
|
1185
3b8bd5ea8d62
action block is evaluated with a fontDescription
Claus Gittinger <cg@exept.de>
parents:
797
diff
changeset
|
388 |
fontPanel action:[:aFontDescription | selectedFont := aFontDescription]. |
2849 | 389 |
initialFont notNil ifTrue:[ |
390 |
fontPanel initialFont:initialFont. |
|
410 | 391 |
]. |
2888 | 392 |
encoding notNil ifTrue:[ |
393 |
fontPanel encoding:encoding. |
|
2937 | 394 |
] ifFalse:[ |
395 |
initialFont notNil ifTrue:[ |
|
396 |
fontPanel encoding:initialFont encoding |
|
397 |
]. |
|
2888 | 398 |
]. |
3740 | 399 |
fontPanel enabled:enabled. |
0 | 400 |
fontPanel showAtPointer. |
1185
3b8bd5ea8d62
action block is evaluated with a fontDescription
Claus Gittinger <cg@exept.de>
parents:
797
diff
changeset
|
401 |
fontPanel destroy. |
3b8bd5ea8d62
action block is evaluated with a fontDescription
Claus Gittinger <cg@exept.de>
parents:
797
diff
changeset
|
402 |
^ selectedFont |
0 | 403 |
|
77 | 404 |
" |
413 | 405 |
FontPanel fontFromUserInitial:(Font family:'courier' size:12) title:'select some font' |
77 | 406 |
" |
410 | 407 |
|
413 | 408 |
"Created: 27.2.1996 / 00:59:46 / cg" |
1185
3b8bd5ea8d62
action block is evaluated with a fontDescription
Claus Gittinger <cg@exept.de>
parents:
797
diff
changeset
|
409 |
"Modified: 10.4.1997 / 09:53:03 / cg" |
3740 | 410 |
! |
411 |
||
412 |
openOn:aFont |
|
413 |
"open a fontPanel showing aFont initially. |
|
414 |
This panel is for information only - no font selection is possible." |
|
415 |
||
416 |
^ self |
|
417 |
fontFromUserInitial:aFont |
|
418 |
title:(aFont userFriendlyName) |
|
419 |
filter:nil |
|
420 |
encoding:nil |
|
421 |
enabled:false |
|
422 |
||
423 |
" |
|
424 |
FontPanel openOn:(Font family:'courier' size:12) |
|
425 |
FontPanel openOn:MenuPanel defaultFont |
|
426 |
" |
|
0 | 427 |
! ! |
428 |
||
429 |
!FontPanel methodsFor:'accessing'! |
|
430 |
||
595 | 431 |
action:aFourArgBlock |
432 |
"set the action to be evaluated on ok. |
|
1185
3b8bd5ea8d62
action block is evaluated with a fontDescription
Claus Gittinger <cg@exept.de>
parents:
797
diff
changeset
|
433 |
The block will be evaluated with family, face, style, size and encoding." |
595 | 434 |
|
435 |
okAction := aFourArgBlock |
|
436 |
||
1185
3b8bd5ea8d62
action block is evaluated with a fontDescription
Claus Gittinger <cg@exept.de>
parents:
797
diff
changeset
|
437 |
"Modified: 10.4.1997 / 09:49:58 / cg" |
197 | 438 |
! |
439 |
||
434
22586d8221e1
dont get confused by same-name but different encoding
Claus Gittinger <cg@exept.de>
parents:
415
diff
changeset
|
440 |
encoding:aPattern |
595 | 441 |
"set the encoding goal" |
442 |
||
434
22586d8221e1
dont get confused by same-name but different encoding
Claus Gittinger <cg@exept.de>
parents:
415
diff
changeset
|
443 |
encoding := aPattern. |
2843 | 444 |
encodingFilter contents:encoding. |
445 |
||
446 |
self encodingFilterSelected:encoding. |
|
434
22586d8221e1
dont get confused by same-name but different encoding
Claus Gittinger <cg@exept.de>
parents:
415
diff
changeset
|
447 |
shown ifTrue:[ |
22586d8221e1
dont get confused by same-name but different encoding
Claus Gittinger <cg@exept.de>
parents:
415
diff
changeset
|
448 |
self updateFamilyList |
22586d8221e1
dont get confused by same-name but different encoding
Claus Gittinger <cg@exept.de>
parents:
415
diff
changeset
|
449 |
]. |
22586d8221e1
dont get confused by same-name but different encoding
Claus Gittinger <cg@exept.de>
parents:
415
diff
changeset
|
450 |
|
22586d8221e1
dont get confused by same-name but different encoding
Claus Gittinger <cg@exept.de>
parents:
415
diff
changeset
|
451 |
"Created: 29.2.1996 / 04:05:31 / cg" |
595 | 452 |
"Modified: 29.4.1996 / 09:40:18 / cg" |
434
22586d8221e1
dont get confused by same-name but different encoding
Claus Gittinger <cg@exept.de>
parents:
415
diff
changeset
|
453 |
! |
22586d8221e1
dont get confused by same-name but different encoding
Claus Gittinger <cg@exept.de>
parents:
415
diff
changeset
|
454 |
|
415 | 455 |
filter:aOneArgBlock |
595 | 456 |
"set a filter; if non-nil, only fonts for which the filterBlock |
457 |
returns true will be offered" |
|
458 |
||
415 | 459 |
filter := aOneArgBlock. |
2826 | 460 |
familyList list:nil. |
415 | 461 |
shown ifTrue:[ |
462 |
self updateFamilyList |
|
463 |
]. |
|
464 |
||
465 |
"Created: 27.2.1996 / 01:40:08 / cg" |
|
595 | 466 |
"Modified: 29.4.1996 / 09:40:49 / cg" |
415 | 467 |
! |
468 |
||
0 | 469 |
initialFont:aFont |
128 | 470 |
"set the font to be selected initially" |
0 | 471 |
|
2849 | 472 |
|encoding| |
473 |
||
128 | 474 |
selectedFont := aFont. |
2849 | 475 |
encoding := aFont encoding. |
3841 | 476 |
sizeUnit := aFont sizeUnit. |
477 |
||
2849 | 478 |
"/ self halt. |
479 |
encodingFilter contents:encoding. |
|
480 |
self encodingFilterSelected:encoding. |
|
382 | 481 |
self showSelectedFont. |
482 |
||
483 |
"Modified: 23.2.1996 / 00:51:32 / cg" |
|
101 | 484 |
! ! |
485 |
||
77 | 486 |
!FontPanel methodsFor:'initialization'! |
487 |
||
3740 | 488 |
enabled:aBoolean |
489 |
familyList enabled:aBoolean. |
|
490 |
faceList enabled:aBoolean. |
|
491 |
sizeList enabled:aBoolean. |
|
3817 | 492 |
encodingFilter notNil ifTrue:[ |
493 |
encodingFilter enabled:aBoolean. |
|
494 |
] |
|
3740 | 495 |
! |
496 |
||
77 | 497 |
initialize |
382 | 498 |
|familyLabel faceLabel sizeLabel panel fontBrowserView v1 v2 v3 |
3841 | 499 |
mm fH eH l box1 box2 showFontNameLabel sep| |
77 | 500 |
|
501 |
super initialize. |
|
502 |
||
2847 | 503 |
showFontNameLabel := device platformName ~= 'WIN32'. |
3837 | 504 |
sizeUnit := #pt. |
2847 | 505 |
|
382 | 506 |
mm := ViewSpacing. |
507 |
||
1763 | 508 |
self addAbortAndOkButtons. |
77 | 509 |
|
390
1d54a9b41463
say Hello world in JIS font ;-)
Claus Gittinger <cg@exept.de>
parents:
382
diff
changeset
|
510 |
panel := View origin:0.0@0.0 corner:1.0@1.0 in:self. |
3607
242d08639bcc
added preferredWidth & preferredHeight
Claus Gittinger <cg@exept.de>
parents:
3604
diff
changeset
|
511 |
panel bottomInset:(buttonPanel preferredHeight |
2847 | 512 |
+ (mm*3) |
513 |
+ (showFontNameLabel ifTrue:24 ifFalse:0) ). |
|
77 | 514 |
|
150 | 515 |
label := resources string:'Font dialog'. |
77 | 516 |
|
3832 | 517 |
box1 := HorizontalPanelView in:panel. |
518 |
"/ box horizontalLayout:#leftFit. |
|
519 |
box1 horizontalLayout:#left. |
|
520 |
box1 origin:0.0@1.0 corner:0.8@1.0. |
|
2842 | 521 |
|
3832 | 522 |
box2 := HorizontalPanelView in:panel. |
523 |
"/ box horizontalLayout:#leftFit. |
|
524 |
box2 horizontalLayout:#right. |
|
525 |
box2 origin:0.8@1.0 corner:1.0@1.0. |
|
526 |
||
527 |
l := Label label:(resources string:'Encoding:') in:box1. |
|
2842 | 528 |
l borderWidth:0. |
529 |
l adjust:#left. |
|
530 |
||
3817 | 531 |
eH := 0. |
532 |
||
3832 | 533 |
encodingFilter := ComboBoxView in:box1. |
2942 | 534 |
"/ encodingFilter font:l font. |
2826 | 535 |
encodingFilter level:-1. |
536 |
encodingFilter contents:'*'. |
|
2842 | 537 |
encodingFilter list:(self listOfEncodingsInFilterCombo). |
2826 | 538 |
encodingFilter action:[:pattern | self encodingFilterSelected:pattern]. |
539 |
encodingFilter immediateAccept:true. |
|
2942 | 540 |
"/ encodingFilter editor font:l font. |
2842 | 541 |
|
3817 | 542 |
self showEncodingFilter ifTrue:[ |
543 |
eH := encodingFilter preferredHeight. |
|
3832 | 544 |
box1 topInset:(eH negated-4); horizontalInset:mm. |
3817 | 545 |
] ifFalse:[ |
546 |
encodingFilter beInvisible |
|
547 |
]. |
|
2842 | 548 |
|
2826 | 549 |
"/ encodingFilter acceptOnReturn:true. |
550 |
"/ encodingFilter acceptOnTab:true. |
|
551 |
"/ encodingFilter acceptOnLeave:true. |
|
552 |
"/ encodingFilter acceptOnLostFocus:true. |
|
553 |
"/ encodingFilter acceptOnPointerLeave:true. |
|
554 |
||
3832 | 555 |
encodingLabel := Label label:' ' in:box1. |
2842 | 556 |
"/ eH := encodingLabel preferredExtent y. |
3832 | 557 |
"/ encodingLabel origin:0.6@1.0 corner:1.0@1.0. |
558 |
"/ encodingLabel topInset:(eH negated); horizontalInset:mm. |
|
2842 | 559 |
encodingLabel level:0; adjust:#left. |
560 |
encodingLabel adjust:#right. |
|
3817 | 561 |
self showEncodingFilter ifFalse:[ |
562 |
encodingLabel beInvisible |
|
563 |
]. |
|
382 | 564 |
|
3832 | 565 |
sep := View in:box1. |
566 |
sep width:20 height:10. |
|
567 |
||
568 |
pixelPointSwitch := ComboListView in:box2. |
|
569 |
"/ encodingFilter font:l font. |
|
570 |
pixelPointSwitch level:-1. |
|
3841 | 571 |
pixelPointSwitch contents:'pt'. |
3837 | 572 |
pixelPointSwitch list:#(#pt #px). |
3832 | 573 |
pixelPointSwitch action:[:sizeUnit | self sizeUnitSelected:sizeUnit]. |
574 |
box2 topInset:(pixelPointSwitch preferredHeight negated-4); horizontalInset:mm. |
|
575 |
"/ encodingFilter editor font:l font. |
|
576 |
||
577 |
self showEncodingFilter ifTrue:[ |
|
578 |
eH := encodingFilter preferredHeight. |
|
579 |
box1 topInset:(eH negated-4); horizontalInset:mm. |
|
580 |
] ifFalse:[ |
|
581 |
encodingFilter beInvisible |
|
582 |
]. |
|
583 |
||
2847 | 584 |
showFontNameLabel ifTrue:[ |
585 |
nameLabel := Label label:'' in:self. |
|
586 |
nameLabel origin:0.0@1.0 corner:1.0@1.0. |
|
3607
242d08639bcc
added preferredWidth & preferredHeight
Claus Gittinger <cg@exept.de>
parents:
3604
diff
changeset
|
587 |
nameLabel bottomInset:(buttonPanel preferredHeight + (mm*2)). |
242d08639bcc
added preferredWidth & preferredHeight
Claus Gittinger <cg@exept.de>
parents:
3604
diff
changeset
|
588 |
nameLabel topInset:(buttonPanel preferredHeight + (mm*2) + 24) negated; horizontalInset:mm. |
2847 | 589 |
nameLabel level:0; adjust:#left. |
590 |
nameLabel font:(FontDescription family:'helvetica' face:'medium' style:'roman' size:9). |
|
591 |
]. |
|
382 | 592 |
|
2842 | 593 |
previewField := HVScrollableView for:TextView in:panel. |
594 |
previewField origin:0.0@0.0 corner:1.0@0.4. |
|
595 |
previewField autoHideScrollBars:true. |
|
596 |
previewField := previewField scrolledView. |
|
382 | 597 |
previewField inset:mm. |
77 | 598 |
|
599 |
self is3D ifTrue:[ |
|
251
25f76efaa547
oops - dont pass a collection of numbers to the size-view
Claus Gittinger <cg@exept.de>
parents:
243
diff
changeset
|
600 |
previewField level:-1. |
77 | 601 |
] ifFalse:[ |
251
25f76efaa547
oops - dont pass a collection of numbers to the size-view
Claus Gittinger <cg@exept.de>
parents:
243
diff
changeset
|
602 |
previewField borderWidth:1. |
77 | 603 |
]. |
604 |
||
390
1d54a9b41463
say Hello world in JIS font ;-)
Claus Gittinger <cg@exept.de>
parents:
382
diff
changeset
|
605 |
fontBrowserView := View origin:0.0@0.4 corner:1.0@1.0 in:panel. |
382 | 606 |
fontBrowserView bottomInset:(eH + mm). |
77 | 607 |
|
608 |
v1 := View origin:0.0@0.0 corner:0.4@1.0 in:fontBrowserView. |
|
609 |
||
2842 | 610 |
familyLabel := Label label:(resources string:'Family') in:v1. |
77 | 611 |
familyLabel borderWidth:0. |
612 |
familyLabel origin:(0.0 @ 0.0) extent:(1.0 @ nil). |
|
3607
242d08639bcc
added preferredWidth & preferredHeight
Claus Gittinger <cg@exept.de>
parents:
3604
diff
changeset
|
613 |
fH := familyLabel preferredHeight. |
77 | 614 |
|
615 |
familyList := ScrollableView for:SelectionInListView in:v1. |
|
382 | 616 |
familyList origin:(0.0 @ 0.0) corner:(1.0 @ 1.0). |
617 |
familyList inset:mm. |
|
618 |
familyList topInset:fH. |
|
619 |
||
128 | 620 |
familyList := familyList scrolledView. |
740
2d5cb01c7e11
no need for focusSequence - DialogBox does it
Claus Gittinger <cg@exept.de>
parents:
713
diff
changeset
|
621 |
self makeTabable:familyList. |
77 | 622 |
|
623 |
v2 := View origin:0.4@0.0 corner:0.8@1.0 |
|
251
25f76efaa547
oops - dont pass a collection of numbers to the size-view
Claus Gittinger <cg@exept.de>
parents:
243
diff
changeset
|
624 |
in:fontBrowserView. |
77 | 625 |
|
2842 | 626 |
faceLabel := Label label:(resources string:'Typeface') in:v2. |
77 | 627 |
faceLabel borderWidth:0. |
628 |
faceLabel origin:(0.0 @ 0.0) extent:(1.0 @ nil). |
|
629 |
||
630 |
faceList := ScrollableView for:SelectionInListView in:v2. |
|
382 | 631 |
faceList origin:(0.0 @ 0.0) corner:(1.0 @ 1.0). |
632 |
faceList inset:mm. |
|
633 |
faceList topInset:fH. |
|
128 | 634 |
faceList := faceList scrolledView. |
740
2d5cb01c7e11
no need for focusSequence - DialogBox does it
Claus Gittinger <cg@exept.de>
parents:
713
diff
changeset
|
635 |
self makeTabable:faceList. |
77 | 636 |
|
2842 | 637 |
v3 := View origin:0.8@0.0 corner:1.0@1.0 in:fontBrowserView. |
77 | 638 |
|
3832 | 639 |
sizeLabelHolder := (resources string:'Size') asValue. |
640 |
sizeLabel := Label in:v3. |
|
641 |
sizeLabel labelChannel:sizeLabelHolder. |
|
77 | 642 |
sizeLabel borderWidth:0. |
643 |
sizeLabel origin:(0.0 @ 0.0)extent:(1.0 @ nil). |
|
644 |
||
645 |
sizeList := ScrollableView for:SelectionInListView in:v3. |
|
382 | 646 |
sizeList origin:(0.0 @ 0.0) corner:(1.0 @ 1.0). |
647 |
sizeList inset:mm. |
|
648 |
sizeList topInset:fH. |
|
128 | 649 |
sizeList := sizeList scrolledView. |
740
2d5cb01c7e11
no need for focusSequence - DialogBox does it
Claus Gittinger <cg@exept.de>
parents:
713
diff
changeset
|
650 |
self makeTabable:sizeList. |
77 | 651 |
|
652 |
familyList action:[:lineNr | self familySelected:(familyList selectionValue)]. |
|
653 |
faceList action:[:lineNr | self faceSelected:(faceList selectionValue)]. |
|
654 |
sizeList action:[:lineNr | self sizeSelected:(sizeList selectionValue)]. |
|
655 |
||
2852 | 656 |
previewField menuHolder:self previewMenu. |
657 |
||
77 | 658 |
" |
659 |
FontPanel new showAtPointer |
|
660 |
" |
|
251
25f76efaa547
oops - dont pass a collection of numbers to the size-view
Claus Gittinger <cg@exept.de>
parents:
243
diff
changeset
|
661 |
|
740
2d5cb01c7e11
no need for focusSequence - DialogBox does it
Claus Gittinger <cg@exept.de>
parents:
713
diff
changeset
|
662 |
"Modified: 31.5.1996 / 22:01:45 / cg" |
77 | 663 |
! |
664 |
||
2842 | 665 |
listOfEncodingsInFilterCombo |
2878 | 666 |
|availableEncodings listPresentedToUser| |
2842 | 667 |
|
2878 | 668 |
listOfEncodings := OrderedCollection new. |
2849 | 669 |
device platformName = 'WIN32' ifTrue:[ |
2878 | 670 |
listOfEncodings |
2849 | 671 |
addAll: |
672 |
#( |
|
673 |
'*' |
|
674 |
nil |
|
675 |
). |
|
676 |
] ifFalse:[ |
|
2878 | 677 |
listOfEncodings |
2849 | 678 |
addAll: |
679 |
#( |
|
680 |
'*' |
|
681 |
'iso8859*' |
|
682 |
'iso10646-1' |
|
683 |
'jis*' |
|
684 |
nil |
|
685 |
). |
|
686 |
]. |
|
2842 | 687 |
|
688 |
availableEncodings := Set new. |
|
2845 | 689 |
device listOfAvailableFonts do:[:f | availableEncodings add:(f encoding ? '?')]. |
2842 | 690 |
availableEncodings := availableEncodings asSortedCollection. |
2878 | 691 |
listOfEncodings addAll:availableEncodings. |
692 |
||
693 |
listPresentedToUser := listOfEncodings collect:[:enc | |
|
694 |
|encoder userFriendlyName| |
|
695 |
||
2938 | 696 |
"/ |
697 |
"/ disabled to avoid autoloading of encoders. |
|
698 |
"/ (enc notNil and:[enc ~= '*']) ifTrue:[ |
|
699 |
"/ encoder := CharacterEncoder encoderFor:enc ifAbsent:nil. |
|
700 |
"/ encoder notNil ifTrue:[ |
|
701 |
"/ userFriendlyName := encoder userFriendlyNameOfEncoding. |
|
702 |
"/ ]. |
|
703 |
"/ ]. |
|
2937 | 704 |
(userFriendlyName notNil and:[(userFriendlyName sameAs: enc) not]) ifTrue:[ |
2878 | 705 |
enc , ' (' , userFriendlyName , ')' |
706 |
] ifFalse:[ |
|
707 |
enc |
|
708 |
] |
|
709 |
]. |
|
710 |
^ listPresentedToUser. |
|
2842 | 711 |
! |
712 |
||
1277 | 713 |
postRealize |
197 | 714 |
"kludge for sco - xlsfont fails sometimes - try again here" |
715 |
||
415 | 716 |
self updateFamilyList. |
1277 | 717 |
super postRealize |
415 | 718 |
|
719 |
"Modified: 27.2.1996 / 01:40:47 / cg" |
|
1277 | 720 |
"Created: 24.7.1997 / 18:12:42 / cg" |
2852 | 721 |
! |
722 |
||
723 |
previewMenu |
|
724 |
<resource: #programMenu > |
|
725 |
||
726 |
|menu| |
|
727 |
||
3475 | 728 |
menu := Menu decodeFromLiteralArray:(self class previewMenu). |
2852 | 729 |
menu findGuiResourcesIn:self. |
3405
9a03bc64e285
dont offer special-character display in menu, if its not available.
Claus Gittinger <cg@exept.de>
parents:
3274
diff
changeset
|
730 |
^ menu |
2875 | 731 |
|
3475 | 732 |
"Modified: / 27-03-2007 / 11:15:53 / cg" |
3817 | 733 |
! |
734 |
||
735 |
showEncodingFilter |
|
736 |
^ true |
|
77 | 737 |
! ! |
738 |
||
0 | 739 |
!FontPanel methodsFor:'private'! |
740 |
||
541
76018ea821ca
clear preview & encoding when no font is shown
Claus Gittinger <cg@exept.de>
parents:
540
diff
changeset
|
741 |
clearPreview |
595 | 742 |
"clear the preview subview" |
743 |
||
541
76018ea821ca
clear preview & encoding when no font is shown
Claus Gittinger <cg@exept.de>
parents:
540
diff
changeset
|
744 |
shown ifTrue:[ |
1297
f5ea02391a59
use #contents: instead of #clear
Claus Gittinger <cg@exept.de>
parents:
1284
diff
changeset
|
745 |
previewField contents:nil. |
3817 | 746 |
encodingLabel notNil ifTrue:[ |
747 |
encodingLabel label:''. |
|
748 |
]. |
|
541
76018ea821ca
clear preview & encoding when no font is shown
Claus Gittinger <cg@exept.de>
parents:
540
diff
changeset
|
749 |
]. |
76018ea821ca
clear preview & encoding when no font is shown
Claus Gittinger <cg@exept.de>
parents:
540
diff
changeset
|
750 |
|
76018ea821ca
clear preview & encoding when no font is shown
Claus Gittinger <cg@exept.de>
parents:
540
diff
changeset
|
751 |
"Created: 17.4.1996 / 15:19:16 / cg" |
1297
f5ea02391a59
use #contents: instead of #clear
Claus Gittinger <cg@exept.de>
parents:
1284
diff
changeset
|
752 |
"Modified: 11.8.1997 / 03:01:42 / cg" |
541
76018ea821ca
clear preview & encoding when no font is shown
Claus Gittinger <cg@exept.de>
parents:
540
diff
changeset
|
753 |
! |
76018ea821ca
clear preview & encoding when no font is shown
Claus Gittinger <cg@exept.de>
parents:
540
diff
changeset
|
754 |
|
197 | 755 |
extractFaceAndStyleFrom:aString |
595 | 756 |
"given a string, extract currentFace and currentStyle" |
757 |
||
197 | 758 |
|index| |
759 |
||
760 |
index := aString indexOf:$-. |
|
761 |
(index ~~ 0) ifTrue:[ |
|
595 | 762 |
currentFaceAndStyle := aString. |
763 |
currentFace := aString copyTo:(index - 1). |
|
764 |
currentStyle := aString copyFrom:(index + 1) |
|
197 | 765 |
] |
766 |
||
595 | 767 |
"Modified: 29.4.1996 / 09:41:47 / cg" |
197 | 768 |
! |
769 |
||
3817 | 770 |
fontForPreview |
771 |
"get the preview font" |
|
772 |
||
3837 | 773 |
|font allFonts fonts| |
3817 | 774 |
|
3841 | 775 |
self assert:(currentSize notNil). |
776 |
||
3817 | 777 |
allFonts := device |
3837 | 778 |
fontsInFamily:(currentFamily ? '*') |
779 |
face:(currentFace ? '*') |
|
780 |
style:(currentStyle ? '*') |
|
781 |
filtering:filter. |
|
3817 | 782 |
|
3837 | 783 |
sizeUnit == #px ifTrue:[ |
3834 | 784 |
fonts := allFonts select:[:f | f pixelSize = currentSize]. |
785 |
] ifFalse:[ |
|
786 |
fonts := allFonts select:[:f | f size = currentSize]. |
|
787 |
]. |
|
3817 | 788 |
fonts notEmpty ifTrue:[ |
789 |
font := fonts anElement. |
|
790 |
] ifFalse:[ |
|
791 |
"/ mhmh: |
|
792 |
"/ size=0 is returned for scalable fonts. |
|
793 |
"/ Any size is possible. |
|
794 |
"/ |
|
795 |
fonts := allFonts select:[:f | f size = 0]. |
|
796 |
fonts notEmpty ifTrue:[ |
|
797 |
font := Font family:currentFamily |
|
798 |
face:currentFace |
|
799 |
style:currentStyle |
|
3837 | 800 |
size:currentSize |
801 |
sizeUnit:sizeUnit |
|
3817 | 802 |
encoding:(fonts anElement encoding). |
803 |
] |
|
804 |
]. |
|
805 |
^ font |
|
806 |
! |
|
807 |
||
808 |
getFacesForFamily:aFamilyName filtering:filter |
|
809 |
"the list of font faces for a given family" |
|
810 |
||
811 |
^ device facesInFamily:aFamilyName filtering:filter |
|
812 |
! |
|
813 |
||
814 |
getFamilyList |
|
815 |
"the list of font families" |
|
816 |
||
817 |
^ device fontFamiliesFiltering:filter. |
|
818 |
! |
|
819 |
||
820 |
getSizesInFamily:aFamilyName face:face style:style filtering:filter |
|
3837 | 821 |
sizeUnit == #px ifTrue:[ |
3834 | 822 |
^ device |
823 |
pixelSizesInFamily:(currentFamily ? '*') |
|
824 |
face:(currentFace ? '*') |
|
825 |
style:(currentStyle ? '*') |
|
826 |
filtering:filter. |
|
827 |
]. |
|
828 |
||
3817 | 829 |
^ device |
830 |
sizesInFamily:(currentFamily ? '*') |
|
831 |
face:(currentFace ? '*') |
|
832 |
style:(currentStyle ? '*') |
|
833 |
filtering:filter. |
|
834 |
! |
|
835 |
||
836 |
getStylesInFamily:aFamilyName face:aFace filtering:filter |
|
837 |
"the list of font styles for a given family-face" |
|
838 |
||
839 |
^ device stylesInFamily:aFamilyName face:aFace filtering:filter. |
|
840 |
! |
|
841 |
||
197 | 842 |
showPreview |
595 | 843 |
"show the preview text" |
844 |
||
3817 | 845 |
|font deviceFont enc fontName| |
382 | 846 |
|
541
76018ea821ca
clear preview & encoding when no font is shown
Claus Gittinger <cg@exept.de>
parents:
540
diff
changeset
|
847 |
self clearPreview. |
76018ea821ca
clear preview & encoding when no font is shown
Claus Gittinger <cg@exept.de>
parents:
540
diff
changeset
|
848 |
|
197 | 849 |
" |
850 |
show a wait cursor: for some fonts (kanji etc) the |
|
2890 | 851 |
X-server needs quite some time to load the font |
197 | 852 |
" |
255 | 853 |
self withWaitCursorDo:[ |
3817 | 854 |
font := self fontForPreview. |
2843 | 855 |
font notNil ifTrue:[ |
2890 | 856 |
deviceFont := font onDevice:device. |
857 |
enc := deviceFont encoding. |
|
2916 | 858 |
enc isNil ifTrue:[enc := #'fontspecific']. |
434
22586d8221e1
dont get confused by same-name but different encoding
Claus Gittinger <cg@exept.de>
parents:
415
diff
changeset
|
859 |
|
2874 | 860 |
previewField font:deviceFont. |
861 |
previewField characterEncoding:enc. |
|
862 |
||
2287
b33ad40d7538
preview fixed when font is bad
Claus Gittinger <cg@exept.de>
parents:
2286
diff
changeset
|
863 |
encodingLabel label:enc. |
2843 | 864 |
currentEncoding := enc. |
865 |
fontName := deviceFont fullName. |
|
2899 | 866 |
previewField contents:(self class defaultSampleStringForEncoding:enc). |
382 | 867 |
] ifFalse:[ |
2842 | 868 |
previewField contents:nil. |
869 |
encodingLabel label:nil. |
|
2843 | 870 |
currentEncoding := nil. |
2842 | 871 |
fontName := nil. |
382 | 872 |
]. |
2842 | 873 |
nameLabel notNil ifTrue:[nameLabel label:fontName]. |
197 | 874 |
] |
255 | 875 |
|
1257 | 876 |
"Modified: 30.6.1997 / 17:26:22 / cg" |
197 | 877 |
! |
878 |
||
128 | 879 |
showSelectedFont |
2843 | 880 |
|fam face faceAndStyle style sz| |
128 | 881 |
|
882 |
fam := selectedFont family. |
|
2843 | 883 |
currentEncoding := selectedFont encoding. |
884 |
||
2888 | 885 |
self familySelected:fam showPreview:false. |
128 | 886 |
fam notNil ifTrue:[ |
2842 | 887 |
face := selectedFont face. |
888 |
(face notNil and:[(style := selectedFont style) notNil]) ifTrue:[ |
|
889 |
faceAndStyle := face , '-' , style. |
|
890 |
]. |
|
2888 | 891 |
self faceSelected:faceAndStyle showPreview:false. |
2842 | 892 |
faceAndStyle notNil ifTrue:[ |
3841 | 893 |
sz := sizeUnit == #px ifTrue:[selectedFont pixelSize] ifFalse:[selectedFont size]. |
894 |
pixelPointSwitch contents:sizeUnit. |
|
2888 | 895 |
self sizeSelected:sz showPreview:false. |
2842 | 896 |
] |
897 |
]. |
|
2888 | 898 |
|
899 |
self showPreview |
|
2826 | 900 |
! |
901 |
||
902 |
updateFamilyList |
|
903 |
"update the list of font families" |
|
904 |
||
905 |
|families| |
|
906 |
||
907 |
familyList list isNil ifTrue:[ |
|
3817 | 908 |
families := self getFamilyList. |
2826 | 909 |
families notNil ifTrue:[ |
910 |
families := families asOrderedCollection sort |
|
911 |
]. |
|
912 |
familyList list:families |
|
913 |
]. |
|
914 |
selectedFont notNil ifTrue:[ |
|
915 |
self showSelectedFont |
|
916 |
]. |
|
917 |
||
918 |
"Modified: 27.2.1996 / 01:39:42 / cg" |
|
919 |
"Created: 27.2.1996 / 01:40:37 / cg" |
|
197 | 920 |
! ! |
128 | 921 |
|
197 | 922 |
!FontPanel methodsFor:'queries'! |
0 | 923 |
|
3405
9a03bc64e285
dont offer special-character display in menu, if its not available.
Claus Gittinger <cg@exept.de>
parents:
3274
diff
changeset
|
924 |
characterSetViewClassAvailable |
9a03bc64e285
dont offer special-character display in menu, if its not available.
Claus Gittinger <cg@exept.de>
parents:
3274
diff
changeset
|
925 |
^ CharacterSetView notNil |
9a03bc64e285
dont offer special-character display in menu, if its not available.
Claus Gittinger <cg@exept.de>
parents:
3274
diff
changeset
|
926 |
|
9a03bc64e285
dont offer special-character display in menu, if its not available.
Claus Gittinger <cg@exept.de>
parents:
3274
diff
changeset
|
927 |
"Created: / 11-10-2006 / 21:27:51 / cg" |
9a03bc64e285
dont offer special-character display in menu, if its not available.
Claus Gittinger <cg@exept.de>
parents:
3274
diff
changeset
|
928 |
! |
9a03bc64e285
dont offer special-character display in menu, if its not available.
Claus Gittinger <cg@exept.de>
parents:
3274
diff
changeset
|
929 |
|
9a03bc64e285
dont offer special-character display in menu, if its not available.
Claus Gittinger <cg@exept.de>
parents:
3274
diff
changeset
|
930 |
characterSetViewClassAvailableOrOSIsUNIX |
9a03bc64e285
dont offer special-character display in menu, if its not available.
Claus Gittinger <cg@exept.de>
parents:
3274
diff
changeset
|
931 |
^ self characterSetViewClassAvailable or:[self osIsUNIX] |
9a03bc64e285
dont offer special-character display in menu, if its not available.
Claus Gittinger <cg@exept.de>
parents:
3274
diff
changeset
|
932 |
|
9a03bc64e285
dont offer special-character display in menu, if its not available.
Claus Gittinger <cg@exept.de>
parents:
3274
diff
changeset
|
933 |
"Created: / 11-10-2006 / 21:29:20 / cg" |
9a03bc64e285
dont offer special-character display in menu, if its not available.
Claus Gittinger <cg@exept.de>
parents:
3274
diff
changeset
|
934 |
! |
9a03bc64e285
dont offer special-character display in menu, if its not available.
Claus Gittinger <cg@exept.de>
parents:
3274
diff
changeset
|
935 |
|
9a03bc64e285
dont offer special-character display in menu, if its not available.
Claus Gittinger <cg@exept.de>
parents:
3274
diff
changeset
|
936 |
osIsUNIX |
9a03bc64e285
dont offer special-character display in menu, if its not available.
Claus Gittinger <cg@exept.de>
parents:
3274
diff
changeset
|
937 |
^ OperatingSystem isUNIXlike |
9a03bc64e285
dont offer special-character display in menu, if its not available.
Claus Gittinger <cg@exept.de>
parents:
3274
diff
changeset
|
938 |
|
9a03bc64e285
dont offer special-character display in menu, if its not available.
Claus Gittinger <cg@exept.de>
parents:
3274
diff
changeset
|
939 |
"Modified: / 11-10-2006 / 21:28:59 / cg" |
9a03bc64e285
dont offer special-character display in menu, if its not available.
Claus Gittinger <cg@exept.de>
parents:
3274
diff
changeset
|
940 |
! |
9a03bc64e285
dont offer special-character display in menu, if its not available.
Claus Gittinger <cg@exept.de>
parents:
3274
diff
changeset
|
941 |
|
197 | 942 |
preferredExtent |
595 | 943 |
"return the boxes preferredExtent" |
572 | 944 |
|
3769
758f8b0b6cf2
changed #preferredExtent - use explicitExtent instvar
Stefan Vogel <sv@exept.de>
parents:
3740
diff
changeset
|
945 |
"/ If I have an explicit preferredExtent.. |
758f8b0b6cf2
changed #preferredExtent - use explicitExtent instvar
Stefan Vogel <sv@exept.de>
parents:
3740
diff
changeset
|
946 |
explicitExtent notNil ifTrue:[ |
758f8b0b6cf2
changed #preferredExtent - use explicitExtent instvar
Stefan Vogel <sv@exept.de>
parents:
3740
diff
changeset
|
947 |
^ explicitExtent |
758f8b0b6cf2
changed #preferredExtent - use explicitExtent instvar
Stefan Vogel <sv@exept.de>
parents:
3740
diff
changeset
|
948 |
]. |
797 | 949 |
|
3769
758f8b0b6cf2
changed #preferredExtent - use explicitExtent instvar
Stefan Vogel <sv@exept.de>
parents:
3740
diff
changeset
|
950 |
"/ If I have a cached preferredExtent value.. |
713
0c38ad51016d
care for preSet preferredExtent
Claus Gittinger <cg@exept.de>
parents:
690
diff
changeset
|
951 |
preferredExtent notNil ifTrue:[ |
0c38ad51016d
care for preSet preferredExtent
Claus Gittinger <cg@exept.de>
parents:
690
diff
changeset
|
952 |
^ preferredExtent |
0c38ad51016d
care for preSet preferredExtent
Claus Gittinger <cg@exept.de>
parents:
690
diff
changeset
|
953 |
]. |
0c38ad51016d
care for preSet preferredExtent
Claus Gittinger <cg@exept.de>
parents:
690
diff
changeset
|
954 |
|
2842 | 955 |
^ 450@350 |
572 | 956 |
|
797 | 957 |
"Modified: 19.7.1996 / 20:44:08 / cg" |
0 | 958 |
! ! |
77 | 959 |
|
960 |
!FontPanel methodsFor:'user interaction'! |
|
961 |
||
3604 | 962 |
copyFontName |
963 |
self setClipboardText:(previewField font storeString). |
|
964 |
! |
|
965 |
||
2826 | 966 |
encodingFilterSelected:anEncodingPattern |
967 |
"another encoding was selected; find available fonts and update lists" |
|
968 |
||
969 |
|pattern| |
|
970 |
||
2887 | 971 |
anEncodingPattern isNil ifTrue:[ |
972 |
self filter:nil. |
|
973 |
^ self. |
|
974 |
]. |
|
975 |
||
2878 | 976 |
pattern := (anEncodingPattern upTo:$( ) withoutSeparators. |
977 |
||
978 |
pattern = '?' ifTrue:[ |
|
2845 | 979 |
pattern := '' |
980 |
] ifFalse:[ |
|
2878 | 981 |
pattern := (pattern isEmptyOrNil ifTrue:'*' ifFalse:pattern). |
2845 | 982 |
]. |
2826 | 983 |
self |
984 |
filter: |
|
985 |
[:f | |
|
986 |
|encoding| |
|
987 |
||
3848 | 988 |
"/ Transcript showCR:f encoding. |
2826 | 989 |
encoding := f encoding ? ''. |
990 |
pattern match:encoding |
|
991 |
]. |
|
992 |
! |
|
993 |
||
197 | 994 |
faceSelected:aFaceAndStyleName |
2826 | 995 |
"a fonts face was selected; find available sizes and update lists" |
595 | 996 |
|
2842 | 997 |
self faceSelected:aFaceAndStyleName showPreview:true |
998 |
! |
|
999 |
||
1000 |
faceSelected:aFaceAndStyleName showPreview:showPreview |
|
1001 |
"a fonts face was selected; find available sizes and update lists" |
|
1002 |
||
3740 | 1003 |
|sizes sizeStrings didShow| |
197 | 1004 |
|
1005 |
aFaceAndStyleName notNil ifTrue:[ |
|
251
25f76efaa547
oops - dont pass a collection of numbers to the size-view
Claus Gittinger <cg@exept.de>
parents:
243
diff
changeset
|
1006 |
self extractFaceAndStyleFrom:aFaceAndStyleName. |
197 | 1007 |
]. |
3834 | 1008 |
self updateSizeList. |
1009 |
showPreview ifTrue:[ |
|
1010 |
self showPreview. |
|
1011 |
]. |
|
1012 |
^ self. |
|
1013 |
||
3817 | 1014 |
sizes := self |
1015 |
getSizesInFamily:(currentFamily ? '*') |
|
1016 |
face:(currentFace ? '*') |
|
1017 |
style:(currentStyle ? '*') |
|
1018 |
filtering:filter. |
|
251
25f76efaa547
oops - dont pass a collection of numbers to the size-view
Claus Gittinger <cg@exept.de>
parents:
243
diff
changeset
|
1019 |
|
3238
7b868226a0c0
isEmptyOrNil / notEmptyOrNil refactoring
Claus Gittinger <cg@exept.de>
parents:
3187
diff
changeset
|
1020 |
(sizes isEmptyOrNil) ifTrue:[ |
251
25f76efaa547
oops - dont pass a collection of numbers to the size-view
Claus Gittinger <cg@exept.de>
parents:
243
diff
changeset
|
1021 |
sizeList list:nil. |
25f76efaa547
oops - dont pass a collection of numbers to the size-view
Claus Gittinger <cg@exept.de>
parents:
243
diff
changeset
|
1022 |
currentSize := nil. |
3841 | 1023 |
self halt. |
2842 | 1024 |
showPreview ifTrue:[ |
1025 |
self showPreview. |
|
1026 |
]. |
|
251
25f76efaa547
oops - dont pass a collection of numbers to the size-view
Claus Gittinger <cg@exept.de>
parents:
243
diff
changeset
|
1027 |
^ self |
197 | 1028 |
]. |
1029 |
||
2890 | 1030 |
didShow := false. |
541
76018ea821ca
clear preview & encoding when no font is shown
Claus Gittinger <cg@exept.de>
parents:
540
diff
changeset
|
1031 |
|
3740 | 1032 |
sizes := sizes asOrderedCollection. |
1033 |
selectedFont notNil ifTrue:[ |
|
1034 |
(sizes includes:selectedFont size) ifFalse:[ |
|
1035 |
sizes add:selectedFont size |
|
1036 |
]. |
|
1037 |
]. |
|
1038 |
sizes sort. |
|
1039 |
||
1040 |
sizeStrings := sizes collect:[:entry | entry printString]. |
|
1041 |
sizeList list:sizeStrings. |
|
197 | 1042 |
currentSize notNil ifTrue:[ |
3740 | 1043 |
(sizeStrings includes:(currentSize printString)) ifTrue:[ |
2170 | 1044 |
sizeList setSelectElement:currentSize printString. |
2842 | 1045 |
showPreview ifTrue:[ |
2890 | 1046 |
self showPreview. |
1047 |
didShow := true. |
|
2842 | 1048 |
] |
251
25f76efaa547
oops - dont pass a collection of numbers to the size-view
Claus Gittinger <cg@exept.de>
parents:
243
diff
changeset
|
1049 |
] |
2890 | 1050 |
]. |
1051 |
didShow ifFalse:[ |
|
1052 |
self clearPreview |
|
1053 |
]. |
|
251
25f76efaa547
oops - dont pass a collection of numbers to the size-view
Claus Gittinger <cg@exept.de>
parents:
243
diff
changeset
|
1054 |
|
1257 | 1055 |
"Modified: 30.6.1997 / 17:25:46 / cg" |
197 | 1056 |
! |
1057 |
||
77 | 1058 |
familySelected:aFamilyName |
2826 | 1059 |
"a fonts family was selected; find available faces and update lists" |
595 | 1060 |
|
2842 | 1061 |
self familySelected:aFamilyName showPreview:true |
1062 |
! |
|
1063 |
||
1064 |
familySelected:aFamilyName showPreview:showPreview |
|
1065 |
"a fonts family was selected; find available faces and update lists" |
|
1066 |
||
77 | 1067 |
|faces styles list| |
1068 |
||
690 | 1069 |
familyList setSelectElement:aFamilyName. |
77 | 1070 |
|
1071 |
currentFamily := aFamilyName. |
|
3817 | 1072 |
faces := self getFacesForFamily:aFamilyName filtering:filter. |
2353 | 1073 |
(faces size = 0) ifTrue:[ |
415 | 1074 |
currentFace := currentStyle := currentFaceAndStyle := nil. |
1075 |
faceList list:nil. |
|
2842 | 1076 |
self faceSelected:nil showPreview:showPreview. |
415 | 1077 |
^ self. |
77 | 1078 |
]. |
1079 |
||
2353 | 1080 |
list := SortedCollection new. |
77 | 1081 |
faces do:[:aFace | |
3817 | 1082 |
styles := self getStylesInFamily:aFamilyName face:aFace filtering:filter. |
415 | 1083 |
styles do:[:aStyle | |
1084 |
list add:(aFace , '-' , aStyle) |
|
1085 |
] |
|
77 | 1086 |
]. |
541
76018ea821ca
clear preview & encoding when no font is shown
Claus Gittinger <cg@exept.de>
parents:
540
diff
changeset
|
1087 |
|
77 | 1088 |
faceList list:list. |
1089 |
currentFaceAndStyle notNil ifTrue:[ |
|
415 | 1090 |
(list includes:currentFaceAndStyle) ifTrue:[ |
690 | 1091 |
faceList setSelectElement:currentFaceAndStyle. |
2842 | 1092 |
self faceSelected:currentFaceAndStyle showPreview:showPreview. |
415 | 1093 |
^ self |
1094 |
] |
|
77 | 1095 |
]. |
2842 | 1096 |
|
541
76018ea821ca
clear preview & encoding when no font is shown
Claus Gittinger <cg@exept.de>
parents:
540
diff
changeset
|
1097 |
sizeList list:nil. |
76018ea821ca
clear preview & encoding when no font is shown
Claus Gittinger <cg@exept.de>
parents:
540
diff
changeset
|
1098 |
self clearPreview. |
415 | 1099 |
|
690 | 1100 |
"Modified: 26.5.1996 / 15:04:29 / cg" |
77 | 1101 |
! |
1102 |
||
1103 |
okPressed |
|
595 | 1104 |
"ok was pressed; hide myself and evaluate the okAction, passing |
1105 |
family, face, style and size as arguments" |
|
1106 |
||
77 | 1107 |
self hide. |
1108 |
okAction notNil ifTrue:[ |
|
410 | 1109 |
currentFamily notNil ifTrue:[ |
2842 | 1110 |
okAction |
1111 |
value:(FontDescription |
|
1112 |
family:currentFamily |
|
1113 |
face:currentFace |
|
1114 |
style:currentStyle |
|
1115 |
size:currentSize |
|
3841 | 1116 |
sizeUnit:(sizeUnit ? #pt) |
2843 | 1117 |
encoding:(currentEncoding ? encoding)). |
410 | 1118 |
] |
77 | 1119 |
] |
410 | 1120 |
|
1185
3b8bd5ea8d62
action block is evaluated with a fontDescription
Claus Gittinger <cg@exept.de>
parents:
797
diff
changeset
|
1121 |
"Modified: 10.4.1997 / 09:51:31 / cg" |
77 | 1122 |
! |
1123 |
||
2852 | 1124 |
previewCopySelection |
1125 |
previewField copySelection. |
|
1126 |
! |
|
1127 |
||
2935 | 1128 |
previewInspectFont |
1129 |
previewField font inspect. |
|
1130 |
! |
|
1131 |
||
2852 | 1132 |
previewShowCharacterSet |
1133 |
CharacterSetView openOn:(previewField font) |
|
1134 |
! |
|
1135 |
||
2875 | 1136 |
previewShowCharacterSetUsingXFD |
2878 | 1137 |
[ |
1138 |
OperatingSystem executeCommand:'xfd -fn ' , previewField font fullName. |
|
1139 |
] fork. |
|
2875 | 1140 |
! |
1141 |
||
77 | 1142 |
sizeSelected:aNumberOrString |
2826 | 1143 |
"a size was selected; update preview" |
595 | 1144 |
|
2842 | 1145 |
self sizeSelected:aNumberOrString showPreview:true. |
1146 |
! |
|
1147 |
||
1148 |
sizeSelected:aNumberOrString showPreview:showPreview |
|
1149 |
"a size was selected; update preview" |
|
1150 |
||
77 | 1151 |
aNumberOrString isNumber ifTrue:[ |
595 | 1152 |
currentSize := aNumberOrString |
77 | 1153 |
] ifFalse:[ |
2826 | 1154 |
currentSize := Number readFromString:aNumberOrString onError:nil |
77 | 1155 |
]. |
2842 | 1156 |
showPreview ifTrue:[self showPreview] |
595 | 1157 |
|
1158 |
"Modified: 29.4.1996 / 09:43:23 / cg" |
|
3832 | 1159 |
! |
1160 |
||
1161 |
sizeUnitSelected:unitSymbol |
|
1162 |
sizeUnit := unitSymbol. |
|
1163 |
sizeLabelHolder value:(resources |
|
3837 | 1164 |
string:(sizeUnit == #px |
3832 | 1165 |
ifTrue:'Size (px)' |
1166 |
ifFalse:'Size')). |
|
3834 | 1167 |
|
1168 |
self showPreview |
|
1169 |
! |
|
1170 |
||
1171 |
updateSizeList |
|
1172 |
|sizes sizeStrings| |
|
1173 |
||
1174 |
sizes := self |
|
3841 | 1175 |
getSizesInFamily:(currentFamily ? '*') |
1176 |
face:(currentFace ? '*') |
|
1177 |
style:(currentStyle ? '*') |
|
1178 |
filtering:filter. |
|
3834 | 1179 |
|
1180 |
(sizes isEmptyOrNil) ifTrue:[ |
|
1181 |
sizeList list:nil. |
|
1182 |
currentSize := nil. |
|
3841 | 1183 |
self halt. |
3834 | 1184 |
^ self |
1185 |
]. |
|
1186 |
||
1187 |
sizes := sizes asOrderedCollection. |
|
1188 |
selectedFont notNil ifTrue:[ |
|
3841 | 1189 |
currentSize := (selectedFont sizeUnit == #px) |
1190 |
ifTrue:[ selectedFont pixelSize ] |
|
1191 |
ifFalse:[ selectedFont size ]. |
|
1192 |
||
1193 |
(sizes includes:currentSize) ifFalse:[ |
|
1194 |
sizes add:currentSize |
|
3834 | 1195 |
]. |
1196 |
]. |
|
1197 |
sizes sort. |
|
1198 |
||
1199 |
sizeStrings := sizes collect:[:entry | entry printString]. |
|
1200 |
sizeList list:sizeStrings. |
|
1201 |
currentSize notNil ifTrue:[ |
|
1202 |
(sizeStrings includes:(currentSize printString)) ifTrue:[ |
|
1203 |
sizeList setSelectElement:currentSize printString. |
|
1204 |
] |
|
1205 |
]. |
|
77 | 1206 |
! ! |
197 | 1207 |
|
1185
3b8bd5ea8d62
action block is evaluated with a fontDescription
Claus Gittinger <cg@exept.de>
parents:
797
diff
changeset
|
1208 |
!FontPanel class methodsFor:'documentation'! |
243 | 1209 |
|
1210 |
version |
|
3848 | 1211 |
^ '$Header: /cvs/stx/stx/libwidg/FontPanel.st,v 1.100 2009-03-02 16:19:16 cg Exp $' |
243 | 1212 |
! ! |