diff --git a/doc/SetOptions.3 b/doc/SetOptions.3 index 2eb3b88c4..716321485 100644 --- a/doc/SetOptions.3 +++ b/doc/SetOptions.3 @@ -14,30 +14,31 @@ Tk_CreateOptionTable, Tk_DeleteOptionTable, Tk_InitOptions, Tk_SetOptions, Tk_Fr \fB#include \fR .sp Tk_OptionTable -\fBTk_CreateOptionTable(\fIinterp, templatePtr\fB)\fR +\fBTk_CreateOptionTable\fR(\fIinterp, templatePtr\fR) .sp -\fBTk_DeleteOptionTable(\fIoptionTable\fB)\fR +\fBTk_DeleteOptionTable\fR(\fIoptionTable\fR) .sp int -\fBTk_InitOptions(\fIinterp, recordPtr, optionTable, tkwin\fB)\fR +\fBTk_InitOptions\fR(\fIinterp, recordPtr, optionTable, tkwin\fR) .sp int -\fBTk_SetOptions(\fIinterp, recordPtr, optionTable, objc, objv, tkwin, savePtr, maskPtr\fB)\fR +\fBTk_SetOptions\fR(\fIinterp, recordPtr, optionTable, objc, objv, tkwin, savePtr, maskPtr\fR) .sp -\fBTk_FreeSavedOptions(\fIsavedPtr\fB)\fR +\fBTk_FreeSavedOptions\fR(\fIsavedPtr\fR) .sp -\fBTk_RestoreSavedOptions(\fIsavedPtr\fB)\fR +\fBTk_RestoreSavedOptions\fR(\fIsavedPtr\fR) .sp Tcl_Obj * -\fBTk_GetOptionValue(\fIinterp, recordPtr, optionTable, namePtr, tkwin\fB)\fR +\fBTk_GetOptionValue\fR(\fIinterp, recordPtr, optionTable, namePtr, tkwin\fR) .sp Tcl_Obj * -\fBTk_GetOptionInfo(\fIinterp, recordPtr, optionTable, namePtr, tkwin\fB)\fR +\fBTk_GetOptionInfo\fR(\fIinterp, recordPtr, optionTable, namePtr, tkwin\fR) .sp -\fBTk_FreeConfigOptions(\fIrecordPtr, optionTable, tkwin\fB)\fR +\fBTk_FreeConfigOptions\fR(\fIrecordPtr, optionTable, tkwin\fR) .sp int \fBTk_Offset(\fItype, field\fB)\fR +.fi .SH ARGUMENTS .AS Tk_SavedOptions "*const objv[]" in/out .AP Tcl_Interp *interp in @@ -101,7 +102,7 @@ practice the object may not actually be a widget. The term is used to refer to the C-level structure in which information about a particular widget or object is stored. .PP -Note: the easiest way to learn how to use these procedures is to +Note that the easiest way to learn how to use these procedures is to look at a working example. In Tk, the simplest example is the code that implements the button family of widgets, which is in \fBtkButton.c\fR. Other examples are in \fBtkSquare.c\fR and \fBtkMenu.c\fR. @@ -310,8 +311,7 @@ greater than or equal to zero. .PP The \fIflags\fR field consists of one or more bits ORed together. The following flags are supported: -.TP -\fBTK_OPTION_NULL_OK\fR +.IP \fBTK_OPTION_NULL_OK\fR If this bit is set for an option then an empty string will be accepted as the value for the option and the resulting internal form will be a NULL pointer, a zero value, or \fBNone\fR, depending on the type of the option. @@ -322,13 +322,13 @@ feature to be turned off entirely, e.g. set a cursor value to Not all option types support the \fBTK_OPTION_NULL_OK\fR flag; for those that do, there is an explicit indication of that fact in the descriptions below. -.TP -\fBTK_OPTION_DONT_SET_DEFAULT\fR +.IP \fBTK_OPTION_DONT_SET_DEFAULT\fR If this bit is set for an option then no default value will be set in \fBTk_InitOptions\fR for this option. Neither the option database, nor any system default value, nor \fIoptionTable\fR are used to give a default value to this option. Instead it is assumed that the caller has already supplied a default value in the widget code. +.RS .PP The \fItype\fR field of each Tk_OptionSpec structure determines how to parse the value of that configuration option. The @@ -338,37 +338,34 @@ passed into procedures like \fBTk_SetOptions\fR, or if it uses the \fIclientData\fR field of the Tk_OptionSpec, then it is indicated explicitly; if not mentioned, the type requires neither \fItkwin\fR nor \fIclientData\fR. -.TP -\fBTK_OPTION_ANCHOR\fR +.RE +.IP \fBTK_OPTION_ANCHOR\fR The value must be a standard anchor position such as \fBne\fR or \fBcenter\fR. The internal form is a Tk_Anchor value like the ones returned by \fBTk_GetAnchorFromObj\fR. -.TP -\fBTK_OPTION_BITMAP\fR +.IP \fBTK_OPTION_BITMAP\fR The value must be a standard Tk bitmap name. The internal form is a Pixmap token like the ones returned by \fBTk_AllocBitmapFromObj\fR. This option type requires \fItkwin\fR to be supplied to procedures such as \fBTk_SetOptions\fR, and it supports the \fBTK_OPTION_NULL_OK\fR flag. -.TP -\fBTK_OPTION_BOOLEAN\fR +.IP \fBTK_OPTION_BOOLEAN\fR The value must be a standard boolean value such as \fBtrue\fR or -\fBno\fR. The internal form is an integer with value 0 or 1. -.TP -\fBTK_OPTION_BORDER\fR +\fBno\fR. The internal form is an integer with value 0 or 1. Note that if +the \fIobjOffset\fR field is not used, information about the original +value of this option will be lost. +.IP \fBTK_OPTION_BORDER\fR The value must be a standard color name such as \fBred\fR or \fB#ff8080\fR. The internal form is a Tk_3DBorder token like the ones returned by \fBTk_Alloc3DBorderFromObj\fR. This option type requires \fItkwin\fR to be supplied to procedures such as \fBTk_SetOptions\fR, and it supports the \fBTK_OPTION_NULL_OK\fR flag. -.TP -\fBTK_OPTION_COLOR\fR +.IP \fBTK_OPTION_COLOR\fR The value must be a standard color name such as \fBred\fR or \fB#ff8080\fR. The internal form is an (XColor *) token like the ones returned by \fBTk_AllocColorFromObj\fR. This option type requires \fItkwin\fR to be supplied to procedures such as \fBTk_SetOptions\fR, and it supports the \fBTK_OPTION_NULL_OK\fR flag. -.TP -\fBTK_OPTION_CURSOR\fR +.IP \fBTK_OPTION_CURSOR\fR The value must be a standard cursor name such as \fBcross\fR or \fB@foo\fR. The internal form is a Tk_Cursor token like the ones returned by \fBTk_AllocCursorFromObj\fR. @@ -376,19 +373,16 @@ This option type requires \fItkwin\fR to be supplied to procedures such as \fBTk_SetOptions\fR, and when the option is set the cursor for the window is changed by calling \fBXDefineCursor\fR. This option type also supports the \fBTK_OPTION_NULL_OK\fR flag. -.TP -\fBTK_OPTION_CUSTOM\fR +.IP \fBTK_OPTION_CUSTOM\fR This option allows applications to define new option types. The clientData field of the entry points to a structure defining the new option type. See the section \fBCUSTOM OPTION TYPES\fR below for details. -.TP -\fBTK_OPTION_DOUBLE\fR +.IP \fBTK_OPTION_DOUBLE\fR The string value must be a floating-point number in the format accepted by \fBstrtol\fR. The internal form is a C \fBdouble\fR value. This option type supports the \fBTK_OPTION_NULL_OK\fR flag; if a NULL value is set, the internal representation is set to zero. -.TP -\fBTK_OPTION_END\fR +.IP \fBTK_OPTION_END\fR Marks the end of the template. There must be a Tk_OptionSpec structure with \fItype\fR \fBTK_OPTION_END\fR at the end of each template. If the \fIclientData\fR field of this structure is not NULL, then it points to @@ -396,48 +390,41 @@ an additional array of Tk_OptionSpec's, which is itself terminated by another \fBTK_OPTION_END\fR entry. Templates may be chained arbitrarily deeply. This feature allows common options to be shared by several widget classes. -.TP -\fBTK_OPTION_FONT\fR +.IP \fBTK_OPTION_FONT\fR The value must be a standard font name such as \fBTimes 16\fR. The internal form is a Tk_Font handle like the ones returned by \fBTk_AllocFontFromObj\fR. This option type requires \fItkwin\fR to be supplied to procedures such as \fBTk_SetOptions\fR, and it supports the \fBTK_OPTION_NULL_OK\fR flag. -.TP -\fBTK_OPTION_INT\fR +.IP \fBTK_OPTION_INT\fR The string value must be an integer in the format accepted by \fBstrtol\fR (e.g. \fB0\fR and \fB0x\fR prefixes may be used to -specify octal or hexadecimal numbers, respectively). The internal -form is a C \fBint\fR value. -.TP -\fBTK_OPTION_JUSTIFY\fR +specify octal or hexadecimal numbers, respectively). The internal form is +a C \fBint\fR value. +.IP \fBTK_OPTION_JUSTIFY\fR The value must be a standard justification value such as \fBleft\fR. The internal form is a Tk_Justify like the values returned by \fBTk_GetJustifyFromObj\fR. -.TP -\fBTK_OPTION_PIXELS\fR +.IP \fBTK_OPTION_PIXELS\fR The value must specify a screen distance such as \fB2i\fR or \fB6.4\fR. The internal form is an integer value giving a distance in pixels, like the values returned by -\fBTk_GetPixelsFromObj\fR. Note: if the \fIobjOffset\fR field is not -used then information about the original value of this option will be lost. +\fBTk_GetPixelsFromObj\fR. Note that if the \fIobjOffset\fR field is not +used, information about the original value of this option will be lost. See \fBOBJOFFSET VS. INTERNALOFFSET\fR below for details. This option type supports the \fBTK_OPTION_NULL_OK\fR flag; if a NULL value is set, the -internal representation is set to zero. -.TP -\fBTK_OPTION_RELIEF\fR +internal representation is set to INT_MIN. +.IP \fBTK_OPTION_RELIEF\fR The value must be standard relief such as \fBraised\fR. The internal form is an integer relief value such as \fBTK_RELIEF_RAISED\fR. This option type supports the \fBTK_OPTION_NULL_OK\fR flag; if a NULL value is set, the internal representation is set to \fBTK_RELIEF_NULL\fR. -.TP -\fBTK_OPTION_STRING\fR +.IP \fBTK_OPTION_STRING\fR The value may be any string. The internal form is a (char *) pointer that points to a dynamically allocated copy of the value. This option type supports the \fBTK_OPTION_NULL_OK\fR flag. -.TP -\fBTK_OPTION_STRING_TABLE\fR +.IP \fBTK_OPTION_STRING_TABLE\fR For this type, \fIclientData\fR is a pointer to an array of strings suitable for passing to \fBTcl_GetIndexFromObj\fR. The value must be one of the strings in the table, or a unique abbreviation of @@ -446,15 +433,13 @@ into the table of the matching string, like the return value from \fBTcl_GetStringFromObj\fR. This option type supports the \fBTK_OPTION_NULL_OK\fR flag; if a NULL value is set, the internal representation is set to -1. -.TP -\fBTK_OPTION_SYNONYM\fR +.IP \fBTK_OPTION_SYNONYM\fR This type is used to provide alternative names for an option (for example, \fB\-bg\fR is often used as a synonym for \fB\-background\fR). The \fBclientData\fR field is a string that gives the name of another option in the same table. Whenever the synonym option is used, the information from the other option will be used instead. -.TP -\fBTK_OPTION_WINDOW\fR +.IP \fBTK_OPTION_WINDOW\fR The value must be a window path name. The internal form is a \fBTk_Window\fR token for the window. This option type requires \fItkwin\fR to be supplied to procedures @@ -504,8 +489,8 @@ the option is retrieved. In most cases it is convenient to use the \fIinternalOffset\fR field as well, so that the integer value is immediately available for use in the widget code (alternatively, \fBTk_GetPixelsFromObj\fR can be used to extract the integer value from -the object whenever it is needed). Note: the problem of losing information -on retrievals exists only for \fBTK_OPTION_PIXELS\fR options. +the object whenever it is needed). Note that the problem of losing +information on retrievals exists only for \fBTK_OPTION_PIXELS\fR options. .PP The second reason to use the \fIobjOffset\fR field is in order to implement new types of options not supported by these procedures. @@ -513,6 +498,10 @@ To implement a new type of option, you can use \fBTK_OPTION_STRING\fR as the type in the Tk_OptionSpec structure and set the \fIobjOffset\fR field but not the \fIinternalOffset\fR field. Then, after calling \fBTk_SetOptions\fR, convert the object to internal form yourself. +.PP +Ttk widgets do not support the \fIinternalOffset\fR machinery. +Option values of Ttk widgets are always stored as (Tcl_Obj *), meaning that +the \fIobjOffset\fR field must be used. .SH "CUSTOM OPTION TYPES" .PP Applications can extend the built-in configuration types with @@ -521,7 +510,7 @@ free, and restore saved copies of the type and creating a structure pointing to those procedures: .CS typedef struct Tk_ObjCustomOption { - const char *\fname\fR; + const char *\fIname\fR; Tk_CustomOptionSetProc *\fIsetProc\fR; Tk_CustomOptionGetProc *\fIgetProc\fR; Tk_CustomOptionRestoreProc *\fIrestoreProc\fR; @@ -570,18 +559,14 @@ The \fIsetProc\fR procedure is invoked by \fBTk_SetOptions\fR to convert a Tcl_Obj into an internal representation and store the resulting value in the widget record. The arguments are: .RS -.TP -\fIclientData\fR +.IP \fIclientData\fR A copy of the \fIclientData\fR field in the Tk_ObjCustomOption structure. -.TP -\fIinterp\fR +.IP \fIinterp\fR A pointer to a Tcl interpreter, used for error reporting. -.TP -\fITkwin\fR +.IP \fITkwin\fR A copy of the \fItkwin\fR argument to \fBTk_SetOptions\fR -.TP -\fIvaluePtr\fR +.IP \fIvaluePtr\fR A pointer to a reference to a Tcl_Obj describing the new value for the option; it could have been specified explicitly in the call to \fBTk_SetOptions\fR or it could come from the option database or a @@ -591,22 +576,18 @@ pointer referenced by \fIvaluePtr\fR is the pointer that will be stored at the objOffset for the option. \fISetProc\fR may modify the value if necessary; for example, \fIsetProc\fR may change the value to NULL to support the \fBTK_OPTION_NULL_OK\fR flag. -.TP -\fIrecordPtr\fR +.IP \fIrecordPtr\fR A pointer to the start of the widget record to modify. -.TP -\fIinternalOffset\fR +.IP \fIinternalOffset\fR Offset in bytes from the start of the widget record to the location where the internal representation of the option value is to be placed. -.TP -\fIsaveInternalPtr\fR +.IP \fIsaveInternalPtr\fR A pointer to storage allocated in a Tk_SavedOptions structure for the internal representation of the original option value. Before setting the option to its new value, \fIsetProc\fR should set the value referenced by \fIsaveInternalPtr\fR to the original value of the option in order to support \fBTk_RestoreSavedOptions\fR. -.TP -\fIflags\fR +.IP \fIflags\fR A copy of the \fIflags\fR field in the Tk_OptionSpec structure for the option .RE diff --git a/doc/scrollbar.n b/doc/scrollbar.n index eee6a637a..109793865 100644 --- a/doc/scrollbar.n +++ b/doc/scrollbar.n @@ -12,7 +12,7 @@ .SH NAME scrollbar \- Create and manipulate 'scrollbar' scrolling control and indicator widgets .SH SYNOPSIS -\fBscrollbar\fR \fIpathName \fR?\fIoptions\fR? +\fBscrollbar\fI pathName \fR?\fIoptions\fR? .SO \-activebackground \-highlightcolor \-repeatdelay \-background \-highlightthickness \-repeatinterval @@ -81,20 +81,15 @@ below for details. .PP A scrollbar displays five elements, which are referred to in the widget commands for the scrollbar: -.TP 10 -\fBarrow1\fR +.IP \fBarrow1\fR 10 The top or left arrow in the scrollbar. -.TP 10 -\fBtrough1\fR +.IP \fBtrough1\fR 10 The region between the slider and \fBarrow1\fR. -.TP 10 -\fBslider\fR +.IP \fBslider\fR 10 The rectangle that indicates what is visible in the associated widget. -.TP 10 -\fBtrough2\fR +.IP \fBtrough2\fR 10 The region between the slider and \fBarrow2\fR. -.TP 10 -\fBarrow2\fR +.IP \fBarrow2\fR 10 The bottom or right arrow in the scrollbar. .SH "WIDGET COMMAND" .PP @@ -103,11 +98,12 @@ name is \fIpathName\fR. This command may be used to invoke various operations on the widget. It has the following general form: .CS -\fIpathName option \fR?\fIarg arg ...\fR? +\fIpathName option \fR?\fIarg ...\fR? .CE \fIOption\fR and the \fIarg\fRs determine the exact behavior of the command. The following commands are possible for scrollbar widgets: +.\" METHOD: activate .TP \fIpathName \fBactivate \fR?\fIelement\fR? . @@ -121,6 +117,7 @@ will be active. If \fIelement\fR is not specified, the command returns the name of the element that is currently active, or an empty string if no element is active. +.\" METHOD: cget .TP \fIpathName \fBcget \fIoption\fR . @@ -128,6 +125,7 @@ Returns the current value of the configuration option given by \fIoption\fR. \fIOption\fR may have any of the values accepted by the \fBscrollbar\fR command. +.\" METHOD: configure .TP \fIpathName \fBconfigure\fR ?\fIoption\fR? ?\fIvalue option value ...\fR? . @@ -143,6 +141,7 @@ modifies the given widget option(s) to have the given value(s); in this case the command returns an empty string. \fIOption\fR may have any of the values accepted by the \fBscrollbar\fR command. +.\" METHOD: delta .TP \fIpathName \fBdelta \fIdeltaX deltaY\fR . @@ -155,6 +154,7 @@ ignored in this case). If the scrollbar is vertical, the result indicates how much the scrollbar setting must change to move the slider \fIdeltaY\fR pixels down. The arguments and the result may be zero or negative. +.\" METHOD: fraction .TP \fIpathName \fBfraction \fIx y\fR . @@ -167,11 +167,13 @@ the middle, and so on. widget. If \fIx\fR and \fIy\fR refer to a point outside the trough, the closest point in the trough is used. +.\" METHOD: get .TP \fIpathName \fBget\fR . Returns the scrollbar settings in the form of a list whose elements are the arguments to the most recent \fBset\fR widget command. +.\" METHOD: identify .TP \fIpathName \fBidentify \fIx y\fR . @@ -180,6 +182,7 @@ Returns the name of the element under the point given by \fIx\fR and not lie in any element of the scrollbar. \fIX\fR and \fIy\fR must be pixel coordinates relative to the scrollbar widget. +.\" METHOD: set .TP \fIpathName \fBset \fIfirst last\fR . @@ -204,6 +207,7 @@ The command may take any of the following forms. In each case, \fIprefix\fR is the contents of the \fB\-command\fR option, which usually has a form like .QW "\fB.t yview\fR" . +.\" METHOD: moveto .TP \fIprefix \fBmoveto \fIfraction\fR . @@ -214,6 +218,7 @@ If \fIfraction\fR is 0 it refers to the beginning of the document. 1.0 refers to the end of the document, 0.333 refers to a point one-third of the way through the document, and so on. +.\" METHOD: scroll .TP \fIprefix \fBscroll \fInumber \fBunits\fR . @@ -345,14 +350,14 @@ The End key adjusts the view to the bottom (right edge) of the document. Create a window with a scrollable \fBtext\fR widget: .CS toplevel .tl -text .tl.t \-yscrollcommand {.tl.s set} -\fBscrollbar\fR .tl.s \-command {.tl.t yview} -grid .tl.t .tl.s \-sticky nsew -grid columnconfigure .tl 0 \-weight 1 -grid rowconfigure .tl 0 \-weight 1 +text .tl.t -yscrollcommand {.tl.s set} +\fBscrollbar\fR .tl.s -command {.tl.t yview} +grid .tl.t .tl.s -sticky nsew +grid columnconfigure .tl 0 -weight 1 +grid rowconfigure .tl 0 -weight 1 .CE .SH "SEE ALSO" -ttk:scrollbar(n) +ttk::scrollbar(n) .SH KEYWORDS scrollbar, widget '\" Local Variables: diff --git a/generic/tkImgGIF.c b/generic/tkImgGIF.c index 33bf004e4..a22e2c907 100644 --- a/generic/tkImgGIF.c +++ b/generic/tkImgGIF.c @@ -436,7 +436,8 @@ FileReadGIF( Tcl_SetObjResult(interp, Tcl_ObjPrintf( "no value given for \"%s\" option", Tcl_GetString(objv[i]))); - Tcl_SetErrorCode(interp, "TK", "IMAGE", "GIF", "OPT_VALUE", NULL); + Tcl_SetErrorCode(interp, "TK", "IMAGE", "GIF", "OPT_VALUE", + (char *) NULL); return TCL_ERROR; } if (Tcl_GetIntFromObj(interp, objv[++i], &index) != TCL_OK) { @@ -451,13 +452,15 @@ FileReadGIF( if (!ReadGIFHeader(gifConfPtr, chan, &fileWidth, &fileHeight)) { Tcl_SetObjResult(interp, Tcl_ObjPrintf( "couldn't read GIF header from file \"%s\"", fileName)); - Tcl_SetErrorCode(interp, "TK", "IMAGE", "GIF", "HEADER", NULL); + Tcl_SetErrorCode(interp, "TK", "IMAGE", "GIF", "HEADER", + (char *) NULL); return TCL_ERROR; } if ((fileWidth <= 0) || (fileHeight <= 0)) { Tcl_SetObjResult(interp, Tcl_ObjPrintf( "GIF image file \"%s\" has dimension(s) <= 0", fileName)); - Tcl_SetErrorCode(interp, "TK", "IMAGE", "GIF", "BOGUS_SIZE", NULL); + Tcl_SetErrorCode(interp, "TK", "IMAGE", "GIF", "BOGUS_SIZE", + (char *) NULL); return TCL_ERROR; } @@ -471,7 +474,8 @@ FileReadGIF( */ Tcl_SetObjResult(interp, Tcl_NewStringObj( "GIF file truncated", -1)); - Tcl_SetErrorCode(interp, "TK", "IMAGE", "GIF", "TRUNCATED", NULL); + Tcl_SetErrorCode(interp, "TK", "IMAGE", "GIF", "TRUNCATED", + (char *) NULL); return TCL_ERROR; } bitPixel = 2 << (buf[0] & 0x07); @@ -480,7 +484,8 @@ FileReadGIF( if (!ReadColorMap(gifConfPtr, chan, bitPixel, colorMap)) { Tcl_SetObjResult(interp, Tcl_NewStringObj( "error reading color map", -1)); - Tcl_SetErrorCode(interp, "TK", "IMAGE", "GIF", "COLOR_MAP", NULL); + Tcl_SetErrorCode(interp, "TK", "IMAGE", "GIF", "COLOR_MAP", + (char *) NULL); return TCL_ERROR; } } @@ -519,7 +524,7 @@ FileReadGIF( Tcl_SetObjResult(interp, Tcl_NewStringObj( "premature end of image data for this index", -1)); Tcl_SetErrorCode(interp, "TK", "IMAGE", "GIF", "PREMATURE_END", - NULL); + (char *) NULL); goto error; } @@ -527,7 +532,8 @@ FileReadGIF( case GIF_TERMINATOR: Tcl_SetObjResult(interp, Tcl_NewStringObj( "no image data for this index", -1)); - Tcl_SetErrorCode(interp, "TK", "IMAGE", "GIF", "NO_DATA", NULL); + Tcl_SetErrorCode(interp, "TK", "IMAGE", "GIF", "NO_DATA", + (char *) NULL); goto error; case GIF_EXTENSION: @@ -540,7 +546,7 @@ FileReadGIF( "error reading extension function code in GIF image", -1)); Tcl_SetErrorCode(interp, "TK", "IMAGE", "GIF", "BAD_EXT", - NULL); + (char *) NULL); goto error; } if (DoExtension(gifConfPtr, chan, buf[0], @@ -548,7 +554,7 @@ FileReadGIF( Tcl_SetObjResult(interp, Tcl_NewStringObj( "error reading extension in GIF image", -1)); Tcl_SetErrorCode(interp, "TK", "IMAGE", "GIF", "BAD_EXT", - NULL); + (char *) NULL); goto error; } continue; @@ -558,7 +564,7 @@ FileReadGIF( "couldn't read left/top/width/height in GIF image", -1)); Tcl_SetErrorCode(interp, "TK", "IMAGE", "GIF", "DIMENSIONS", - NULL); + (char *) NULL); goto error; } break; @@ -589,7 +595,7 @@ FileReadGIF( Tcl_SetObjResult(interp, Tcl_NewStringObj( "error reading color map", -1)); Tcl_SetErrorCode(interp, "TK", "IMAGE", "GIF", - "COLOR_MAP", NULL); + "COLOR_MAP", (char *) NULL); goto error; } } @@ -651,7 +657,8 @@ FileReadGIF( if (!ReadColorMap(gifConfPtr, chan, bitPixel, colorMap)) { Tcl_SetObjResult(interp, Tcl_NewStringObj( "error reading color map", -1)); - Tcl_SetErrorCode(interp, "TK", "IMAGE", "GIF", "COLOR_MAP", NULL); + Tcl_SetErrorCode(interp, "TK", "IMAGE", "GIF", "COLOR_MAP", + (char *) NULL); goto error; } } @@ -1079,7 +1086,8 @@ ReadImage( if (initialCodeSize > MAX_LWZ_BITS) { Tcl_SetObjResult(interp, Tcl_NewStringObj("malformed image", -1)); - Tcl_SetErrorCode(interp, "TK", "IMAGE", "GIF", "MALFORMED", NULL); + Tcl_SetErrorCode(interp, "TK", "IMAGE", "GIF", "MALFORMED", + (char *) NULL); return TCL_ERROR; } @@ -1768,7 +1776,8 @@ CommonWriteGIF( SaveMap(&state, blockPtr); if (state.num >= MAXCOLORMAPSIZE) { Tcl_SetObjResult(interp, Tcl_NewStringObj("too many colors", -1)); - Tcl_SetErrorCode(interp, "TK", "IMAGE", "GIF", "COLORFUL", NULL); + Tcl_SetErrorCode(interp, "TK", "IMAGE", "GIF", "COLORFUL", + (char *) NULL); return TCL_ERROR; } if (state.num<2) { diff --git a/generic/tkInt.h b/generic/tkInt.h index 00a55be8b..29cd83ab1 100644 --- a/generic/tkInt.h +++ b/generic/tkInt.h @@ -1315,6 +1315,8 @@ MODULE_SCOPE int TkBackgroundEvalObjv(Tcl_Interp *interp, int objc, Tcl_Obj *const *objv, int flags); MODULE_SCOPE void TkSendVirtualEvent(Tk_Window tgtWin, const char *eventName, Tcl_Obj *detail); +MODULE_SCOPE void TkDrawDottedRect(Display *disp, Drawable d, GC gc, + int x, int y, int width, int height); MODULE_SCOPE Tcl_Command TkMakeEnsemble(Tcl_Interp *interp, const char *nsname, const char *name, ClientData clientData, const TkEnsemble *map); diff --git a/generic/tkListbox.c b/generic/tkListbox.c index f97a9c81f..bad4e6444 100644 --- a/generic/tkListbox.c +++ b/generic/tkListbox.c @@ -15,10 +15,6 @@ #include "default.h" #include "tkInt.h" -#ifdef _WIN32 -#include "tkWinInt.h" -#endif - typedef struct { Tk_OptionTable listboxOptionTable; /* Table defining configuration options @@ -1831,6 +1827,7 @@ DisplayListbox( { Listbox *listPtr = clientData; Tk_Window tkwin = listPtr->tkwin; + Display *disp = listPtr->display; GC gc; int i, limit, x, y, prevSelected, freeGC, stringLen; Tk_FontMetrics fm; @@ -1885,7 +1882,7 @@ DisplayListbox( * screen). */ - pixmap = Tk_GetPixmap(listPtr->display, Tk_WindowId(tkwin), + pixmap = Tk_GetPixmap(disp, Tk_WindowId(tkwin), Tk_Width(tkwin), Tk_Height(tkwin), Tk_Depth(tkwin)); #else pixmap = Tk_WindowId(tkwin); @@ -1915,7 +1912,7 @@ DisplayListbox( int width = Tk_Width(tkwin); /* zeroth approx to silence warning */ x = listPtr->inset; - y = ((i - listPtr->topIndex) * listPtr->lineHeight) + listPtr->inset; + y = (i - listPtr->topIndex) * listPtr->lineHeight + listPtr->inset; gc = listPtr->textGC; freeGC = 0; @@ -2082,7 +2079,7 @@ DisplayListbox( - listPtr->xOffset + GetMaxOffset(listPtr)/2; } - Tk_DrawChars(listPtr->display, pixmap, gc, listPtr->tkfont, + Tk_DrawChars(disp, pixmap, gc, listPtr->tkfont, stringRep, stringLen, x, y); /* @@ -2095,71 +2092,34 @@ DisplayListbox( * Underline the text. */ - Tk_UnderlineChars(listPtr->display, pixmap, gc, - listPtr->tkfont, stringRep, x, y, 0, stringLen); + Tk_UnderlineChars(disp, pixmap, gc, listPtr->tkfont, + stringRep, x, y, 0, stringLen); } else if (listPtr->activeStyle == ACTIVE_STYLE_DOTBOX) { -#ifdef _WIN32 - /* - * This provides for exact default look and feel on Windows. - */ - - TkWinDCState state; - HDC dc; - RECT rect; - - dc = TkWinGetDrawableDC(listPtr->display, pixmap, &state); - rect.left = listPtr->inset; - rect.top = ((i - listPtr->topIndex) * listPtr->lineHeight) - + listPtr->inset; - rect.right = rect.left + width; - rect.bottom = rect.top + listPtr->lineHeight; - DrawFocusRect(dc, &rect); - TkWinReleaseDrawableDC(pixmap, dc, &state); -#else /* !_WIN32 */ /* * Draw a dotted box around the text. */ x = listPtr->inset; - y = ((i - listPtr->topIndex) * listPtr->lineHeight) + y = (i - listPtr->topIndex) * listPtr->lineHeight + listPtr->inset; - width = Tk_Width(tkwin) - 2*listPtr->inset - 1; - - gcValues.line_style = LineOnOffDash; - gcValues.line_width = listPtr->selBorderWidth; - if (gcValues.line_width <= 0) { - gcValues.line_width = 1; - } - gcValues.dash_offset = 0; - gcValues.dashes = 1; + width = Tk_Width(tkwin) - 2*listPtr->inset; - /* - * You would think the XSetDashes was necessary, but it - * appears that the default dotting for just saying we want - * dashes appears to work correctly. - static char dashList[] = { 1 }; - static int dashLen = sizeof(dashList); - XSetDashes(listPtr->display, gc, 0, dashList, dashLen); - */ + TkDrawDottedRect(disp, pixmap, gc, x, y, + width, listPtr->lineHeight); - mask = GCLineWidth | GCLineStyle | GCDashList | GCDashOffset; - XChangeGC(listPtr->display, gc, mask, &gcValues); - XDrawRectangle(listPtr->display, pixmap, gc, x, y, - (unsigned) width, (unsigned) listPtr->lineHeight - 1); if (!freeGC) { /* * Don't bother changing if it is about to be freed. */ gcValues.line_style = LineSolid; - XChangeGC(listPtr->display, gc, GCLineStyle, &gcValues); + XChangeGC(disp, gc, GCLineStyle, &gcValues); } -#endif /* _WIN32 */ } } if (freeGC) { - Tk_FreeGC(listPtr->display, gc); + Tk_FreeGC(disp, gc); } } @@ -2187,10 +2147,9 @@ DisplayListbox( } } #ifndef TK_NO_DOUBLE_BUFFERING - XCopyArea(listPtr->display, pixmap, Tk_WindowId(tkwin), - listPtr->textGC, 0, 0, (unsigned) Tk_Width(tkwin), - (unsigned) Tk_Height(tkwin), 0, 0); - Tk_FreePixmap(listPtr->display, pixmap); + XCopyArea(disp, pixmap, Tk_WindowId(tkwin), listPtr->textGC, 0, 0, + (unsigned) Tk_Width(tkwin), (unsigned) Tk_Height(tkwin), 0, 0); + Tk_FreePixmap(disp, pixmap); #endif /* TK_NO_DOUBLE_BUFFERING */ } diff --git a/generic/tkUtil.c b/generic/tkUtil.c index a673b6860..5bfea6110 100644 --- a/generic/tkUtil.c +++ b/generic/tkUtil.c @@ -617,6 +617,70 @@ Tk_DrawFocusHighlight( TkDrawInsetFocusHighlight(tkwin, gc, width, drawable, 0); } +/* + *---------------------------------------------------------------------- + * + * TkDrawDottedRect -- + * + * This function draws a dotted rectangle, used as focus ring of Ttk + * widgets and for rendering the active element of a listbox. + * + * Results: + * None. + * + * Side effects: + * A dotted rectangle is drawn in the specified Drawable. On the + * windowing systems x11 and aqua the GC components line_style, + * line_width, dashes, and dash_offset are modified as needed. + * + *---------------------------------------------------------------------- + */ + +void +TkDrawDottedRect( + Display *disp, /* Display containing the dotted rectangle. */ + Drawable d, /* Where to draw the rectangle (typically a + * pixmap for double buffering). */ + GC gc, /* Graphics context to use for drawing the + * rectangle. */ + int x, int y, /* Coordinates of the top-left corner. */ + int width, int height) /* Width & height, _including the border_. */ +{ +#ifdef _WIN32 + TkWinDrawDottedRect(disp, d, gc->foreground, x, y, width, height); + +#else + XGCValues gcValues; + int widthMod2 = width % 2, heightMod2 = height % 2; + int x2 = x + width - 1, y2 = y + height - 1; + + gcValues.line_style = LineOnOffDash; + gcValues.line_width = 1; + gcValues.dashes = 1; +#ifdef MAC_OSX_TK + gcValues.dash_offset = 1; +#else + gcValues.dash_offset = 0; +#endif + XChangeGC(disp, gc, GCLineStyle | GCLineWidth | GCDashList | GCDashOffset, + &gcValues); + + if (widthMod2 == 0 && heightMod2 == 0) { + XDrawLine(disp, d, gc, x+1, y, x2-1, y); /* N */ + XDrawLine(disp, d, gc, x+2, y2, x2, y2); /* S */ + XDrawLine(disp, d, gc, x, y+2, x, y2); /* W */ + XDrawLine(disp, d, gc, x2, y+1, x2, y2-1); /* E */ + } else { + int dx = 1 - widthMod2, dy = 1 - heightMod2; + + XDrawLine(disp, d, gc, x+1, y, x2-dx, y); /* N */ + XDrawLine(disp, d, gc, x+1, y2, x2-dx, y2); /* S */ + XDrawLine(disp, d, gc, x, y+1, x, y2-dy); /* W */ + XDrawLine(disp, d, gc, x2, y+1, x2, y2-dy); /* E */ + } +#endif +} + /* *---------------------------------------------------------------------- * diff --git a/generic/ttk/ttkElements.c b/generic/ttk/ttkElements.c index 365314ffd..d52c4288a 100644 --- a/generic/ttk/ttkElements.c +++ b/generic/ttk/ttkElements.c @@ -372,24 +372,31 @@ static void DrawFocusRing( Ttk_Box b) { XColor *color = Tk_GetColorFromObj(tkwin, colorObj); - unsigned long mask = 0UL; - XGCValues gcvalues; + XGCValues gcValues; GC gc; + Display *disp = Tk_Display(tkwin); + + if (thickness < 1 && solid) { + thickness = 1; + } + + gcValues.foreground = color->pixel; + gc = Tk_GetGC(tkwin, GCForeground, &gcValues); - gcvalues.foreground = color->pixel; - gcvalues.line_width = thickness < 1 ? 1 : thickness; if (solid) { - gcvalues.line_style = LineSolid; - mask = GCForeground | GCLineStyle | GCLineWidth; + XRectangle rects[4] = { + {b.x, b.y, b.width, thickness}, /* N */ + {b.x, b.y + b.height - thickness, b.width, thickness}, /* S */ + {b.x, b.y + thickness, thickness, b.height - 2*thickness}, /* W */ + {b.x + b.width - thickness, b.y + thickness, /* E */ + thickness, b.height - 2*thickness} + }; + + XFillRectangles(disp, d, gc, rects, 4); } else { - gcvalues.line_style = LineOnOffDash; - gcvalues.dashes = 1; - gcvalues.dash_offset = 1; - mask = GCForeground | GCLineStyle | GCDashList | GCDashOffset | GCLineWidth; + TkDrawDottedRect(disp, d, gc, b.x, b.y, b.width, b.height); } - gc = Tk_GetGC(tkwin, mask, &gcvalues); - XDrawRectangle(Tk_Display(tkwin), d, gc, b.x, b.y, b.width-1, b.height-1); Tk_FreeGC(Tk_Display(tkwin), gc); } diff --git a/library/ttk/classicTheme.tcl b/library/ttk/classicTheme.tcl index 609c5d78d..f1ebda80b 100644 --- a/library/ttk/classicTheme.tcl +++ b/library/ttk/classicTheme.tcl @@ -111,7 +111,17 @@ namespace eval ttk::theme::classic { # # Toolbar buttons: # - ttk::style configure Toolbutton -padding 2 -relief flat -shiftrelief 2 + ttk::style layout Toolbutton { + Toolbutton.focus -children { + Toolbutton.border -children { + Toolbutton.padding -children { + Toolbutton.label + } + } + } + } + ttk::style configure Toolbutton -padding 2 -relief flat \ + -shiftrelief 2 -focussolid 1 ttk::style map Toolbutton -relief \ {disabled flat selected sunken pressed sunken active raised} ttk::style map Toolbutton -background \ diff --git a/library/ttk/defaults.tcl b/library/ttk/defaults.tcl index 66706a311..06e29b23b 100644 --- a/library/ttk/defaults.tcl +++ b/library/ttk/defaults.tcl @@ -134,12 +134,13 @@ namespace eval ttk::theme::default { # ttk::style layout Toolbutton { Toolbutton.border -children { - Toolbutton.padding -children { - Toolbutton.label + Toolbutton.focus -children { + Toolbutton.padding -children { + Toolbutton.label + } } } } - ttk::style configure Toolbutton \ -padding 2 -relief flat ttk::style map Toolbutton -relief \ diff --git a/tests/bell.test b/tests/bell.test index f1ecac467..75f42445c 100644 --- a/tests/bell.test +++ b/tests/bell.test @@ -2,7 +2,7 @@ # It is organized in the standard fashion for Tcl tests. # # Copyright (c) 1994 The Regents of the University of California. -# Copyright (c) 1998-2000 by Scriptics Corporation. +# Copyright (c) 1998-2000 Scriptics Corporation. # All rights reserved. package require tcltest 2.2 @@ -12,19 +12,19 @@ tcltest::loadTestedCommands test bell-1.1 {bell command} -body { bell a -} -returnCodes {error} -result {bad option "a": must be -displayof or -nice} +} -returnCodes error -result {bad option "a": must be -displayof or -nice} test bell-1.2 {bell command} -body { bell a b -} -returnCodes {error} -result {bad option "a": must be -displayof or -nice} +} -returnCodes error -result {bad option "a": must be -displayof or -nice} test bell-1.3 {bell command} -body { bell -displayof gorp -} -returnCodes {error} -result {bad window path name "gorp"} +} -returnCodes error -result {bad window path name "gorp"} test bell-1.4 {bell command} -body { bell -nice -displayof -} -returnCodes {error} -result {wrong # args: should be "bell ?-displayof window? ?-nice?"} +} -returnCodes error -result {wrong # args: should be "bell ?-displayof window? ?-nice?"} test bell-1.5 {bell command} -body { bell -nice -nice -nice @@ -36,7 +36,7 @@ test bell-1.6 {bell command} -body { test bell-1.7 {bell command} -body { bell -nice -displayof . -nice -} -returnCodes {error} -result {wrong # args: should be "bell ?-displayof window? ?-nice?"} +} -returnCodes error -result {wrong # args: should be "bell ?-displayof window? ?-nice?"} test bell-1.8 {bell command} -body { puts "Bell should ring now ..." diff --git a/tests/bgerror.test b/tests/bgerror.test index fd9594a26..a516d2461 100644 --- a/tests/bgerror.test +++ b/tests/bgerror.test @@ -2,7 +2,7 @@ # It is organized in the standard fashion for Tcl tests. # # Copyright (c) 1997 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. package require tcltest 2.2 diff --git a/tests/bind.test b/tests/bind.test index ce88fd5db..0c9e6d0ad 100644 --- a/tests/bind.test +++ b/tests/bind.test @@ -4,7 +4,7 @@ # # Copyright (c) 1994 The Regents of the University of California. # Copyright (c) 1994-1995 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. package require tcltest 2.2 diff --git a/tests/bitmap.test b/tests/bitmap.test index 6996f8875..a8a3ee788 100644 --- a/tests/bitmap.test +++ b/tests/bitmap.test @@ -3,7 +3,7 @@ # Tcl tests. # # Copyright (c) 1998 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. package require tcltest 2.2 diff --git a/tests/border.test b/tests/border.test index d6ff5c7a8..1efc1e6ba 100644 --- a/tests/border.test +++ b/tests/border.test @@ -2,7 +2,7 @@ # tkBorder.c. It is organized in the standard fashion for Tcl tests. # # Copyright (c) 1998 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. package require tcltest 2.2 diff --git a/tests/busy.test b/tests/busy.test index ae7a2a576..cd1f9cf1c 100644 --- a/tests/busy.test +++ b/tests/busy.test @@ -4,7 +4,7 @@ # commands. Sourcing this file runs the tests and generates output for errors. # No output means no errors were found. # -# Copyright (c) 1998-2000 by Jos Decoster. All rights reserved. +# Copyright (c) 1998-2000 Jos Decoster. All rights reserved. package require tcltest 2.2 tcltest::configure {*}$argv @@ -77,7 +77,7 @@ test busy-2.8 {tk busy hold non existing window} -body { test busy-2.9 {tk busy hold (shortcut) non existing window} -body { tk busy .f update -} -returnCodes {error} -result {bad window path name ".f"} +} -returnCodes error -result {bad window path name ".f"} test busy-2.10 {tk busy hold root window with cursor} -body { tk busy hold . -cursor arrow update diff --git a/tests/button.test b/tests/button.test index 85dc67b81..c51e90863 100644 --- a/tests/button.test +++ b/tests/button.test @@ -4,7 +4,7 @@ # # Copyright (c) 1994 The Regents of the University of California. # Copyright (c) 1994-1996 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. package require tcltest 2.2 @@ -35,7 +35,7 @@ test button-1.2 {configuration option: "activebackground" for label} -setup { .l configure -activebackground non-existent } -cleanup { destroy .l -} -returnCodes {error} -result {unknown color name "non-existent"} +} -returnCodes error -result {unknown color name "non-existent"} test button-1.3 {configuration option: "activebackground" for button} -setup { button .b -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .b @@ -54,7 +54,7 @@ test button-1.4 {configuration option: "activebackground" for button} -setup { .b configure -activebackground non-existent } -cleanup { destroy .b -} -returnCodes {error} -result {unknown color name "non-existent"} +} -returnCodes error -result {unknown color name "non-existent"} test button-1.5 {configuration option: "activebackground" for checkbutton} -setup { checkbutton .c -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .c @@ -73,7 +73,7 @@ test button-1.6 {configuration option: "activebackground" for checkbutton} -setu .c configure -activebackground non-existent } -cleanup { destroy .c -} -returnCodes {error} -result {unknown color name "non-existent"} +} -returnCodes error -result {unknown color name "non-existent"} test button-1.7 {configuration option: "activebackground" for radiobutton} -setup { radiobutton .r -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .r @@ -92,7 +92,7 @@ test button-1.8 {configuration option: "activebackground" for radiobutton} -setu .r configure -activebackground non-existent } -cleanup { destroy .r -} -returnCodes {error} -result {unknown color name "non-existent"} +} -returnCodes error -result {unknown color name "non-existent"} test button-1.9 {configuration option: "activeforeground" for label} -setup { label .l -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} @@ -112,7 +112,7 @@ test button-1.10 {configuration option: "activeforeground" for label} -setup { .l configure -activeforeground non-existent } -cleanup { destroy .l -} -returnCodes {error} -result {unknown color name "non-existent"} +} -returnCodes error -result {unknown color name "non-existent"} test button-1.11 {configuration option: "activeforeground" for button} -setup { button .b -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .b @@ -131,7 +131,7 @@ test button-1.12 {configuration option: "activeforeground" for button} -setup { .b configure -activeforeground non-existent } -cleanup { destroy .b -} -returnCodes {error} -result {unknown color name "non-existent"} +} -returnCodes error -result {unknown color name "non-existent"} test button-1.13 {configuration option: "activeforeground" for checkbutton} -setup { checkbutton .c -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .c @@ -150,7 +150,7 @@ test button-1.14 {configuration option: "activeforeground" for checkbutton} -set .c configure -activeforeground non-existent } -cleanup { destroy .c -} -returnCodes {error} -result {unknown color name "non-existent"} +} -returnCodes error -result {unknown color name "non-existent"} test button-1.15 {configuration option: "activeforeground" for radiobutton} -setup { radiobutton .r -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .r @@ -169,7 +169,7 @@ test button-1.16 {configuration option: "activeforeground" for radiobutton} -set .r configure -activeforeground non-existent } -cleanup { destroy .r -} -returnCodes {error} -result {unknown color name "non-existent"} +} -returnCodes error -result {unknown color name "non-existent"} test button-1.17 {configuration option: "anchor" for label} -setup { label .l -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} @@ -189,7 +189,7 @@ test button-1.18 {configuration option: "anchor" for label} -setup { .l configure -anchor bogus } -cleanup { destroy .l -} -returnCodes {error} -result {bad anchor "bogus": must be n, ne, e, se, s, sw, w, nw, or center} +} -returnCodes error -result {bad anchor "bogus": must be n, ne, e, se, s, sw, w, nw, or center} test button-1.19 {configuration option: "anchor" for button} -setup { button .b -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .b @@ -208,7 +208,7 @@ test button-1.20 {configuration option: "anchor" for button} -setup { .b configure -anchor bogus } -cleanup { destroy .b -} -returnCodes {error} -result {bad anchor "bogus": must be n, ne, e, se, s, sw, w, nw, or center} +} -returnCodes error -result {bad anchor "bogus": must be n, ne, e, se, s, sw, w, nw, or center} test button-1.21 {configuration option: "anchor" for checkbutton} -setup { checkbutton .c -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .c @@ -227,7 +227,7 @@ test button-1.22 {configuration option: "anchor" for checkbutton} -setup { .c configure -anchor bogus } -cleanup { destroy .c -} -returnCodes {error} -result {bad anchor "bogus": must be n, ne, e, se, s, sw, w, nw, or center} +} -returnCodes error -result {bad anchor "bogus": must be n, ne, e, se, s, sw, w, nw, or center} test button-1.23 {configuration option: "anchor" for radiobutton} -setup { radiobutton .r -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .r @@ -246,7 +246,7 @@ test button-1.24 {configuration option: "anchor" for radiobutton} -setup { .r configure -anchor bogus } -cleanup { destroy .r -} -returnCodes {error} -result {bad anchor "bogus": must be n, ne, e, se, s, sw, w, nw, or center} +} -returnCodes error -result {bad anchor "bogus": must be n, ne, e, se, s, sw, w, nw, or center} test button-1.25 {configuration option: "background" for label} -setup { label .l -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} @@ -266,7 +266,7 @@ test button-1.26 {configuration option: "background" for label} -setup { .l configure -background non-existent } -cleanup { destroy .l -} -returnCodes {error} -result {unknown color name "non-existent"} +} -returnCodes error -result {unknown color name "non-existent"} test button-1.27 {configuration option: "background" for button} -setup { button .b -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .b @@ -285,7 +285,7 @@ test button-1.28 {configuration option: "background" for button} -setup { .b configure -background non-existent } -cleanup { destroy .b -} -returnCodes {error} -result {unknown color name "non-existent"} +} -returnCodes error -result {unknown color name "non-existent"} test button-1.29 {configuration option: "background" for checkbutton} -setup { checkbutton .c -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .c @@ -304,7 +304,7 @@ test button-1.30 {configuration option: "background" for checkbutton} -setup { .c configure -background non-existent } -cleanup { destroy .c -} -returnCodes {error} -result {unknown color name "non-existent"} +} -returnCodes error -result {unknown color name "non-existent"} test button-1.31 {configuration option: "background" for radiobutton} -setup { radiobutton .r -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .r @@ -323,7 +323,7 @@ test button-1.32 {configuration option: "background" for radiobutton} -setup { .r configure -background non-existent } -cleanup { destroy .r -} -returnCodes {error} -result {unknown color name "non-existent"} +} -returnCodes error -result {unknown color name "non-existent"} test button-1.33 {configuration option: "bd" for label} -setup { label .l -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} @@ -343,7 +343,7 @@ test button-1.34 {configuration option: "bd" for label} -setup { .l configure -bd badValue } -cleanup { destroy .l -} -returnCodes {error} -result {bad screen distance "badValue"} +} -returnCodes error -result {bad screen distance "badValue"} test button-1.35 {configuration option: "bd" for button} -setup { button .b -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .b @@ -362,7 +362,7 @@ test button-1.36 {configuration option: "bd" for button} -setup { .b configure -bd badValue } -cleanup { destroy .b -} -returnCodes {error} -result {bad screen distance "badValue"} +} -returnCodes error -result {bad screen distance "badValue"} test button-1.37 {configuration option: "bd" for checkbutton} -setup { checkbutton .c -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .c @@ -381,7 +381,7 @@ test button-1.38 {configuration option: "bd" for checkbutton} -setup { .c configure -bd badValue } -cleanup { destroy .c -} -returnCodes {error} -result {bad screen distance "badValue"} +} -returnCodes error -result {bad screen distance "badValue"} test button-1.39 {configuration option: "bd" for radiobutton} -setup { radiobutton .r -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .r @@ -400,7 +400,7 @@ test button-1.40 {configuration option: "bd" for radiobutton} -setup { .r configure -bd badValue } -cleanup { destroy .r -} -returnCodes {error} -result {bad screen distance "badValue"} +} -returnCodes error -result {bad screen distance "badValue"} test button-1.41 {configuration option: "bg" for label} -setup { label .l -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} @@ -420,7 +420,7 @@ test button-1.42 {configuration option: "bg" for label} -setup { .l configure -bg non-existent } -cleanup { destroy .l -} -returnCodes {error} -result {unknown color name "non-existent"} +} -returnCodes error -result {unknown color name "non-existent"} test button-1.43 {configuration option: "bg" for button} -setup { button .b -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .b @@ -439,7 +439,7 @@ test button-1.44 {configuration option: "bg" for button} -setup { .b configure -bg non-existent } -cleanup { destroy .b -} -returnCodes {error} -result {unknown color name "non-existent"} +} -returnCodes error -result {unknown color name "non-existent"} test button-1.45 {configuration option: "bg" for checkbutton} -setup { checkbutton .c -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .c @@ -458,7 +458,7 @@ test button-1.46 {configuration option: "bg" for checkbutton} -setup { .c configure -bg non-existent } -cleanup { destroy .c -} -returnCodes {error} -result {unknown color name "non-existent"} +} -returnCodes error -result {unknown color name "non-existent"} test button-1.47 {configuration option: "bg" for radiobutton} -setup { radiobutton .r -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .r @@ -477,7 +477,7 @@ test button-1.48 {configuration option: "bg" for radiobutton} -setup { .r configure -bg non-existent } -cleanup { destroy .r -} -returnCodes {error} -result {unknown color name "non-existent"} +} -returnCodes error -result {unknown color name "non-existent"} test button-1.49 {configuration option: "bitmap" for label} -setup { label .l -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} @@ -497,7 +497,7 @@ test button-1.50 {configuration option: "bitmap" for label} -setup { .l configure -bitmap badValue } -cleanup { destroy .l -} -returnCodes {error} -result {bitmap "badValue" not defined} +} -returnCodes error -result {bitmap "badValue" not defined} test button-1.51 {configuration option: "bitmap" for button} -setup { button .b -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .b @@ -516,7 +516,7 @@ test button-1.52 {configuration option: "bitmap" for button} -setup { .b configure -bitmap badValue } -cleanup { destroy .b -} -returnCodes {error} -result {bitmap "badValue" not defined} +} -returnCodes error -result {bitmap "badValue" not defined} test button-1.53 {configuration option: "bitmap" for checkbutton} -setup { checkbutton .c -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .c @@ -535,7 +535,7 @@ test button-1.54 {configuration option: "bitmap" for checkbutton} -setup { .c configure -bitmap badValue } -cleanup { destroy .c -} -returnCodes {error} -result {bitmap "badValue" not defined} +} -returnCodes error -result {bitmap "badValue" not defined} test button-1.55 {configuration option: "bitmap" for radiobutton} -setup { radiobutton .r -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .r @@ -554,7 +554,7 @@ test button-1.56 {configuration option: "bitmap" for radiobutton} -setup { .r configure -bitmap badValue } -cleanup { destroy .r -} -returnCodes {error} -result {bitmap "badValue" not defined} +} -returnCodes error -result {bitmap "badValue" not defined} test button-1.57 {configuration option: "borderwidth" for label} -setup { label .l -highlightthickness 2 -font {Helvetica -12 bold} @@ -574,7 +574,7 @@ test button-1.58 {configuration option: "borderwidth" for label} -setup { .l configure -borderwidth badValue } -cleanup { destroy .l -} -returnCodes {error} -result {bad screen distance "badValue"} +} -returnCodes error -result {bad screen distance "badValue"} test button-1.59 {configuration option: "borderwidth" for button} -setup { button .b -highlightthickness 2 -font {Helvetica -12 bold} pack .b @@ -593,7 +593,7 @@ test button-1.60 {configuration option: "borderwidth" for button} -setup { .b configure -borderwidth badValue } -cleanup { destroy .b -} -returnCodes {error} -result {bad screen distance "badValue"} +} -returnCodes error -result {bad screen distance "badValue"} test button-1.61 {configuration option: "borderwidth" for checkbutton} -setup { checkbutton .c -highlightthickness 2 -font {Helvetica -12 bold} pack .c @@ -612,7 +612,7 @@ test button-1.62 {configuration option: "borderwidth" for checkbutton} -setup { .c configure -borderwidth badValue } -cleanup { destroy .c -} -returnCodes {error} -result {bad screen distance "badValue"} +} -returnCodes error -result {bad screen distance "badValue"} test button-1.63 {configuration option: "borderwidth" for radiobutton} -setup { radiobutton .r -highlightthickness 2 -font {Helvetica -12 bold} pack .r @@ -631,7 +631,7 @@ test button-1.64 {configuration option: "borderwidth" for radiobutton} -setup { .r configure -borderwidth badValue } -cleanup { destroy .r -} -returnCodes {error} -result {bad screen distance "badValue"} +} -returnCodes error -result {bad screen distance "badValue"} test button-1.65 {configuration option: "command" for button} -setup { button .b -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} @@ -692,7 +692,7 @@ test button-1.70 {configuration option: "compound" for label} -setup { .l configure -compound bogus } -cleanup { destroy .l -} -returnCodes {error} -result {bad compound "bogus": must be bottom, center, left, none, right, or top} +} -returnCodes error -result {bad compound "bogus": must be bottom, center, left, none, right, or top} test button-1.71 {configuration option: "compound" for button} -setup { button .b -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .b @@ -711,7 +711,7 @@ test button-1.72 {configuration option: "compound" for button} -setup { .b configure -compound bogus } -cleanup { destroy .b -} -returnCodes {error} -result {bad compound "bogus": must be bottom, center, left, none, right, or top} +} -returnCodes error -result {bad compound "bogus": must be bottom, center, left, none, right, or top} test button-1.73 {configuration option: "compound" for checkbutton} -setup { checkbutton .c -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .c @@ -730,7 +730,7 @@ test button-1.74 {configuration option: "compound" for checkbutton} -setup { .c configure -compound bogus } -cleanup { destroy .c -} -returnCodes {error} -result {bad compound "bogus": must be bottom, center, left, none, right, or top} +} -returnCodes error -result {bad compound "bogus": must be bottom, center, left, none, right, or top} test button-1.75 {configuration option: "compound" for radiobutton} -setup { radiobutton .r -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .r @@ -749,7 +749,7 @@ test button-1.76 {configuration option: "compound" for radiobutton} -setup { .r configure -compound bogus } -cleanup { destroy .r -} -returnCodes {error} -result {bad compound "bogus": must be bottom, center, left, none, right, or top} +} -returnCodes error -result {bad compound "bogus": must be bottom, center, left, none, right, or top} test button-1.77 {configuration option: "cursor" for label} -setup { label .l -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} @@ -769,7 +769,7 @@ test button-1.78 {configuration option: "cursor" for label} -setup { .l configure -cursor badValue } -cleanup { destroy .l -} -returnCodes {error} -result {bad cursor spec "badValue"} +} -returnCodes error -result {bad cursor spec "badValue"} test button-1.79 {configuration option: "cursor" for button} -setup { button .b -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .b @@ -788,7 +788,7 @@ test button-1.80 {configuration option: "cursor" for button} -setup { .b configure -cursor badValue } -cleanup { destroy .b -} -returnCodes {error} -result {bad cursor spec "badValue"} +} -returnCodes error -result {bad cursor spec "badValue"} test button-1.81 {configuration option: "cursor" for checkbutton} -setup { checkbutton .c -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .c @@ -807,7 +807,7 @@ test button-1.82 {configuration option: "cursor" for checkbutton} -setup { .c configure -cursor badValue } -cleanup { destroy .c -} -returnCodes {error} -result {bad cursor spec "badValue"} +} -returnCodes error -result {bad cursor spec "badValue"} test button-1.83 {configuration option: "cursor" for radiobutton} -setup { radiobutton .r -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .r @@ -826,7 +826,7 @@ test button-1.84 {configuration option: "cursor" for radiobutton} -setup { .r configure -cursor badValue } -cleanup { destroy .r -} -returnCodes {error} -result {bad cursor spec "badValue"} +} -returnCodes error -result {bad cursor spec "badValue"} test button-1.85 {configuration option: "default" for button} -setup { button .b -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} @@ -846,7 +846,7 @@ test button-1.86 {configuration option: "default" for button} -setup { .b configure -default huh? } -cleanup { destroy .b -} -returnCodes {error} -result {bad default "huh?": must be active, disabled, or normal} +} -returnCodes error -result {bad default "huh?": must be active, disabled, or normal} test button-1.87 {configuration option: "disabledforeground" for label} -setup { label .l -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} @@ -866,7 +866,7 @@ test button-1.88 {configuration option: "disabledforeground" for label} -setup { .l configure -disabledforeground non-existent } -cleanup { destroy .l -} -returnCodes {error} -result {unknown color name "non-existent"} +} -returnCodes error -result {unknown color name "non-existent"} test button-1.89 {configuration option: "disabledforeground" for button} -setup { button .b -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .b @@ -885,7 +885,7 @@ test button-1.90 {configuration option: "disabledforeground" for button} -setup .b configure -disabledforeground non-existent } -cleanup { destroy .b -} -returnCodes {error} -result {unknown color name "non-existent"} +} -returnCodes error -result {unknown color name "non-existent"} test button-1.91 {configuration option: "disabledforeground" for checkbutton} -setup { checkbutton .c -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .c @@ -904,7 +904,7 @@ test button-1.92 {configuration option: "disabledforeground" for checkbutton} -s .c configure -disabledforeground non-existent } -cleanup { destroy .c -} -returnCodes {error} -result {unknown color name "non-existent"} +} -returnCodes error -result {unknown color name "non-existent"} test button-1.93 {configuration option: "disabledforeground" for radiobutton} -setup { radiobutton .r -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .r @@ -923,7 +923,7 @@ test button-1.94 {configuration option: "disabledforeground" for radiobutton} -s .r configure -disabledforeground non-existent } -cleanup { destroy .r -} -returnCodes {error} -result {unknown color name "non-existent"} +} -returnCodes error -result {unknown color name "non-existent"} test button-1.95 {configuration option: "fg" for label} -setup { label .l -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} @@ -943,7 +943,7 @@ test button-1.96 {configuration option: "fg" for label} -setup { .l configure -fg non-existent } -cleanup { destroy .l -} -returnCodes {error} -result {unknown color name "non-existent"} +} -returnCodes error -result {unknown color name "non-existent"} test button-1.97 {configuration option: "fg" for button} -setup { button .b -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .b @@ -962,7 +962,7 @@ test button-1.98 {configuration option: "fg" for button} -setup { .b configure -fg non-existent } -cleanup { destroy .b -} -returnCodes {error} -result {unknown color name "non-existent"} +} -returnCodes error -result {unknown color name "non-existent"} test button-1.99 {configuration option: "fg" for checkbutton} -setup { checkbutton .c -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .c @@ -981,7 +981,7 @@ test button-1.100 {configuration option: "fg" for checkbutton} -setup { .c configure -fg non-existent } -cleanup { destroy .c -} -returnCodes {error} -result {unknown color name "non-existent"} +} -returnCodes error -result {unknown color name "non-existent"} test button-1.101 {configuration option: "fg" for radiobutton} -setup { radiobutton .r -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .r @@ -1000,7 +1000,7 @@ test button-1.102 {configuration option: "fg" for radiobutton} -setup { .r configure -fg non-existent } -cleanup { destroy .r -} -returnCodes {error} -result {unknown color name "non-existent"} +} -returnCodes error -result {unknown color name "non-existent"} test button-1.103 {configuration option: "font" for label} -setup { label .l -borderwidth 2 -highlightthickness 2 @@ -1020,7 +1020,7 @@ test button-1.104 {configuration option: "activebackground" for label} -setup { .l configure -font {} } -cleanup { destroy .l -} -returnCodes {error} -result {font "" doesn't exist} +} -returnCodes error -result {font "" doesn't exist} test button-1.105 {configuration option: "font" for button} -setup { button .b -borderwidth 2 -highlightthickness 2 pack .b @@ -1039,7 +1039,7 @@ test button-1.106 {configuration option: "activebackground" for button} -setup { .b configure -font {} } -cleanup { destroy .b -} -returnCodes {error} -result {font "" doesn't exist} +} -returnCodes error -result {font "" doesn't exist} test button-1.107 {configuration option: "font" for checkbutton} -setup { checkbutton .c -borderwidth 2 -highlightthickness 2 pack .c @@ -1058,7 +1058,7 @@ test button-1.108 {configuration option: "activebackground" for checkbutton} -se .c configure -font {} } -cleanup { destroy .c -} -returnCodes {error} -result {font "" doesn't exist} +} -returnCodes error -result {font "" doesn't exist} test button-1.109 {configuration option: "font" for radiobutton} -setup { radiobutton .r -borderwidth 2 -highlightthickness 2 pack .r @@ -1077,7 +1077,7 @@ test button-1.110 {configuration option: "activebackground" for radiobutton} -se .r configure -font {} } -cleanup { destroy .r -} -returnCodes {error} -result {font "" doesn't exist} +} -returnCodes error -result {font "" doesn't exist} test button-1.111 {configuration option: "foreground" for label} -setup { label .l -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} @@ -1097,7 +1097,7 @@ test button-1.112 {configuration option: "foreground" for label} -setup { .l configure -foreground non-existent } -cleanup { destroy .l -} -returnCodes {error} -result {unknown color name "non-existent"} +} -returnCodes error -result {unknown color name "non-existent"} test button-1.113 {configuration option: "foreground" for button} -setup { button .b -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .b @@ -1116,7 +1116,7 @@ test button-1.114 {configuration option: "foreground" for button} -setup { .b configure -foreground non-existent } -cleanup { destroy .b -} -returnCodes {error} -result {unknown color name "non-existent"} +} -returnCodes error -result {unknown color name "non-existent"} test button-1.115 {configuration option: "foreground" for checkbutton} -setup { checkbutton .c -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .c @@ -1135,7 +1135,7 @@ test button-1.116 {configuration option: "foreground" for checkbutton} -setup { .c configure -foreground non-existent } -cleanup { destroy .c -} -returnCodes {error} -result {unknown color name "non-existent"} +} -returnCodes error -result {unknown color name "non-existent"} test button-1.117 {configuration option: "foreground" for radiobutton} -setup { radiobutton .r -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .r @@ -1154,7 +1154,7 @@ test button-1.118 {configuration option: "foreground" for radiobutton} -setup { .r configure -foreground non-existent } -cleanup { destroy .r -} -returnCodes {error} -result {unknown color name "non-existent"} +} -returnCodes error -result {unknown color name "non-existent"} test button-1.119 {configuration option: "height" for label} -setup { label .l -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} @@ -1174,7 +1174,7 @@ test button-1.120 {configuration option: "height" for label} -setup { .l configure -height 20.0 } -cleanup { destroy .l -} -returnCodes {error} -result {expected integer but got "20.0"} +} -returnCodes error -result {expected integer but got "20.0"} test button-1.121 {configuration option: "height" for button} -setup { button .b -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .b @@ -1193,7 +1193,7 @@ test button-1.122 {configuration option: "height" for button} -setup { .b configure -height 20.0 } -cleanup { destroy .b -} -returnCodes {error} -result {expected integer but got "20.0"} +} -returnCodes error -result {expected integer but got "20.0"} test button-1.123 {configuration option: "height" for checkbutton} -setup { checkbutton .c -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .c @@ -1212,7 +1212,7 @@ test button-1.124 {configuration option: "height" for checkbutton} -setup { .c configure -height 20.0 } -cleanup { destroy .c -} -returnCodes {error} -result {expected integer but got "20.0"} +} -returnCodes error -result {expected integer but got "20.0"} test button-1.125 {configuration option: "height" for radiobutton} -setup { radiobutton .r -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .r @@ -1231,7 +1231,7 @@ test button-1.126 {configuration option: "height" for radiobutton} -setup { .r configure -height 20.0 } -cleanup { destroy .r -} -returnCodes {error} -result {expected integer but got "20.0"} +} -returnCodes error -result {expected integer but got "20.0"} test button-1.127 {configuration option: "highlightbackground" for label} -setup { label .l -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} @@ -1251,7 +1251,7 @@ test button-1.128 {configuration option: "highlightbackground" for label} -setup .l configure -highlightbackground non-existent } -cleanup { destroy .l -} -returnCodes {error} -result {unknown color name "non-existent"} +} -returnCodes error -result {unknown color name "non-existent"} test button-1.129 {configuration option: "highlightbackground" for button} -setup { button .b -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .b @@ -1270,7 +1270,7 @@ test button-1.130 {configuration option: "highlightbackground" for button} -setu .b configure -highlightbackground non-existent } -cleanup { destroy .b -} -returnCodes {error} -result {unknown color name "non-existent"} +} -returnCodes error -result {unknown color name "non-existent"} test button-1.131 {configuration option: "highlightbackground" for checkbutton} -setup { checkbutton .c -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .c @@ -1289,7 +1289,7 @@ test button-1.132 {configuration option: "highlightbackground" for checkbutton} .c configure -highlightbackground non-existent } -cleanup { destroy .c -} -returnCodes {error} -result {unknown color name "non-existent"} +} -returnCodes error -result {unknown color name "non-existent"} test button-1.133 {configuration option: "highlightbackground" for radiobutton} -setup { radiobutton .r -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .r @@ -1308,7 +1308,7 @@ test button-1.134 {configuration option: "highlightbackground" for radiobutton} .r configure -highlightbackground non-existent } -cleanup { destroy .r -} -returnCodes {error} -result {unknown color name "non-existent"} +} -returnCodes error -result {unknown color name "non-existent"} test button-1.135 {configuration option: "highlightcolor" for label} -setup { label .l -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} @@ -1328,7 +1328,7 @@ test button-1.136 {configuration option: "highlightcolor" for label} -setup { .l configure -highlightcolor non-existent } -cleanup { destroy .l -} -returnCodes {error} -result {unknown color name "non-existent"} +} -returnCodes error -result {unknown color name "non-existent"} test button-1.137 {configuration option: "highlightcolor" for button} -setup { button .b -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .b @@ -1347,7 +1347,7 @@ test button-1.138 {configuration option: "highlightcolor" for button} -setup { .b configure -highlightcolor non-existent } -cleanup { destroy .b -} -returnCodes {error} -result {unknown color name "non-existent"} +} -returnCodes error -result {unknown color name "non-existent"} test button-1.139 {configuration option: "highlightcolor" for checkbutton} -setup { checkbutton .c -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .c @@ -1366,7 +1366,7 @@ test button-1.140 {configuration option: "highlightcolor" for checkbutton} -setu .c configure -highlightcolor non-existent } -cleanup { destroy .c -} -returnCodes {error} -result {unknown color name "non-existent"} +} -returnCodes error -result {unknown color name "non-existent"} test button-1.141 {configuration option: "highlightcolor" for radiobutton} -setup { radiobutton .r -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .r @@ -1385,7 +1385,7 @@ test button-1.142 {configuration option: "highlightcolor" for radiobutton} -setu .r configure -highlightcolor non-existent } -cleanup { destroy .r -} -returnCodes {error} -result {unknown color name "non-existent"} +} -returnCodes error -result {unknown color name "non-existent"} test button-1.143 {configuration option: "highlightthickness" for label} -setup { label .l -borderwidth 2 -font {Helvetica -12 bold} @@ -1405,7 +1405,7 @@ test button-1.144 {configuration option: "highlightthickness" for label} -setup .l configure -highlightthickness badValue } -cleanup { destroy .l -} -returnCodes {error} -result {bad screen distance "badValue"} +} -returnCodes error -result {bad screen distance "badValue"} test button-1.145 {configuration option: "highlightthickness" for button} -setup { button .b -borderwidth 2 -font {Helvetica -12 bold} pack .b @@ -1424,7 +1424,7 @@ test button-1.146 {configuration option: "highlightthickness" for button} -setup .b configure -highlightthickness badValue } -cleanup { destroy .b -} -returnCodes {error} -result {bad screen distance "badValue"} +} -returnCodes error -result {bad screen distance "badValue"} test button-1.147 {configuration option: "highlightthickness" for checkbutton} -setup { checkbutton .c -borderwidth 2 -font {Helvetica -12 bold} pack .c @@ -1443,7 +1443,7 @@ test button-1.148 {configuration option: "highlightthickness" for checkbutton} - .c configure -highlightthickness badValue } -cleanup { destroy .c -} -returnCodes {error} -result {bad screen distance "badValue"} +} -returnCodes error -result {bad screen distance "badValue"} test button-1.149 {configuration option: "highlightthickness" for radiobutton} -setup { radiobutton .r -borderwidth 2 -font {Helvetica -12 bold} pack .r @@ -1462,7 +1462,7 @@ test button-1.150 {configuration option: "highlightthickness" for radiobutton} - .r configure -highlightthickness badValue } -cleanup { destroy .r -} -returnCodes {error} -result {bad screen distance "badValue"} +} -returnCodes error -result {bad screen distance "badValue"} test button-1.151 {configuration option: "image" for label} -constraints { testImageType @@ -1486,7 +1486,7 @@ test button-1.152 {configuration option: "image" for label} -setup { .l configure -image bogus } -cleanup { destroy .l -} -returnCodes {error} -result {image "bogus" doesn't exist} +} -returnCodes error -result {image "bogus" doesn't exist} test button-1.153 {configuration option: "image" for button} -constraints { testImageType } -setup { @@ -1509,7 +1509,7 @@ test button-1.154 {configuration option: "image" for button} -setup { .b configure -image bogus } -cleanup { destroy .b -} -returnCodes {error} -result {image "bogus" doesn't exist} +} -returnCodes error -result {image "bogus" doesn't exist} test button-1.155 {configuration option: "image" for checkbutton} -constraints { testImageType } -setup { @@ -1532,7 +1532,7 @@ test button-1.156 {configuration option: "image" for checkbutton} -setup { .c configure -image bogus } -cleanup { destroy .c -} -returnCodes {error} -result {image "bogus" doesn't exist} +} -returnCodes error -result {image "bogus" doesn't exist} test button-1.157 {configuration option: "image" for radiobutton} -constraints { testImageType } -setup { @@ -1555,7 +1555,7 @@ test button-1.158 {configuration option: "image" for radiobutton} -setup { .r configure -image bogus } -cleanup { destroy .r -} -returnCodes {error} -result {image "bogus" doesn't exist} +} -returnCodes error -result {image "bogus" doesn't exist} test button-1.159 {configuration option: "indicatoron" for checkbutton} -setup { checkbutton .c -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} @@ -1575,7 +1575,7 @@ test button-1.160 {configuration option: "indicatoron" for checkbutton} -setup { .c configure -indicatoron no_way } -cleanup { destroy .c -} -returnCodes {error} -result {expected boolean value but got "no_way"} +} -returnCodes error -result {expected boolean value but got "no_way"} test button-1.161 {configuration option: "indicatoron" for radiobutton} -setup { radiobutton .r -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .r @@ -1594,7 +1594,7 @@ test button-1.162 {configuration option: "indicatoron" for radiobutton} -setup { .r configure -indicatoron no_way } -cleanup { destroy .r -} -returnCodes {error} -result {expected boolean value but got "no_way"} +} -returnCodes error -result {expected boolean value but got "no_way"} test button-1.163 {configuration option: "justify" for label} -setup { label .l -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} @@ -1614,7 +1614,7 @@ test button-1.164 {configuration option: "justify" for label} -setup { .l configure -justify bogus } -cleanup { destroy .l -} -returnCodes {error} -result {bad justification "bogus": must be left, right, or center} +} -returnCodes error -result {bad justification "bogus": must be left, right, or center} test button-1.165 {configuration option: "justify" for button} -setup { button .b -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .b @@ -1633,7 +1633,7 @@ test button-1.166 {configuration option: "justify" for button} -setup { .b configure -justify bogus } -cleanup { destroy .b -} -returnCodes {error} -result {bad justification "bogus": must be left, right, or center} +} -returnCodes error -result {bad justification "bogus": must be left, right, or center} test button-1.167 {configuration option: "justify" for checkbutton} -setup { checkbutton .c -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .c @@ -1652,7 +1652,7 @@ test button-1.168 {configuration option: "justify" for checkbutton} -setup { .c configure -justify bogus } -cleanup { destroy .c -} -returnCodes {error} -result {bad justification "bogus": must be left, right, or center} +} -returnCodes error -result {bad justification "bogus": must be left, right, or center} test button-1.169 {configuration option: "justify" for radiobutton} -setup { radiobutton .r -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .r @@ -1671,7 +1671,7 @@ test button-1.170 {configuration option: "justify" for radiobutton} -setup { .r configure -justify bogus } -cleanup { destroy .r -} -returnCodes {error} -result {bad justification "bogus": must be left, right, or center} +} -returnCodes error -result {bad justification "bogus": must be left, right, or center} test button-1.171 {configuration option: "offrelief" for checkbutton} -setup { checkbutton .c -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} @@ -1691,7 +1691,7 @@ test button-1.172 {configuration option: "offrelief" for checkbutton} -setup { .c configure -offrelief 1.5 } -cleanup { destroy .c -} -returnCodes {error} -result {bad relief "1.5": must be flat, groove, raised, ridge, solid, or sunken} +} -returnCodes error -result {bad relief "1.5": must be flat, groove, raised, ridge, solid, or sunken} test button-1.173 {configuration option: "offrelief" for radiobutton} -setup { radiobutton .r -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .r @@ -1710,7 +1710,7 @@ test button-1.174 {configuration option: "offrelief" for radiobutton} -setup { .r configure -offrelief 1.5 } -cleanup { destroy .r -} -returnCodes {error} -result {bad relief "1.5": must be flat, groove, raised, ridge, solid, or sunken} +} -returnCodes error -result {bad relief "1.5": must be flat, groove, raised, ridge, solid, or sunken} test button-1.175 {configuration option: "offvalue" for checkbutton} -setup { checkbutton .c -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} @@ -1752,7 +1752,7 @@ test button-1.178 {configuration option: "overrelief" for button} -setup { .b configure -overrelief 1.5 } -cleanup { destroy .b -} -returnCodes {error} -result {bad relief "1.5": must be flat, groove, raised, ridge, solid, or sunken} +} -returnCodes error -result {bad relief "1.5": must be flat, groove, raised, ridge, solid, or sunken} test button-1.179 {configuration option: "overrelief" for checkbutton} -setup { checkbutton .c -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .c @@ -1771,7 +1771,7 @@ test button-1.180 {configuration option: "overrelief" for checkbutton} -setup { .c configure -overrelief 1.5 } -cleanup { destroy .c -} -returnCodes {error} -result {bad relief "1.5": must be flat, groove, raised, ridge, solid, or sunken} +} -returnCodes error -result {bad relief "1.5": must be flat, groove, raised, ridge, solid, or sunken} test button-1.181 {configuration option: "overrelief" for radiobutton} -setup { radiobutton .r -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .r @@ -1790,7 +1790,7 @@ test button-1.182 {configuration option: "overrelief" for radiobutton} -setup { .r configure -overrelief 1.5 } -cleanup { destroy .r -} -returnCodes {error} -result {bad relief "1.5": must be flat, groove, raised, ridge, solid, or sunken} +} -returnCodes error -result {bad relief "1.5": must be flat, groove, raised, ridge, solid, or sunken} test button-1.183 {configuration option: "padx" for label} -setup { label .l -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} @@ -1810,7 +1810,7 @@ test button-1.184 {configuration option: "padx" for label} -setup { .l configure -padx 420x } -cleanup { destroy .l -} -returnCodes {error} -result {bad screen distance "420x"} +} -returnCodes error -result {bad screen distance "420x"} test button-1.185 {configuration option: "padx" for button} -setup { button .b -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .b @@ -1829,7 +1829,7 @@ test button-1.186 {configuration option: "padx" for button} -setup { .b configure -padx 420x } -cleanup { destroy .b -} -returnCodes {error} -result {bad screen distance "420x"} +} -returnCodes error -result {bad screen distance "420x"} test button-1.187 {configuration option: "padx" for checkbutton} -setup { checkbutton .c -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .c @@ -1848,7 +1848,7 @@ test button-1.188 {configuration option: "padx" for checkbutton} -setup { .c configure -padx 420x } -cleanup { destroy .c -} -returnCodes {error} -result {bad screen distance "420x"} +} -returnCodes error -result {bad screen distance "420x"} test button-1.189 {configuration option: "padx" for radiobutton} -setup { radiobutton .r -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .r @@ -1867,7 +1867,7 @@ test button-1.190 {configuration option: "padx" for radiobutton} -setup { .r configure -padx 420x } -cleanup { destroy .r -} -returnCodes {error} -result {bad screen distance "420x"} +} -returnCodes error -result {bad screen distance "420x"} test button-1.191 {configuration option: "pady" for label} -setup { label .l -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} @@ -1887,7 +1887,7 @@ test button-1.192 {configuration option: "pady" for label} -setup { .l configure -pady 420x } -cleanup { destroy .l -} -returnCodes {error} -result {bad screen distance "420x"} +} -returnCodes error -result {bad screen distance "420x"} test button-1.193 {configuration option: "pady" for button} -setup { button .b -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .b @@ -1906,7 +1906,7 @@ test button-1.194 {configuration option: "pady" for button} -setup { .b configure -pady 420x } -cleanup { destroy .b -} -returnCodes {error} -result {bad screen distance "420x"} +} -returnCodes error -result {bad screen distance "420x"} test button-1.195 {configuration option: "pady" for checkbutton} -setup { checkbutton .c -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .c @@ -1925,7 +1925,7 @@ test button-1.196 {configuration option: "pady" for checkbutton} -setup { .c configure -pady 420x } -cleanup { destroy .c -} -returnCodes {error} -result {bad screen distance "420x"} +} -returnCodes error -result {bad screen distance "420x"} test button-1.197 {configuration option: "pady" for radiobutton} -setup { radiobutton .r -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .r @@ -1944,7 +1944,7 @@ test button-1.198 {configuration option: "pady" for radiobutton} -setup { .r configure -pady 420x } -cleanup { destroy .r -} -returnCodes {error} -result {bad screen distance "420x"} +} -returnCodes error -result {bad screen distance "420x"} test button-1.199 {configuration option: "repeatdelay" for button} -setup { button .b -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} @@ -1964,7 +1964,7 @@ test button-1.200 {configuration option: "repeatdelay" for button} -setup { .b configure -repeatdelay foo } -cleanup { destroy .b -} -returnCodes {error} -result {expected integer but got "foo"} +} -returnCodes error -result {expected integer but got "foo"} test button-1.201 {configuration option: "repeatinterval" for button} -setup { button .b -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} @@ -1984,7 +1984,7 @@ test button-1.202 {configuration option: "repeatinterval" for button} -setup { .b configure -repeatinterval foo } -cleanup { destroy .b -} -returnCodes {error} -result {expected integer but got "foo"} +} -returnCodes error -result {expected integer but got "foo"} test button-1.203 {configuration option: "relief" for label} -setup { label .l -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} @@ -2004,7 +2004,7 @@ test button-1.204 {configuration option: "relief" for label} -setup { .l configure -relief 1.5 } -cleanup { destroy .l -} -returnCodes {error} -result {bad relief "1.5": must be flat, groove, raised, ridge, solid, or sunken} +} -returnCodes error -result {bad relief "1.5": must be flat, groove, raised, ridge, solid, or sunken} test button-1.205 {configuration option: "relief" for button} -setup { button .b -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .b @@ -2023,7 +2023,7 @@ test button-1.206 {configuration option: "relief" for button} -setup { .b configure -relief 1.5 } -cleanup { destroy .b -} -returnCodes {error} -result {bad relief "1.5": must be flat, groove, raised, ridge, solid, or sunken} +} -returnCodes error -result {bad relief "1.5": must be flat, groove, raised, ridge, solid, or sunken} test button-1.207 {configuration option: "relief" for checkbutton} -setup { checkbutton .c -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .c @@ -2042,7 +2042,7 @@ test button-1.208 {configuration option: "relief" for checkbutton} -setup { .c configure -relief 1.5 } -cleanup { destroy .c -} -returnCodes {error} -result {bad relief "1.5": must be flat, groove, raised, ridge, solid, or sunken} +} -returnCodes error -result {bad relief "1.5": must be flat, groove, raised, ridge, solid, or sunken} test button-1.209 {configuration option: "relief" for radiobutton} -setup { radiobutton .r -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .r @@ -2061,7 +2061,7 @@ test button-1.210 {configuration option: "relief" for radiobutton} -setup { .r configure -relief 1.5 } -cleanup { destroy .r -} -returnCodes {error} -result {bad relief "1.5": must be flat, groove, raised, ridge, solid, or sunken} +} -returnCodes error -result {bad relief "1.5": must be flat, groove, raised, ridge, solid, or sunken} test button-1.211 {configuration option: "selectcolor" for checkbutton} -setup { checkbutton .c -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} @@ -2081,7 +2081,7 @@ test button-1.212 {configuration option: "selectcolor" for checkbutton} -setup { .c configure -selectcolor non-existent } -cleanup { destroy .c -} -returnCodes {error} -result {unknown color name "non-existent"} +} -returnCodes error -result {unknown color name "non-existent"} test button-1.213 {configuration option: "selectcolor" for radiobutton} -setup { radiobutton .r -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .r @@ -2100,7 +2100,7 @@ test button-1.214 {configuration option: "selectcolor" for radiobutton} -setup { .r configure -selectcolor non-existent } -cleanup { destroy .r -} -returnCodes {error} -result {unknown color name "non-existent"} +} -returnCodes error -result {unknown color name "non-existent"} test button-1.215 {configuration option: "selectimage" for checkbutton} -constraints { testImageType @@ -2124,7 +2124,7 @@ test button-1.216 {configuration option: "selectimage" for checkbutton} -setup { .c configure -selectimage bogus } -cleanup { destroy .c -} -returnCodes {error} -result {image "bogus" doesn't exist} +} -returnCodes error -result {image "bogus" doesn't exist} test button-1.217 {configuration option: "selectimage" for radiobutton} -constraints { testImageType } -setup { @@ -2147,7 +2147,7 @@ test button-1.218 {configuration option: "selectimage" for radiobutton} -setup { .r configure -selectimage bogus } -cleanup { destroy .r -} -returnCodes {error} -result {image "bogus" doesn't exist} +} -returnCodes error -result {image "bogus" doesn't exist} test button-1.219 {configuration option: "state" for label} -setup { label .l -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} @@ -2167,7 +2167,7 @@ test button-1.220 {configuration option: "state" for label} -setup { .l configure -state bogus } -cleanup { destroy .l -} -returnCodes {error} -result {bad state "bogus": must be active, disabled, or normal} +} -returnCodes error -result {bad state "bogus": must be active, disabled, or normal} test button-1.221 {configuration option: "state" for button} -setup { button .b -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .b @@ -2186,7 +2186,7 @@ test button-1.222 {configuration option: "state" for button} -setup { .b configure -state bogus } -cleanup { destroy .b -} -returnCodes {error} -result {bad state "bogus": must be active, disabled, or normal} +} -returnCodes error -result {bad state "bogus": must be active, disabled, or normal} test button-1.223 {configuration option: "state" for checkbutton} -setup { checkbutton .c -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .c @@ -2205,7 +2205,7 @@ test button-1.224 {configuration option: "state" for checkbutton} -setup { .c configure -state bogus } -cleanup { destroy .c -} -returnCodes {error} -result {bad state "bogus": must be active, disabled, or normal} +} -returnCodes error -result {bad state "bogus": must be active, disabled, or normal} test button-1.225 {configuration option: "state" for radiobutton} -setup { radiobutton .r -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .r @@ -2224,7 +2224,7 @@ test button-1.226 {configuration option: "state" for radiobutton} -setup { .r configure -state bogus } -cleanup { destroy .r -} -returnCodes {error} -result {bad state "bogus": must be active, disabled, or normal} +} -returnCodes error -result {bad state "bogus": must be active, disabled, or normal} test button-1.227 {configuration option: "takefocus" for label} -setup { label .l -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} @@ -2371,7 +2371,7 @@ test button-1.240 {configuration option: "tristateimage" for checkbutton} -setup .c configure -tristateimage bogus } -cleanup { destroy .c -} -returnCodes {error} -result {image "bogus" doesn't exist} +} -returnCodes error -result {image "bogus" doesn't exist} test button-1.241 {configuration option: "tristateimage" for radiobutton} -constraints { testImageType } -setup { @@ -2394,7 +2394,7 @@ test button-1.242 {configuration option: "tristateimage" for radiobutton} -setup .r configure -tristateimage bogus } -cleanup { destroy .r -} -returnCodes {error} -result {image "bogus" doesn't exist} +} -returnCodes error -result {image "bogus" doesn't exist} test button-1.243 {configuration option: "underline" for label} -setup { label .l -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} @@ -2414,7 +2414,7 @@ test button-1.244 {configuration option: "underline" for label} -setup { .l configure -underline 3p } -cleanup { destroy .l -} -returnCodes {error} -result {expected integer but got "3p"} +} -returnCodes error -result {expected integer but got "3p"} test button-1.245 {configuration option: "underline" for button} -setup { button .b -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .b @@ -2433,7 +2433,7 @@ test button-1.246 {configuration option: "underline" for button} -setup { .b configure -underline 3p } -cleanup { destroy .b -} -returnCodes {error} -result {expected integer but got "3p"} +} -returnCodes error -result {expected integer but got "3p"} test button-1.247 {configuration option: "underline" for checkbutton} -setup { checkbutton .c -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .c @@ -2452,7 +2452,7 @@ test button-1.248 {configuration option: "underline" for checkbutton} -setup { .c configure -underline 3p } -cleanup { destroy .c -} -returnCodes {error} -result {expected integer but got "3p"} +} -returnCodes error -result {expected integer but got "3p"} test button-1.249 {configuration option: "underline" for radiobutton} -setup { radiobutton .r -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .r @@ -2471,7 +2471,7 @@ test button-1.250 {configuration option: "underline" for radiobutton} -setup { .r configure -underline 3p } -cleanup { destroy .r -} -returnCodes {error} -result {expected integer but got "3p"} +} -returnCodes error -result {expected integer but got "3p"} test button-1.251 {configuration option: "tristatevalue" for checkbutton} -setup { checkbutton .c -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} @@ -2523,7 +2523,7 @@ test button-1.255 {configuration option: "width" for label} -setup { .l configure -width 3p } -cleanup { destroy .l -} -returnCodes {error} -result {expected integer but got "3p"} +} -returnCodes error -result {expected integer but got "3p"} test button-1.256 {configuration option: "width" for button} -setup { button .b -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .b @@ -2542,7 +2542,7 @@ test button-1.257 {configuration option: "width" for button} -setup { .b configure -width 3p } -cleanup { destroy .b -} -returnCodes {error} -result {expected integer but got "3p"} +} -returnCodes error -result {expected integer but got "3p"} test button-1.258 {configuration option: "width" for checkbutton} -setup { checkbutton .c -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .c @@ -2561,7 +2561,7 @@ test button-1.259 {configuration option: "width" for checkbutton} -setup { .c configure -width 3p } -cleanup { destroy .c -} -returnCodes {error} -result {expected integer but got "3p"} +} -returnCodes error -result {expected integer but got "3p"} test button-1.260 {configuration option: "width" for radiobutton} -setup { radiobutton .r -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .r @@ -2580,7 +2580,7 @@ test button-1.261 {configuration option: "width" for radiobutton} -setup { .r configure -width 3p } -cleanup { destroy .r -} -returnCodes {error} -result {expected integer but got "3p"} +} -returnCodes error -result {expected integer but got "3p"} test button-1.262 {configuration option: "wraplength" for label} -setup { label .l -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} @@ -2600,7 +2600,7 @@ test button-1.263 {configuration option: "wraplength" for label} -setup { .l configure -wraplength 6x } -cleanup { destroy .l -} -returnCodes {error} -result {bad screen distance "6x"} +} -returnCodes error -result {bad screen distance "6x"} test button-1.264 {configuration option: "wraplength" for button} -setup { button .b -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .b @@ -2619,7 +2619,7 @@ test button-1.265 {configuration option: "wraplength" for button} -setup { .b configure -wraplength 6x } -cleanup { destroy .b -} -returnCodes {error} -result {bad screen distance "6x"} +} -returnCodes error -result {bad screen distance "6x"} test button-1.266 {configuration option: "wraplength" for checkbutton} -setup { checkbutton .c -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .c @@ -2638,7 +2638,7 @@ test button-1.267 {configuration option: "wraplength" for checkbutton} -setup { .c configure -wraplength 6x } -cleanup { destroy .c -} -returnCodes {error} -result {bad screen distance "6x"} +} -returnCodes error -result {bad screen distance "6x"} test button-1.268 {configuration option: "wraplength" for radiobutton} -setup { radiobutton .r -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} pack .r @@ -2657,7 +2657,7 @@ test button-1.269 {configuration option: "wraplength" for radiobutton} -setup { .r configure -wraplength 6x } -cleanup { destroy .r -} -returnCodes {error} -result {bad screen distance "6x"} +} -returnCodes error -result {bad screen distance "6x"} test button-1.270 {configuration options} -body { # Additional check to make sure that -selectcolor may be empty in @@ -2671,7 +2671,7 @@ test button-1.270 {configuration options} -body { # ex-tests 3.* test button-2.1 {ButtonCreate - not enough arguments} -body { button -} -returnCodes {error} -result {wrong # args: should be "button pathName ?-option value ...?"} +} -returnCodes error -result {wrong # args: should be "button pathName ?-option value ...?"} test button-2.2 {ButtonCreate procedure - setting label class} -body { label .x @@ -2710,7 +2710,7 @@ test button-2.7 {ButtonCreate - bad window name} -body { button foo } -cleanup { destroy foo -} -returnCodes {error} -result {bad window path name "foo"} +} -returnCodes error -result {bad window path name "foo"} ######### test ex 3.8 test button-2.8 {ButtonCreate procedure - error in default option value} -body { option add *funny.background bogus @@ -2718,7 +2718,7 @@ test button-2.8 {ButtonCreate procedure - error in default option value} -body { } -cleanup { option clear destroy .funny -} -returnCodes {error} -result {unknown color name "bogus"} +} -returnCodes error -result {unknown color name "bogus"} test button-2.9 {ButtonCreate procedure - error in default option value} -body { option add *funny.background bogus catch {button .funny} @@ -2735,7 +2735,7 @@ test button-2.10 {ButtonCreate procedure - option error} -body { button .x -gorp foo } -cleanup { destroy .x -} -returnCodes {error} -result {unknown option "-gorp"} +} -returnCodes error -result {unknown option "-gorp"} test button-2.11 {ButtonCreate procedure - option error} -body { catch {button .x -gorp foo} winfo exists .x @@ -2756,31 +2756,31 @@ test button-3.1 {ButtonWidgetCmd - too few arguments} -body { .b } -cleanup { destroy .b -} -returnCodes {error} -result {wrong # args: should be ".b option ?arg ...?"} +} -returnCodes error -result {wrong # args: should be ".b option ?arg ...?"} test button-3.2 {ButtonWidgetCmd - bad option name} -body { button .b .b c } -cleanup { destroy .b -} -returnCodes {error} -result {ambiguous option "c": must be cget, configure, flash, or invoke} +} -returnCodes error -result {ambiguous option "c": must be cget, configure, flash, or invoke} test button-3.3 {ButtonWidgetCmd - bad option name} -body { button .b .b bogus } -cleanup { destroy .b -} -returnCodes {error} -result {bad option "bogus": must be cget, configure, flash, or invoke} +} -returnCodes error -result {bad option "bogus": must be cget, configure, flash, or invoke} test button-3.4 {ButtonWidgetCmd procedure, "cget" option} -body { button .b .b cget a b } -cleanup { destroy .b -} -returnCodes {error} -result {wrong # args: should be ".b cget option"} +} -returnCodes error -result {wrong # args: should be ".b cget option"} test button-3.5 {ButtonWidgetCmd procedure, "cget" option} -body { button .b .b cget -gorp } -cleanup { destroy .b -} -returnCodes {error} -result {unknown option "-gorp"} +} -returnCodes error -result {unknown option "-gorp"} #ex 4.7 test button-3.6 {ButtonWidgetCmd procedure, "cget" option} -body { @@ -2788,45 +2788,45 @@ test button-3.6 {ButtonWidgetCmd procedure, "cget" option} -body { .l cget -disabledforeground } -cleanup { destroy .l -} -returnCodes {ok} -match {glob} -result {*} +} -returnCodes {ok} -match glob -result {*} test button-3.7 {ButtonWidgetCmd procedure, "cget" option} -body { button .b .b cget -disabledforeground } -cleanup { destroy .b -} -returnCodes {ok} -match {glob} -result {*} +} -returnCodes {ok} -match glob -result {*} test button-3.8 {ButtonWidgetCmd procedure, "cget" option} -body { button .b .b cget -variable } -cleanup { destroy .b -} -returnCodes {error} -result {unknown option "-variable"} +} -returnCodes error -result {unknown option "-variable"} test button-3.9 {ButtonWidgetCmd procedure, "cget" option} -body { checkbutton .c .c cget -variable } -cleanup { destroy .c -} -returnCodes {ok} -match {glob} -result {*} +} -returnCodes {ok} -match glob -result {*} test button-3.10 {ButtonWidgetCmd procedure, "cget" option} -body { checkbutton .c .c cget -value } -cleanup { destroy .c -} -returnCodes {error} -result {unknown option "-value"} +} -returnCodes error -result {unknown option "-value"} test button-3.11 {ButtonWidgetCmd procedure, "cget" option} -body { radiobutton .r .r cget -value } -cleanup { destroy .r -} -returnCodes {ok} -match {glob} -result {*} +} -returnCodes {ok} -match glob -result {*} test button-3.12 {ButtonWidgetCmd procedure, "cget" option} -body { radiobutton .r .r cget -onvalue } -cleanup { destroy .r -} -returnCodes {error} -result {unknown option "-onvalue"} +} -returnCodes error -result {unknown option "-onvalue"} # ex 4.6 test button-3.13 {ButtonWidgetCmd procedure, "configure" option} -body { @@ -2846,14 +2846,14 @@ test button-3.15 {ButtonWidgetCmd procedure, "configure" option} -body { .b configure -gorp } -cleanup { destroy .b -} -returnCodes {error} -result {unknown option "-gorp"} +} -returnCodes error -result {unknown option "-gorp"} test button-3.16 {ButtonWidgetCmd procedure, "configure" option} -setup { button .b } -body { .b co -bg #ffffff -fg } -cleanup { destroy .b -} -returnCodes {error} -result {value for "-fg" missing} +} -returnCodes error -result {value for "-fg" missing} test button-3.17 {ButtonWidgetCmd procedure, "configure" option} -setup { button .b } -body { @@ -2868,19 +2868,19 @@ test button-3.18 {ButtonWidgetCmd procedure, "deselect" option} -body { .c deselect foo } -cleanup { destroy .c -} -returnCodes {error} -result {wrong # args: should be ".c deselect"} +} -returnCodes error -result {wrong # args: should be ".c deselect"} test button-3.19 {ButtonWidgetCmd procedure, "deselect" option} -body { label .l .l deselect } -cleanup { destroy .l -} -returnCodes {error} -result {bad option "deselect": must be cget or configure} +} -returnCodes error -result {bad option "deselect": must be cget or configure} test button-3.20 {ButtonWidgetCmd procedure, "deselect" option} -body { button .b .b deselect } -cleanup { destroy .b -} -returnCodes {error} -result {bad option "deselect": must be cget, configure, flash, or invoke} +} -returnCodes error -result {bad option "deselect": must be cget, configure, flash, or invoke} test button-3.21 {ButtonWidgetCmd procedure, "deselect" option} -body { checkbutton .c -variable checkvar -onvalue 1 -offvalue 0 @@ -2915,7 +2915,7 @@ test button-3.24 {ButtonWidgetCmd procedure, "deselect" option} -body { } -cleanup { destroy .c trace remove variable checkvar write bogusTrace -} -returnCodes {error} -result {can't set "checkvar": trace aborted} +} -returnCodes error -match glob -result {can*t set "checkvar": trace aborted} test button-3.25 {ButtonWidgetCmd procedure, "deselect" option} -body { checkbutton .c -variable checkvar -onvalue 1 -offvalue 0 set checkvar 1 @@ -2925,7 +2925,7 @@ test button-3.25 {ButtonWidgetCmd procedure, "deselect" option} -body { } -cleanup { trace remove variable checkvar write bogusTrace destroy .c -} -match {glob} -result {{*trace aborted +} -match glob -result {{*trace aborted while executing * ".c deselect"} 0} @@ -2937,7 +2937,7 @@ test button-3.26 {ButtonWidgetCmd procedure, "deselect" option} -body { } -cleanup { destroy .r trace remove variable radiovar write bogusTrace -} -match {glob} -returnCodes {error} -result {can't set "radiovar": trace aborted} +} -match glob -returnCodes error -result {can*t set "radiovar": trace aborted} test button-3.27 {ButtonWidgetCmd procedure, "deselect" option} -body { radiobutton .r -variable radiovar -value red set radiovar red @@ -2957,44 +2957,44 @@ test button-3.28 {ButtonWidgetCmd procedure, "flash" option} -body { .b flash foo } -cleanup { destroy .b -} -returnCodes {error} -result {wrong # args: should be ".b flash"} +} -returnCodes error -result {wrong # args: should be ".b flash"} test button-3.29 {ButtonWidgetCmd procedure, "flash" option} -body { label .l .l flash } -cleanup { destroy .l -} -returnCodes {error} -result {bad option "flash": must be cget or configure} +} -returnCodes error -result {bad option "flash": must be cget or configure} test button-3.30 {ButtonWidgetCmd procedure, "flash" option} -body { button .b catch {.b flash} } -cleanup { destroy .b -} -returnCodes {ok} -match {glob} -result {*} +} -returnCodes {ok} -match glob -result {*} test button-3.31 {ButtonWidgetCmd procedure, "flash" option} -body { checkbutton .c catch {.c flash} } -cleanup { destroy .c -} -returnCodes {ok} -match {glob} -result {*} +} -returnCodes {ok} -match glob -result {*} test button-3.32 {ButtonWidgetCmd procedure, "flash" option} -body { radiobutton .r catch {.r f} } -cleanup { destroy .r -} -returnCodes {ok} -match {glob} -result {*} +} -returnCodes {ok} -match glob -result {*} test button-3.33 {ButtonWidgetCmd procedure, "invoke" option} -body { label .l .l invoke } -cleanup { destroy .l -} -returnCodes {error} -result {bad option "invoke": must be cget or configure} +} -returnCodes error -result {bad option "invoke": must be cget or configure} test button-3.34 {ButtonWidgetCmd procedure, "invoke" option} -body { button .b .b invoke foo } -cleanup { destroy .b -} -returnCodes {error} -result {wrong # args: should be ".b invoke"} +} -returnCodes error -result {wrong # args: should be ".b invoke"} test button-3.35 {ButtonWidgetCmd procedure, "invoke" option} -body { button .b .b configure -command {set x invoked} @@ -3038,19 +3038,19 @@ test button-3.39 {ButtonWidgetCmd procedure, "select" option} -body { .l select } -cleanup { destroy .l -} -returnCodes {error} -result {bad option "select": must be cget or configure} +} -returnCodes error -result {bad option "select": must be cget or configure} test button-3.40 {ButtonWidgetCmd procedure, "select" option} -body { button .b .b select } -cleanup { destroy .b -} -returnCodes {error} -result {bad option "select": must be cget, configure, flash, or invoke} +} -returnCodes error -result {bad option "select": must be cget, configure, flash, or invoke} test button-3.41 {ButtonWidgetCmd procedure, "select" option} -body { checkbutton .c .c select foo } -cleanup { destroy .c -} -returnCodes {error} -result {wrong # args: should be ".c select"} +} -returnCodes error -result {wrong # args: should be ".c select"} test button-3.42 {ButtonWidgetCmd procedure, "select" option} -body { checkbutton .c -variable checkvar -onvalue lovely -offvalue 0 set checkvar bogus @@ -3075,7 +3075,7 @@ test button-3.44 {ButtonWidgetCmd procedure, "select" option} -body { } -cleanup { destroy .r trace remove variable radiovar write bogusTrace -} -returnCodes {error} -result {can't set "radiovar": trace aborted} +} -returnCodes error -match glob -result {can*t set "radiovar": trace aborted} test button-3.45 {ButtonWidgetCmd procedure, "select" option} -body { radiobutton .r -variable radiovar -value red set radiovar yellow @@ -3085,7 +3085,7 @@ test button-3.45 {ButtonWidgetCmd procedure, "select" option} -body { } -cleanup { destroy .r trace remove variable radiovar write bogusTrace -} -match {glob} -result {{*trace aborted +} -match glob -result {{*trace aborted while executing * ".r select"} red} @@ -3096,25 +3096,25 @@ test button-3.46 {ButtonWidgetCmd procedure, "toggle" option} -body { .l toggle } -cleanup { destroy .l -} -returnCodes {error} -result {bad option "toggle": must be cget or configure} +} -returnCodes error -result {bad option "toggle": must be cget or configure} test button-3.47 {ButtonWidgetCmd procedure, "toggle" option} -body { button .b .b toggle } -cleanup { destroy .b -} -returnCodes {error} -result {bad option "toggle": must be cget, configure, flash, or invoke} +} -returnCodes error -result {bad option "toggle": must be cget, configure, flash, or invoke} test button-3.48 {ButtonWidgetCmd procedure, "toggle" option} -body { radiobutton .r .r toggle } -cleanup { destroy .r -} -returnCodes {error} -result {bad option "toggle": must be cget, configure, deselect, flash, invoke, or select} +} -returnCodes error -result {bad option "toggle": must be cget, configure, deselect, flash, invoke, or select} test button-3.49 {ButtonWidgetCmd procedure, "toggle" option} -body { checkbutton .c .c toggle foo } -cleanup { destroy .c -} -returnCodes {error} -result {wrong # args: should be ".c toggle"} +} -returnCodes error -result {wrong # args: should be ".c toggle"} test button-3.50 {ButtonWidgetCmd procedure, "toggle" option} -body { set checkvar bogus checkbutton .c -variable checkvar -onvalue sunshine -offvalue rain @@ -3136,7 +3136,7 @@ test button-3.51 {ButtonWidgetCmd procedure, "toggle" option} -body { } -cleanup { destroy .c trace remove variable checkvar write bogusTrace -} -returnCodes {error} -result {can't set "checkvar": trace aborted} +} -returnCodes error -match glob -result {can*t set "checkvar": trace aborted} test button-3.52 {ButtonWidgetCmd procedure, "toggle" option} -body { checkbutton .c -variable checkvar -onvalue xyz -offvalue abc set checkvar xyz @@ -3146,7 +3146,7 @@ test button-3.52 {ButtonWidgetCmd procedure, "toggle" option} -body { } -cleanup { trace remove variable checkvar write bogusTrace destroy .c -} -match {glob} -result {{*trace aborted +} -match glob -result {{*trace aborted while executing * ".c toggle"} abc} @@ -3158,7 +3158,7 @@ test button-3.53 {ButtonWidgetCmd procedure, "toggle" option} -body { } -cleanup { trace remove variable checkvar write bogusTrace destroy .c -} -returnCodes {error} -result {can't set "checkvar": trace aborted} +} -returnCodes error -match glob -result {can*t set "checkvar": trace aborted} test button-3.54 {ButtonWidgetCmd procedure, "toggle" option} -body { checkbutton .c -variable checkvar -onvalue xyz -offvalue abc set checkvar abc @@ -3168,7 +3168,7 @@ test button-3.54 {ButtonWidgetCmd procedure, "toggle" option} -body { } -cleanup { trace remove variable checkvar write bogusTrace destroy .c -} -match {glob} -result {{*trace aborted +} -match glob -result {{*trace aborted while executing * ".c toggle"} xyz} @@ -3181,7 +3181,7 @@ test button-3.55 {ButtonWidgetCmd procedure, "toggle" option} -setup { .c toggle } -cleanup { destroy .c -} -returnCodes {error} -result {can't set "checkvar": variable is array} +} -returnCodes error -match glob -result {can*t set "checkvar": variable is *array} test button-3.56 {ButtonWidgetCmd procedure, "toggle" option} -setup { unset -nocomplain checkvar } -body { @@ -3192,7 +3192,7 @@ test button-3.56 {ButtonWidgetCmd procedure, "toggle" option} -setup { return $errorInfo } -cleanup { destroy .c -} -match {glob} -result {can't set "checkvar": variable is array +} -match glob -result {can*t set "checkvar": variable is *array while executing ".c toggle"} @@ -3221,7 +3221,7 @@ test button-5.1 {ConfigureButton - textvariable trace} -body { .b configure -bd 7 -bg red -fg bogus } -cleanup { destroy .b -} -returnCodes {error} -result {unknown color name "bogus"} +} -returnCodes error -result {unknown color name "bogus"} test button-5.2 {ConfigureButton - textvariable trace} -body { button .b -bd 4 -bg green catch {.b configure -bd 7 -bg red -fg bogus} @@ -3309,13 +3309,13 @@ test button-5.10 {ConfigureButton - error in setting variable} -setup { } -cleanup { destroy .r trace remove variable x write bogusTrace -} -returnCodes {error} -result {can't set "x": trace aborted} +} -returnCodes error -match glob -result {can*t set "x": trace aborted} test button-5.11 {ConfigureButton - bad image name} -body { button .b -image bogus } -cleanup { destroy .b -} -returnCodes {error} -result {image "bogus" doesn't exist} +} -returnCodes error -result {image "bogus" doesn't exist} test button-5.12 {ConfigureButton - setting variable from current text value} -setup { unset -nocomplain x @@ -3342,7 +3342,7 @@ test button-5.14 {ConfigureButton - variable handling} -setup { } -cleanup { trace remove variable x write bogusTrace destroy .r -} -returnCodes {error} -result {can't set "x": trace aborted} +} -returnCodes error -match glob -result {can*t set "x": trace aborted} test button-5.15 {ConfigureButton - variable handling} -setup { unset -nocomplain x } -body { @@ -3360,7 +3360,7 @@ test button-5.16 {ConfigureButton - -width option} -body { .b configure -width 1i } -cleanup { destroy .b -} -returnCodes {error} -result {expected integer but got "1i"} +} -returnCodes error -result {expected integer but got "1i"} test button-5.17 {ConfigureButton - -width option} -body { button .b -text "Button 1" catch {.b configure -width 1i} @@ -3376,7 +3376,7 @@ test button-5.18 {ConfigureButton - -height option} -body { .b configure -height 0.5c } -cleanup { destroy .b -} -returnCodes {error} -result {expected integer but got "0.5c"} +} -returnCodes error -result {expected integer but got "0.5c"} test button-5.19 {ConfigureButton - -height option} -body { button .b -text "Button 1" catch {.b configure -height 0.5c} @@ -3393,7 +3393,7 @@ test button-5.20 {ConfigureButton - -width option} -body { .b configure -width abc } -cleanup { destroy .b -} -returnCodes {error} -result {bad screen distance "abc"} +} -returnCodes error -result {bad screen distance "abc"} test button-5.21 {ConfigureButton - -width option} -body { button .b -bitmap questhead catch {.b configure -width abc} @@ -3414,7 +3414,7 @@ test button-5.22 {ConfigureButton - -height option} -constraints { } -cleanup { destroy .b image delete image1 -} -returnCodes {error} -result {bad screen distance "0.5x"} +} -returnCodes error -result {bad screen distance "0.5x"} test button-5.23 {ConfigureButton - -height option} -constraints { testImageType } -setup { @@ -3543,7 +3543,7 @@ test button-8.2 {TkInvokeButton procedure} -setup { } -cleanup { destroy .c trace remove variable x write bogusTrace -} -returnCodes {error} -result {can't set "x": trace aborted} +} -returnCodes error -match glob -result {can*t set "x": trace aborted} test button-8.3 {TkInvokeButton procedure} -setup { set x 0 } -body { @@ -3564,7 +3564,7 @@ test button-8.4 {TkInvokeButton procedure} -setup { } -cleanup { destroy .c trace remove variable x write bogusTrace -} -returnCodes {error} -result {can't set "x": trace aborted} +} -returnCodes error -match glob -result {can*t set "x": trace aborted} test button-8.5 {TkInvokeButton procedure} -setup { set x 1 } -body { @@ -3598,7 +3598,7 @@ test button-8.7 {TkInvokeButton procedure} -body { } -cleanup { destroy .r trace remove variable x write bogusTrace -} -returnCodes {error} -result {can't set "x": trace aborted} +} -returnCodes error -match glob -result {can*t set "x": trace aborted} test button-8.8 {TkInvokeButton procedure} -body { radiobutton .r -variable x -value red set x green @@ -3608,7 +3608,7 @@ test button-8.8 {TkInvokeButton procedure} -body { } -cleanup { destroy .r trace remove variable x write bogusTrace -} -match {glob} -result {{*trace aborted +} -match glob -result {{*trace aborted while executing * ".r invoke"} red} diff --git a/tests/canvImg.test b/tests/canvImg.test index e2e9e58b8..1b4d3a1c5 100644 --- a/tests/canvImg.test +++ b/tests/canvImg.test @@ -4,7 +4,7 @@ # # Copyright (c) 1994 The Regents of the University of California. # Copyright (c) 1994-1996 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. package require tcltest 2.2 @@ -29,7 +29,7 @@ test canvImg-1.2 {options for image items} -body { .c create image 50 50 -anchor gorp -tags i1 } -cleanup { .c delete all -} -returnCodes {error} -result {bad anchor position "gorp": must be n, ne, e, se, s, sw, w, nw, or center} +} -returnCodes error -result {bad anchor position "gorp": must be n, ne, e, se, s, sw, w, nw, or center} test canvImg-1.3 {options for image items} -constraints testImageType -setup { image create test foo .c delete all @@ -44,7 +44,7 @@ test canvImg-1.4 {options for image items} -body { .c create image 50 50 -image unknown -tags i1 } -cleanup { .c delete all -} -returnCodes {error} -result {image "unknown" doesn't exist} +} -returnCodes error -result {image "unknown" doesn't exist} test canvImg-1.5 {options for image items} -constraints testImageType -setup { image create test foo .c delete all @@ -60,12 +60,12 @@ test canvImg-2.1 {CreateImage procedure} -body { .c create image 40 } -cleanup { .c delete all -} -returnCodes {error} -result {wrong # coordinates: expected 2, got 1} +} -returnCodes error -result {wrong # coordinates: expected 2, got 1} test canvImg-2.2 {CreateImage procedure} -body { .c create image 40 50 60 } -cleanup { .c delete all -} -returnCodes {error} -result {unknown option "60"} +} -returnCodes error -result {unknown option "60"} test canvImg-2.3 {CreateImage procedure} -body { .c delete all set i [.c create image 50 50] @@ -79,17 +79,17 @@ test canvImg-2.4 {CreateImage procedure} -body { .c create image xyz 40 } -cleanup { .c delete all -} -returnCodes {error} -result {bad screen distance "xyz"} +} -returnCodes error -result {bad screen distance "xyz"} test canvImg-2.5 {CreateImage procedure} -body { .c create image 50 qrs } -cleanup { .c delete all -} -returnCodes {error} -result {bad screen distance "qrs"} +} -returnCodes error -result {bad screen distance "qrs"} test canvImg-2.6 {CreateImage procedure} -constraints testImageType -body { .c create image 50 50 -gorp foo } -cleanup { .c delete all -} -returnCodes {error} -result {unknown option "-gorp"} +} -returnCodes error -result {unknown option "-gorp"} test canvImg-3.1 {ImageCoords procedure} -constraints testImageType -setup { @@ -109,7 +109,7 @@ test canvImg-3.2 {ImageCoords procedure} -constraints testImageType -setup { } -cleanup { .c delete all image delete foo -} -returnCodes {error} -result {bad screen distance "dumb"} +} -returnCodes error -result {bad screen distance "dumb"} test canvImg-3.3 {ImageCoords procedure} -constraints testImageType -setup { image create test foo } -body { @@ -119,7 +119,7 @@ test canvImg-3.3 {ImageCoords procedure} -constraints testImageType -setup { } -cleanup { .c delete all image delete foo -} -returnCodes {error} -result {bad screen distance "dumb0"} +} -returnCodes error -result {bad screen distance "dumb0"} test canvImg-3.4 {ImageCoords procedure} -constraints testImageType -setup { image create test foo } -body { @@ -129,7 +129,7 @@ test canvImg-3.4 {ImageCoords procedure} -constraints testImageType -setup { } -cleanup { .c delete all image delete foo -} -returnCodes {error} -result {wrong # coordinates: expected 2, got 1} +} -returnCodes error -result {wrong # coordinates: expected 2, got 1} test canvImg-3.5 {ImageCoords procedure} -constraints testImageType -setup { image create test foo } -body { @@ -139,7 +139,7 @@ test canvImg-3.5 {ImageCoords procedure} -constraints testImageType -setup { } -cleanup { .c delete all image delete foo -} -returnCodes {error} -result {wrong # coordinates: expected 0 or 2, got 3} +} -returnCodes error -result {wrong # coordinates: expected 0 or 2, got 3} test canvImg-4.1 {ConfiugreImage procedure} -constraints testImageType -setup { @@ -195,7 +195,7 @@ test canvImg-4.3 {ConfiugreImage procedure} -constraints testImageType -setup { } -cleanup { .c delete all image delete foo foo2 -} -returnCodes {error} -result {image "lousy" doesn't exist} +} -returnCodes error -result {image "lousy" doesn't exist} test canvImg-5.1 {DeleteImage procedure} -constraints testImageType -setup { diff --git a/tests/canvMoveto.test b/tests/canvMoveto.test index a6cf849f5..4a78893eb 100644 --- a/tests/canvMoveto.test +++ b/tests/canvMoveto.test @@ -2,7 +2,7 @@ # derived from canvRect.test. # # Copyright (c) 1994-1996 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # Copyright (c) 2004 Neil McKay. # All rights reserved. diff --git a/tests/canvPs.test b/tests/canvPs.test index 365eb1d68..02ed4a1b0 100644 --- a/tests/canvPs.test +++ b/tests/canvPs.test @@ -3,7 +3,7 @@ # TkCanvPostscriptCmd in generic/tkCanvPs.c # # Copyright (c) 1995 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. package require tcltest 2.2 diff --git a/tests/canvRect.test b/tests/canvRect.test index 1aa5421ea..8fd00aedf 100644 --- a/tests/canvRect.test +++ b/tests/canvRect.test @@ -3,7 +3,7 @@ # in the standard fashion for Tcl tests. # # Copyright (c) 1994-1996 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. package require tcltest 2.2 diff --git a/tests/canvText.test b/tests/canvText.test index 10e4fb5bc..ffa017676 100644 --- a/tests/canvText.test +++ b/tests/canvText.test @@ -3,7 +3,7 @@ # fashion for Tcl tests. # # Copyright (c) 1996-1997 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. package require tcltest 2.2 @@ -95,22 +95,22 @@ test canvasText-1.19 {configuration options: bounding of "angle"} -body { test canvText-2.1 {CreateText procedure: args} -body { .c create text -} -returnCodes {error} -result {wrong # args: should be ".c create text coords ?arg ...?"} +} -returnCodes error -result {wrong # args: should be ".c create text coords ?arg ...?"} test canvText-2.2 {CreateText procedure: args} -body { .c create text xyz 0 } -cleanup { .c delete all -} -returnCodes {error} -result {bad screen distance "xyz"} +} -returnCodes error -result {bad screen distance "xyz"} test canvText-2.3 {CreateText procedure: args} -body { .c create text 0 xyz } -cleanup { .c delete all -} -returnCodes {error} -result {bad screen distance "xyz"} +} -returnCodes error -result {bad screen distance "xyz"} test canvText-2.4 {CreateText procedure: args} -body { .c create text 0 0 -xyz xyz } -cleanup { .c delete all -} -returnCodes {error} -result {unknown option "-xyz"} +} -returnCodes error -result {unknown option "-xyz"} test canvText-2.5 {CreateText procedure} -body { .c create text 0 0 -tags x .c coords x @@ -133,14 +133,14 @@ test canvText-3.2 {TextCoords procedure} -setup { .c coords test xyz 0 } -cleanup { .c delete test -} -returnCodes {error} -result {bad screen distance "xyz"} +} -returnCodes error -result {bad screen distance "xyz"} test canvText-3.3 {TextCoords procedure} -setup { .c create text 20 20 -tag test } -body { .c coords test 0 xyz } -cleanup { .c delete test -} -returnCodes {error} -result {bad screen distance "xyz"} +} -returnCodes error -result {bad screen distance "xyz"} test canvText-3.4 {TextCoords procedure} -setup { .c create text 20 20 -tag test } -body { @@ -159,14 +159,14 @@ test canvText-3.5 {TextCoords procedure} -setup { .c coords test 10 } -cleanup { .c delete test -} -returnCodes {error} -result {wrong # coordinates: expected 2, got 1} +} -returnCodes error -result {wrong # coordinates: expected 2, got 1} test canvText-3.6 {TextCoords procedure} -setup { .c create text 20 20 -tag test } -body { .c coords test 10 10 10 } -cleanup { .c delete test -} -returnCodes {error} -result {wrong # coordinates: expected 0 or 2, got 3} +} -returnCodes error -result {wrong # coordinates: expected 0 or 2, got 3} test canvText-4.1 {ConfigureText procedure} -setup { @@ -175,7 +175,7 @@ test canvText-4.1 {ConfigureText procedure} -setup { .c itemconfig test -fill xyz } -cleanup { .c delete test -} -returnCodes {error} -result {unknown color name "xyz"} +} -returnCodes error -result {unknown color name "xyz"} test canvText-4.2 {ConfigureText procedure} -setup { .c create text 20 20 -tag test } -body { @@ -636,7 +636,7 @@ test canvText-9.8 {TextInsert procedure: selectFirst > selectLast: deselect} -bo .c select to test 8 .c dchars test 3 10 .c index test sel.first -} -returnCodes {error} -result {selection isn't in item} +} -returnCodes error -result {selection isn't in item} test canvText-9.9 {TextInsert procedure: selectFirst <= selectLast} -body { .c itemconfig test -text "abcdefghijk" .c select from test 4 @@ -766,7 +766,7 @@ test canvText-14.2 {GetTextIndex procedure: select error} -setup { .c index test sel.first } -cleanup { .c delete test -} -returnCodes {error} -result {selection isn't in item} +} -returnCodes error -result {selection isn't in item} test canvText-14.3 {GetTextIndex procedure: select error} -setup { .c create text 0 0 -tag test focus .c @@ -776,7 +776,7 @@ test canvText-14.3 {GetTextIndex procedure: select error} -setup { .c index test sel.last } -cleanup { .c delete test -} -returnCodes {error} -result {selection isn't in item} +} -returnCodes error -result {selection isn't in item} test canvText-14.4 {GetTextIndex procedure: select error} -setup { .c create text 0 0 -tag test focus .c @@ -786,7 +786,7 @@ test canvText-14.4 {GetTextIndex procedure: select error} -setup { .c index test sel. } -cleanup { .c delete test -} -returnCodes {error} -result {bad index "sel."} +} -returnCodes error -result {bad index "sel."} test canvText-14.5 {GetTextIndex procedure: bad int or unknown index} -setup { .c create text 0 0 -tag test focus .c @@ -795,7 +795,7 @@ test canvText-14.5 {GetTextIndex procedure: bad int or unknown index} -setup { .c index test xyz } -cleanup { .c delete test -} -returnCodes {error} -result {bad index "xyz"} +} -returnCodes error -result {bad index "xyz"} test canvText-14.6 {select clear errors} -setup { .c create text 0 0 -tag test } -body { diff --git a/tests/canvWind.test b/tests/canvWind.test index 750321ebe..94850912e 100644 --- a/tests/canvWind.test +++ b/tests/canvWind.test @@ -3,7 +3,7 @@ # fashion for Tcl tests. # # Copyright (c) 1997 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. package require tcltest 2.2 diff --git a/tests/choosedir.test b/tests/choosedir.test index f67a7216e..53100c929 100644 --- a/tests/choosedir.test +++ b/tests/choosedir.test @@ -2,7 +2,7 @@ # It is organized in the standard fashion for Tcl tests. # # Copyright (c) 1996 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. package require tcltest 2.2 diff --git a/tests/clipboard.test b/tests/clipboard.test index 81534d5e9..b7514bf22 100644 --- a/tests/clipboard.test +++ b/tests/clipboard.test @@ -3,7 +3,7 @@ # fashion for Tcl tests. # # Copyright (c) 1994 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. # diff --git a/tests/clrpick.test b/tests/clrpick.test index 84d48de66..8a98ad6dd 100644 --- a/tests/clrpick.test +++ b/tests/clrpick.test @@ -2,7 +2,7 @@ # It is organized in the standard fashion for Tcl tests. # # Copyright (c) 1996 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. package require tcltest 2.2 diff --git a/tests/cmds.test b/tests/cmds.test index caf5afe9a..8509fb5df 100644 --- a/tests/cmds.test +++ b/tests/cmds.test @@ -2,7 +2,7 @@ # tkCmds.c. It is organized in the standard fashion for Tcl tests. # # Copyright (c) 1996 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. package require tcltest 2.2 @@ -14,13 +14,13 @@ update test cmds-1.1 {tkwait visibility, argument errors} -body { tkwait visibility -} -returnCodes {error} -result {wrong # args: should be "tkwait variable|visibility|window name"} +} -returnCodes error -result {wrong # args: should be "tkwait variable|visibility|window name"} test cmds-1.2 {tkwait visibility, argument errors} -body { tkwait visibility foo bar -} -returnCodes {error} -result {wrong # args: should be "tkwait variable|visibility|window name"} +} -returnCodes error -result {wrong # args: should be "tkwait variable|visibility|window name"} test cmds-1.3 {tkwait visibility, argument errors} -body { tkwait visibility bad_window -} -returnCodes {error} -result {bad window path name "bad_window"} +} -returnCodes error -result {bad window path name "bad_window"} test cmds-1.4 {tkwait visibility, waiting for window to be mapped} -setup { button .b -text "Test" set x init @@ -39,7 +39,7 @@ test cmds-1.5 {tkwait visibility, window gets deleted} -setup { } -body { after 100 {set x deleted; destroy .f} tkwait visibility .f.b -} -returnCodes {error} -result {window ".f.b" was deleted before its visibility changed} +} -returnCodes error -result {window ".f.b" was deleted before its visibility changed} test cmds-1.6 {tkwait visibility, window gets deleted} -setup { frame .f button .f.b -text "Test" diff --git a/tests/color.test b/tests/color.test index fe92aaf11..8c9a02a45 100644 --- a/tests/color.test +++ b/tests/color.test @@ -2,7 +2,7 @@ # tkColor.c. It is organized in the standard fashion for Tcl tests. # # Copyright (c) 1995-1998 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. package require tcltest 2.2 diff --git a/tests/cursor.test b/tests/cursor.test index 8d7ebb053..5765ed95e 100644 --- a/tests/cursor.test +++ b/tests/cursor.test @@ -3,7 +3,7 @@ # Tcl tests. # # Copyright (c) 1998 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. package require tcltest 2.2 diff --git a/tests/embed.test b/tests/embed.test index 1fe73ef8b..63815c4e0 100644 --- a/tests/embed.test +++ b/tests/embed.test @@ -1,7 +1,7 @@ # This file is a Tcl script to test out embedded Windows. # # Copyright (c) 1996-1997 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. package require tcltest 2.2 diff --git a/tests/entry.test b/tests/entry.test index 977531aa0..d3249d6ac 100644 --- a/tests/entry.test +++ b/tests/entry.test @@ -3,7 +3,7 @@ # # Copyright (c) 1994 The Regents of the University of California. # Copyright (c) 1994-1997 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. package require tcltest 2.2 @@ -59,7 +59,7 @@ test entry-1.2 {configuration option: "background" for entry} -setup { .e configure -background non-existent } -cleanup { destroy .e -} -returnCodes {error} -result {unknown color name "non-existent"} +} -returnCodes error -result {unknown color name "non-existent"} test entry-1.3 {configuration option: "bd" for entry} -setup { entry .e -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} @@ -79,7 +79,7 @@ test entry-1.4 {configuration option: "bd" for entry} -setup { .e configure -bd badValue } -cleanup { destroy .e -} -returnCodes {error} -result {bad screen distance "badValue"} +} -returnCodes error -result {bad screen distance "badValue"} test entry-1.5 {configuration option: "bg" for entry} -setup { entry .e -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} @@ -99,7 +99,7 @@ test entry-1.6 {configuration option: "bg" for entry} -setup { .e configure -bg non-existent } -cleanup { destroy .e -} -returnCodes {error} -result {unknown color name "non-existent"} +} -returnCodes error -result {unknown color name "non-existent"} test entry-1.7 {configuration option: "borderwidth" for entry} -setup { entry .e -highlightthickness 2 -font {Helvetica -12 bold} @@ -119,7 +119,7 @@ test entry-1.8 {configuration option: "borderwidth" for entry} -setup { .e configure -borderwidth badValue } -cleanup { destroy .e -} -returnCodes {error} -result {bad screen distance "badValue"} +} -returnCodes error -result {bad screen distance "badValue"} test entry-1.9 {configuration option: "cursor" for entry} -setup { entry .e -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} @@ -139,7 +139,7 @@ test entry-1.10 {configuration option: "cursor" for entry} -setup { .e configure -cursor badValue } -cleanup { destroy .e -} -returnCodes {error} -result {bad cursor spec "badValue"} +} -returnCodes error -result {bad cursor spec "badValue"} test entry-1.11 {configuration option: "disabledbackground" for entry} -setup { entry .e -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} @@ -159,7 +159,7 @@ test entry-1.12 {configuration option: "disabledbackground" for entry} -setup { .e configure -disabledbackground non-existent } -cleanup { destroy .e -} -returnCodes {error} -result {unknown color name "non-existent"} +} -returnCodes error -result {unknown color name "non-existent"} test entry-1.13 {configuration option: "disabledforeground" for entry} -setup { entry .e -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} @@ -179,7 +179,7 @@ test entry-1.14 {configuration option: "disabledforeground" for entry} -setup { .e configure -disabledforeground non-existent } -cleanup { destroy .e -} -returnCodes {error} -result {unknown color name "non-existent"} +} -returnCodes error -result {unknown color name "non-existent"} test entry-1.15 {configuration option: "exportselection" for entry} -setup { entry .e -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} @@ -199,7 +199,7 @@ test entry-1.16 {configuration option: "exportselection" for entry} -setup { .e configure -exportselection xyzzy } -cleanup { destroy .e -} -returnCodes {error} -result {expected boolean value but got "xyzzy"} +} -returnCodes error -result {expected boolean value but got "xyzzy"} test entry-1.17 {configuration option: "fg" for entry} -setup { entry .e -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} @@ -219,7 +219,7 @@ test entry-1.18 {configuration option: "fg" for entry} -setup { .e configure -fg non-existent } -cleanup { destroy .e -} -returnCodes {error} -result {unknown color name "non-existent"} +} -returnCodes error -result {unknown color name "non-existent"} test entry-1.19 {configuration option: "font" for entry} -setup { entry .e -borderwidth 2 -highlightthickness 2 @@ -239,7 +239,7 @@ test entry-1.20 {configuration option: "font" for entry} -setup { .e configure -font {} } -cleanup { destroy .e -} -returnCodes {error} -result {font "" doesn't exist} +} -returnCodes error -result {font "" doesn't exist} test entry-1.21 {configuration option: "foreground" for entry} -setup { entry .e -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} @@ -259,7 +259,7 @@ test entry-1.22 {configuration option: "foreground" for entry} -setup { .e configure -foreground non-existent } -cleanup { destroy .e -} -returnCodes {error} -result {unknown color name "non-existent"} +} -returnCodes error -result {unknown color name "non-existent"} test entry-1.23 {configuration option: "highlightbackground" for entry} -setup { entry .e -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} @@ -279,7 +279,7 @@ test entry-1.24 {configuration option: "highlightbackground" for entry} -setup { .e configure -highlightbackground non-existent } -cleanup { destroy .e -} -returnCodes {error} -result {unknown color name "non-existent"} +} -returnCodes error -result {unknown color name "non-existent"} test entry-1.25 {configuration option: "highlightcolor" for entry} -setup { entry .e -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} @@ -299,7 +299,7 @@ test entry-1.26 {configuration option: "highlightcolor" for entry} -setup { .e configure -highlightcolor non-existent } -cleanup { destroy .e -} -returnCodes {error} -result {unknown color name "non-existent"} +} -returnCodes error -result {unknown color name "non-existent"} test entry-1.27 {configuration option: "highlightthickness" for entry} -setup { entry .e -borderwidth 2 -font {Helvetica -12 bold} @@ -329,7 +329,7 @@ test entry-1.29 {configuration option: "highlightthickness" for entry} -setup { .e configure -highlightthickness badValue } -cleanup { destroy .e -} -returnCodes {error} -result {bad screen distance "badValue"} +} -returnCodes error -result {bad screen distance "badValue"} test entry-1.30 {configuration option: "insertbackground" for entry} -setup { entry .e -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} @@ -349,7 +349,7 @@ test entry-1.31 {configuration option: "insertbackground" for entry} -setup { .e configure -insertbackground non-existent } -cleanup { destroy .e -} -returnCodes {error} -result {unknown color name "non-existent"} +} -returnCodes error -result {unknown color name "non-existent"} test entry-1.32 {configuration option: "insertborderwidth" for entry} -setup { entry .e -borderwidth 2 -insertwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} @@ -369,7 +369,7 @@ test entry-1.33 {configuration option: "insertborderwidth" for entry} -setup { .e configure -insertborderwidth 2.6x } -cleanup { destroy .e -} -returnCodes {error} -result {bad screen distance "2.6x"} +} -returnCodes error -result {bad screen distance "2.6x"} test entry-1.34 {configuration option: "insertofftime" for entry} -setup { entry .e -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} @@ -389,7 +389,7 @@ test entry-1.35 {configuration option: "insertofftime" for entry} -setup { .e configure -insertofftime 3.2 } -cleanup { destroy .e -} -returnCodes {error} -result {expected integer but got "3.2"} +} -returnCodes error -result {expected integer but got "3.2"} test entry-1.36 {configuration option: "insertontime" for entry} -setup { entry .e -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} @@ -409,7 +409,7 @@ test entry-1.37 {configuration option: "insertontime" for entry} -setup { .e configure -insertontime 3.2 } -cleanup { destroy .e -} -returnCodes {error} -result {expected integer but got "3.2"} +} -returnCodes error -result {expected integer but got "3.2"} test entry-1.38 {configuration option: "invalidcommand" for entry} -setup { entry .e -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} @@ -451,7 +451,7 @@ test entry-1.41 {configuration option: "justify" for entry} -setup { .e configure -justify bogus } -cleanup { destroy .e -} -returnCodes {error} -result {bad justification "bogus": must be left, right, or center} +} -returnCodes error -result {bad justification "bogus": must be left, right, or center} test entry-1.42 {configuration option: "readonlybackground" for entry} -setup { entry .e -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} @@ -471,7 +471,7 @@ test entry-1.43 {configuration option: "readonlybackground" for entry} -setup { .e configure -readonlybackground non-existent } -cleanup { destroy .e -} -returnCodes {error} -result {unknown color name "non-existent"} +} -returnCodes error -result {unknown color name "non-existent"} test entry-1.44 {configuration option: "relief" for entry} -setup { entry .e -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} @@ -502,7 +502,7 @@ test entry-1.46 {configuration option: "selectbackground" for entry} -setup { .e configure -selectbackground non-existent } -cleanup { destroy .e -} -returnCodes {error} -result {unknown color name "non-existent"} +} -returnCodes error -result {unknown color name "non-existent"} test entry-1.47 {configuration option: "selectborderwidth" for entry} -setup { entry .e -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} @@ -522,7 +522,7 @@ test entry-1.48 {configuration option: "selectborderwidth" for entry} -setup { .e configure -selectborderwidth badValue } -cleanup { destroy .e -} -returnCodes {error} -result {bad screen distance "badValue"} +} -returnCodes error -result {bad screen distance "badValue"} test entry-1.49 {configuration option: "selectforeground" for entry} -setup { entry .e -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} @@ -542,7 +542,7 @@ test entry-1.50 {configuration option: "selectforeground" for entry} -setup { .e configure -selectforeground non-existent } -cleanup { destroy .e -} -returnCodes {error} -result {unknown color name "non-existent"} +} -returnCodes error -result {unknown color name "non-existent"} test entry-1.51 {configuration option: "show" for entry} -setup { entry .e -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} @@ -573,7 +573,7 @@ test entry-1.53 {configuration option: "state" for entry} -setup { .e configure -state bogus } -cleanup { destroy .e -} -returnCodes {error} -result {bad state "bogus": must be disabled, normal, or readonly} +} -returnCodes error -result {bad state "bogus": must be disabled, normal, or readonly} test entry-1.54 {configuration option: "takefocus" for entry} -setup { entry .e -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} @@ -615,7 +615,7 @@ test entry-1.57 {configuration option: "width" for entry} -setup { .e configure -width 3p } -cleanup { destroy .e -} -returnCodes {error} -result {expected integer but got "3p"} +} -returnCodes error -result {expected integer but got "3p"} test entry-1.58 {configuration option: "xscrollcommand" for entry} -setup { entry .e -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} @@ -3517,7 +3517,7 @@ test entry-22.1 {lost namespaced textvar} -body { set ::test::foo } -cleanup { destroy .e -} -returnCodes error -result {can't read "::test::foo": no such variable} +} -match glob -returnCodes error -result {can*t read "::test::foo": no such variable} test entry-22.2 {lost namespaced textvar} -body { namespace eval test { variable foo {a b} } entry .e -textvariable ::test::foo @@ -3528,10 +3528,10 @@ test entry-22.2 {lost namespaced textvar} -body { list [.e get] [.e cget -textvar] $result1 $result2 $result3 } -cleanup { destroy .e -} -result [list "a bmo" ::test::foo \ - {can't set "::test::foo": parent namespace doesn't exist} \ - {can't set "::test::foo": parent namespace doesn't exist} \ - {can't read "::test::foo": no such variable}] +} -match glob -result [list "a bmo" ::test::foo \ + {can*t set "::test::foo": parent namespace does*t exist} \ + {can*t set "::test::foo": parent namespace does*t exist} \ + {can*t read "::test::foo": no such variable}] test entry-23.1 {error in trace proc attached to the textvariable} -setup { destroy .e @@ -3544,8 +3544,8 @@ test entry-23.1 {error in trace proc attached to the textvariable} -setup { list $result1 $result2 } -cleanup { destroy .e -} -result [list {can't set "myvar": Intentional error here!} \ - {can't set "myvar": Intentional error here!}] +} -match glob -result [list {ca*t set "myvar": Intentional error here!} \ + {can*t set "myvar": Intentional error here!}] test entry-24.1 {textvariable lives in a non-existing namespace} -setup { destroy .e @@ -3554,7 +3554,7 @@ test entry-24.1 {textvariable lives in a non-existing namespace} -setup { set result1 } -cleanup { destroy .e -} -result {can't trace "thisnsdoesntexist::myvar": parent namespace doesn't exist} +} -match glob -result {can*t trace "thisnsdoesntexist::myvar": parent namespace does*t exist} test entry-25.1 {Bug [5d991b822e]} { # Want this not to segfault, or write to variable with empty name diff --git a/tests/event.test b/tests/event.test index 8f5490de4..147eb326f 100644 --- a/tests/event.test +++ b/tests/event.test @@ -3,7 +3,7 @@ # # Copyright (c) 1994 The Regents of the University of California. # Copyright (c) 1994-1995 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. package require tcltest 2.2 @@ -24,53 +24,53 @@ proc _init_keypress_lookup {} { scan Z %c finish for {set i $start} {$i <= $finish} {incr i} { - set l [format %c $i] - set keypress_lookup($l) $l + set l [format %c $i] + set keypress_lookup($l) $l } scan a %c start scan z %c finish for {set i $start} {$i <= $finish} {incr i} { - set l [format %c $i] - set keypress_lookup($l) $l + set l [format %c $i] + set keypress_lookup($l) $l } scan 0 %c start scan 9 %c finish for {set i $start} {$i <= $finish} {incr i} { - set l [format %c $i] - set keypress_lookup($l) $l + set l [format %c $i] + set keypress_lookup($l) $l } # Most punctuation array set keypress_lookup { - ! exclam - % percent - & ampersand - ( parenleft - ) parenright - * asterisk - + plus - , comma - - minus - . period - / slash - : colon - < less - = equal - > greater - ? question - @ at - ^ asciicircum - _ underscore - | bar - ~ asciitilde - ' apostrophe + ! exclam + % percent + & ampersand + ( parenleft + ) parenright + * asterisk + + plus + , comma + . period + / slash + : colon + < less + = equal + ? question + @ at + ^ asciicircum + _ underscore + | bar + ~ asciitilde + ' apostrophe } # Characters with meaning to Tcl... array set keypress_lookup [list \ + - minus \ + > greater \ \" quotedbl \ \# numbersign \ \$ dollar \ @@ -81,6 +81,7 @@ proc _init_keypress_lookup {} { \{ braceleft \ \} braceright \ " " space \ + \xA0 nobreakspace \ "\n" Return \ "\t" Tab] } @@ -88,8 +89,8 @@ proc _init_keypress_lookup {} { # Lookup an event in the keypress table. # For example: # Q -> Q -# . -> period -# / -> slash +# ; -> semicolon +# > -> greater # Delete -> Delete # Escape -> Escape @@ -97,21 +98,21 @@ proc _keypress_lookup {char} { global keypress_lookup if {! [info exists keypress_lookup]} { - _init_keypress_lookup + _init_keypress_lookup } if {$char == ""} { - error "empty char" + error "empty char" } if {[info exists keypress_lookup($char)]} { - return $keypress_lookup($char) + return $keypress_lookup($char) } else { - return $char + return $char } } -# Lookup and generate a pair of KeyPress and KeyRelease events +# Lookup and generate a pair of Key and KeyRelease events proc _keypress {win key} { set keysym [_keypress_lookup $key] @@ -122,12 +123,12 @@ proc _keypress {win key} { # the focus if the mouse is moved around. if {[focus] != $win} { - focus -force $win + focus -force $win } - event generate $win + event generate $win _pause 50 if {[focus] != $win} { - focus -force $win + focus -force $win } event generate $win _pause 50 @@ -137,7 +138,7 @@ proc _keypress {win key} { proc _keypress_string {win string} { foreach letter [split $string ""] { - _keypress $win $letter + _keypress $win $letter } } @@ -147,7 +148,7 @@ proc _pause {{msecs 1000}} { global _pause if {! [info exists _pause(number)]} { - set _pause(number) 0 + set _pause(number) 0 } set num [incr _pause(number)] @@ -163,7 +164,7 @@ proc _pause {{msecs 1000}} { proc _text_ind_to_x_y {text ind} { set bbox [$text bbox $ind] if {[llength $bbox] != 4} { - error "got bbox \{$bbox\} from $text, index $ind" + error "got bbox \{$bbox\} from $text, index $ind" } foreach {x1 y1 width height} $bbox break set middle_y [expr {$y1 + ($height / 2)}] @@ -174,10 +175,10 @@ proc _text_ind_to_x_y {text ind} { proc _get_selection {widget} { if {[string compare $widget [selection own]] != 0} { - return "" + return "" } if {[catch {selection get} sel]} { - return "" + return "" } return $sel } @@ -194,10 +195,10 @@ test event-1.1 {Tk_HandleEvent procedure, filter events for dead windows} -setup update bind .b { lappend x destroy - event generate .b <1> + event generate .b event generate .b } - bind .b <1> { + bind .b { lappend x button } @@ -255,7 +256,7 @@ test event-2.2(keypress) {type into entry widget and then delete some text} -set deleteWindows } -result {MEL} test event-2.3(keypress) {type into entry widget, triple click, hit Delete key, - and then type some more} -setup { + and then type some more} -setup { deleteWindows } -body { set t [toplevel .t] @@ -268,10 +269,10 @@ test event-2.3(keypress) {type into entry widget, triple click, hit Delete key, event generate $e for {set i 0} {$i < 3} {incr i} { - _pause 100 - event generate $e - _pause 100 - event generate $e + _pause 100 + event generate $e + _pause 100 + event generate $e } _keypress $e Delete @@ -311,6 +312,7 @@ test event-2.5(keypress) {type into text widget and then delete some text} -setu test event-2.6(keypress) {type into text widget, triple click, hit Delete key, and then type some more} -setup { deleteWindows + update idletasks } -body { set t [toplevel .t] set e [text $t.e] @@ -322,10 +324,10 @@ test event-2.6(keypress) {type into text widget, triple click, event generate $e for {set i 0} {$i < 3} {incr i} { - _pause 100 - event generate $e - _pause 100 - event generate $e + _pause 100 + event generate $e + _pause 100 + event generate $e } _keypress $e Delete @@ -355,7 +357,7 @@ test event-3.1(click-drag) {click and drag in a text widget, this tests # Click down to set the insert cursor position event generate $e - event generate $e -x $anchor_x -y $anchor_y + event generate $e -x $anchor_x -y $anchor_y # Save the position of the insert cursor lappend result [$e index insert] @@ -364,10 +366,10 @@ test event-3.1(click-drag) {click and drag in a text widget, this tests set current $anchor while {[$e compare $current <= $selend]} { - foreach {current_x current_y} [_text_ind_to_x_y $e $current] break - event generate $e -x $current_x -y $current_y - set current [$e index [list $current + 1 char]] - _pause 50 + foreach {current_x current_y} [_text_ind_to_x_y $e $current] break + event generate $e -x $current_x -y $current_y + set current [$e index [list $current + 1 char]] + _pause 50 } event generate $e -x $current_x -y $current_y @@ -381,13 +383,13 @@ test event-3.1(click-drag) {click and drag in a text widget, this tests # Now click and click and drag to the left, over "Tcl/Tk selection" - event generate $e -x $current_x -y $current_y + event generate $e -x $current_x -y $current_y while {[$e compare $current >= [list $anchor - 4 char]]} { - foreach {current_x current_y} [_text_ind_to_x_y $e $current] break - event generate $e -x $current_x -y $current_y - set current [$e index [list $current - 1 char]] - _pause 50 + foreach {current_x current_y} [_text_ind_to_x_y $e $current] break + event generate $e -x $current_x -y $current_y + set current [$e index [list $current - 1 char]] + _pause 50 } event generate $e -x $current_x -y $current_y @@ -422,7 +424,7 @@ test event-3.1(click-drag) {click and drag in a text widget, this tests # Click down to set the insert cursor position event generate $e - event generate $e -x $anchor_x -y $anchor_y + event generate $e -x $anchor_x -y $anchor_y # Save the position of the insert cursor lappend result [$e index insert] @@ -431,10 +433,10 @@ test event-3.1(click-drag) {click and drag in a text widget, this tests set current $anchor while {$current <= $selend} { - foreach {current_x current_y} [_text_ind_to_x_y $e $current] break - event generate $e -x $current_x -y $current_y - incr current - _pause 50 + foreach {current_x current_y} [_text_ind_to_x_y $e $current] break + event generate $e -x $current_x -y $current_y + incr current + _pause 50 } event generate $e -x $current_x -y $current_y @@ -448,13 +450,13 @@ test event-3.1(click-drag) {click and drag in a text widget, this tests # Now click and click and drag to the left, over "Tcl/Tk selection" - event generate $e -x $current_x -y $current_y + event generate $e -x $current_x -y $current_y while {$current >= ($anchor - 4)} { - foreach {current_x current_y} [_text_ind_to_x_y $e $current] break - event generate $e -x $current_x -y $current_y - incr current -1 - _pause 50 + foreach {current_x current_y} [_text_ind_to_x_y $e $current] break + event generate $e -x $current_x -y $current_y + incr current -1 + _pause 50 } event generate $e -x $current_x -y $current_y @@ -487,11 +489,11 @@ test event-4.1(double-click-drag) {click down, click up, click down again, # Click down, release, then click down again event generate $e - event generate $e -x $anchor_x -y $anchor_y + event generate $e -x $anchor_x -y $anchor_y _pause 50 event generate $e -x $anchor_x -y $anchor_y _pause 50 - event generate $e -x $anchor_x -y $anchor_y + event generate $e -x $anchor_x -y $anchor_y _pause 50 # Save the highlighted text @@ -558,11 +560,11 @@ test event-4.2(double-click-drag) {click down, click up, click down again, # Click down, release, then click down again event generate $e - event generate $e -x $anchor_x -y $anchor_y + event generate $e -x $anchor_x -y $anchor_y _pause 50 event generate $e -x $anchor_x -y $anchor_y _pause 50 - event generate $e -x $anchor_x -y $anchor_y + event generate $e -x $anchor_x -y $anchor_y _pause 50 set result [list] @@ -613,7 +615,7 @@ test event-4.2(double-click-drag) {click down, click up, click down again, } -result {select 11 7 select 4 { select} {Word select} 2} test event-5.1(triple-click-drag) {Triple click and drag across lines in a - text widget, this should extend the selection to the new line} -setup { + text widget, this should extend the selection to the new line} -setup { deleteWindows } -body { set t [toplevel .t] @@ -630,17 +632,17 @@ test event-5.1(triple-click-drag) {Triple click and drag across lines in a event generate $e - event generate $e -x $anchor_x -y $anchor_y + event generate $e -x $anchor_x -y $anchor_y _pause 50 event generate $e -x $anchor_x -y $anchor_y _pause 50 - event generate $e -x $anchor_x -y $anchor_y + event generate $e -x $anchor_x -y $anchor_y _pause 50 event generate $e -x $anchor_x -y $anchor_y _pause 50 - event generate $e -x $anchor_x -y $anchor_y + event generate $e -x $anchor_x -y $anchor_y _pause 50 set result [list] @@ -670,17 +672,17 @@ test event-5.1(triple-click-drag) {Triple click and drag across lines in a } -cleanup { deleteWindows } -result [list "LINE THREE\n" "LINE TWO\nLINE THREE\n" \ - "LINE ONE\nLINE TWO\nLINE THREE\n"] + "LINE ONE\nLINE TWO\nLINE THREE\n"] test event-6.1(button-state) {button press in a window that is then - destroyed, when the mouse is moved into another window it - should not generate a event since the mouse - was not pressed down in that window} -setup { + destroyed, when the mouse is moved into another window it + should not generate a event since the mouse + was not pressed down in that window} -setup { deleteWindows } -body { set t [toplevel .t] - event generate $t + event generate $t destroy $t set t [toplevel .t] set motion nomotion @@ -719,11 +721,11 @@ test event-7.1(double-click) {A double click on a lone character # Double click near left hand egde of the letter A event generate $e - event generate $e -x $left_x -y $left_y + event generate $e -x $left_x -y $left_y _pause 50 event generate $e -x $left_x -y $left_y _pause 50 - event generate $e -x $left_x -y $left_y + event generate $e -x $left_x -y $left_y _pause 50 event generate $e -x $left_x -y $left_y _pause 50 @@ -734,18 +736,18 @@ test event-7.1(double-click) {A double click on a lone character # Clear selection by clicking at 0,0 - event generate $e -x 0 -y 0 + event generate $e -x 0 -y 0 _pause 50 event generate $e -x 0 -y 0 _pause 50 # Double click near right hand edge of the letter A - event generate $e -x $right_x -y $right_y + event generate $e -x $right_x -y $right_y _pause 50 event generate $e -x $right_x -y $right_y _pause 50 - event generate $e -x $right_x -y $right_y + event generate $e -x $right_x -y $right_y _pause 50 event generate $e -x $right_x -y $right_y _pause 50 @@ -786,11 +788,11 @@ test event-7.2(double-click) {A double click on a lone character # Double click near left hand egde of the letter A event generate $e - event generate $e -x $left_x -y $left_y + event generate $e -x $left_x -y $left_y _pause 50 event generate $e -x $left_x -y $left_y _pause 50 - event generate $e -x $left_x -y $left_y + event generate $e -x $left_x -y $left_y _pause 50 event generate $e -x $left_x -y $left_y _pause 50 @@ -801,18 +803,18 @@ test event-7.2(double-click) {A double click on a lone character # Clear selection by clicking at 0,0 - event generate $e -x 0 -y 0 + event generate $e -x 0 -y 0 _pause 50 event generate $e -x 0 -y 0 _pause 50 # Double click near right hand edge of the letter A - event generate $e -x $right_x -y $right_y + event generate $e -x $right_x -y $right_y _pause 50 event generate $e -x $right_x -y $right_y _pause 50 - event generate $e -x $right_x -y $right_y + event generate $e -x $right_x -y $right_y _pause 50 event generate $e -x $right_x -y $right_y _pause 50 @@ -827,8 +829,8 @@ test event-7.2(double-click) {A double click on a lone character } -result {4 A 4 A} test event-8 {event generate with keysyms corresponding to - multi-byte virtual keycodes - bug - e36963bfe8df9f5e528134707a91b9c0051de723} -constraints nonPortable -setup { + multi-byte virtual keycodes - bug + e36963bfe8df9f5e528134707a91b9c0051de723} -constraints nonPortable -setup { deleteWindows set res [list ] } -body { @@ -836,7 +838,7 @@ test event-8 {event generate with keysyms corresponding to set e [entry $t.e] pack $e tkwait visibility $e - bind $e {lappend res keycode: %k keysym: %K} + bind $e {lappend res keycode: %k keysym: %K} focus -force $e update event generate $e @@ -850,12 +852,12 @@ test event-8 {event generate with keysyms corresponding to # running the test does not have a keyboard with a # diaeresis key. if {[expr {[lindex $res 3] ne "??"}]} { - # keyboard has a physical diaeresis key and bug is fixed - return "OK" + # keyboard has a physical diaeresis key and bug is fixed + return "OK" } else { - return "Test failed, unless the keyboard tied to the system \ - on which this test is run does NOT have a diaeresis \ - physical key - in this case, test is actually void." + return "Test failed, unless the keyboard tied to the system \ + on which this test is run does NOT have a diaeresis \ + physical key - in this case, test is actually void." } } -cleanup { deleteWindows @@ -887,9 +889,9 @@ test event-9.1 {enter . window by destroying a toplevel - bug b1d115fa60} -setup test event-9.2 {enter toplevel window by destroying a toplevel - bug b1d115fa60} -setup { set iconified false if {[winfo ismapped .]} { - wm iconify . - update - set iconified true + wm iconify . + update + set iconified true } } -body { toplevel .top1 @@ -913,8 +915,8 @@ test event-9.2 {enter toplevel window by destroying a toplevel - bug b1d115fa60} } -cleanup { deleteWindows ; # destroy all children of ".", this already includes .top1 if {$iconified} { - wm deiconify . - update + wm deiconify . + update } } -result {.top1} diff --git a/tests/filebox.test b/tests/filebox.test index 3c48846df..fca339b57 100644 --- a/tests/filebox.test +++ b/tests/filebox.test @@ -3,7 +3,7 @@ # for Tcl tests. # # Copyright (c) 1996 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. package require tcltest 2.2 diff --git a/tests/focus.test b/tests/focus.test index 03ac8c7bb..e0d6743d3 100644 --- a/tests/focus.test +++ b/tests/focus.test @@ -3,7 +3,7 @@ # standard fashion for Tcl tests. # # Copyright (c) 1994-1996 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. package require tcltest 2.2 diff --git a/tests/focusTcl.test b/tests/focusTcl.test index 0e457a6a3..33d9f1220 100644 --- a/tests/focusTcl.test +++ b/tests/focusTcl.test @@ -4,7 +4,7 @@ # standard fashion for Tcl tests. # # Copyright (c) 1995 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. package require tcltest 2.2 diff --git a/tests/font.test b/tests/font.test index 277139f29..a6223c38a 100644 --- a/tests/font.test +++ b/tests/font.test @@ -3,7 +3,7 @@ # standard white-box fashion for Tcl tests. # # Copyright (c) 1996-1998 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. package require tcltest 2.2 diff --git a/tests/frame.test b/tests/frame.test index a7f1b0b97..1bb9464f6 100644 --- a/tests/frame.test +++ b/tests/frame.test @@ -4,7 +4,7 @@ # # Copyright (c) 1994 The Regents of the University of California. # Copyright (c) 1994-1996 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. package require tcltest 2.2 diff --git a/tests/geometry.test b/tests/geometry.test index d3bb0c5d9..4693c6485 100644 --- a/tests/geometry.test +++ b/tests/geometry.test @@ -4,7 +4,7 @@ # # Copyright (c) 1994 The Regents of the University of California. # Copyright (c) 1994 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. proc getsize w { diff --git a/tests/get.test b/tests/get.test index ea08c8c71..24ba1a0c3 100644 --- a/tests/get.test +++ b/tests/get.test @@ -3,7 +3,7 @@ # white-box tests. # # Copyright (c) 1998 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. package require tcltest 2.2 @@ -97,7 +97,7 @@ test get-1.11 {Tk_GetAnchorFromObj - error} -setup { .b configure -anchor unknown } -cleanup { destroy .b -} -returnCodes {error} -result {bad anchor "unknown": must be n, ne, e, se, s, sw, w, nw, or center} +} -returnCodes error -result {bad anchor "unknown": must be n, ne, e, se, s, sw, w, nw, or center} test get-2.1 {Tk_GetJustifyFromObj} -setup { @@ -130,7 +130,7 @@ test get-2.4 {Tk_GetJustifyFromObj - error} -setup { .b configure -justify stupid } -cleanup { destroy .b -} -returnCodes {error} -result {bad justification "stupid": must be left, right, or center} +} -returnCodes error -result {bad justification "stupid": must be left, right, or center} # cleanup cleanupTests diff --git a/tests/grab.test b/tests/grab.test index 2eeb54555..804711a3e 100644 --- a/tests/grab.test +++ b/tests/grab.test @@ -4,7 +4,7 @@ # built-in commands. Sourcing this file runs the tests and # generates output for errors. No output means no errors were found. # -# Copyright (c) 1998-2000 by Ajuba Solutions. +# Copyright (c) 1998-2000 Ajuba Solutions. # All rights reserved. package require tcltest 2.2 diff --git a/tests/grid.test b/tests/grid.test index 89897cafd..a23a3a227 100644 --- a/tests/grid.test +++ b/tests/grid.test @@ -2,7 +2,7 @@ # (almost) organized in the standard fashion for Tcl tests. # # Copyright (c) 1996 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. package require tcltest 2.2 diff --git a/tests/image.test b/tests/image.test index f11682737..0e565ad51 100644 --- a/tests/image.test +++ b/tests/image.test @@ -4,7 +4,7 @@ # # Copyright (c) 1994 The Regents of the University of California. # Copyright (c) 1994 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. package require tcltest 2.2 diff --git a/tests/imgBmap.test b/tests/imgBmap.test index 8f5b5fb20..3d6ef734a 100644 --- a/tests/imgBmap.test +++ b/tests/imgBmap.test @@ -4,7 +4,7 @@ # # Copyright (c) 1994 The Regents of the University of California. # Copyright (c) 1994-1995 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. package require tcltest 2.2 diff --git a/tests/imgPNG.test b/tests/imgPNG.test index 4bd4e4028..d64c9bdc7 100644 --- a/tests/imgPNG.test +++ b/tests/imgPNG.test @@ -3,7 +3,7 @@ # in the standard fashion for Tcl tests. # # Copyright (c) 1994-1997 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # Copyright (c) 1998 Willem van Schaik (images only) # Copyright (c) 2008 Donal K. Fellows # All rights reserved. diff --git a/tests/imgPPM.test b/tests/imgPPM.test index e3a738aee..38c262fc2 100644 --- a/tests/imgPPM.test +++ b/tests/imgPPM.test @@ -3,7 +3,7 @@ # The files is organized in the standard fashion for Tcl tests. # # Copyright (c) 1994-1997 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. package require tcltest 2.2 diff --git a/tests/imgPhoto.test b/tests/imgPhoto.test index 34107cce8..01673dc35 100644 --- a/tests/imgPhoto.test +++ b/tests/imgPhoto.test @@ -4,7 +4,7 @@ # # Copyright (c) 1994 The Australian National University # Copyright (c) 1994-1997 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # Copyright (c) 2002-2008 Donal K. Fellows # All rights reserved. # diff --git a/tests/listbox.test b/tests/listbox.test index 6bd49ff42..3b15a0d5a 100644 --- a/tests/listbox.test +++ b/tests/listbox.test @@ -3,7 +3,7 @@ # # Copyright (c) 1993-1994 The Regents of the University of California. # Copyright (c) 1994-1997 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. package require tcltest 2.2 @@ -1485,8 +1485,8 @@ test listbox-4.19 {ConfigureListbox, no listvar -> bad non-existent listvar} -se list [.l2 get 0 end] [.l2 cget -listvar] $foo $result } -cleanup { destroy .l2 -} -result [list [list a b c d] foo [list a b c d] \ - {can't set "::zoo::bar::foo": parent namespace doesn't exist}] +} -match glob -result [list [list a b c d] foo [list a b c d] \ + {can*t set "::zoo::bar::foo": parent namespace does*t exist}] # No tests for DisplayListbox: I don't know how to test this procedure. diff --git a/tests/main.test b/tests/main.test index 4a3be63c3..2c440ceb0 100644 --- a/tests/main.test +++ b/tests/main.test @@ -4,8 +4,8 @@ # built-in commands. Sourcing this file into Tcl runs the tests and # generates output for errors. No output means no errors were found. # -# Copyright (c) 1997 by Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1997 Sun Microsystems, Inc. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. package require tcltest 2.2 diff --git a/tests/menu.test b/tests/menu.test index 6ce702c29..5332648e2 100644 --- a/tests/menu.test +++ b/tests/menu.test @@ -2,7 +2,7 @@ # organized in the standard fashion for Tcl tests. # # Copyright (c) 1995-1997 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. package require tcltest 2.2 diff --git a/tests/menuDraw.test b/tests/menuDraw.test index bf15f25e0..bef92bd15 100644 --- a/tests/menuDraw.test +++ b/tests/menuDraw.test @@ -2,7 +2,7 @@ # organized in the standard fashion for Tcl tests. # # Copyright (c) 1996-1997 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. package require tcltest 2.2 diff --git a/tests/menubut.test b/tests/menubut.test index 81794f78a..617a2de4a 100644 --- a/tests/menubut.test +++ b/tests/menubut.test @@ -3,7 +3,7 @@ # # Copyright (c) 1994 The Regents of the University of California. # Copyright (c) 1994-1996 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. # XXX This test file is woefully incomplete right now. If any part diff --git a/tests/message.test b/tests/message.test index 4d6c77fc1..f91030482 100644 --- a/tests/message.test +++ b/tests/message.test @@ -3,7 +3,7 @@ # # Copyright (c) 1994 The Regents of the University of California. # Copyright (c) 1994-1996 Sun Microsystems, Inc. -# Copyright (c) 1998-2000 by Ajuba Solutions. +# Copyright (c) 1998-2000 Ajuba Solutions. # All rights reserved. package require tcltest 2.2 @@ -30,7 +30,7 @@ test message-1.2 {configuration option: "anchor"} -setup { .m configure -anchor bogus } -cleanup { destroy .m -} -returnCodes {error} -result {bad anchor "bogus": must be n, ne, e, se, s, sw, w, nw, or center} +} -returnCodes error -result {bad anchor "bogus": must be n, ne, e, se, s, sw, w, nw, or center} test message-1.3 {configuration option: "aspect"} -setup { message .m -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} @@ -50,7 +50,7 @@ test message-1.4 {configuration option: "aspect"} -setup { .m configure -aspect bogus } -cleanup { destroy .m -} -returnCodes {error} -result {expected integer but got "bogus"} +} -returnCodes error -result {expected integer but got "bogus"} test message-1.5 {configuration option: "background"} -setup { message .m -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} @@ -70,7 +70,7 @@ test message-1.6 {configuration option: "background"} -setup { .m configure -background non-existent } -cleanup { destroy .m -} -returnCodes {error} -result {unknown color name "non-existent"} +} -returnCodes error -result {unknown color name "non-existent"} test message-1.7 {configuration option: "bd"} -setup { message .m -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} @@ -90,7 +90,7 @@ test message-1.8 {configuration option: "bd"} -setup { .m configure -bd badValue } -cleanup { destroy .m -} -returnCodes {error} -result {bad screen distance "badValue"} +} -returnCodes error -result {bad screen distance "badValue"} test message-1.9 {configuration option: "bg"} -setup { message .m -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} @@ -110,7 +110,7 @@ test message-1.10 {configuration option: "bg"} -setup { .m configure -bg non-existent } -cleanup { destroy .m -} -returnCodes {error} -result {unknown color name "non-existent"} +} -returnCodes error -result {unknown color name "non-existent"} test message-1.11 {configuration option: "borderwidth"} -setup { message .m -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} @@ -130,7 +130,7 @@ test message-1.12 {configuration option: "borderwidth"} -setup { .m configure -borderwidth badValue } -cleanup { destroy .m -} -returnCodes {error} -result {bad screen distance "badValue"} +} -returnCodes error -result {bad screen distance "badValue"} test message-1.13 {configuration option: "cursor"} -setup { message .m -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} @@ -150,7 +150,7 @@ test message-1.14 {configuration option: "cursor"} -setup { .m configure -cursor badValue } -cleanup { destroy .m -} -returnCodes {error} -result {bad cursor spec "badValue"} +} -returnCodes error -result {bad cursor spec "badValue"} test message-1.15 {configuration option: "fg"} -setup { message .m -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} @@ -170,7 +170,7 @@ test message-1.16 {configuration option: "fg"} -setup { .m configure -fg badValue } -cleanup { destroy .m -} -returnCodes {error} -result {unknown color name "badValue"} +} -returnCodes error -result {unknown color name "badValue"} test message-1.17 {configuration option: "font"} -setup { message .m -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} @@ -190,7 +190,7 @@ test message-1.18 {configuration option: "font"} -setup { .m configure -font {} } -cleanup { destroy .m -} -returnCodes {error} -result {font "" doesn't exist} +} -returnCodes error -result {font "" doesn't exist} test message-1.19 {configuration option: "-foreground"} -setup { message .m -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} @@ -210,7 +210,7 @@ test message-1.20 {configuration option: "-foreground"} -setup { .m configure -foreground badValue } -cleanup { destroy .m -} -returnCodes {error} -result {unknown color name "badValue"} +} -returnCodes error -result {unknown color name "badValue"} test message-1.21 {configuration option: "highlightbackground"} -setup { message .m -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} @@ -230,7 +230,7 @@ test message-1.22 {configuration option: "highlightbackground"} -setup { .m configure -highlightbackground ugly } -cleanup { destroy .m -} -returnCodes {error} -result {unknown color name "ugly"} +} -returnCodes error -result {unknown color name "ugly"} test message-1.23 {configuration option: "highlightcolor"} -setup { message .m -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} @@ -250,7 +250,7 @@ test message-1.24 {configuration option: "highlightcolor"} -setup { .m configure -highlightcolor non-existent } -cleanup { destroy .m -} -returnCodes {error} -result {unknown color name "non-existent"} +} -returnCodes error -result {unknown color name "non-existent"} test message-1.25 {configuration option: "highlightthickness"} -setup { message .m -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} @@ -270,7 +270,7 @@ test message-1.26 {configuration option: "highlightthickness"} -setup { .m configure -highlightthickness badValue } -cleanup { destroy .m -} -returnCodes {error} -result {bad screen distance "badValue"} +} -returnCodes error -result {bad screen distance "badValue"} test message-1.27 {configuration option: "justify"} -setup { message .m -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} @@ -290,7 +290,7 @@ test message-1.28 {configuration option: "justify"} -setup { .m configure -justify bogus } -cleanup { destroy .m -} -returnCodes {error} -result {bad justification "bogus": must be left, right, or center} +} -returnCodes error -result {bad justification "bogus": must be left, right, or center} test message-1.29 {configuration option: "padx"} -setup { message .m -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} @@ -310,7 +310,7 @@ test message-1.30 {configuration option: "padx"} -setup { .m configure -padx 420x } -cleanup { destroy .m -} -returnCodes {error} -result {bad screen distance "420x"} +} -returnCodes error -result {bad screen distance "420x"} test message-1.31 {configuration option: "pady"} -setup { message .m -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} @@ -330,7 +330,7 @@ test message-1.32 {configuration option: "pady"} -setup { .m configure -pady 420x } -cleanup { destroy .m -} -returnCodes {error} -result {bad screen distance "420x"} +} -returnCodes error -result {bad screen distance "420x"} test message-1.33 {configuration option: "relief"} -setup { message .m -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} @@ -350,7 +350,7 @@ test message-1.34 {configuration option: "relief"} -setup { .m configure -relief badValue } -cleanup { destroy .m -} -returnCodes {error} -result {bad relief "badValue": must be flat, groove, raised, ridge, solid, or sunken} +} -returnCodes error -result {bad relief "badValue": must be flat, groove, raised, ridge, solid, or sunken} test message-1.35 {configuration options: "text"} -setup { message .m -borderwidth 2 -highlightthickness 2 -font {Helvetica -12 bold} @@ -392,16 +392,16 @@ test message-1.38 {configuration option: "width"} -setup { .m configure -width badValue } -cleanup { destroy .m -} -returnCodes {error} -result {bad screen distance "badValue"} +} -returnCodes error -result {bad screen distance "badValue"} test message-2.1 {Tk_MessageObjCmd procedure} -body { message -} -returnCodes {error} -result {wrong # args: should be "message pathName ?-option value ...?"} +} -returnCodes error -result {wrong # args: should be "message pathName ?-option value ...?"} test message-2.2 {Tk_MessageObjCmd procedure} -body { message foo -} -returnCodes {error} -result {bad window path name "foo"} +} -returnCodes error -result {bad window path name "foo"} test message-2.3 {Tk_MessageObjCmd procedure} -body { catch {message foo} winfo children . @@ -409,7 +409,7 @@ test message-2.3 {Tk_MessageObjCmd procedure} -body { test message-2.4 {Tk_MessageObjCmd procedure} -body { message .s -gorp dump -} -returnCodes {error} -result {unknown option "-gorp"} +} -returnCodes error -result {unknown option "-gorp"} test message-2.5 {Tk_MessageObjCmd procedure} -body { catch {message .s -gorp dump} winfo children . diff --git a/tests/msgbox.test b/tests/msgbox.test index 4a6de5796..1c60009b5 100644 --- a/tests/msgbox.test +++ b/tests/msgbox.test @@ -2,7 +2,7 @@ # It is organized in the standard fashion for Tcl tests. # # Copyright (c) 1996 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. package require tcltest 2.2 diff --git a/tests/obj.test b/tests/obj.test index eece58e7a..d5d907e86 100644 --- a/tests/obj.test +++ b/tests/obj.test @@ -2,7 +2,7 @@ # It is organized in the standard fashion for Tcl tests. # # Copyright (c) 1997 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. package require tcltest 2.2 diff --git a/tests/oldpack.test b/tests/oldpack.test index 00de930ce..51c627312 100644 --- a/tests/oldpack.test +++ b/tests/oldpack.test @@ -4,7 +4,7 @@ # # Copyright (c) 1991-1994 The Regents of the University of California. # Copyright (c) 1994 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. package require tcltest 2.2 diff --git a/tests/option.test b/tests/option.test index 0d89ec548..9ed2756b4 100644 --- a/tests/option.test +++ b/tests/option.test @@ -3,7 +3,7 @@ # # Copyright (c) 1991-1993 The Regents of the University of California. # Copyright (c) 1994 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. package require tcltest 2.2 diff --git a/tests/pack.test b/tests/pack.test index 6ee65f4f9..539d2e416 100644 --- a/tests/pack.test +++ b/tests/pack.test @@ -3,7 +3,7 @@ # # Copyright (c) 1993 The Regents of the University of California. # Copyright (c) 1994 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. package require tcltest 2.2 diff --git a/tests/panedwindow.test b/tests/panedwindow.test index 192bff4a0..7e40a9845 100644 --- a/tests/panedwindow.test +++ b/tests/panedwindow.test @@ -3,7 +3,7 @@ # # Copyright (c) 1994 The Regents of the University of California. # Copyright (c) 1994-1997 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. package require tcltest 2.2 diff --git a/tests/place.test b/tests/place.test index 5927f2fc4..ee6c6b850 100644 --- a/tests/place.test +++ b/tests/place.test @@ -2,7 +2,7 @@ # organized in the standard fashion for Tcl tests. # # Copyright (c) 1995 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. package require tcltest 2.2 diff --git a/tests/raise.test b/tests/raise.test index d4ffe4967..7a7558b0b 100644 --- a/tests/raise.test +++ b/tests/raise.test @@ -5,7 +5,7 @@ # # Copyright (c) 1993-1994 The Regents of the University of California. # Copyright (c) 1994 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. package require tcltest 2.2 diff --git a/tests/safePrimarySelection.test b/tests/safePrimarySelection.test index 30d8fe13d..45fc4fdcd 100644 --- a/tests/safePrimarySelection.test +++ b/tests/safePrimarySelection.test @@ -3,7 +3,7 @@ # # Copyright (c) 1994 The Regents of the University of California. # Copyright (c) 1994-1997 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. package require tcltest 2.2 diff --git a/tests/scale.test b/tests/scale.test index 6fc0089e1..a00753797 100644 --- a/tests/scale.test +++ b/tests/scale.test @@ -3,7 +3,7 @@ # # Copyright (c) 1994 The Regents of the University of California. # Copyright (c) 1994-1996 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. package require tcltest 2.2 diff --git a/tests/scrollbar.test b/tests/scrollbar.test index fe10d5b96..f6139d618 100644 --- a/tests/scrollbar.test +++ b/tests/scrollbar.test @@ -4,7 +4,7 @@ # # Copyright (c) 1994 The Regents of the University of California. # Copyright (c) 1994-1997 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. package require tcltest 2.2 diff --git a/tests/select.test b/tests/select.test index bc41ce5a2..914adc260 100644 --- a/tests/select.test +++ b/tests/select.test @@ -3,7 +3,7 @@ # for Tcl tests. # # Copyright (c) 1994 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. # diff --git a/tests/send.test b/tests/send.test index 722005bf1..b97b94dd1 100644 --- a/tests/send.test +++ b/tests/send.test @@ -4,8 +4,8 @@ # # Copyright (c) 1994 Sun Microsystems, Inc. # Copyright (c) 1994-1996 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. -# Copyright (c) 2001 by ActiveState Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. +# Copyright (c) 2001 ActiveState Corporation. # # See the file "license.terms" for information on usage and redistribution # of this file, and for a DISCLAIMER OF ALL WARRANTIES. diff --git a/tests/spinbox.test b/tests/spinbox.test index d0dad2b7f..4a7bd2fa3 100644 --- a/tests/spinbox.test +++ b/tests/spinbox.test @@ -3,7 +3,7 @@ # # Copyright (c) 1994 The Regents of the University of California. # Copyright (c) 1994-1997 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. package require tcltest 2.2 @@ -60,7 +60,7 @@ test spinbox-1.2 {configuration option: "activebackground" for spinbox} -setup { .e configure -activebackground non-existent } -cleanup { destroy .e -} -returnCodes {error} -result {unknown color name "non-existent"} +} -returnCodes error -result {unknown color name "non-existent"} test spinbox-1.3 {configuration option: "background"} -setup { spinbox .e -borderwidth 2 -highlightthickness 2 -font {Helvetica -12} \ @@ -82,7 +82,7 @@ test spinbox-1.4 {configuration option: "background" for spinbox} -setup { .e configure -background non-existent } -cleanup { destroy .e -} -returnCodes {error} -result {unknown color name "non-existent"} +} -returnCodes error -result {unknown color name "non-existent"} test spinbox-1.5 {configuration option: "bd"} -setup { spinbox .e -borderwidth 2 -highlightthickness 2 -font {Helvetica -12} \ @@ -104,7 +104,7 @@ test spinbox-1.6 {configuration option: "bd" for spinbox} -setup { .e configure -bd badValue } -cleanup { destroy .e -} -returnCodes {error} -result {bad screen distance "badValue"} +} -returnCodes error -result {bad screen distance "badValue"} test spinbox-1.7 {configuration option: "bg"} -setup { spinbox .e -borderwidth 2 -highlightthickness 2 -font {Helvetica -12} \ @@ -126,7 +126,7 @@ test spinbox-1.8 {configuration option: "bg" for spinbox} -setup { .e configure -bg non-existent } -cleanup { destroy .e -} -returnCodes {error} -result {unknown color name "non-existent"} +} -returnCodes error -result {unknown color name "non-existent"} test spinbox-1.9 {configuration option: "borderwidth"} -setup { spinbox .e -borderwidth 2 -highlightthickness 2 -font {Helvetica -12} \ @@ -148,7 +148,7 @@ test spinbox-1.10 {configuration option: "borderwidth" for spinbox} -setup { .e configure -borderwidth badValue } -cleanup { destroy .e -} -returnCodes {error} -result {bad screen distance "badValue"} +} -returnCodes error -result {bad screen distance "badValue"} test spinbox-1.11 {configuration option: "buttonbackground"} -setup { spinbox .e -borderwidth 2 -highlightthickness 2 -font {Helvetica -12} \ @@ -170,7 +170,7 @@ test spinbox-1.12 {configuration option: "buttonbackground" for spinbox} -setup .e configure -buttonbackground non-existent } -cleanup { destroy .e -} -returnCodes {error} -result {unknown color name "non-existent"} +} -returnCodes error -result {unknown color name "non-existent"} test spinbox-1.13 {configuration option: "buttoncursor"} -setup { spinbox .e -borderwidth 2 -highlightthickness 2 -font {Helvetica -12} \ @@ -192,7 +192,7 @@ test spinbox-1.14 {configuration option: "buttoncursor" for spinbox} -setup { .e configure -buttoncursor badValue } -cleanup { destroy .e -} -returnCodes {error} -result {bad cursor spec "badValue"} +} -returnCodes error -result {bad cursor spec "badValue"} test spinbox-1.15 {configuration option: "command"} -setup { spinbox .e -borderwidth 2 -highlightthickness 2 -font {Helvetica -12} \ @@ -226,7 +226,7 @@ test spinbox-1.17 {configuration option: "cursor" for spinbox} -setup { .e configure -cursor badValue } -cleanup { destroy .e -} -returnCodes {error} -result {bad cursor spec "badValue"} +} -returnCodes error -result {bad cursor spec "badValue"} test spinbox-1.18 {configuration option: "disabledbackground"} -setup { spinbox .e -borderwidth 2 -highlightthickness 2 -font {Helvetica -12} \ @@ -248,7 +248,7 @@ test spinbox-1.19 {configuration option: "disabledbackground" for spinbox} -setu .e configure -disabledbackground non-existent } -cleanup { destroy .e -} -returnCodes {error} -result {unknown color name "non-existent"} +} -returnCodes error -result {unknown color name "non-existent"} test spinbox-1.20 {configuration option: "disabledforeground"} -setup { spinbox .e -borderwidth 2 -highlightthickness 2 -font {Helvetica -12} \ @@ -270,7 +270,7 @@ test spinbox-1.21 {configuration option: "disabledforeground" for spinbox} -setu .e configure -disabledforeground bogus } -cleanup { destroy .e -} -returnCodes {error} -result {unknown color name "bogus"} +} -returnCodes error -result {unknown color name "bogus"} test spinbox-1.22 {configuration option: "exportselection"} -setup { spinbox .e -borderwidth 2 -highlightthickness 2 -font {Helvetica -12} \ @@ -292,7 +292,7 @@ test spinbox-1.23 {configuration option: "exportselection" for spinbox} -setup { .e configure -exportselection xyzzy } -cleanup { destroy .e -} -returnCodes {error} -result {expected boolean value but got "xyzzy"} +} -returnCodes error -result {expected boolean value but got "xyzzy"} test spinbox-1.24 {configuration option: "fg"} -setup { spinbox .e -borderwidth 2 -highlightthickness 2 -font {Helvetica -12} \ @@ -314,7 +314,7 @@ test spinbox-1.25 {configuration option: "fg" for spinbox} -setup { .e configure -fg bogus } -cleanup { destroy .e -} -returnCodes {error} -result {unknown color name "bogus"} +} -returnCodes error -result {unknown color name "bogus"} test spinbox-1.26 {configuration option: "font"} -setup { spinbox .e -borderwidth 2 -highlightthickness 2 -font {Helvetica -12} \ @@ -336,7 +336,7 @@ test spinbox-1.27 {configuration option: "font" for spinbox} -setup { .e configure -font {} } -cleanup { destroy .e -} -returnCodes {error} -result {font "" doesn't exist} +} -returnCodes error -result {font "" doesn't exist} test spinbox-1.28 {configuration option: "foreground"} -setup { spinbox .e -borderwidth 2 -highlightthickness 2 -font {Helvetica -12} \ @@ -358,7 +358,7 @@ test spinbox-1.29 {configuration option: "foreground" for spinbox} -setup { .e configure -foreground bogus } -cleanup { destroy .e -} -returnCodes {error} -result {unknown color name "bogus"} +} -returnCodes error -result {unknown color name "bogus"} test spinbox-1.30 {configuration option: "format"} -setup { spinbox .e -borderwidth 2 -highlightthickness 2 -font {Helvetica -12} \ @@ -380,7 +380,7 @@ test spinbox-1.31 {configuration option: "format" for spinbox} -setup { .e configure -format %d } -cleanup { destroy .e -} -returnCodes {error} -result {bad spinbox format specifier "%d"} +} -returnCodes error -result {bad spinbox format specifier "%d"} test spinbox-1.32 {configuration option: "from"} -setup { spinbox .e -borderwidth 2 -highlightthickness 2 -font {Helvetica -12} \ @@ -402,7 +402,7 @@ test spinbox-1.33 {configuration option: "from" for spinbox} -setup { .e configure -from bogus } -cleanup { destroy .e -} -returnCodes {error} -result {expected floating-point number but got "bogus"} +} -returnCodes error -result {expected floating-point number but got "bogus"} test spinbox-1.34 {configuration option: "highlightbackground"} -setup { spinbox .e -borderwidth 2 -highlightthickness 2 -font {Helvetica -12} \ @@ -424,7 +424,7 @@ test spinbox-1.35 {configuration option: "highlightbackground" for spinbox} -set .e configure -highlightbackground ugly } -cleanup { destroy .e -} -returnCodes {error} -result {unknown color name "ugly"} +} -returnCodes error -result {unknown color name "ugly"} test spinbox-1.36 {configuration option: "highlightcolor"} -setup { spinbox .e -borderwidth 2 -highlightthickness 2 -font {Helvetica -12} \ @@ -446,7 +446,7 @@ test spinbox-1.37 {configuration option: "highlightcolor" for spinbox} -setup { .e configure -highlightcolor bogus } -cleanup { destroy .e -} -returnCodes {error} -result {unknown color name "bogus"} +} -returnCodes error -result {unknown color name "bogus"} test spinbox-1.38 {configuration option: "highlightthickness"} -setup { spinbox .e -borderwidth 2 -highlightthickness 2 -font {Helvetica -12} \ @@ -468,7 +468,7 @@ test spinbox-1.39 {configuration option: "highlightthickness" for spinbox} -setu .e configure -highlightthickness bogus } -cleanup { destroy .e -} -returnCodes {error} -result {bad screen distance "bogus"} +} -returnCodes error -result {bad screen distance "bogus"} test spinbox-1.40 {configuration option: "highlightthickness"} -setup { spinbox .e -borderwidth 2 -highlightthickness 2 -font {Helvetica -12} \ @@ -502,7 +502,7 @@ test spinbox-1.42 {configuration option: "increment" for spinbox} -setup { .e configure -increment bogus } -cleanup { destroy .e -} -returnCodes {error} -result {expected floating-point number but got "bogus"} +} -returnCodes error -result {expected floating-point number but got "bogus"} test spinbox-1.43 {configuration option: "insertbackground"} -setup { spinbox .e -borderwidth 2 -highlightthickness 2 -font {Helvetica -12} \ @@ -524,7 +524,7 @@ test spinbox-1.44 {configuration option: "insertbackground" for spinbox} -setup .e configure -insertbackground bogus } -cleanup { destroy .e -} -returnCodes {error} -result {unknown color name "bogus"} +} -returnCodes error -result {unknown color name "bogus"} test spinbox-1.45 {configuration option: "insertborderwidth"} -setup { spinbox .e -borderwidth 2 -insertwidth 2 -highlightthickness 2 -font {Helvetica -12} \ @@ -546,7 +546,7 @@ test spinbox-1.46 {configuration option: "insertborderwidth" for spinbox} -setup .e configure -insertborderwidth 2.6x } -cleanup { destroy .e -} -returnCodes {error} -result {bad screen distance "2.6x"} +} -returnCodes error -result {bad screen distance "2.6x"} test spinbox-1.47 {configuration option: "insertofftime"} -setup { spinbox .e -borderwidth 2 -highlightthickness 2 -font {Helvetica -12} \ @@ -568,7 +568,7 @@ test spinbox-1.48 {configuration option: "insertofftime" for spinbox} -setup { .e configure -insertofftime 3.2 } -cleanup { destroy .e -} -returnCodes {error} -result {expected integer but got "3.2"} +} -returnCodes error -result {expected integer but got "3.2"} test spinbox-1.49 {configuration option: "insertontime"} -setup { spinbox .e -borderwidth 2 -highlightthickness 2 -font {Helvetica -12} \ @@ -590,7 +590,7 @@ test spinbox-1.50 {configuration option: "insertontime" for spinbox} -setup { .e configure -insertontime 3.2 } -cleanup { destroy .e -} -returnCodes {error} -result {expected integer but got "3.2"} +} -returnCodes error -result {expected integer but got "3.2"} test spinbox-1.51 {configuration option: "invalidcommand"} -setup { spinbox .e -borderwidth 2 -highlightthickness 2 -font {Helvetica -12} \ @@ -636,7 +636,7 @@ test spinbox-1.54 {configuration option: "justify" for spinbox} -setup { .e configure -justify bogus } -cleanup { destroy .e -} -returnCodes {error} -result {bad justification "bogus": must be left, right, or center} +} -returnCodes error -result {bad justification "bogus": must be left, right, or center} test spinbox-1.55 {configuration option: "readonlybackground"} -setup { spinbox .e -borderwidth 2 -highlightthickness 2 -font {Helvetica -12} \ @@ -658,7 +658,7 @@ test spinbox-1.56 {configuration option: "readonlybackground" for spinbox} -setu .e configure -readonlybackground non-existent } -cleanup { destroy .e -} -returnCodes {error} -result {unknown color name "non-existent"} +} -returnCodes error -result {unknown color name "non-existent"} test spinbox-1.57 {configuration option: "relief"} -setup { spinbox .e -borderwidth 2 -highlightthickness 2 -font {Helvetica -12} \ @@ -680,7 +680,7 @@ test spinbox-1.58 {configuration option: "relief" for spinbox} -setup { .e configure -relief 1.5 } -cleanup { destroy .e -} -returnCodes {error} -result {bad relief "1.5": must be flat, groove, raised, ridge, solid, or sunken} +} -returnCodes error -result {bad relief "1.5": must be flat, groove, raised, ridge, solid, or sunken} test spinbox-1.59 {configuration option: "repeatdelay"} -setup { spinbox .e -borderwidth 2 -highlightthickness 2 -font {Helvetica -12} \ @@ -702,7 +702,7 @@ test spinbox-1.60 {configuration option: "repeatdelay" for spinbox} -setup { .e configure -repeatdelay 3p } -cleanup { destroy .e -} -returnCodes {error} -result {expected integer but got "3p"} +} -returnCodes error -result {expected integer but got "3p"} test spinbox-1.61 {configuration option: "repeatinterval"} -setup { spinbox .e -borderwidth 2 -highlightthickness 2 -font {Helvetica -12} \ @@ -724,7 +724,7 @@ test spinbox-1.62 {configuration option: "repeatinterval" for spinbox} -setup { .e configure -repeatinterval 3p } -cleanup { destroy .e -} -returnCodes {error} -result {expected integer but got "3p"} +} -returnCodes error -result {expected integer but got "3p"} test spinbox-1.63 {configuration option: "selectbackground"} -setup { spinbox .e -borderwidth 2 -highlightthickness 2 -font {Helvetica -12} \ @@ -746,7 +746,7 @@ test spinbox-1.64 {configuration option: "selectbackground" for spinbox} -setup .e configure -selectbackground bogus } -cleanup { destroy .e -} -returnCodes {error} -result {unknown color name "bogus"} +} -returnCodes error -result {unknown color name "bogus"} test spinbox-1.65 {configuration option: "selectborderwidth"} -setup { spinbox .e -borderwidth 2 -highlightthickness 2 -font {Helvetica -12} \ @@ -768,7 +768,7 @@ test spinbox-1.66 {configuration option: "selectborderwidth" for spinbox} -setup .e configure -selectborderwidth badValue } -cleanup { destroy .e -} -returnCodes {error} -result {bad screen distance "badValue"} +} -returnCodes error -result {bad screen distance "badValue"} test spinbox-1.67 {configuration option: "selectforeground"} -setup { spinbox .e -borderwidth 2 -highlightthickness 2 -font {Helvetica -12} \ @@ -790,7 +790,7 @@ test spinbox-1.68 {configuration option: "selectforeground" for spinbox} -setup .e configure -selectforeground bogus } -cleanup { destroy .e -} -returnCodes {error} -result {unknown color name "bogus"} +} -returnCodes error -result {unknown color name "bogus"} test spinbox-1.69 {configuration option: "state"} -setup { spinbox .e -borderwidth 2 -highlightthickness 2 -font {Helvetica -12} \ @@ -812,7 +812,7 @@ test spinbox-1.70 {configuration option: "state" for spinbox} -setup { .e configure -state bogus } -cleanup { destroy .e -} -returnCodes {error} -result {bad state "bogus": must be disabled, normal, or readonly} +} -returnCodes error -result {bad state "bogus": must be disabled, normal, or readonly} test spinbox-1.71 {configuration option: "takefocus"} -setup { spinbox .e -borderwidth 2 -highlightthickness 2 -font {Helvetica -12} \ @@ -858,7 +858,7 @@ test spinbox-1.74 {configuration option: "to" for spinbox} -setup { .e configure -to bogus } -cleanup { destroy .e -} -returnCodes {error} -result {expected floating-point number but got "bogus"} +} -returnCodes error -result {expected floating-point number but got "bogus"} test spinbox-1.75 {configuration option: "validate"} -setup { spinbox .e -borderwidth 2 -highlightthickness 2 -font {Helvetica -12} \ @@ -880,7 +880,7 @@ test spinbox-1.76 {configuration option: "validate" for spinbox} -setup { .e configure -validate "bogus" } -cleanup { destroy .e -} -returnCodes {error} -result {bad validate "bogus": must be all, key, focus, focusin, focusout, or none} +} -returnCodes error -result {bad validate "bogus": must be all, key, focus, focusin, focusout, or none} test spinbox-1.77 {configuration option: "validatecommand"} -setup { spinbox .e -borderwidth 2 -highlightthickness 2 -font {Helvetica -12} \ @@ -914,7 +914,7 @@ test spinbox-1.79 {configuration option: "values" for spinbox} -setup { .e configure -values {bad {}list} } -cleanup { destroy .e -} -returnCodes {error} -result {list element in braces followed by "list" instead of space} +} -returnCodes error -result {list element in braces followed by "list" instead of space} test spinbox-1.80 {configuration option: "validatecommand"} -setup { spinbox .e -borderwidth 2 -highlightthickness 2 -font {Helvetica -12} \ @@ -948,7 +948,7 @@ test spinbox-1.82 {configuration option: "width" for spinbox} -setup { .e configure -width 3p } -cleanup { destroy .e -} -returnCodes {error} -result {expected integer but got "3p"} +} -returnCodes error -result {expected integer but got "3p"} test spinbox-1.83 {configuration option: "wrap"} -setup { spinbox .e -borderwidth 2 -highlightthickness 2 -font {Helvetica -12} \ @@ -970,7 +970,7 @@ test spinbox-1.84 {configuration option: "wrap" for spinbox} -setup { .e configure -wrap xyzzy } -cleanup { destroy .e -} -returnCodes {error} -result {expected boolean value but got "xyzzy"} +} -returnCodes error -result {expected boolean value but got "xyzzy"} test spinbox-1.85 {configuration option: "xscrollcommand"} -setup { spinbox .e -borderwidth 2 -highlightthickness 2 -font {Helvetica -12} \ @@ -3694,19 +3694,19 @@ test spinbox-20.5 {spinbox config, -format specifier} -body { .e config -format %2e-1f } -cleanup { destroy .e -} -returnCodes {error} -result {bad spinbox format specifier "%2e-1f"} +} -returnCodes error -result {bad spinbox format specifier "%2e-1f"} test spinbox-20.6 {spinbox config, -format specifier} -body { spinbox .e .e config -format 2.2 } -cleanup { destroy .e -} -returnCodes {error} -result {bad spinbox format specifier "2.2"} +} -returnCodes error -result {bad spinbox format specifier "2.2"} test spinbox-20.7 {spinbox config, -format specifier} -body { spinbox .e .e config -format %2.-2f } -cleanup { destroy .e -} -returnCodes {error} -result {bad spinbox format specifier "%2.-2f"} +} -returnCodes error -result {bad spinbox format specifier "%2.-2f"} test spinbox-20.8 {spinbox config, -format specifier} -body { spinbox .e .e config -format %-2.02f @@ -3862,10 +3862,10 @@ test spinbox-24.1 {error in trace proc attached to the textvariable} -setup { list $result1 $result2 $result3 $result4 } -cleanup { destroy .s -} -result [list {can't set "myvar": Intentional error here!} \ - {can't set "myvar": Intentional error here!} \ - {can't set "myvar": Intentional error here!} \ - {can't set "myvar": Intentional error here!}] +} -match glob -result [list {can*t set "myvar": Intentional error here!} \ + {can*t set "myvar": Intentional error here!} \ + {can*t set "myvar": Intentional error here!} \ + {can*t set "myvar": Intentional error here!}] test spinbox-25.1 {textvariable lives in a non-existing namespace} -setup { destroy .s @@ -3874,7 +3874,7 @@ test spinbox-25.1 {textvariable lives in a non-existing namespace} -setup { set result1 } -cleanup { destroy .s -} -result {can't trace "thisnsdoesntexist::myvar": parent namespace doesn't exist} +} -match glob -result {can*t trace "thisnsdoesntexist::myvar": parent namespace does*t exist} test spinbox-25.3 {Bugs [2a32225cd1] and [9fa3e08243]} -setup { destroy .s pack [spinbox .s] diff --git a/tests/text.test b/tests/text.test index 5e2de4a32..edc314477 100644 --- a/tests/text.test +++ b/tests/text.test @@ -3,7 +3,7 @@ # # Copyright (c) 1992-1994 The Regents of the University of California. # Copyright (c) 1994-1996 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. package require tcltest 2.2 @@ -46,7 +46,7 @@ test text-1.2 {configuration option: "autoseparators"} -setup { .t configure -autoseparators nah } -cleanup { destroy .t -} -match glob -returnCodes {error} -result {*} +} -match glob -returnCodes error -result {*} test text-1.3 {configuration option: "background"} -setup { text .t -borderwidth 2 -highlightthickness 2 -font {Courier -12 bold} pack .t @@ -65,7 +65,7 @@ test text-1.4 {configuration option: "background"} -setup { .t configure -background } -cleanup { destroy .t -} -match glob -returnCodes {error} -result {*} +} -match glob -returnCodes error -result {*} test text-1.5 {configuration option: "bd"} -setup { text .t -borderwidth 2 -highlightthickness 2 -font {Courier -12 bold} pack .t @@ -84,7 +84,7 @@ test text-1.6 {configuration option: "bd"} -setup { .t configure -bd foo } -cleanup { destroy .t -} -match glob -returnCodes {error} -result {*} +} -match glob -returnCodes error -result {*} test text-1.7 {configuration option: "bg"} -setup { text .t -borderwidth 2 -highlightthickness 2 -font {Courier -12 bold} pack .t @@ -103,7 +103,7 @@ test text-1.8 {configuration option: "bg"} -setup { .t configure -bg #xx } -cleanup { destroy .t -} -match glob -returnCodes {error} -result {*} +} -match glob -returnCodes error -result {*} test text-1.9 {configuration option: "blockcursor"} -setup { text .t -borderwidth 2 -highlightthickness 2 -font {Courier -12 bold} pack .t @@ -122,7 +122,7 @@ test text-1.10 {configuration option: "blockcursor"} -setup { .t configure -blockcursor xx } -cleanup { destroy .t -} -match glob -returnCodes {error} -result {*} +} -match glob -returnCodes error -result {*} test text-1.11 {configuration option: "borderwidth"} -setup { text .t -borderwidth 2 -highlightthickness 2 -font {Courier -12 bold} pack .t @@ -141,7 +141,7 @@ test text-1.12 {configuration option: "borderwidth"} -setup { .t configure -borderwidth ++ } -cleanup { destroy .t -} -match glob -returnCodes {error} -result {*} +} -match glob -returnCodes error -result {*} test text-1.13 {configuration option: "cursor"} -setup { text .t -borderwidth 2 -highlightthickness 2 -font {Courier -12 bold} pack .t @@ -160,7 +160,7 @@ test text-1.14 {configuration option: "cursor"} -setup { .t configure -cursor lousy } -cleanup { destroy .t -} -match glob -returnCodes {error} -result {*} +} -match glob -returnCodes error -result {*} test text-1.15 {configuration option: "exportselection"} -setup { text .t -borderwidth 2 -highlightthickness 2 -font {Courier -12 bold} pack .t @@ -179,7 +179,7 @@ test text-1.16 {configuration option: "exportselection"} -setup { .t configure -exportselection maybe } -cleanup { destroy .t -} -match glob -returnCodes {error} -result {*} +} -match glob -returnCodes error -result {*} test text-1.17 {configuration option: "fg"} -setup { text .t -borderwidth 2 -highlightthickness 2 -font {Courier -12 bold} pack .t @@ -198,7 +198,7 @@ test text-1.18 {configuration option: "fg"} -setup { .t configure -fg stupid } -cleanup { destroy .t -} -match glob -returnCodes {error} -result {*} +} -match glob -returnCodes error -result {*} test text-1.19 {configuration option: "font"} -setup { text .t -borderwidth 2 -highlightthickness 2 -font {Courier -12 bold} pack .t @@ -217,7 +217,7 @@ test text-1.20 {configuration option: "font"} -setup { .t configure -font {} } -cleanup { destroy .t -} -match glob -returnCodes {error} -result {*} +} -match glob -returnCodes error -result {*} test text-1.21 {configuration option: "foreground"} -setup { text .t -borderwidth 2 -highlightthickness 2 -font {Courier -12 bold} pack .t @@ -236,7 +236,7 @@ test text-1.22 {configuration option: "foreground"} -setup { .t configure -foreground bogus } -cleanup { destroy .t -} -match glob -returnCodes {error} -result {*} +} -match glob -returnCodes error -result {*} test text-1.23 {configuration option: "height"} -setup { text .t -borderwidth 2 -highlightthickness 2 -font {Courier -12 bold} pack .t @@ -255,7 +255,7 @@ test text-1.24 {configuration option: "height"} -setup { .t configure -height bad } -cleanup { destroy .t -} -match glob -returnCodes {error} -result {*} +} -match glob -returnCodes error -result {*} test text-1.25 {configuration option: "highlightbackground"} -setup { text .t -borderwidth 2 -highlightthickness 2 -font {Courier -12 bold} pack .t @@ -274,7 +274,7 @@ test text-1.26 {configuration option: "highlightbackground"} -setup { .t configure -highlightbackground bogus } -cleanup { destroy .t -} -match glob -returnCodes {error} -result {*} +} -match glob -returnCodes error -result {*} test text-1.27 {configuration option: "highlightcolor"} -setup { text .t -borderwidth 2 -highlightthickness 2 -font {Courier -12 bold} pack .t @@ -293,7 +293,7 @@ test text-1.28 {configuration option: "highlightcolor"} -setup { .t configure -highlightcolor bogus } -cleanup { destroy .t -} -match glob -returnCodes {error} -result {*} +} -match glob -returnCodes error -result {*} test text-1.29 {configuration option: "highlightthickness"} -setup { text .t -borderwidth 2 -highlightthickness 2 -font {Courier -12 bold} pack .t @@ -312,7 +312,7 @@ test text-1.30 {configuration option: "highlightthickness"} -setup { .t configure -highlightthickness bad } -cleanup { destroy .t -} -match glob -returnCodes {error} -result {*} +} -match glob -returnCodes error -result {*} test text-1.31 {configuration option: "inactiveselectbackground"} -setup { text .t -borderwidth 2 -highlightthickness 2 -font {Courier -12 bold} pack .t @@ -331,7 +331,7 @@ test text-1.32 {configuration option: "inactiveselectbackground"} -setup { .t configure -inactiveselectbackground bogus } -cleanup { destroy .t -} -match glob -returnCodes {error} -result {*} +} -match glob -returnCodes error -result {*} test text-1.33 {configuration option: "insertbackground"} -setup { text .t -borderwidth 2 -highlightthickness 2 -font {Courier -12 bold} pack .t @@ -350,7 +350,7 @@ test text-1.34 {configuration option: "insertbackground"} -setup { .t configure -insertbackground } -cleanup { destroy .t -} -match glob -returnCodes {error} -result {*} +} -match glob -returnCodes error -result {*} test text-1.35 {configuration option: "insertborderwidth"} -setup { text .t -borderwidth 2 -highlightthickness 2 -font {Courier -12 bold} pack .t @@ -369,7 +369,7 @@ test text-1.36 {configuration option: "insertborderwidth"} -setup { .t configure -insertborderwidth bogus } -cleanup { destroy .t -} -match glob -returnCodes {error} -result {*} +} -match glob -returnCodes error -result {*} test text-1.37 {configuration option: "insertofftime"} -setup { text .t -borderwidth 2 -highlightthickness 2 -font {Courier -12 bold} pack .t @@ -388,7 +388,7 @@ test text-1.38 {configuration option: "insertofftime"} -setup { .t configure -insertofftime 2.4 } -cleanup { destroy .t -} -match glob -returnCodes {error} -result {*} +} -match glob -returnCodes error -result {*} test text-1.39 {configuration option: "insertontime"} -setup { text .t -borderwidth 2 -highlightthickness 2 -font {Courier -12 bold} pack .t @@ -407,7 +407,7 @@ test text-1.40 {configuration option: "insertontime"} -setup { .t configure -insertontime e1 } -cleanup { destroy .t -} -match glob -returnCodes {error} -result {*} +} -match glob -returnCodes error -result {*} test text-1.41 {configuration option: "insertwidth"} -setup { text .t -borderwidth 2 -highlightthickness 2 -font {Courier -12 bold} pack .t @@ -426,7 +426,7 @@ test text-1.42 {configuration option: "insertwidth"} -setup { .t configure -insertwidth 47d } -cleanup { destroy .t -} -match glob -returnCodes {error} -result {*} +} -match glob -returnCodes error -result {*} test text-1.43 {configuration option: "maxundo"} -setup { text .t -borderwidth 2 -highlightthickness 2 -font {Courier -12 bold} pack .t @@ -454,7 +454,7 @@ test text-1.44 {configuration option: "maxundo"} -setup { .t configure -maxundo noway } -cleanup { destroy .t -} -match glob -returnCodes {error} -result {*} +} -match glob -returnCodes error -result {*} test text-1.45 {configuration option: "padx"} -setup { text .t -borderwidth 2 -highlightthickness 2 -font {Courier -12 bold} pack .t @@ -473,7 +473,7 @@ test text-1.46 {configuration option: "padx"} -setup { .t configure -padx 2.4. } -cleanup { destroy .t -} -match glob -returnCodes {error} -result {*} +} -match glob -returnCodes error -result {*} test text-1.47 {configuration option: "pady"} -setup { text .t -borderwidth 2 -highlightthickness 2 -font {Courier -12 bold} pack .t @@ -492,7 +492,7 @@ test text-1.48 {configuration option: "pady"} -setup { .t configure -pady bogus } -cleanup { destroy .t -} -match glob -returnCodes {error} -result {*} +} -match glob -returnCodes error -result {*} test text-1.49 {configuration option: "relief"} -setup { text .t -borderwidth 2 -highlightthickness 2 -font {Courier -12 bold} pack .t @@ -511,7 +511,7 @@ test text-1.50 {configuration option: "relief"} -setup { .t configure -relief bumpy } -cleanup { destroy .t -} -match glob -returnCodes {error} -result {*} +} -match glob -returnCodes error -result {*} test text-1.51 {configuration option: "selectbackground"} -setup { text .t -borderwidth 2 -highlightthickness 2 -font {Courier -12 bold} pack .t @@ -530,7 +530,7 @@ test text-1.52 {configuration option: "selectbackground"} -setup { .t configure -selectbackground bogus } -cleanup { destroy .t -} -match glob -returnCodes {error} -result {*} +} -match glob -returnCodes error -result {*} test text-1.53 {configuration option: "selectborderwidth"} -setup { text .t -borderwidth 2 -highlightthickness 2 -font {Courier -12 bold} pack .t @@ -549,7 +549,7 @@ test text-1.54 {configuration option: "selectborderwidth"} -setup { .t configure -selectborderwidth 3x } -cleanup { destroy .t -} -match glob -returnCodes {error} -result {*} +} -match glob -returnCodes error -result {*} test text-1.55 {configuration option: "selectforeground"} -setup { text .t -borderwidth 2 -highlightthickness 2 -font {Courier -12 bold} pack .t @@ -568,7 +568,7 @@ test text-1.56 {configuration option: "selectforeground"} -setup { .t configure -selectforeground #12345 } -cleanup { destroy .t -} -match glob -returnCodes {error} -result {*} +} -match glob -returnCodes error -result {*} test text-1.57 {configuration option: "spacing1"} -setup { text .t -borderwidth 2 -highlightthickness 2 -font {Courier -12 bold} pack .t @@ -587,7 +587,7 @@ test text-1.58 {configuration option: "spacing1"} -setup { .t configure -spacing1 1.3x } -cleanup { destroy .t -} -match glob -returnCodes {error} -result {*} +} -match glob -returnCodes error -result {*} test text-1.59 {configuration option: "spacing1"} -setup { text .t -borderwidth 2 -highlightthickness 2 -font {Courier -12 bold} pack .t @@ -606,7 +606,7 @@ test text-1.60 {configuration option: "spacing1"} -setup { .t configure -spacing1 bogus } -cleanup { destroy .t -} -match glob -returnCodes {error} -result {*} +} -match glob -returnCodes error -result {*} test text-1.61 {configuration option: "spacing2"} -setup { text .t -borderwidth 2 -highlightthickness 2 -font {Courier -12 bold} pack .t @@ -625,7 +625,7 @@ test text-1.62 {configuration option: "spacing2"} -setup { .t configure -spacing2 bogus } -cleanup { destroy .t -} -match glob -returnCodes {error} -result {*} +} -match glob -returnCodes error -result {*} test text-1.63 {configuration option: "spacing2"} -setup { text .t -borderwidth 2 -highlightthickness 2 -font {Courier -12 bold} pack .t @@ -644,7 +644,7 @@ test text-1.64 {configuration option: "spacing2"} -setup { .t configure -spacing2 bogus } -cleanup { destroy .t -} -match glob -returnCodes {error} -result {*} +} -match glob -returnCodes error -result {*} test text-1.65 {configuration option: "spacing3"} -setup { text .t -borderwidth 2 -highlightthickness 2 -font {Courier -12 bold} pack .t @@ -663,7 +663,7 @@ test text-1.66 {configuration option: "spacing3"} -setup { .t configure -spacing3 bogus } -cleanup { destroy .t -} -match glob -returnCodes {error} -result {*} +} -match glob -returnCodes error -result {*} test text-1.67 {configuration option: "spacing3"} -setup { text .t -borderwidth 2 -highlightthickness 2 -font {Courier -12 bold} pack .t @@ -682,7 +682,7 @@ test text-1.68 {configuration option: "spacing3"} -setup { .t configure -spacing3 bogus } -cleanup { destroy .t -} -match glob -returnCodes {error} -result {*} +} -match glob -returnCodes error -result {*} test text-1.69 {configuration option: "state"} -setup { text .t -borderwidth 2 -highlightthickness 2 -font {Courier -12 bold} pack .t @@ -701,7 +701,7 @@ test text-1.70 {configuration option: "state"} -setup { .t configure -state foo } -cleanup { destroy .t -} -match glob -returnCodes {error} -result {*} +} -match glob -returnCodes error -result {*} test text-1.71 {configuration option: "tabs"} -setup { text .t -borderwidth 2 -highlightthickness 2 -font {Courier -12 bold} pack .t @@ -720,7 +720,7 @@ test text-1.72 {configuration option: "tabs"} -setup { .t configure -tabs bad_tabs } -cleanup { destroy .t -} -match glob -returnCodes {error} -result {*} +} -match glob -returnCodes error -result {*} test text-1.73 {configuration option: "tabstyle"} -setup { text .t -borderwidth 2 -highlightthickness 2 -font {Courier -12 bold} pack .t @@ -739,7 +739,7 @@ test text-1.74 {configuration option: "tabstyle"} -setup { .t configure -tabstyle garbage } -cleanup { destroy .t -} -match glob -returnCodes {error} -result {*} +} -match glob -returnCodes error -result {*} test text-1.75 {configuration option: "undo"} -setup { text .t -borderwidth 2 -highlightthickness 2 -font {Courier -12 bold} pack .t @@ -767,7 +767,7 @@ test text-1.76 {configuration option: "undo"} -setup { .t configure -undo eh } -cleanup { destroy .t -} -match glob -returnCodes {error} -result {*} +} -match glob -returnCodes error -result {*} test text-1.77 {configuration option: "width"} -setup { text .t -borderwidth 2 -highlightthickness 2 -font {Courier -12 bold} pack .t @@ -786,7 +786,7 @@ test text-1.78 {configuration option: "width"} -setup { .t configure -width 2.4 } -cleanup { destroy .t -} -match glob -returnCodes {error} -result {*} +} -match glob -returnCodes error -result {*} test text-1.79 {configuration option: "wrap"} -setup { text .t -borderwidth 2 -highlightthickness 2 -font {Courier -12 bold} pack .t @@ -805,7 +805,7 @@ test text-1.80 {configuration option: "wrap"} -setup { .t configure -wrap bad_wrap } -cleanup { destroy .t -} -match glob -returnCodes {error} -result {*} +} -match glob -returnCodes error -result {*} test text-1.81 {text options} -setup { text .t -borderwidth 2 -highlightthickness 2 -font {Courier -12 bold} pack .t @@ -879,15 +879,15 @@ test text-1.86 {configuration option: "insertunfocussed"} -setup { test text-2.1 {Tk_TextCmd procedure} -body { text -} -returnCodes {error} -result {wrong # args: should be "text pathName ?-option value ...?"} +} -returnCodes error -result {wrong # args: should be "text pathName ?-option value ...?"} test text-2.2 {Tk_TextCmd procedure} -body { text foobar -} -returnCodes {error} -result {bad window path name "foobar"} +} -returnCodes error -result {bad window path name "foobar"} test text-2.3 {Tk_TextCmd procedure} -body { text .t -gorp nofun } -cleanup { destroy .t -} -returnCodes {error} -result {unknown option "-gorp"} +} -returnCodes error -result {unknown option "-gorp"} test text-2.4 {Tk_TextCmd procedure} -body { catch {text .t -gorp nofun} winfo exists .t @@ -945,14 +945,14 @@ test text-3.1 {TextWidgetCmd procedure, basics} -setup { .t } -cleanup { destroy .t -} -returnCodes {error} -result {wrong # args: should be ".t option ?arg ...?"} +} -returnCodes error -result {wrong # args: should be ".t option ?arg ...?"} test text-3.2 {TextWidgetCmd procedure} -setup { text .t } -body { .t gorp 1.0 z 1.2 } -cleanup { destroy .t -} -returnCodes {error} -result {bad option "gorp": must be bbox, cget, compare, configure, count, debug, delete, dlineinfo, dump, edit, get, image, index, insert, mark, peer, pendingsync, replace, scan, search, see, sync, tag, window, xview, or yview} +} -returnCodes error -result {bad option "gorp": must be bbox, cget, compare, configure, count, debug, delete, dlineinfo, dump, edit, get, image, index, insert, mark, peer, pendingsync, replace, scan, search, see, sync, tag, window, xview, or yview} test text-4.1 {TextWidgetCmd procedure, "bbox" option} -setup { text .t @@ -960,21 +960,21 @@ test text-4.1 {TextWidgetCmd procedure, "bbox" option} -setup { .t bbox } -cleanup { destroy .t -} -returnCodes {error} -result {wrong # args: should be ".t bbox index"} +} -returnCodes error -result {wrong # args: should be ".t bbox index"} test text-4.2 {TextWidgetCmd procedure, "bbox" option} -setup { text .t } -body { .t bbox a b } -cleanup { destroy .t -} -returnCodes {error} -result {wrong # args: should be ".t bbox index"} +} -returnCodes error -result {wrong # args: should be ".t bbox index"} test text-4.3 {TextWidgetCmd procedure, "bbox" option} -setup { text .t } -body { .t bbox bad_mark } -cleanup { destroy .t -} -returnCodes {error} -result {bad text index "bad_mark"} +} -returnCodes error -result {bad text index "bad_mark"} test text-5.1 {TextWidgetCmd procedure, "cget" option} -setup { text .t @@ -982,21 +982,21 @@ test text-5.1 {TextWidgetCmd procedure, "cget" option} -setup { .t cget } -cleanup { destroy .t -} -returnCodes {error} -result {wrong # args: should be ".t cget option"} +} -returnCodes error -result {wrong # args: should be ".t cget option"} test text-5.2 {TextWidgetCmd procedure, "cget" option} -setup { text .t } -body { .t cget a b } -cleanup { destroy .t -} -returnCodes {error} -result {wrong # args: should be ".t cget option"} +} -returnCodes error -result {wrong # args: should be ".t cget option"} test text-5.3 {TextWidgetCmd procedure, "cget" option} -setup { text .t } -body { .t cget -gorp } -cleanup { destroy .t -} -returnCodes {error} -result {unknown option "-gorp"} +} -returnCodes error -result {unknown option "-gorp"} test text-5.4 {TextWidgetCmd procedure, "cget" option} -setup { text .t } -body { @@ -1013,28 +1013,28 @@ test text-6.1 {TextWidgetCmd procedure, "compare" option} -setup { .t compare a b } -cleanup { destroy .t -} -returnCodes {error} -result {wrong # args: should be ".t compare index1 op index2"} +} -returnCodes error -result {wrong # args: should be ".t compare index1 op index2"} test text-6.2 {TextWidgetCmd procedure, "compare" option} -setup { text .t } -body { .t compare a b c d } -cleanup { destroy .t -} -returnCodes {error} -result {wrong # args: should be ".t compare index1 op index2"} +} -returnCodes error -result {wrong # args: should be ".t compare index1 op index2"} test text-6.3 {TextWidgetCmd procedure, "compare" option} -setup { text .t } -body { .t compare @x == 1.0 } -cleanup { destroy .t -} -returnCodes {error} -result {bad text index "@x"} +} -returnCodes error -result {bad text index "@x"} test text-6.4 {TextWidgetCmd procedure, "compare" option} -setup { text .t } -body { .t compare 1.0 < @y } -cleanup { destroy .t -} -returnCodes {error} -result {bad text index "@y"} +} -returnCodes error -result {bad text index "@y"} test text-6.5 {TextWidgetCmd procedure, "compare" option} -setup { text .t } -body { @@ -1132,7 +1132,7 @@ Line 7" .t compare 1.0 =, >, or !=} +} -returnCodes error -result {bad comparison operator "=, >, or !=} test text-6.12 {TextWidgetCmd procedure, "compare" option} -setup { text .t } -body { @@ -1146,7 +1146,7 @@ Line 7" .t compare 1.0 >> 1.2 } -cleanup { destroy .t -} -returnCodes {error} -result {bad comparison operator ">>": must be <, <=, ==, >=, >, or !=} +} -returnCodes error -result {bad comparison operator ">>": must be <, <=, ==, >=, >, or !=} test text-6.13 {TextWidgetCmd procedure, "compare" option} -setup { text .t } -body { @@ -1160,7 +1160,7 @@ Line 7" .t compare 1.0 z 1.2 } -cleanup { destroy .t -} -returnCodes {error} -result {bad comparison operator "z": must be <, <=, ==, >=, >, or !=} +} -returnCodes error -result {bad comparison operator "z": must be <, <=, ==, >=, >, or !=} test text-6.14 {TextWidgetCmd procedure, "compare" option} -setup { text .t } -body { @@ -1174,7 +1174,7 @@ Line 7" .t co 1.0 z 1.2 } -cleanup { destroy .t -} -returnCodes {error} -result {ambiguous option "co": must be bbox, cget, compare, configure, count, debug, delete, dlineinfo, dump, edit, get, image, index, insert, mark, peer, pendingsync, replace, scan, search, see, sync, tag, window, xview, or yview} +} -returnCodes error -result {ambiguous option "co": must be bbox, cget, compare, configure, count, debug, delete, dlineinfo, dump, edit, get, image, index, insert, mark, peer, pendingsync, replace, scan, search, see, sync, tag, window, xview, or yview} # "configure" option is already covered above test text-7.1 {TextWidgetCmd procedure, "debug" option} -setup { @@ -1183,14 +1183,14 @@ test text-7.1 {TextWidgetCmd procedure, "debug" option} -setup { .t debug 0 1 } -cleanup { destroy .t -} -returnCodes {error} -result {wrong # args: should be ".t debug boolean"} +} -returnCodes error -result {wrong # args: should be ".t debug boolean"} test text-7.2 {TextWidgetCmd procedure, "debug" option} -setup { text .t } -body { .t de 0 1 } -cleanup { destroy .t -} -returnCodes {error} -result {ambiguous option "de": must be bbox, cget, compare, configure, count, debug, delete, dlineinfo, dump, edit, get, image, index, insert, mark, peer, pendingsync, replace, scan, search, see, sync, tag, window, xview, or yview} +} -returnCodes error -result {ambiguous option "de": must be bbox, cget, compare, configure, count, debug, delete, dlineinfo, dump, edit, get, image, index, insert, mark, peer, pendingsync, replace, scan, search, see, sync, tag, window, xview, or yview} test text-7.3 {TextWidgetCmd procedure, "debug" option} -setup { text .t } -body { @@ -1215,21 +1215,21 @@ test text-8.1 {TextWidgetCmd procedure, "delete" option} -setup { .t delete } -cleanup { destroy .t -} -returnCodes {error} -result {wrong # args: should be ".t delete index1 ?index2 ...?"} +} -returnCodes error -result {wrong # args: should be ".t delete index1 ?index2 ...?"} test text-8.2 {TextWidgetCmd procedure, "delete" option} -setup { text .t } -body { .t delete a b c } -cleanup { destroy .t -} -returnCodes {error} -result {bad text index "a"} +} -returnCodes error -result {bad text index "a"} test text-8.3 {TextWidgetCmd procedure, "delete" option} -setup { text .t } -body { .t delete @x 2.2 } -cleanup { destroy .t -} -returnCodes {error} -result {bad text index "@x"} +} -returnCodes error -result {bad text index "@x"} test text-8.4 {TextWidgetCmd procedure, "delete" option} -setup { text .t } -body { @@ -1239,7 +1239,7 @@ abcdefghijklm .t delete 2.3 @y } -cleanup { destroy .t -} -returnCodes {error} -result {bad text index "@y"} +} -returnCodes error -result {bad text index "@y"} test text-8.5 {TextWidgetCmd procedure, "delete" option} -setup { text .t } -body { @@ -1296,7 +1296,7 @@ abcdefghijklm .t delete 2.1 2.3 foo } -cleanup { destroy .t -} -returnCodes {error} -result {bad text index "foo"} +} -returnCodes error -result {bad text index "foo"} test text-8.9 {TextWidgetCmd procedure, "delete" option} -setup { text .t } -body { @@ -1414,7 +1414,7 @@ abcdefghijklm .t replace 1.3 2.3 } -cleanup { destroy .t -} -returnCodes {error} -result {wrong # args: should be ".t replace index1 index2 chars ?tagList chars tagList ...?"} +} -returnCodes error -result {wrong # args: should be ".t replace index1 index2 chars ?tagList chars tagList ...?"} test text-8.19 {TextWidgetCmd procedure, "replace" option} -setup { text .t } -body { @@ -1424,7 +1424,7 @@ abcdefghijklm .t replace 3.1 2.3 foo } -cleanup { destroy .t -} -returnCodes {error} -result {index "2.3" before "3.1" in the text} +} -returnCodes error -result {index "2.3" before "3.1" in the text} test text-8.20 {TextWidgetCmd procedure, "replace" option} -setup { text .t } -body { @@ -1604,28 +1604,28 @@ test text-9.1 {TextWidgetCmd procedure, "get" option} -setup { .t get } -cleanup { destroy .t -} -returnCodes {error} -result {wrong # args: should be ".t get ?-displaychars? ?--? index1 ?index2 ...?"} +} -returnCodes error -result {wrong # args: should be ".t get ?-displaychars? ?--? index1 ?index2 ...?"} test text-9.2 {TextWidgetCmd procedure, "get" option} -setup { text .t } -body { .t get a b c } -cleanup { destroy .t -} -returnCodes {error} -result {bad text index "a"} +} -returnCodes error -result {bad text index "a"} test text-9.3 {TextWidgetCmd procedure, "get" option} -setup { text .t } -body { .t get @q 3.1 } -cleanup { destroy .t -} -returnCodes {error} -result {bad text index "@q"} +} -returnCodes error -result {bad text index "@q"} test text-9.4 {TextWidgetCmd procedure, "get" option} -setup { text .t } -body { .t get 3.1 @r } -cleanup { destroy .t -} -returnCodes {error} -result {bad text index "@r"} +} -returnCodes error -result {bad text index "@r"} test text-9.5 {TextWidgetCmd procedure, "get" option} -setup { text .t } -body { @@ -1855,7 +1855,7 @@ Line 7" .t get 5.2 5.4 5.5 foo } -cleanup { destroy .t -} -returnCodes {error} -result {bad text index "foo"} +} -returnCodes error -result {bad text index "foo"} test text-9.21 {TextWidgetCmd procedure, "get" option} -setup { text .t } -body { @@ -2049,35 +2049,35 @@ test text-10.1 {TextWidgetCmd procedure, "count" option} -setup { .t count } -cleanup { destroy .t -} -returnCodes {error} -result {wrong # args: should be ".t count ?-option value ...? index1 index2"} +} -returnCodes error -result {wrong # args: should be ".t count ?-option value ...? index1 index2"} test text-10.2 {TextWidgetCmd procedure, "count" option} -setup { text .t } -body { .t count blah 1.0 2.0 } -cleanup { destroy .t -} -returnCodes {error} -result {bad option "blah" must be -chars, -displaychars, -displayindices, -displaylines, -indices, -lines, -update, -xpixels, or -ypixels} +} -returnCodes error -result {bad option "blah" must be -chars, -displaychars, -displayindices, -displaylines, -indices, -lines, -update, -xpixels, or -ypixels} test text-10.3 {TextWidgetCmd procedure, "count" option} -setup { text .t } -body { .t count a b } -cleanup { destroy .t -} -returnCodes {error} -result {bad text index "a"} +} -returnCodes error -result {bad text index "a"} test text-10.4 {TextWidgetCmd procedure, "count" option} -setup { text .t } -body { .t count @q 3.1 } -cleanup { destroy .t -} -returnCodes {error} -result {bad text index "@q"} +} -returnCodes error -result {bad text index "@q"} test text-10.5 {TextWidgetCmd procedure, "count" option} -setup { text .t } -body { .t count 3.1 @r } -cleanup { destroy .t -} -returnCodes {error} -result {bad text index "@r"} +} -returnCodes error -result {bad text index "@r"} test text-10.6 {TextWidgetCmd procedure, "count" option} -setup { text .t .t insert 1.0 "Line 1 @@ -2175,7 +2175,7 @@ Line 7" .t count 5.2 foo } -cleanup { destroy .t -} -returnCodes {error} -result {bad text index "foo"} +} -returnCodes error -result {bad text index "foo"} test text-10.13 {TextWidgetCmd procedure, "count" option} -setup { text .t } -body { @@ -2596,7 +2596,7 @@ test text-10.32 {TextWidgetCmd procedure, "count" option} -setup { .t count -lines 1.0 2.0 3.0 } -cleanup { destroy .t -} -returnCodes {error} -result {bad option "1.0" must be -chars, -displaychars, -displayindices, -displaylines, -indices, -lines, -update, -xpixels, or -ypixels} +} -returnCodes error -result {bad option "1.0" must be -chars, -displaychars, -displayindices, -displaylines, -indices, -lines, -update, -xpixels, or -ypixels} test text-10.33 {TextWidgetCmd procedure, "count" option} -setup { text .t } -body { @@ -3136,28 +3136,28 @@ test text-12.1 {TextWidgetCmd procedure, "index" option} -setup { .t index } -cleanup { destroy .t -} -returnCodes {error} -result {wrong # args: should be ".t index index"} +} -returnCodes error -result {wrong # args: should be ".t index index"} test text-12.2 {TextWidgetCmd procedure, "index" option} -setup { text .t } -body { .t ind a b } -cleanup { destroy .t -} -returnCodes {error} -result {wrong # args: should be ".t index index"} +} -returnCodes error -result {wrong # args: should be ".t index index"} test text-12.3 {TextWidgetCmd procedure, "index" option} -setup { text .t } -body { .t in a b } -cleanup { destroy .t -} -returnCodes {error} -result {ambiguous option "in": must be bbox, cget, compare, configure, count, debug, delete, dlineinfo, dump, edit, get, image, index, insert, mark, peer, pendingsync, replace, scan, search, see, sync, tag, window, xview, or yview} +} -returnCodes error -result {ambiguous option "in": must be bbox, cget, compare, configure, count, debug, delete, dlineinfo, dump, edit, get, image, index, insert, mark, peer, pendingsync, replace, scan, search, see, sync, tag, window, xview, or yview} test text-12.4 {TextWidgetCmd procedure, "index" option} -setup { text .t } -body { .t index @xyz } -cleanup { destroy .t -} -returnCodes {error} -result {bad text index "@xyz"} +} -returnCodes error -result {bad text index "@xyz"} test text-12.5 {TextWidgetCmd procedure, "index" option} -setup { [text .t] insert 1.0 "Line 1 aefghijklm @@ -3185,7 +3185,7 @@ Line 7" .t insert 1.2 } -cleanup { destroy .t -} -returnCodes {error} -result {wrong # args: should be ".t insert index chars ?tagList chars tagList ...?"} +} -returnCodes error -result {wrong # args: should be ".t insert index chars ?tagList chars tagList ...?"} test text-13.2 {TextWidgetCmd procedure, "insert" option} -setup { text .t } -body { @@ -3265,7 +3265,7 @@ test text-13.8 {TextWidgetCmd procedure, "insert" option} -setup { .t insert 1.0 "Sample text" "a \{b" } -cleanup { destroy .t -} -returnCodes {error} -result {unmatched open brace in list} +} -returnCodes error -result {unmatched open brace in list} test text-13.9 {TextWidgetCmd procedure, "insert" option} -setup { text .t } -body { @@ -3292,7 +3292,7 @@ test text-14.1 {ConfigureText procedure} -setup { .t configure -state foobar } -cleanup { destroy .t -} -returnCodes {error} -result {bad state "foobar": must be disabled or normal} +} -returnCodes error -result {bad state "foobar": must be disabled or normal} test text-14.2 {ConfigureText procedure} -setup { text .t } -body { @@ -3323,7 +3323,7 @@ test text-14.5 {ConfigureText procedure} -setup { .t configure -tabs {30 foo} } -cleanup { destroy .t -} -returnCodes {error} -result {bad tab alignment "foo": must be left, right, center, or numeric} +} -returnCodes error -result {bad tab alignment "foo": must be left, right, center, or numeric} test text-14.6 {ConfigureText procedure} -setup { text .t } -body { @@ -3351,7 +3351,7 @@ test text-14.8 {ConfigureText procedure} -setup { .t configure -wrap bogus } -cleanup { destroy .t -} -returnCodes {error} -result {bad wrap "bogus": must be char, none, or word} +} -returnCodes error -result {bad wrap "bogus": must be char, none, or word} test text-14.9 {ConfigureText procedure} -setup { text .t -font {Courier -12} -borderwidth 2 -highlightthickness 2 } -body { @@ -3377,7 +3377,7 @@ test text-14.11 {ConfigureText procedure} -setup { .t configure -selectborderwidth foo } -cleanup { destroy .t -} -returnCodes {error} -result {bad screen distance "foo"} +} -returnCodes error -result {bad screen distance "foo"} test text-14.12 {ConfigureText procedure} -body { text .t entry .t.e @@ -3679,13 +3679,13 @@ test text-19.2 {DeleteChars procedure} -body { .t delete foobar } -cleanup { destroy .t -} -returnCodes {error} -result {bad text index "foobar"} +} -returnCodes error -result {bad text index "foobar"} test text-19.3 {DeleteChars procedure} -body { text .t .t delete 1.0 lousy } -cleanup { destroy .t -} -returnCodes {error} -result {bad text index "lousy"} +} -returnCodes error -result {bad text index "lousy"} test text-19.4 {DeleteChars procedure} -body { text .t .t insert 1.0 "Line 1 @@ -4072,7 +4072,7 @@ test text-22.8 {TextSearchCmd procedure, -count option} -body { .t search -count } -cleanup { destroy .t -} -returnCodes {error} -result {no value given for "-count" option} +} -returnCodes error -result {no value given for "-count" option} test text-22.9 {TextSearchCmd procedure, -nocase option} -body { text .t .t insert end "xxyz xyz x. the\nfoo -forward bar xxxxx BaR foo\nxyz xxyzx" @@ -4100,7 +4100,7 @@ test text-22.12 {TextSearchCmd procedure, -nolinestop option} -body { .t search -nolinestop BaR 1.1 } -cleanup { destroy .t -} -returnCodes {error} -result {the "-nolinestop" option requires the "-regexp" option to be present} +} -returnCodes error -result {the "-nolinestop" option requires the "-regexp" option to be present} test text-22.13 {TextSearchCmd procedure, -nolinestop option} -body { text .t .t insert end "xxyz xyz x. the\nfoo -forward bar xxxxx BaR foo\nxyz xxyzx" @@ -4122,20 +4122,20 @@ test text-22.15 {TextSearchCmd procedure, argument parsing} -body { .t search abc } -cleanup { destroy .t -} -returnCodes {error} -result {wrong # args: should be ".t search ?switches? pattern index ?stopIndex?"} +} -returnCodes error -result {wrong # args: should be ".t search ?switches? pattern index ?stopIndex?"} test text-22.16 {TextSearchCmd procedure, argument parsing} -body { text .t .t insert end "xxyz xyz x. the\nfoo -forward bar xxxxx BaR foo\nxyz xxyzx" .t search abc d e f } -cleanup { destroy .t -} -returnCodes {error} -result {wrong # args: should be ".t search ?switches? pattern index ?stopIndex?"} +} -returnCodes error -result {wrong # args: should be ".t search ?switches? pattern index ?stopIndex?"} test text-22.17 {TextSearchCmd procedure, check index} -body { text .t .t search abc gorp } -cleanup { destroy .t -} -returnCodes {error} -result {bad text index "gorp"} +} -returnCodes error -result {bad text index "gorp"} test text-22.18 {TextSearchCmd procedure, startIndex == "end"} -body { text .t .t insert end "xxyz xyz x. the\nfoo -forward bar xxxxx BaR foo\nxyz xxyzx" @@ -4156,7 +4156,7 @@ test text-22.20 {TextSearchCmd procedure, bad stopIndex} -body { .t search abc 1.0 lousy } -cleanup { destroy .t -} -returnCodes {error} -result {bad text index "lousy"} +} -returnCodes error -result {bad text index "lousy"} test text-22.21 {TextSearchCmd procedure, pattern case conversion} -body { text .t .t insert end "xxyz xyz x. the\nfoo -forward bar xxxxx BaR foo\nxyz xxyzx" @@ -4170,7 +4170,7 @@ test text-22.22 {TextSearchCmd procedure, bad regular expression pattern} -body .t search -regexp a( 1.0 } -cleanup { destroy .t -} -returnCodes {error} -result {couldn't compile regular expression pattern: parentheses () not balanced} +} -returnCodes error -match glob -result {*t compile regular expression pattern: parentheses () not balanced} test text-22.23 {TextSearchCmd procedure, skip dummy last line} -body { text .t .t insert end "xxyz xyz x. the\nfoo -forward bar xxxxx BaR foo\nxyz xxyzx" @@ -4474,7 +4474,7 @@ test text-22.56 {TextSearchCmd procedure, error setting variable} -body { .t search -count a(2) xyz 1.0 } -cleanup { destroy .t -} -returnCodes {error} -result {can't set "a(2)": variable isn't array} +} -returnCodes error -match glob -result {can*t set "a(2)": variable is* array} test text-22.57 {TextSearchCmd procedure, wrap-around} -body { text .t .t insert end "xxyz xyz x. the\nfoo -forward bar xxxxx BaR foo\nxyz xxyzx" @@ -6105,7 +6105,7 @@ test text-23.1 {TkTextGetTabs procedure} -setup { .t configure -tabs "\{{}" } -cleanup { destroy .t -} -returnCodes {error} -result {unmatched open brace in list} +} -returnCodes error -result {unmatched open brace in list} test text-23.2 {TkTextGetTabs procedure} -setup { text .t -highlightthickness 0 -bd 0 -relief flat -padx 0 -width 150 pack .t @@ -6114,7 +6114,7 @@ test text-23.2 {TkTextGetTabs procedure} -setup { .t configure -tabs xyz } -cleanup { destroy .t -} -returnCodes {error} -result {bad screen distance "xyz"} +} -returnCodes error -result {bad screen distance "xyz"} test text-23.3 {TkTextGetTabs procedure} -setup { text .t -highlightthickness 0 -bd 0 -relief flat -padx 0 -width 150 pack .t @@ -6162,7 +6162,7 @@ test text-23.6 {TkTextGetTabs procedure} -setup { .t configure -tabs {100 left 200 lork} } -cleanup { destroy .t -} -returnCodes {error} -result {bad tab alignment "lork": must be left, right, center, or numeric} +} -returnCodes error -result {bad tab alignment "lork": must be left, right, center, or numeric} test text-23.7 {TkTextGetTabs procedure} -setup { text .t -highlightthickness 0 -bd 0 -relief flat -padx 0 -width 150 pack .t @@ -6171,7 +6171,7 @@ test text-23.7 {TkTextGetTabs procedure} -setup { .t configure -tabs {100 !44 200 lork} } -cleanup { destroy .t -} -returnCodes {error} -result {bad screen distance "!44"} +} -returnCodes error -result {bad screen distance "!44"} test text-24.1 {TextDumpCmd procedure, bad args} -body { @@ -6181,7 +6181,7 @@ test text-24.1 {TextDumpCmd procedure, bad args} -body { .t dump } -cleanup { destroy .t -} -returnCodes {error} -result {Usage: .t dump ?-all -image -text -mark -tag -window? ?-command script? index ?index2?} +} -returnCodes error -result {Usage: .t dump ?-all -image -text -mark -tag -window? ?-command script? index ?index2?} test text-24.2 {TextDumpCmd procedure, bad args} -body { pack [text .t] .t insert 1.0 "One Line" @@ -6189,7 +6189,7 @@ test text-24.2 {TextDumpCmd procedure, bad args} -body { .t dump -all } -cleanup { destroy .t -} -returnCodes {error} -result {Usage: .t dump ?-all -image -text -mark -tag -window? ?-command script? index ?index2?} +} -returnCodes error -result {Usage: .t dump ?-all -image -text -mark -tag -window? ?-command script? index ?index2?} test text-24.3 {TextDumpCmd procedure, bad args} -body { pack [text .t] .t insert 1.0 "One Line" @@ -6197,7 +6197,7 @@ test text-24.3 {TextDumpCmd procedure, bad args} -body { .t dump -command } -cleanup { destroy .t -} -returnCodes {error} -result {Usage: .t dump ?-all -image -text -mark -tag -window? ?-command script? index ?index2?} +} -returnCodes error -result {Usage: .t dump ?-all -image -text -mark -tag -window? ?-command script? index ?index2?} test text-24.4 {TextDumpCmd procedure, bad args} -body { pack [text .t] .t insert 1.0 "One Line" @@ -6205,7 +6205,7 @@ test text-24.4 {TextDumpCmd procedure, bad args} -body { .t dump -bogus } -cleanup { destroy .t -} -returnCodes {error} -result {bad option "-bogus": must be -all, -command, -image, -mark, -tag, -text, or -window} +} -returnCodes error -result {bad option "-bogus": must be -all, -command, -image, -mark, -tag, -text, or -window} test text-24.5 {TextDumpCmd procedure, bad args} -body { pack [text .t] .t insert 1.0 "One Line" @@ -6213,7 +6213,7 @@ test text-24.5 {TextDumpCmd procedure, bad args} -body { .t dump bogus } -cleanup { destroy .t -} -returnCodes {error} -result {bad text index "bogus"} +} -returnCodes error -result {bad text index "bogus"} test text-24.6 {TextDumpCmd procedure, one index} -body { pack [text .t] .t insert 1.0 "One Line" @@ -6469,13 +6469,13 @@ test text-27.1 {TextEditCmd procedure, argument parsing} -body { .t edit } -cleanup { destroy .t -} -returnCodes {error} -result {wrong # args: should be ".t edit option ?arg ...?"} +} -returnCodes error -result {wrong # args: should be ".t edit option ?arg ...?"} test text-27.2 {TextEditCmd procedure, argument parsing} -body { pack [text .t] .t edit gorp } -cleanup { destroy .t -} -returnCodes {error} -result {bad edit option "gorp": must be canundo, canredo, modified, redo, reset, separator, or undo} +} -returnCodes error -result {bad edit option "gorp": must be canundo, canredo, modified, redo, reset, separator, or undo} test text-27.3 {TextEditUndo procedure, undoing changes} -body { text .t -undo 1 pack .t @@ -6810,14 +6810,14 @@ test text-27.18 {patch 1469210 - inserting after undo} -setup { } -cleanup { destroy .t } -result 1 -test text-27.19 {patch 1669632 (i) - undo after } -setup { +test text-27.19 {patch 1669632 (i) - undo after } -setup { destroy .t } -body { text .t -undo 1 .t insert end foo\nbar .t edit reset .t insert 2.2 WORLD - event generate .t -x 1 -y 1 + event generate .t -x 1 -y 1 .t insert insert HELLO .t edit undo .t get 2.2 2.7 @@ -6850,7 +6850,7 @@ test text-27.21 {patch 1669632 (vii) - <> shall not remove separators} -se .t insert end "This is an example text" .t edit reset .t insert 1.5 "WORLD " - event generate .t -x 1 -y 1 + event generate .t -x 1 -y 1 .t insert insert HELLO event generate .t <> .t insert insert E @@ -6983,7 +6983,6 @@ test text-27.26 {bug ab839efc5f - .text edit undo inserts separators} -setup { destroy .t } -result {3. 123 5 789012 LINE-3} - test text-28.1 {bug fix - 624372, ControlUtfProc long lines} -body { pack [text .t -wrap none] .t insert end [string repeat "\1" 500] @@ -6997,13 +6996,13 @@ test text-29.1 {tabs - must be positive and must be increasing} -body { .t configure -tabs 0 } -cleanup { destroy .t -} -returnCodes {error} -result {tab stop "0" is not at a positive distance} +} -returnCodes error -result {tab stop "0" is not at a positive distance} test text-29.2 {tabs - must be positive and must be increasing} -body { pack [text .t -wrap none] .t configure -tabs -5 } -cleanup { destroy .t -} -returnCodes {error} -result {tab stop "-5" is not at a positive distance} +} -returnCodes error -result {tab stop "-5" is not at a positive distance} test text-29.3 {tabs - must be positive and must be increasing} -constraints { knownBug } -body { @@ -7013,7 +7012,7 @@ test text-29.3 {tabs - must be positive and must be increasing} -constraints { .t configure -tabs {10c 5c} } -cleanup { destroy .t -} -returnCodes {error} -result {tabs must be monotonically increasing, but "5c" is smaller than or equal to the previous tab} +} -returnCodes error -result {tabs must be monotonically increasing, but "5c" is smaller than or equal to the previous tab} test text-29.4 {tabs - must be positive and must be increasing} -body { pack [text .t -wrap none] .t insert end "a\tb\tc\td\te" @@ -7348,7 +7347,7 @@ test text-31.19 {peer widgets} -body { .t index sel.first } -cleanup { destroy .t -} -returnCodes {error} -result {text doesn't contain any characters tagged with "sel"} +} -returnCodes error -result {text doesn't contain any characters tagged with "sel"} test text-32.1 {line heights on creation} -setup { @@ -7489,14 +7488,14 @@ test text-33.1 {TextWidgetCmd procedure, "peer" option} -setup { .t peer foo 1 } -cleanup { destroy .t -} -returnCodes {error} -result {bad peer option "foo": must be create or names} +} -returnCodes error -result {bad peer option "foo": must be create or names} test text-33.2 {TextWidgetCmd procedure, "peer" option} -setup { text .t } -body { .t peer names foo } -cleanup { destroy .t -} -returnCodes {error} -result {wrong # args: should be ".t peer names"} +} -returnCodes error -result {wrong # args: should be ".t peer names"} test text-33.3 {TextWidgetCmd procedure, "peer" option} -setup { text .t } -body { @@ -7517,7 +7516,7 @@ test text-33.5 {TextWidgetCmd procedure, "peer" option} -setup { .t peer create foo } -cleanup { destroy .t -} -returnCodes {error} -result {bad window path name "foo"} +} -returnCodes error -result {bad window path name "foo"} test text-33.6 {TextWidgetCmd procedure, "peer" option} -setup { text .t set res {} @@ -7545,7 +7544,7 @@ test text-33.8 {peer widget -start, -end} -body { .t configure -startline 10 -endline 5 } -cleanup { destroy .t -} -returnCodes {error} -result {-startline must be less than or equal to -endline} +} -returnCodes error -result {-startline must be less than or equal to -endline} test text-33.9 {peer widget -start, -end} -body { text .t for {set i 1} {$i < 100} {incr i} { @@ -7663,8 +7662,8 @@ test text-36.1 "bug #1777362: event handling with hyphenated windows" -setup { pack [set w [text .t-1]] } -body { tkwait visibility $w - event generate $w <1> - event generate $w <1> + event generate $w + event generate $w update set ::my_error } -cleanup { @@ -7681,8 +7680,8 @@ test text-36.2 "bug #1777362: event handling with hyphenated windows" -setup { pack [set w [text .t+1]] } -body { tkwait visibility $w - event generate $w <1> - event generate $w <1> + event generate $w + event generate $w update set ::my_error } -cleanup { @@ -7699,8 +7698,8 @@ test text-36.3 "bug #1777362: event handling with hyphenated windows" -setup { pack [set w [text .t*1]] } -body { tkwait visibility $w - event generate $w <1> - event generate $w <1> + event generate $w + event generate $w update set ::my_error } -cleanup { diff --git a/tests/textBTree.test b/tests/textBTree.test index b1f232c65..f86662e44 100644 --- a/tests/textBTree.test +++ b/tests/textBTree.test @@ -5,7 +5,7 @@ # # Copyright (c) 1992-1994 The Regents of the University of California. # Copyright (c) 1994 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. package require tcltest 2.2 diff --git a/tests/textDisp.test b/tests/textDisp.test index 7fe45a3c6..bdf39cead 100644 --- a/tests/textDisp.test +++ b/tests/textDisp.test @@ -3,7 +3,7 @@ # # Copyright (c) 1994 The Regents of the University of California. # Copyright (c) 1994-1997 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. package require tcltest 2.2 diff --git a/tests/textImage.test b/tests/textImage.test index 5a905b652..27c882807 100644 --- a/tests/textImage.test +++ b/tests/textImage.test @@ -4,7 +4,7 @@ # built-in commands. Sourcing this file into Tcl runs the tests and # generates output for errors. No output means no errors were found. # -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. package require tcltest 2.2 diff --git a/tests/textIndex.test b/tests/textIndex.test index 06c98be68..2931af4f1 100644 --- a/tests/textIndex.test +++ b/tests/textIndex.test @@ -3,7 +3,7 @@ # # Copyright (c) 1994 The Regents of the University of California. # Copyright (c) 1994 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. package require tcltest 2.2 diff --git a/tests/textMark.test b/tests/textMark.test index 6c4d4cd2b..17170ae3e 100644 --- a/tests/textMark.test +++ b/tests/textMark.test @@ -3,7 +3,7 @@ # # Copyright (c) 1994 The Regents of the University of California. # Copyright (c) 1994 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. package require tcltest 2.2 diff --git a/tests/textWind.test b/tests/textWind.test index 1de8a548a..494a9aeae 100644 --- a/tests/textWind.test +++ b/tests/textWind.test @@ -3,7 +3,7 @@ # # Copyright (c) 1994 The Regents of the University of California. # Copyright (c) 1994-1995 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. package require tcltest 2.2 diff --git a/tests/tk.test b/tests/tk.test index bf8db0c19..56c42067d 100644 --- a/tests/tk.test +++ b/tests/tk.test @@ -2,7 +2,7 @@ # It is organized in the standard fashion for Tcl tests. # # Copyright (c) 1997 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # Copyright (c) 2002 ActiveState Corporation. package require tcltest 2.2 diff --git a/tests/ttk/entry.test b/tests/ttk/entry.test index 59ae992f3..b78e57a7c 100644 --- a/tests/ttk/entry.test +++ b/tests/ttk/entry.test @@ -296,7 +296,7 @@ test entry-8.2 "Unset linked variable by deleting namespace" -body { namespace delete ::test .e insert end "baz" ;# <== error here list [.e cget -textvariable] [.e get] [set foo] -} -returnCodes error -result "*parent namespace doesn't exist*" -match glob +} -returnCodes error -result {can*t set "::test::foo": parent namespace does*t exist} -match glob # '-result [list ::test::foo "baz" "baz"]' would also be sensible, # but Tcl namespaces don't work that way. diff --git a/tests/ttk/ttk.test b/tests/ttk/ttk.test index fb7f47b94..ad7f9a996 100644 --- a/tests/ttk/ttk.test +++ b/tests/ttk/ttk.test @@ -209,8 +209,8 @@ test ttk-2.8 "bug 3223850: button state disabled during click" -setup { pack [ttk::button .b -command {set ::ttk28 failed}] update } -body { - bind .b {after 0 {.b configure -state disabled}} - after 1 {event generate .b } + bind .b {after 0 {.b configure -state disabled}} + after 1 {event generate .b } after 50 {event generate .b } set aid [after 100 {set ::ttk28 [.b instate {disabled !pressed}]}] vwait ::ttk28 @@ -248,7 +248,7 @@ test ttk-3.2 "Propagate errors from variable traces" -body { .cb invoke } -cleanup { unset ::A ; destroy .cb -} -returnCodes error -result {can't set "A": failure} +} -returnCodes error -match glob -result {can*t set "A": failure} test ttk-3.3 "Constructor failure with cursor" -body { ttk::button .b -cursor bottom_right_corner -style BadStyle @@ -388,12 +388,12 @@ test ttk-8.4 "ImageChanged" -body { test ttk-9.1 "Traces on nonexistant namespaces" -body { ttk::checkbutton .tcb -variable foo::bar -} -returnCodes error -result "*parent namespace doesn't exist*" -match glob +} -returnCodes error -result "*parent namespace does*t exist" -match glob test ttk-9.2 "Traces on nonexistant namespaces II" -body { ttk::checkbutton .tcb -variable X .tcb configure -variable foo::bar -} -returnCodes error -result "*parent namespace doesn't exist*" -match glob +} -returnCodes error -result "*parent namespace does*t exist" -match glob test ttk-9.3 "Restore saved options on configure error" -body { .tcb cget -variable @@ -582,17 +582,17 @@ test ttk-13.5 "Custom layouts -- missing element definition" -body { test ttk-14.1 "-variable in nonexistant namespace" -body { ttk::checkbutton .tw -variable ::nsn::foo -} -returnCodes error -result {can't trace *: parent namespace doesn't exist} \ +} -returnCodes error -result {can*t trace "::nsn::foo": parent namespace does*t exist} \ -match glob -cleanup { destroy .tw } test ttk-14.2 "-textvariable in nonexistant namespace" -body { ttk::label .tw -textvariable ::nsn::foo -} -returnCodes error -result {can't trace *: parent namespace doesn't exist} \ +} -returnCodes error -result {can*t trace "::nsn::foo": parent namespace does*t exist} \ -match glob -cleanup { destroy .tw } test ttk-14.3 "-textvariable in nonexistant namespace" -body { ttk::entry .tw -textvariable ::nsn::foo -} -returnCodes error -result {can't trace *: parent namespace doesn't exist} \ +} -returnCodes error -result {can*t trace "::nsn::foo": parent namespace does*t exist} \ -match glob -cleanup { destroy .tw } test ttk-15.1 {Bug 3062331} -setup { diff --git a/tests/unixButton.test b/tests/unixButton.test index f0dcde540..f28b567f5 100644 --- a/tests/unixButton.test +++ b/tests/unixButton.test @@ -5,7 +5,7 @@ # # Copyright (c) 1994 The Regents of the University of California. # Copyright (c) 1994-1997 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. package require tcltest 2.2 diff --git a/tests/unixEmbed.test b/tests/unixEmbed.test index 25a06b10e..410f90212 100644 --- a/tests/unixEmbed.test +++ b/tests/unixEmbed.test @@ -3,7 +3,7 @@ # tests. # # Copyright (c) 1996-1997 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. package require tcltest 2.2 diff --git a/tests/unixFont.test b/tests/unixFont.test index 68cb6331c..6a56bcbb7 100644 --- a/tests/unixFont.test +++ b/tests/unixFont.test @@ -9,7 +9,7 @@ # at all sites. # # Copyright (c) 1996 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. package require tcltest 2.2 diff --git a/tests/unixMenu.test b/tests/unixMenu.test index 63e48497c..79587fd67 100644 --- a/tests/unixMenu.test +++ b/tests/unixMenu.test @@ -4,7 +4,7 @@ # system. # # Copyright (c) 1995-1996 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. package require tcltest 2.2 diff --git a/tests/unixSelect.test b/tests/unixSelect.test index d3da806cd..6626ff113 100644 --- a/tests/unixSelect.test +++ b/tests/unixSelect.test @@ -4,7 +4,7 @@ # built-in commands. Sourcing this file into Tcl runs the tests and # generates output for errors. No output means no errors were found. # -# Copyright (c) 1999 by Scriptics Corporation. +# Copyright (c) 1999 Scriptics Corporation. # # See the file "license.terms" for information on usage and redistribution # of this file, and for a DISCLAIMER OF ALL WARRANTIES. diff --git a/tests/unixWm.test b/tests/unixWm.test index e2cab6ea9..cbbe7fb97 100644 --- a/tests/unixWm.test +++ b/tests/unixWm.test @@ -4,7 +4,7 @@ # # Copyright (c) 1992-1994 The Regents of the University of California. # Copyright (c) 1994-1997 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. package require tcltest 2.2 diff --git a/tests/util.test b/tests/util.test index bd347d0d6..5502512f3 100644 --- a/tests/util.test +++ b/tests/util.test @@ -3,7 +3,7 @@ # # Copyright (c) 1994 The Regents of the University of California. # Copyright (c) 1994 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. package require tcltest 2.2 diff --git a/tests/visual.test b/tests/visual.test index 8d6309710..a8dcbda43 100644 --- a/tests/visual.test +++ b/tests/visual.test @@ -4,7 +4,7 @@ # # Copyright (c) 1994 The Regents of the University of California. # Copyright (c) 1994-1995 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. package require tcltest 2.2 diff --git a/tests/winButton.test b/tests/winButton.test index 88b4345ff..8cf52e83e 100644 --- a/tests/winButton.test +++ b/tests/winButton.test @@ -5,7 +5,7 @@ # # Copyright (c) 1994 The Regents of the University of California. # Copyright (c) 1994-1997 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. package require tcltest 2.2 diff --git a/tests/winClipboard.test b/tests/winClipboard.test index 2f7296614..e7495db11 100644 --- a/tests/winClipboard.test +++ b/tests/winClipboard.test @@ -6,8 +6,8 @@ # built-in commands. Sourcing this file into Tcl runs the tests and # generates output for errors. No output means no errors were found. # -# Copyright (c) 1997 by Sun Microsystems, Inc. -# Copyright (c) 1998-2000 by Scriptics Corporation. +# Copyright (c) 1997 Sun Microsystems, Inc. +# Copyright (c) 1998-2000 Scriptics Corporation. # All rights reserved. package require tcltest 2.2 diff --git a/tests/winDialog.test b/tests/winDialog.test index 4f1c98db6..eb5ff311e 100755 --- a/tests/winDialog.test +++ b/tests/winDialog.test @@ -4,7 +4,7 @@ # fashion for Tcl tests. # # Copyright (c) 1997 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # Copyright (c) 1998-1999 ActiveState Corporation. package require tcltest 2.2 diff --git a/tests/winFont.test b/tests/winFont.test index d76972510..f466fd258 100644 --- a/tests/winFont.test +++ b/tests/winFont.test @@ -7,7 +7,7 @@ # but there are no results that can be checked. # # Copyright (c) 1996-1997 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. package require tcltest 2.2 diff --git a/tests/winMenu.test b/tests/winMenu.test index b77e9a934..56010a79b 100644 --- a/tests/winMenu.test +++ b/tests/winMenu.test @@ -4,7 +4,7 @@ # system. # # Copyright (c) 1995-1996 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. package require tcltest 2.2 diff --git a/tests/winSend.test b/tests/winSend.test index a72589fcf..7e26c22e2 100644 --- a/tests/winSend.test +++ b/tests/winSend.test @@ -4,7 +4,7 @@ # # Copyright (c) 1994 Sun Microsystems, Inc. # Copyright (c) 1994-1996 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. package require tcltest 2.2 diff --git a/tests/winWm.test b/tests/winWm.test index f3ba3d42e..b075d28cf 100644 --- a/tests/winWm.test +++ b/tests/winWm.test @@ -5,8 +5,8 @@ # built-in commands. Sourcing this file into Tcl runs the tests and # generates output for errors. No output means no errors were found. # -# Copyright (c) 1996 by Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1996 Sun Microsystems, Inc. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. package require tcltest 2.2 diff --git a/tests/window.test b/tests/window.test index c3b507dbc..9cacc4e12 100644 --- a/tests/window.test +++ b/tests/window.test @@ -2,7 +2,7 @@ # tkWindow.c. It is organized in the standard fashion for Tcl tests. # # Copyright (c) 1995 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. package require tcltest 2.2 diff --git a/tests/winfo.test b/tests/winfo.test index ffacf8f42..c02019659 100644 --- a/tests/winfo.test +++ b/tests/winfo.test @@ -3,7 +3,7 @@ # # Copyright (c) 1994 The Regents of the University of California. # Copyright (c) 1994-1997 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. package require tcltest 2.2 diff --git a/tests/wm.test b/tests/wm.test index 1fe43a5c6..5542f14bf 100644 --- a/tests/wm.test +++ b/tests/wm.test @@ -4,7 +4,7 @@ # # Copyright (c) 1992-1994 The Regents of the University of California. # Copyright (c) 1994-1997 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. # This file tests window manager interactions that work across platforms. @@ -876,7 +876,7 @@ test wm-iconphoto-1.4 {usage} -returnCodes error -body { } -result {wrong # args: should be "wm iconphoto window ?-default? image1 ?image2 ...?"} test wm-iconphoto-1.5.1 {usage} -constraints aquaOrWin32 -returnCodes error -body { wm iconphoto . -default [image create photo -file {}] -} -match {glob} -result {failed to create an iconphoto with image *} +} -match glob -result {failed to create an iconphoto with image *} test wm-iconphoto-1.5.2 {usage} -constraints x11 -body { wm iconphoto . -default [image create photo -file {}] } -result {} diff --git a/tests/xmfbox.test b/tests/xmfbox.test index f50329ce8..547d9d47e 100644 --- a/tests/xmfbox.test +++ b/tests/xmfbox.test @@ -6,7 +6,7 @@ # to call the internal Tcl procedures in xmfbox.tcl directly. # # Copyright (c) 1997 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # Contributions from Don Porter, NIST, 2002. (not subject to US copyright) # All rights reserved. diff --git a/win/tkWinDraw.c b/win/tkWinDraw.c index d0df3eca2..b329d54b7 100644 --- a/win/tkWinDraw.c +++ b/win/tkWinDraw.c @@ -1482,6 +1482,67 @@ TkpDrawHighlightBorder( TkDrawInsetFocusHighlight(tkwin, fgGC, highlightWidth, drawable, 0); } +/* + *---------------------------------------------------------------------- + * + * TkWinDrawDottedRect -- + * + * This function draws a dotted rectangle, used as focus ring of Ttk + * widgets and for rendering the active element of a listbox. + * + * Results: + * None. + * + * Side effects: + * A dotted rectangle is drawn in the specified Drawable. + * + *---------------------------------------------------------------------- + */ + +void +TkWinDrawDottedRect( + Display *disp, /* Display containing the dotted rectangle. */ + Drawable d, /* Where to draw the rectangle (typically a + * pixmap for double buffering). */ + unsigned long pixel, /* color to use for drawing the rectangle. */ + int x, int y, /* Coordinates of the top-left corner. */ + int width, int height) /* Width & height, _including the border_. */ +{ + TkWinDCState state; + HDC dc; + LOGBRUSH lb; + HPEN pen; + int widthMod2 = width % 2, heightMod2 = height % 2; + int x2 = x + width - 1, y2 = y + height - 1; + + dc = TkWinGetDrawableDC(disp, d, &state); + + lb.lbStyle = BS_SOLID; + lb.lbColor = (COLORREF)pixel; + lb.lbHatch = 0; + + pen = ExtCreatePen(PS_COSMETIC | PS_ALTERNATE, 1, &lb, 0, NULL); + SelectObject(dc, pen); + SelectObject(dc, GetStockObject(NULL_BRUSH)); + + if (widthMod2 == 0 && heightMod2 == 0) { + MoveToEx(dc, x+1, y, NULL); LineTo(dc, x2, y); /* N */ + MoveToEx(dc, x+2, y2, NULL); LineTo(dc, x2+1, y2); /* S */ + MoveToEx(dc, x, y+2, NULL); LineTo(dc, x, y2+1); /* W */ + MoveToEx(dc, x2, y+1, NULL); LineTo(dc, x2, y2); /* E */ + } else { + int dx = widthMod2, dy = heightMod2; + + MoveToEx(dc, x+1, y, NULL); LineTo(dc, x2+dx, y); /* N */ + MoveToEx(dc, x+1, y2, NULL); LineTo(dc, x2+dx, y2); /* S */ + MoveToEx(dc, x, y+1, NULL); LineTo(dc, x, y2+dy); /* W */ + MoveToEx(dc, x2, y+1, NULL); LineTo(dc, x2, y2+dy); /* E */ + } + + DeleteObject(pen); + TkWinReleaseDrawableDC(d, dc, &state); +} + /* *---------------------------------------------------------------------- * diff --git a/win/tkWinInt.h b/win/tkWinInt.h index 892d9c699..c2e4715ec 100644 --- a/win/tkWinInt.h +++ b/win/tkWinInt.h @@ -191,26 +191,34 @@ MODULE_SCOPE void TkWinSetupSystemFonts(TkMainInfo *mainPtr); * The following is implemented in tkWinWm and used by tkWinEmbed.c */ -MODULE_SCOPE void TkpWinToplevelWithDraw(TkWindow *winPtr); -MODULE_SCOPE void TkpWinToplevelIconify(TkWindow *winPtr); -MODULE_SCOPE void TkpWinToplevelDeiconify(TkWindow *winPtr); -MODULE_SCOPE long TkpWinToplevelIsControlledByWm(TkWindow *winPtr); -MODULE_SCOPE long TkpWinToplevelMove(TkWindow *winPtr, int x, int y); -MODULE_SCOPE long TkpWinToplevelOverrideRedirect(TkWindow *winPtr, +MODULE_SCOPE void TkpWinToplevelWithDraw(TkWindow *winPtr); +MODULE_SCOPE void TkpWinToplevelIconify(TkWindow *winPtr); +MODULE_SCOPE void TkpWinToplevelDeiconify(TkWindow *winPtr); +MODULE_SCOPE long TkpWinToplevelIsControlledByWm(TkWindow *winPtr); +MODULE_SCOPE long TkpWinToplevelMove(TkWindow *winPtr, int x, int y); +MODULE_SCOPE long TkpWinToplevelOverrideRedirect(TkWindow *winPtr, int reqValue); -MODULE_SCOPE void TkpWinToplevelDetachWindow(TkWindow *winPtr); -MODULE_SCOPE int TkpWmGetState(TkWindow *winPtr); +MODULE_SCOPE void TkpWinToplevelDetachWindow(TkWindow *winPtr); +MODULE_SCOPE int TkpWmGetState(TkWindow *winPtr); /* * The following is implemented in tkWinPointer.c and also used in tkWinWindow.c */ -MODULE_SCOPE void TkSetCursorPos(int x, int y); +MODULE_SCOPE void TkSetCursorPos(int x, int y); + +/* + * The following is implemented in tkWinDraw.c and used in tkUtil.c + */ + +MODULE_SCOPE void TkWinDrawDottedRect (Display *disp, Drawable d, + unsigned long pixel, int x, int y, + int width, int height); /* * Common routines used in Windows implementation */ -MODULE_SCOPE Tcl_Obj * TkWin32ErrorObj(HRESULT hrError); +MODULE_SCOPE Tcl_Obj * TkWin32ErrorObj(HRESULT hrError); /*