arcadia 0.12.2 → 0.13.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/README +25 -14
- data/conf/LC/en-UK.LANG +3 -1
- data/conf/arcadia.conf +10 -0
- data/conf/arcadia.res.rb +29 -1
- data/ext/ae-editor/ae-editor.rb +239 -48
- data/ext/ae-file-history/ae-file-history.conf +11 -1
- data/ext/ae-file-history/ae-file-history.rb +120 -2
- data/ext/ae-ruby-debug/ae-ruby-debug.rb +6 -5
- data/ext/ae-subprocess-inspector/ae-subprocess-inspector.rb +7 -3
- data/ext/ae-term/ae-term.rb +1 -1
- data/lib/a-commons.rb +72 -56
- data/lib/a-contracts.rb +23 -1
- data/lib/a-core.rb +136 -41
- data/lib/a-tkcommons.rb +127 -36
- data/tcl/fsdialog/fsdialog.tcl +2 -2
- data/tcl/ptwidgets-1.1.0/COPYRIGHT +10 -0
- data/tcl/ptwidgets-1.1.0/ChangeLog +194 -0
- data/tcl/ptwidgets-1.1.0/README +50 -0
- data/tcl/ptwidgets-1.1.0/common/stacktrace.tcl +29 -0
- data/tcl/ptwidgets-1.1.0/common/tokenframe.tcl +200 -0
- data/tcl/ptwidgets-1.1.0/doc/img/toggleswitch_off.png +0 -0
- data/tcl/ptwidgets-1.1.0/doc/img/toggleswitch_on.png +0 -0
- data/tcl/ptwidgets-1.1.0/doc/img/tokenentry.png +0 -0
- data/tcl/ptwidgets-1.1.0/doc/img/tokensearch_popup_example.png +0 -0
- data/tcl/ptwidgets-1.1.0/doc/img/tokensearch_popup_example2.png +0 -0
- data/tcl/ptwidgets-1.1.0/doc/img/wmarkentry.png +0 -0
- data/tcl/ptwidgets-1.1.0/doc/toggleswitch.html +402 -0
- data/tcl/ptwidgets-1.1.0/doc/tokenentry.html +1366 -0
- data/tcl/ptwidgets-1.1.0/doc/tokensearch.html +1549 -0
- data/tcl/ptwidgets-1.1.0/doc/wmarkentry.html +634 -0
- data/tcl/ptwidgets-1.1.0/library/toggleswitch.tcl +432 -0
- data/tcl/ptwidgets-1.1.0/library/tokenentry.tcl +2208 -0
- data/tcl/ptwidgets-1.1.0/library/tokensearch.tcl +2488 -0
- data/tcl/ptwidgets-1.1.0/library/wmarkentry.tcl +630 -0
- data/tcl/ptwidgets-1.1.0/pkgIndex.tcl +10 -0
- data/tcl/ptwidgets-1.1.0/test/Makefile +3 -0
- data/tcl/ptwidgets-1.1.0/test/run.tcl +3 -0
- data/tcl/ptwidgets-1.1.0/test/test.tcl +89 -0
- data/tcl/ptwidgets-1.1.0/test/toggleswitch.test +562 -0
- data/tcl/ptwidgets-1.1.0/test/tokenentry.test +1023 -0
- data/tcl/ptwidgets-1.1.0/test/tokensearch.test +1023 -0
- data/tcl/ptwidgets-1.1.0/test/wmarkentry.test +1325 -0
- data/tcl/themes/altTheme.tcl +101 -0
- data/tcl/themes/aquaTheme.tcl +59 -0
- data/tcl/themes/clamTheme.tcl +140 -0
- data/tcl/themes/classicTheme.tcl +108 -0
- data/tcl/themes/pkgIndex.tcl +3 -0
- data/tcl/themes/ttk.tcl +176 -0
- data/tcl/themes/vistaTheme.tcl +224 -0
- data/tcl/themes/winTheme.tcl +80 -0
- data/tcl/themes/xpTheme.tcl +65 -0
- data/tcl/tkfbox/folder.gif +0 -0
- data/tcl/tkfbox/textfile.gif +0 -0
- data/tcl/tkfbox/tkfbox.tcl +1 -0
- data/tcl/tkfbox/tkfbox.tcl~ +1 -0
- data/tcl/tkfbox/updir.xbm +1 -0
- metadata +43 -2
@@ -0,0 +1,1023 @@
|
|
1
|
+
lappend auto_path ".."
|
2
|
+
|
3
|
+
package require tokenentry
|
4
|
+
package require tcltest 2.2
|
5
|
+
|
6
|
+
proc setup {args} {
|
7
|
+
eval "tokenentry::tokenentry .te $args"
|
8
|
+
pack .te
|
9
|
+
}
|
10
|
+
|
11
|
+
proc cleanup {} {
|
12
|
+
destroy .te
|
13
|
+
}
|
14
|
+
|
15
|
+
# Test Contraints
|
16
|
+
tcltest::testConstraint aqua [expr {[tk windowingsystem] eq "aqua"}]
|
17
|
+
tcltest::testConstraint x11 [expr {[tk windowingsystem] eq "x11"}]
|
18
|
+
|
19
|
+
# Skip list
|
20
|
+
tcltest::skip te-bbox-0
|
21
|
+
|
22
|
+
# Tests
|
23
|
+
#---------------------------------
|
24
|
+
|
25
|
+
tcltest::test te-configure-badoption {configure called with a bad option} \
|
26
|
+
-setup setup \
|
27
|
+
-body {
|
28
|
+
.te configure -foobar
|
29
|
+
} -cleanup cleanup \
|
30
|
+
-returnCodes error -result "TokenEntry configuration option -foobar does not exist"
|
31
|
+
|
32
|
+
tcltest::test te-configure-badoptionwithvalue {configure called with a bad option with a value} \
|
33
|
+
-setup setup \
|
34
|
+
-body {
|
35
|
+
.te configure -foobar bubba
|
36
|
+
} -cleanup cleanup \
|
37
|
+
-returnCodes error -result "Illegal option given to the tokenentry configure command (-foobar)"
|
38
|
+
|
39
|
+
tcltest::test te-cget {cget without an option} \
|
40
|
+
-setup setup \
|
41
|
+
-body {
|
42
|
+
.te cget
|
43
|
+
} -cleanup cleanup \
|
44
|
+
-returnCodes error -result "Incorrect number of parameters given to the tokenentry cget command"
|
45
|
+
|
46
|
+
#---------------------------------
|
47
|
+
tcltest::test te-background {setup -background returns correct result} \
|
48
|
+
-setup {
|
49
|
+
setup -background blue
|
50
|
+
} -body {
|
51
|
+
.te cget -background
|
52
|
+
} -cleanup cleanup \
|
53
|
+
-result blue
|
54
|
+
|
55
|
+
tcltest::test te-background-cget-bg {setup -background returns correct result} \
|
56
|
+
-setup {
|
57
|
+
setup -background blue
|
58
|
+
} -body {
|
59
|
+
.te cget -bg
|
60
|
+
} -cleanup cleanup \
|
61
|
+
-result blue
|
62
|
+
|
63
|
+
tcltest::test te-configure-background {configure -background returns correct result} \
|
64
|
+
-setup {
|
65
|
+
setup -background blue
|
66
|
+
} -body {
|
67
|
+
.te configure -background
|
68
|
+
} -cleanup cleanup \
|
69
|
+
-result {-background background Background white blue}
|
70
|
+
|
71
|
+
tcltest::test te-bg {setup -bg returns correct result} \
|
72
|
+
-setup {
|
73
|
+
setup -bg blue
|
74
|
+
} -body {
|
75
|
+
.te cget -bg
|
76
|
+
} -cleanup cleanup \
|
77
|
+
-result blue
|
78
|
+
|
79
|
+
tcltest::test te-bg-cget-background {setup -bg returns correct result} \
|
80
|
+
-setup {
|
81
|
+
setup -bg blue
|
82
|
+
} -body {
|
83
|
+
.te cget -background
|
84
|
+
} -cleanup cleanup \
|
85
|
+
-result blue
|
86
|
+
|
87
|
+
tcltest::test te-configure-bg {configure -bg returns correct result} \
|
88
|
+
-setup {
|
89
|
+
setup -bg blue
|
90
|
+
} -body {
|
91
|
+
.te configure -bg
|
92
|
+
} -cleanup cleanup \
|
93
|
+
-result {-background background Background white blue}
|
94
|
+
|
95
|
+
tcltest::test te-cget-background {cget -background returns the correct result} \
|
96
|
+
-setup setup \
|
97
|
+
-body {
|
98
|
+
.te cget -background
|
99
|
+
} -cleanup cleanup \
|
100
|
+
-result white
|
101
|
+
|
102
|
+
tcltest::test te-cget-bg {cget -bg returns the correct result} \
|
103
|
+
-setup setup \
|
104
|
+
-body {
|
105
|
+
.te cget -bg
|
106
|
+
} -cleanup cleanup \
|
107
|
+
-result white
|
108
|
+
|
109
|
+
tcltest::test te-configure-cget-background {configure/cget -background returns the correct result} \
|
110
|
+
-setup setup \
|
111
|
+
-body {
|
112
|
+
.te configure -background blue
|
113
|
+
.te cget -background
|
114
|
+
} -cleanup cleanup \
|
115
|
+
-result blue
|
116
|
+
|
117
|
+
tcltest::test te-configure-cget-bg {configure/cget -bg returns correct result} \
|
118
|
+
-setup setup \
|
119
|
+
-body {
|
120
|
+
.te configure -bg blue
|
121
|
+
.te cget -bg
|
122
|
+
} -cleanup cleanup \
|
123
|
+
-result blue
|
124
|
+
|
125
|
+
tcltest::test te-configure-background-cget-bg {configure/cget -background/-bg returns correct result} \
|
126
|
+
-setup setup \
|
127
|
+
-body {
|
128
|
+
.te configure -background blue
|
129
|
+
.te cget -bg
|
130
|
+
} -cleanup cleanup \
|
131
|
+
-result blue
|
132
|
+
|
133
|
+
tcltest::test te-configure-bg-cget-background {configure/cget -bg/-background returns correct result} \
|
134
|
+
-setup setup \
|
135
|
+
-body {
|
136
|
+
.te configure -bg blue
|
137
|
+
.te cget -background
|
138
|
+
} -cleanup cleanup \
|
139
|
+
-result blue
|
140
|
+
|
141
|
+
#---------------------------------
|
142
|
+
tcltest::test te-configure-borderwidth {configure -borderwidth returns correct result} \
|
143
|
+
-setup {
|
144
|
+
setup -borderwidth 5
|
145
|
+
} -body {
|
146
|
+
.te configure -borderwidth
|
147
|
+
} -cleanup cleanup \
|
148
|
+
-match glob \
|
149
|
+
-result {-borderwidth borderWidth BorderWidth * 5}
|
150
|
+
|
151
|
+
tcltest::test te-configure-bd {configure -bd returns correct result} \
|
152
|
+
-setup {
|
153
|
+
setup -bd 5
|
154
|
+
} -body {
|
155
|
+
.te configure -bd
|
156
|
+
} -cleanup cleanup \
|
157
|
+
-match glob \
|
158
|
+
-result {-borderwidth borderWidth BorderWidth * 5}
|
159
|
+
|
160
|
+
tcltest::test te-cget-borderwidth {cget -borderwidth returns the correct result} \
|
161
|
+
-setup {
|
162
|
+
setup -borderwidth 5
|
163
|
+
} -body {
|
164
|
+
.te cget -borderwidth
|
165
|
+
} -cleanup cleanup \
|
166
|
+
-result 5
|
167
|
+
|
168
|
+
tcltest::test te-cget-bd {cget -bd returns the correct result} \
|
169
|
+
-setup {
|
170
|
+
setup -bd 5
|
171
|
+
} -body {
|
172
|
+
.te cget -bd
|
173
|
+
} -cleanup cleanup \
|
174
|
+
-result 5
|
175
|
+
|
176
|
+
tcltest::test te-configure-cget-borderwidth {configure/cget -borderwidth returns the correct result} \
|
177
|
+
-setup setup \
|
178
|
+
-body {
|
179
|
+
.te configure -borderwidth 2
|
180
|
+
.te cget -borderwidth
|
181
|
+
} -cleanup cleanup \
|
182
|
+
-result 2
|
183
|
+
|
184
|
+
tcltest::test te-configure-cget-bd {configure/cget -bd returns the correct result} \
|
185
|
+
-setup setup \
|
186
|
+
-body {
|
187
|
+
.te configure -bd 2
|
188
|
+
.te cget -bd
|
189
|
+
} -cleanup cleanup \
|
190
|
+
-result 2
|
191
|
+
|
192
|
+
tcltest::test te-configure-borderwidth-cget-bd {configure/cget -borderwidth/-bd returns the correct result} \
|
193
|
+
-setup setup \
|
194
|
+
-body {
|
195
|
+
.te configure -borderwidth 2
|
196
|
+
.te cget -bd
|
197
|
+
} -cleanup cleanup \
|
198
|
+
-result 2
|
199
|
+
|
200
|
+
tcltest::test te-configure-bd-cget-borderwidth {configure/cget -bd/-borderwidth returns the correct result} \
|
201
|
+
-setup setup \
|
202
|
+
-body {
|
203
|
+
.te configure -bd 2
|
204
|
+
.te cget -borderwidth
|
205
|
+
} -cleanup cleanup \
|
206
|
+
-result 2
|
207
|
+
|
208
|
+
#---------------------------------
|
209
|
+
tcltest::test te-configure-exportselection {configure -exportselection returns correct result} \
|
210
|
+
-setup {
|
211
|
+
setup -exportselection 1
|
212
|
+
} -body {
|
213
|
+
.te configure -exportselection
|
214
|
+
} -cleanup cleanup \
|
215
|
+
-result {-exportselection exportSelection ExportSelection 1 1}
|
216
|
+
|
217
|
+
tcltest::test te-cget-exportselection {cget -exportselection returns correct result} \
|
218
|
+
-setup {
|
219
|
+
setup -exportselection 1
|
220
|
+
} -body {
|
221
|
+
.te cget -exportselection
|
222
|
+
} -cleanup cleanup \
|
223
|
+
-result 1
|
224
|
+
|
225
|
+
tcltest::test te-configure-cget-exportselection {configure/cget -exportselection returns correct result} \
|
226
|
+
-setup setup \
|
227
|
+
-body {
|
228
|
+
.te configure -exportselection 0
|
229
|
+
.te cget -exportselection
|
230
|
+
} -cleanup cleanup \
|
231
|
+
-result 0
|
232
|
+
|
233
|
+
#---------------------------------
|
234
|
+
tcltest::test te-configure-font {configure -font returns correct result} \
|
235
|
+
-setup {
|
236
|
+
setup -font TkTextFont
|
237
|
+
} -body {
|
238
|
+
.te configure -font
|
239
|
+
} -cleanup cleanup \
|
240
|
+
-result {-font font Font TkFixedFont TkTextFont}
|
241
|
+
|
242
|
+
tcltest::test te-cget-font {cget -font returns correct result} \
|
243
|
+
-setup {
|
244
|
+
setup -font TkTextFont
|
245
|
+
} -body {
|
246
|
+
.te cget -font
|
247
|
+
} -cleanup cleanup \
|
248
|
+
-result TkTextFont
|
249
|
+
|
250
|
+
tcltest::test te-configure-cget-font {configure/cget -font returns correct result} \
|
251
|
+
-setup setup \
|
252
|
+
-body {
|
253
|
+
.te configure -font TkFixedFont
|
254
|
+
.te cget -font
|
255
|
+
} -cleanup cleanup \
|
256
|
+
-result TkFixedFont
|
257
|
+
|
258
|
+
#---------------------------------
|
259
|
+
tcltest::test te-configure-foreground {configure -foreground returns correct result} \
|
260
|
+
-setup {
|
261
|
+
setup -foreground yellow
|
262
|
+
} -body {
|
263
|
+
.te configure -foreground
|
264
|
+
} -cleanup cleanup \
|
265
|
+
-match regexp \
|
266
|
+
-result {-foreground foreground Foreground \S+ yellow}
|
267
|
+
|
268
|
+
tcltest::test te-configure-fg {configure -fg returns correct result} \
|
269
|
+
-setup {
|
270
|
+
setup -fg yellow
|
271
|
+
} -body {
|
272
|
+
.te configure -fg
|
273
|
+
} -cleanup cleanup \
|
274
|
+
-match regexp \
|
275
|
+
-result {-foreground foreground Foreground \S+ yellow}
|
276
|
+
|
277
|
+
tcltest::test te-cget-foreground {cget -foreground returns correct result} \
|
278
|
+
-setup {
|
279
|
+
setup -foreground yellow
|
280
|
+
} -body {
|
281
|
+
.te cget -foreground
|
282
|
+
} -cleanup cleanup \
|
283
|
+
-result yellow
|
284
|
+
|
285
|
+
tcltest::test te-cget-fg {cget -fg returns correct result} \
|
286
|
+
-setup {
|
287
|
+
setup -fg yellow
|
288
|
+
} -body {
|
289
|
+
.te cget -fg
|
290
|
+
} -cleanup cleanup \
|
291
|
+
-result yellow
|
292
|
+
|
293
|
+
tcltest::test te-configure-cget-foreground {configure/cget -foreground returns correct result} \
|
294
|
+
-setup setup \
|
295
|
+
-body {
|
296
|
+
.te configure -foreground red
|
297
|
+
.te cget -foreground
|
298
|
+
} -cleanup cleanup \
|
299
|
+
-result red
|
300
|
+
|
301
|
+
tcltest::test te-configure-cget-fg {configure/cget -fg returns correct result} \
|
302
|
+
-setup setup \
|
303
|
+
-body {
|
304
|
+
.te configure -fg red
|
305
|
+
.te cget -fg
|
306
|
+
} -cleanup cleanup \
|
307
|
+
-result red
|
308
|
+
|
309
|
+
tcltest::test te-configure-foreground-cget-fg {configure/cget -foreground/-fg returns correct result} \
|
310
|
+
-setup setup \
|
311
|
+
-body {
|
312
|
+
.te configure -foreground red
|
313
|
+
.te cget -fg
|
314
|
+
} -cleanup cleanup \
|
315
|
+
-result red
|
316
|
+
|
317
|
+
tcltest::test te-configure-fg-cget-foreground {configure/cget -fg/-foreground returns correct result} \
|
318
|
+
-setup setup \
|
319
|
+
-body {
|
320
|
+
.te configure -fg red
|
321
|
+
.te cget -foreground
|
322
|
+
} -cleanup cleanup \
|
323
|
+
-result red
|
324
|
+
|
325
|
+
#---------------------------------
|
326
|
+
tcltest::test te-configure-highlightbackground {configure -highlightbackground returns correct result} \
|
327
|
+
-setup {
|
328
|
+
setup -highlightbackground yellow
|
329
|
+
} -body {
|
330
|
+
.te configure -highlightbackground
|
331
|
+
} -cleanup cleanup \
|
332
|
+
-match regexp \
|
333
|
+
-result {-highlightbackground highlightBackground HighlightBackground \S+ yellow}
|
334
|
+
|
335
|
+
tcltest::test te-cget-highlightbackground {cget -highlightbackground returns correct result} \
|
336
|
+
-setup {
|
337
|
+
setup -highlightbackground yellow
|
338
|
+
} -body {
|
339
|
+
.te cget -highlightbackground
|
340
|
+
} -cleanup cleanup \
|
341
|
+
-result yellow
|
342
|
+
|
343
|
+
tcltest::test te-configure-cget-highlightbackground {configure/cget -highlightbackground returns correct result} \
|
344
|
+
-setup setup \
|
345
|
+
-body {
|
346
|
+
.te configure -highlightbackground yellow
|
347
|
+
.te cget -highlightbackground
|
348
|
+
} -cleanup cleanup \
|
349
|
+
-result yellow
|
350
|
+
|
351
|
+
#---------------------------------
|
352
|
+
tcltest::test te-configure-highlightcolor {configure -highlightcolor returns correct result} \
|
353
|
+
-setup {
|
354
|
+
setup -highlightcolor yellow
|
355
|
+
} -body {
|
356
|
+
.te configure -highlightcolor
|
357
|
+
} -cleanup cleanup \
|
358
|
+
-match regexp \
|
359
|
+
-result {-highlightcolor highlightColor HighlightColor \S+ yellow}
|
360
|
+
|
361
|
+
tcltest::test te-cget-highlightcolor {cget -highlightcolor returns correct result} \
|
362
|
+
-setup {
|
363
|
+
setup -highlightcolor yellow
|
364
|
+
} -body {
|
365
|
+
.te cget -highlightcolor
|
366
|
+
} -cleanup cleanup \
|
367
|
+
-result yellow
|
368
|
+
|
369
|
+
tcltest::test te-configure-cget-highlightcolor {configure/cget -highlightcolor returns correct result} \
|
370
|
+
-setup setup \
|
371
|
+
-body {
|
372
|
+
.te configure -highlightcolor yellow
|
373
|
+
.te cget -highlightcolor
|
374
|
+
} -cleanup cleanup \
|
375
|
+
-result yellow
|
376
|
+
|
377
|
+
#---------------------------------
|
378
|
+
tcltest::test te-configure-highlightthickness {configure -highlightthickness returns correct result} \
|
379
|
+
-setup {
|
380
|
+
setup -highlightthickness 2
|
381
|
+
} -body {
|
382
|
+
.te configure -highlightthickness
|
383
|
+
} -cleanup cleanup \
|
384
|
+
-match glob \
|
385
|
+
-result {-highlightthickness highlightThickness HighlightThickness * 2}
|
386
|
+
|
387
|
+
tcltest::test te-cget-highlightthickness {cget -highlightthickness returns correct result} \
|
388
|
+
-setup {
|
389
|
+
setup -highlightthickness 2
|
390
|
+
} -body {
|
391
|
+
.te cget -highlightthickness
|
392
|
+
} -cleanup cleanup \
|
393
|
+
-result 2
|
394
|
+
|
395
|
+
tcltest::test te-configure-cget-highlightthickness {configure/cget -highlightthickness returns correct result} \
|
396
|
+
-setup setup \
|
397
|
+
-body {
|
398
|
+
.te configure -highlightthickness 5
|
399
|
+
.te cget -highlightthickness
|
400
|
+
} -cleanup cleanup \
|
401
|
+
-result 5
|
402
|
+
|
403
|
+
#---------------------------------
|
404
|
+
tcltest::test te-configure-insertbackground {configure -insertbackground returns correct result} \
|
405
|
+
-setup {
|
406
|
+
setup -insertbackground yellow
|
407
|
+
} -body {
|
408
|
+
.te configure -insertbackground
|
409
|
+
} -cleanup cleanup \
|
410
|
+
-match regexp \
|
411
|
+
-result {-insertbackground insertBackground InsertBackground \S+ yellow}
|
412
|
+
|
413
|
+
tcltest::test te-cget-insertbackground {cget -insertbackground returns correct result} \
|
414
|
+
-setup {
|
415
|
+
setup -insertbackground yellow
|
416
|
+
} -body {
|
417
|
+
.te cget -insertbackground
|
418
|
+
} -cleanup cleanup \
|
419
|
+
-result yellow
|
420
|
+
|
421
|
+
tcltest::test te-configure-cget-insertbackground {configure/cget -insertbackground returns correct result} \
|
422
|
+
-setup setup \
|
423
|
+
-body {
|
424
|
+
.te configure -insertbackground yellow
|
425
|
+
.te cget -insertbackground
|
426
|
+
} -cleanup cleanup \
|
427
|
+
-result yellow
|
428
|
+
|
429
|
+
#---------------------------------
|
430
|
+
tcltest::test te-configure-insertborderwidth {configure -insertborderwidth returns correct result} \
|
431
|
+
-setup {
|
432
|
+
setup -insertborderwidth 0
|
433
|
+
} -body {
|
434
|
+
.te configure -insertborderwidth
|
435
|
+
} -cleanup cleanup \
|
436
|
+
-match glob \
|
437
|
+
-result {-insertborderwidth insertBorderWidth InsertBorderWidth * 0}
|
438
|
+
|
439
|
+
tcltest::test te-cget-insertborderwidth {cget -insertborderwidth returns correct result} \
|
440
|
+
-setup {
|
441
|
+
setup -insertborderwidth 0
|
442
|
+
} -body {
|
443
|
+
.te cget -insertborderwidth
|
444
|
+
} -cleanup cleanup \
|
445
|
+
-result 0
|
446
|
+
|
447
|
+
tcltest::test te-configure-cget-insertborderwidth {configure/cget -insertborderwidth returns correct result} \
|
448
|
+
-setup setup \
|
449
|
+
-body {
|
450
|
+
.te configure -insertborderwidth 0
|
451
|
+
.te cget -insertborderwidth
|
452
|
+
} -cleanup cleanup \
|
453
|
+
-result 0
|
454
|
+
|
455
|
+
#---------------------------------
|
456
|
+
tcltest::test te-configure-insertofftime {configure -insertofftime returns correct result} \
|
457
|
+
-setup {
|
458
|
+
setup -insertofftime 500
|
459
|
+
} -body {
|
460
|
+
.te configure -insertofftime
|
461
|
+
} -cleanup cleanup \
|
462
|
+
-match regexp \
|
463
|
+
-result {-insertofftime insertOffTime InsertOffTime \d+ 500}
|
464
|
+
|
465
|
+
tcltest::test te-cget-insertofftime {cget -insertofftime returns correct result} \
|
466
|
+
-setup {
|
467
|
+
setup -insertofftime 500
|
468
|
+
} -body {
|
469
|
+
.te cget -insertofftime
|
470
|
+
} -cleanup cleanup \
|
471
|
+
-result 500
|
472
|
+
|
473
|
+
tcltest::test te-configure-cget-insertofftime {configure/cget -insertofftime returns correct result} \
|
474
|
+
-setup setup \
|
475
|
+
-body {
|
476
|
+
.te configure -insertofftime 600
|
477
|
+
.te cget -insertofftime
|
478
|
+
} -cleanup cleanup \
|
479
|
+
-result 600
|
480
|
+
|
481
|
+
#---------------------------------
|
482
|
+
tcltest::test te-configure-insertontime {configure -insertontime returns correct result} \
|
483
|
+
-setup {
|
484
|
+
setup -insertontime 500
|
485
|
+
} -body {
|
486
|
+
.te configure -insertontime
|
487
|
+
} -cleanup cleanup \
|
488
|
+
-match regexp \
|
489
|
+
-result {-insertontime insertOnTime InsertOnTime \d+ 500}
|
490
|
+
|
491
|
+
tcltest::test te-cget-insertontime {cget -insertontime returns correct result} \
|
492
|
+
-setup {
|
493
|
+
setup -insertontime 500
|
494
|
+
} -body {
|
495
|
+
.te cget -insertontime
|
496
|
+
} -cleanup cleanup \
|
497
|
+
-result 500
|
498
|
+
|
499
|
+
tcltest::test te-configure-cget-insertontime {configure/cget -insertontime returns correct result} \
|
500
|
+
-setup setup \
|
501
|
+
-body {
|
502
|
+
.te configure -insertontime 1000
|
503
|
+
.te cget -insertontime
|
504
|
+
} -cleanup cleanup \
|
505
|
+
-result 1000
|
506
|
+
|
507
|
+
#---------------------------------
|
508
|
+
tcltest::test te-configure-insertwidth {configure -insertwidth returns correct result} \
|
509
|
+
-setup {
|
510
|
+
setup -insertwidth 5
|
511
|
+
} -body {
|
512
|
+
.te configure -insertwidth
|
513
|
+
} -cleanup cleanup \
|
514
|
+
-match glob \
|
515
|
+
-result {-insertwidth insertWidth InsertWidth * 5}
|
516
|
+
|
517
|
+
tcltest::test te-cget-insertwidth {cget -insertwidth returns correct result} \
|
518
|
+
-setup {
|
519
|
+
setup -insertwidth 5
|
520
|
+
} -body {
|
521
|
+
.te cget -insertwidth
|
522
|
+
} -cleanup cleanup \
|
523
|
+
-result 5
|
524
|
+
|
525
|
+
tcltest::test te-configure-cget-insertwidth {configure/cget -insertwidth returns correct result} \
|
526
|
+
-setup setup \
|
527
|
+
-body {
|
528
|
+
.te configure -insertwidth 10
|
529
|
+
.te cget -insertwidth
|
530
|
+
} -cleanup cleanup \
|
531
|
+
-result 10
|
532
|
+
|
533
|
+
#---------------------------------
|
534
|
+
tcltest::test te-configure-relief {configure -relief returns correct result} \
|
535
|
+
-setup {
|
536
|
+
setup -relief flat
|
537
|
+
} -body {
|
538
|
+
.te configure -relief
|
539
|
+
} -cleanup cleanup \
|
540
|
+
-match regexp \
|
541
|
+
-result {-relief relief Relief \S+ flat}
|
542
|
+
|
543
|
+
tcltest::test te-cget-relief {cget -relief returns correct result} \
|
544
|
+
-setup {
|
545
|
+
setup -relief flat
|
546
|
+
} -body {
|
547
|
+
.te cget -relief
|
548
|
+
} -cleanup cleanup \
|
549
|
+
-result flat
|
550
|
+
|
551
|
+
tcltest::test te-configure-cget-relief {configure/cget -relief returns correct result} \
|
552
|
+
-setup setup \
|
553
|
+
-body {
|
554
|
+
.te configure -relief ridge
|
555
|
+
.te cget -relief
|
556
|
+
} -cleanup cleanup \
|
557
|
+
-result ridge
|
558
|
+
|
559
|
+
#---------------------------------
|
560
|
+
tcltest::test te-configure-selectbackground {configure -selectbackground returns correct result} \
|
561
|
+
-setup {
|
562
|
+
setup -selectbackground yellow
|
563
|
+
} -body {
|
564
|
+
.te configure -selectbackground
|
565
|
+
} -cleanup cleanup \
|
566
|
+
-match regexp \
|
567
|
+
-result {-selectbackground selectBackground Background \S+ yellow}
|
568
|
+
|
569
|
+
tcltest::test te-cget-selectbackground {cget -selectbackground returns correct result} \
|
570
|
+
-setup {
|
571
|
+
setup -selectbackground yellow
|
572
|
+
} -body {
|
573
|
+
.te cget -selectbackground
|
574
|
+
} -cleanup cleanup \
|
575
|
+
-result yellow
|
576
|
+
|
577
|
+
tcltest::test te-configure-cget-selectbackground {configure/cget -selectbackground returns correct result} \
|
578
|
+
-setup setup \
|
579
|
+
-body {
|
580
|
+
.te configure -selectbackground yellow
|
581
|
+
.te cget -selectbackground
|
582
|
+
} -cleanup cleanup \
|
583
|
+
-result yellow
|
584
|
+
|
585
|
+
#---------------------------------
|
586
|
+
tcltest::test te-configure-selectborderwidth {configure -selectborderwidth returns correct result} \
|
587
|
+
-setup {
|
588
|
+
setup -selectborderwidth 5
|
589
|
+
} -body {
|
590
|
+
.te configure -selectborderwidth
|
591
|
+
} -cleanup cleanup \
|
592
|
+
-match glob \
|
593
|
+
-result {-selectborderwidth selectBorderWidth BorderWidth * 5}
|
594
|
+
|
595
|
+
tcltest::test te-cget-selectborderwidth {cget -selectborderwidth returns correct result} \
|
596
|
+
-setup {
|
597
|
+
setup -selectborderwidth 5
|
598
|
+
} -body {
|
599
|
+
.te cget -selectborderwidth
|
600
|
+
} -cleanup cleanup \
|
601
|
+
-result 5
|
602
|
+
|
603
|
+
tcltest::test te-configure-cget-selectborderwidth {configure/cget -selectborderwidth returns correct result} \
|
604
|
+
-setup setup \
|
605
|
+
-body {
|
606
|
+
.te configure -selectborderwidth 1
|
607
|
+
.te cget -selectborderwidth
|
608
|
+
} -cleanup cleanup \
|
609
|
+
-result 1
|
610
|
+
|
611
|
+
#---------------------------------
|
612
|
+
tcltest::test te-configure-selectforeground {configure -selectforeground returns correct result} \
|
613
|
+
-setup {
|
614
|
+
setup -selectforeground yellow
|
615
|
+
} -body {
|
616
|
+
.te configure -selectforeground
|
617
|
+
} -cleanup cleanup \
|
618
|
+
-match regexp \
|
619
|
+
-result {-selectforeground selectForeground Foreground \S+ yellow}
|
620
|
+
|
621
|
+
tcltest::test te-cget-selectforeground {cget -selectforeground returns correct result} \
|
622
|
+
-setup {
|
623
|
+
setup -selectforeground yellow
|
624
|
+
} -body {
|
625
|
+
.te cget -selectforeground
|
626
|
+
} -cleanup cleanup \
|
627
|
+
-result yellow
|
628
|
+
|
629
|
+
tcltest::test te-configure-cget-selectforeground {configure/cget -selectforeground returns correct result} \
|
630
|
+
-setup setup \
|
631
|
+
-body {
|
632
|
+
.te configure -selectforeground yellow
|
633
|
+
.te cget -selectforeground
|
634
|
+
} -cleanup cleanup \
|
635
|
+
-result yellow
|
636
|
+
|
637
|
+
#---------------------------------
|
638
|
+
tcltest::test te-configure-state {configure -state returns correct result} \
|
639
|
+
-setup {
|
640
|
+
setup -state disabled
|
641
|
+
} -body {
|
642
|
+
.te configure -state
|
643
|
+
} -cleanup cleanup \
|
644
|
+
-result {-state state State normal disabled}
|
645
|
+
|
646
|
+
tcltest::test te-cget-state {cget -state returns correct result} \
|
647
|
+
-setup setup \
|
648
|
+
-body {
|
649
|
+
.te cget -state
|
650
|
+
} -cleanup cleanup \
|
651
|
+
-result normal
|
652
|
+
|
653
|
+
tcltest::test te-configure-cget-state {configure/cget -state returns correct result} \
|
654
|
+
-setup setup \
|
655
|
+
-body {
|
656
|
+
.te configure -state disabled
|
657
|
+
.te cget -state
|
658
|
+
} -cleanup cleanup \
|
659
|
+
-result disabled
|
660
|
+
|
661
|
+
#---------------------------------
|
662
|
+
tcltest::test te-configure-takefocus {configure -takefocus returns correct result} \
|
663
|
+
-setup setup \
|
664
|
+
-body {
|
665
|
+
.te configure -takefocus
|
666
|
+
} -cleanup cleanup \
|
667
|
+
-result {-takefocus takeFocus TakeFocus 1 1}
|
668
|
+
|
669
|
+
tcltest::test te-cget-takefocus {cget -takefocus returns correct result} \
|
670
|
+
-setup setup \
|
671
|
+
-body {
|
672
|
+
.te cget -takefocus
|
673
|
+
} -cleanup cleanup \
|
674
|
+
-result 1
|
675
|
+
|
676
|
+
tcltest::test te-configure-cget-takefocus {configure/cget -takefocsu returns correct result} \
|
677
|
+
-setup setup \
|
678
|
+
-body {
|
679
|
+
.te configure -takefocus 0
|
680
|
+
.te cget -takefocus
|
681
|
+
} -cleanup cleanup \
|
682
|
+
-result 0
|
683
|
+
|
684
|
+
#---------------------------------
|
685
|
+
tcltest::test te-configure-watermark {configure -watermark returns correct result} \
|
686
|
+
-setup setup \
|
687
|
+
-body {
|
688
|
+
.te configure -watermark
|
689
|
+
} -cleanup cleanup \
|
690
|
+
-result {-watermark watermark Watermark {} {}}
|
691
|
+
|
692
|
+
tcltest::test te-cget-watermark {cget -watermark returns correct result} \
|
693
|
+
-setup setup \
|
694
|
+
-body {
|
695
|
+
.te cget -watermark
|
696
|
+
} -cleanup cleanup \
|
697
|
+
-result ""
|
698
|
+
|
699
|
+
tcltest::test te-configure-cget-watermark {configure/cget -watermark returns correct result} \
|
700
|
+
-setup setup \
|
701
|
+
-body {
|
702
|
+
.te configure -watermark "Enter string"
|
703
|
+
.te cget -watermark
|
704
|
+
} -cleanup cleanup \
|
705
|
+
-result "Enter string"
|
706
|
+
|
707
|
+
tcltest::test te-no-watermark {verify that no watermark exists in the entry field when -watermark is empty} \
|
708
|
+
-setup setup \
|
709
|
+
-body {
|
710
|
+
.te configure -watermark ""
|
711
|
+
string trim [.te.txt get 1.0 end]
|
712
|
+
} -cleanup cleanup \
|
713
|
+
-result ""
|
714
|
+
|
715
|
+
tcltest::test te-watermark {verify that a watermark exists in the entry field when -watermark is non-empty} \
|
716
|
+
-setup setup \
|
717
|
+
-body {
|
718
|
+
.te configure -watermark "Enter string"
|
719
|
+
string trim [.te.txt get 1.0 end]
|
720
|
+
} -cleanup cleanup \
|
721
|
+
-result "Enter string"
|
722
|
+
|
723
|
+
tcltest::test te-watermark-removed {verify that the watermark is removed when text is inserted into the widget} \
|
724
|
+
-setup setup \
|
725
|
+
-body {
|
726
|
+
.te configure -watermark "Enter string"
|
727
|
+
.te insert end "foobar"
|
728
|
+
string trim [.te.txt get 1.0 end]
|
729
|
+
} -cleanup cleanup \
|
730
|
+
-result "foobar"
|
731
|
+
|
732
|
+
#---------------------------------
|
733
|
+
tcltest::test te-configure-watermarkforeground {configure -watermarkforeground returns correct result} \
|
734
|
+
-setup setup \
|
735
|
+
-body {
|
736
|
+
.te configure -watermarkforeground
|
737
|
+
} -cleanup cleanup \
|
738
|
+
-result {-watermarkforeground watermarkForeground Foreground {light gray} {light gray}}
|
739
|
+
|
740
|
+
tcltest::test te-cget-watermarkforeground {cget -watermarkforeground returns correct result} \
|
741
|
+
-setup setup \
|
742
|
+
-body {
|
743
|
+
.te cget -watermarkforeground
|
744
|
+
} -cleanup cleanup \
|
745
|
+
-result "light gray"
|
746
|
+
|
747
|
+
tcltest::test te-configure-cget-watermarkforeground {configure/cget -watermarkforeground returns correct result} \
|
748
|
+
-setup setup \
|
749
|
+
-body {
|
750
|
+
.te configure -watermarkforeground orange
|
751
|
+
.te cget -watermarkforeground
|
752
|
+
} -cleanup cleanup \
|
753
|
+
-result orange
|
754
|
+
|
755
|
+
tcltest::test te-watermark-color-check {check that the color is the watercolor when the watermark is present} \
|
756
|
+
-setup setup \
|
757
|
+
-body {
|
758
|
+
.te configure -watermark "Enter string" -watermarkforeground orange -foreground black
|
759
|
+
.te.txt cget -foreground
|
760
|
+
} -cleanup cleanup \
|
761
|
+
-result orange
|
762
|
+
|
763
|
+
tcltest::test te-watermark-removed-color-check {check that the color is the foreground color when the watermark is removed} \
|
764
|
+
-setup setup \
|
765
|
+
-body {
|
766
|
+
.te configure -watermark "Enter string" -watermarkforeground orange -foreground black
|
767
|
+
.te insert end "foobar"
|
768
|
+
.te.txt cget -foreground
|
769
|
+
} -cleanup cleanup \
|
770
|
+
-match regexp \
|
771
|
+
-result {(black|Black|#000000)}
|
772
|
+
|
773
|
+
#---------------------------------
|
774
|
+
tcltest::test te-configure-width {configure -width returns correct result} \
|
775
|
+
-setup {
|
776
|
+
setup -width 40
|
777
|
+
} -body {
|
778
|
+
.te configure -width
|
779
|
+
} -cleanup cleanup \
|
780
|
+
-match regexp \
|
781
|
+
-result {-width width Width \d+ 40}
|
782
|
+
|
783
|
+
tcltest::test te-cget-width {cget -width returns correct result} \
|
784
|
+
-setup {
|
785
|
+
setup -width 40
|
786
|
+
} -body {
|
787
|
+
.te cget -width
|
788
|
+
} -cleanup cleanup \
|
789
|
+
-result 40
|
790
|
+
|
791
|
+
tcltest::test te-configure-cget-width {configure/cget -width returns correct result} \
|
792
|
+
-setup setup \
|
793
|
+
-body {
|
794
|
+
.te configure -width 50
|
795
|
+
.te cget -width
|
796
|
+
} -cleanup cleanup \
|
797
|
+
-result 50
|
798
|
+
|
799
|
+
#---------------------------------
|
800
|
+
tcltest::test te-configure-xscrollcommand {configure -xscrollcommand returns correct result} \
|
801
|
+
-setup setup \
|
802
|
+
-body {
|
803
|
+
.te configure -xscrollcommand
|
804
|
+
} -cleanup cleanup \
|
805
|
+
-result {-xscrollcommand xScrollCommand ScrollCommand {} {}}
|
806
|
+
|
807
|
+
tcltest::test te-cget-xscrollcommand {cget -xscrollcommand returns correct result} \
|
808
|
+
-setup setup \
|
809
|
+
-body {
|
810
|
+
.te cget -xscrollcommand
|
811
|
+
} -cleanup cleanup \
|
812
|
+
-result ""
|
813
|
+
|
814
|
+
tcltest::test te-configure-cget-xscrollcommand {configure/cget -xscrollcommand returns correct result} \
|
815
|
+
-setup setup \
|
816
|
+
-body {
|
817
|
+
.te configure -xscrollcommand "foobar"
|
818
|
+
.te cget -xscrollcommand
|
819
|
+
} -cleanup cleanup \
|
820
|
+
-result "foobar"
|
821
|
+
|
822
|
+
#---------------------------------
|
823
|
+
tcltest::test te-bbox-0 {bbox returns correct result} \
|
824
|
+
-setup setup \
|
825
|
+
-body {
|
826
|
+
.te insert end "foobar"
|
827
|
+
.te bbox 0
|
828
|
+
} -cleanup cleanup \
|
829
|
+
-match regexp \
|
830
|
+
-result {\d+ -\d+ \d+ \d+}
|
831
|
+
|
832
|
+
#---------------------------------
|
833
|
+
tcltest::test te-delete-0 {delete returns correct result} \
|
834
|
+
-setup setup \
|
835
|
+
-body {
|
836
|
+
.te insert end "foobar"
|
837
|
+
.te delete 0
|
838
|
+
.te get
|
839
|
+
} -cleanup cleanup \
|
840
|
+
-result "oobar"
|
841
|
+
|
842
|
+
tcltest::test te-delete-end {delete returns correct result} \
|
843
|
+
-setup setup \
|
844
|
+
-body {
|
845
|
+
.te insert end "foobar"
|
846
|
+
.te delete end
|
847
|
+
.te get
|
848
|
+
} -cleanup cleanup \
|
849
|
+
-result "foobar"
|
850
|
+
|
851
|
+
tcltest::test te-delete-less {delete returns correct result} \
|
852
|
+
-setup setup \
|
853
|
+
-body {
|
854
|
+
.te insert end "foobar"
|
855
|
+
.te delete end-1
|
856
|
+
.te get
|
857
|
+
} -cleanup cleanup \
|
858
|
+
-result "fooba"
|
859
|
+
|
860
|
+
tcltest::test te-delete-more {delete returns correct result} \
|
861
|
+
-setup setup \
|
862
|
+
-body {
|
863
|
+
.te insert end "foobar"
|
864
|
+
.te delete 10
|
865
|
+
.te get
|
866
|
+
} -cleanup cleanup \
|
867
|
+
-result "foobar"
|
868
|
+
|
869
|
+
tcltest::test te-delete-first-last {delete first/last returns correct result} \
|
870
|
+
-setup setup \
|
871
|
+
-body {
|
872
|
+
.te insert end "foobar"
|
873
|
+
.te delete 1 4
|
874
|
+
.te get
|
875
|
+
} -cleanup cleanup \
|
876
|
+
-result "far"
|
877
|
+
|
878
|
+
tcltest::test te-delete-all {delete all returns correct result} \
|
879
|
+
-setup setup \
|
880
|
+
-body {
|
881
|
+
.te insert end "foobar"
|
882
|
+
.te delete 0 end
|
883
|
+
.te get
|
884
|
+
} -cleanup cleanup \
|
885
|
+
-result ""
|
886
|
+
|
887
|
+
tcltest::test te-delete-watermark {delete returns correct result} \
|
888
|
+
-setup setup \
|
889
|
+
-body {
|
890
|
+
.te configure -watermark "Enter string"
|
891
|
+
.te delete 1 end
|
892
|
+
.te get
|
893
|
+
} -cleanup cleanup \
|
894
|
+
-result ""
|
895
|
+
|
896
|
+
tcltest::test te-delete-watermark-all {delete returns correct result} \
|
897
|
+
-setup setup \
|
898
|
+
-body {
|
899
|
+
.te configure -watermark "Enter string"
|
900
|
+
.te delete 0 end
|
901
|
+
.te get
|
902
|
+
} -cleanup cleanup \
|
903
|
+
-result ""
|
904
|
+
|
905
|
+
#---------------------------------
|
906
|
+
tcltest::test te-get-empty {get returns correct result} \
|
907
|
+
-setup setup \
|
908
|
+
-body {
|
909
|
+
.te get
|
910
|
+
} -cleanup cleanup \
|
911
|
+
-result ""
|
912
|
+
|
913
|
+
tcltest::test te-get-watermark-empty {get returns correct result} \
|
914
|
+
-setup setup \
|
915
|
+
-body {
|
916
|
+
.te configure -watermark "Enter string"
|
917
|
+
.te get
|
918
|
+
} -cleanup cleanup \
|
919
|
+
-result ""
|
920
|
+
|
921
|
+
tcltest::test te-get {get returns correct result} \
|
922
|
+
-setup setup \
|
923
|
+
-body {
|
924
|
+
.te insert end "foobar"
|
925
|
+
.te get
|
926
|
+
} -cleanup cleanup \
|
927
|
+
-result "foobar"
|
928
|
+
|
929
|
+
tcltest::test te-get-watermark {get returns correct result} \
|
930
|
+
-setup setup \
|
931
|
+
-body {
|
932
|
+
.te configure -watermark "Enter string"
|
933
|
+
.te insert end "foobar"
|
934
|
+
.te get
|
935
|
+
} -cleanup cleanup \
|
936
|
+
-result "foobar"
|
937
|
+
|
938
|
+
#---------------------------------
|
939
|
+
tcltest::test te-icursor-watermark-empty-1 {icursor returns correct result} \
|
940
|
+
-setup setup \
|
941
|
+
-body {
|
942
|
+
.te configure -watermark "Empty string"
|
943
|
+
.te icursor 1
|
944
|
+
.te index insert
|
945
|
+
} -cleanup cleanup \
|
946
|
+
-result 0
|
947
|
+
|
948
|
+
tcltest::test te-icursor-watermark-empty-end {icursor returns correct result} \
|
949
|
+
-setup setup \
|
950
|
+
-body {
|
951
|
+
.te configure -watermark "Empty string"
|
952
|
+
.te icursor end
|
953
|
+
.te index insert
|
954
|
+
} -cleanup cleanup \
|
955
|
+
-result 0
|
956
|
+
|
957
|
+
tcltest::test te-icursor-watermark-empty-less {icursor returns correct result} \
|
958
|
+
-setup setup \
|
959
|
+
-body {
|
960
|
+
.te configure -watermark "Empty string"
|
961
|
+
.te icursor -1
|
962
|
+
.te index insert
|
963
|
+
} -cleanup cleanup \
|
964
|
+
-result 0
|
965
|
+
|
966
|
+
tcltest::test te-icursor-1 {icursor returns correct result} \
|
967
|
+
-setup setup \
|
968
|
+
-body {
|
969
|
+
.te insert end "foobar"
|
970
|
+
.te icursor 1
|
971
|
+
.te index insert
|
972
|
+
} -cleanup cleanup \
|
973
|
+
-result 1
|
974
|
+
|
975
|
+
tcltest::test te-icursor-end {icursor returns correct result} \
|
976
|
+
-setup setup \
|
977
|
+
-body {
|
978
|
+
.te insert end "foobar"
|
979
|
+
.te icursor end
|
980
|
+
.te index insert
|
981
|
+
} -cleanup cleanup \
|
982
|
+
-result 6
|
983
|
+
|
984
|
+
tcltest::test te-icursor-less {icursor returns correct result} \
|
985
|
+
-setup setup \
|
986
|
+
-body {
|
987
|
+
.te insert end "foobar"
|
988
|
+
.te icursor -1
|
989
|
+
.te index insert
|
990
|
+
} -cleanup cleanup \
|
991
|
+
-result 0
|
992
|
+
|
993
|
+
tcltest::test te-icursor-more {icursor returns correct result} \
|
994
|
+
-setup setup \
|
995
|
+
-body {
|
996
|
+
.te insert end "foobar"
|
997
|
+
.te icursor 10
|
998
|
+
.te index insert
|
999
|
+
} -cleanup cleanup \
|
1000
|
+
-result 6
|
1001
|
+
|
1002
|
+
#---------------------------------
|
1003
|
+
tcltest::test te-index-1 {make sure the index of end is 0 when watermark is displayed} \
|
1004
|
+
-setup setup \
|
1005
|
+
-body {
|
1006
|
+
.te configure -watermark "Enter string"
|
1007
|
+
.te index end
|
1008
|
+
} -cleanup cleanup \
|
1009
|
+
-result 0
|
1010
|
+
|
1011
|
+
tcltest::test te-index-2 {make sure the index is correct if the watermark is not displayed} \
|
1012
|
+
-setup setup \
|
1013
|
+
-body {
|
1014
|
+
.te configure -watermark "Enter string"
|
1015
|
+
.te insert end "foobar"
|
1016
|
+
.te index end
|
1017
|
+
} -cleanup cleanup \
|
1018
|
+
-result 6
|
1019
|
+
|
1020
|
+
# Cleanup the tests
|
1021
|
+
tcltest::cleanupTests
|
1022
|
+
|
1023
|
+
|