summaryrefslogtreecommitdiffstats
path: root/Source/cmAddTestCommand.cxx
Commit message (Collapse)AuthorAgeFilesLines
* COMP: Fix problem on compilers that cannot implicitly convert std::string to ↵Andy Cedilnik2005-04-241-1/+5
| | | | cmStdString
* ENH: Improve internal test handling by creating a test class. Command ↵Andy Cedilnik2005-04-241-61/+9
| | | | cmEnableTesting now only sets CMAKE_TESTING_ENABLED and cmAddTest only adds a test to the list. The actual test files are written by local generator. This way we can at some point in the future replace DartTestfile with some XML file
* BUG: By default disable new files.Andy Cedilnik2005-04-041-3/+3
|
* ENH: More ctest changes and move SetupTest to superclassAndy Cedilnik2005-04-011-1/+1
|
* ENH: Start adding support for CTest testfilesAndy Cedilnik2005-04-011-1/+8
|
* ENH: big change that includes immediate subdir support, removing the notion ↵Ken Martin2005-03-181-1/+1
| | | | of inherited commands, makefiles no longer read in the parent makefiles but instead inherit thier parent makefiles current settings
* BUG: Cannot add extra escapes for backslashes because it makes the behavior ↵Brad King2003-11-041-2/+4
| | | | inconsistent with previous versions of cmake.
* BUG#259: ADD_TEST command generated in DartTestfile.txt now quotes/escapes ↵Brad King2003-11-031-7/+12
| | | | all arguments.
* BUG: Backing out previous change until a deeper problem can be investigated.Brad King2003-10-301-10/+9
|
* BUG#259: Do not double quote arguments if they are already quoted when ↵Brad King2003-10-301-9/+10
| | | | writing DartTestfile.txt.
* ENH: Moved ExpandListVariables out of individual commands. Argument ↵Brad King2002-12-111-2/+1
| | | | evaluation rules are now very consistent. Double quotes can always be used to create exactly one argument, regardless of contents inside.
* ENH: Added reference to Copyright.txt. Removed old reference to ITK ↵Brad King2002-10-231-11/+11
| | | | copyright. Changed program name to CMake instead of Insight in source file header. Also removed tabs.
* removed some includesKen Martin2002-09-271-1/+0
|
* make sure ; expansion is done in all commandsBill Hoffman2002-03-291-7/+1
|
* ENH: expand variables in arguments before the commands get themBill Hoffman2002-03-051-3/+1
|
* FIX: command now expands args during the first pass (found through FOREACH ↵Sebastien Barre2002-02-261-9/+11
| | | | example)
* ENH: fix for spaces in paths on unixBill Hoffman2002-02-221-1/+8
|
* ENH:Updated copyrightWill Schroeder2002-01-211-29/+5
|
* ENH: change InitialPass to take a const reference to the argument string, to ↵Bill Hoffman2001-09-201-1/+1
| | | | avoid changes to the file cache
* BUG: ADD_TEST now only does stuff if ENABLE_TESTING has been run.Amitha Perera2001-08-231-18/+22
|
* ENH: Changed generated filename to DartTestfile.txtJim Miller2001-06-191-1/+1
|
* ENH: move utilities to targets from makefile, and add versioning to cacheBill Hoffman2001-06-071-1/+1
|
* FIX: InitialPass() seg fault on std::copy and FinalPass() was not appending ↵Jim Miller2001-06-061-3/+4
| | | | to the file
* added enable testing deprecated some commandsKen Martin2001-06-061-4/+39
|
* ENH: rename Invoke to InitialPassBill Hoffman2001-06-061-1/+1
|
* New cmake command to specify a single testJim Miller2001-06-061-0/+69
ng a graphical user interface (GUI) in many programming languages.
summaryrefslogtreecommitdiffstats
path: root/generic
diff options
context:
space:
mode:
authorericm <ericm>2000-11-22 01:49:37 (GMT)
committerericm <ericm>2000-11-22 01:49:37 (GMT)
commit31e9ab3d0310055f094cbcfa64af7e6834555cb5 (patch)
treeb3d9ff19b6b8294780db27da55671e4ef2f9fd75 /generic
parent5fb60902d139dbaa22360245c548fbdbfa0e28fa (diff)
downloadtk-31e9ab3d0310055f094cbcfa64af7e6834555cb5.zip
tk-31e9ab3d0310055f094cbcfa64af7e6834555cb5.tar.gz
tk-31e9ab3d0310055f094cbcfa64af7e6834555cb5.tar.bz2
Overall change: Implemented TIP 5, which exports
TkClassProcs/TkSetClassProcs as Tk_ClassProcs/Tk_SetClassProcs, adding a size field to Tk_ClassProcs to allow for future expansion, and renaming the geometryProc to worldChangedProc, which is more in keeping with the actual use of the callback. See ChangeLog for details.
Diffstat (limited to 'generic')
-rw-r--r--generic/tk.decls7
-rw-r--r--generic/tk.h47
-rw-r--r--generic/tkBind.c9
-rw-r--r--generic/tkButton.c4
-rw-r--r--generic/tkButton.h4
-rw-r--r--generic/tkCanvas.c11
-rw-r--r--generic/tkDecls.h11
-rw-r--r--generic/tkEntry.c13
-rw-r--r--generic/tkFont.c28
-rw-r--r--generic/tkFrame.c4
-rw-r--r--generic/tkInt.decls11
-rw-r--r--generic/tkInt.h30
-rw-r--r--generic/tkIntDecls.h14
-rw-r--r--generic/tkListbox.c11
-rw-r--r--generic/tkMenu.c12
-rw-r--r--generic/tkMenubutton.c4
-rw-r--r--generic/tkMenubutton.h4
-rw-r--r--generic/tkMessage.c13
-rw-r--r--generic/tkScale.c11
-rw-r--r--generic/tkScrollbar.c4
-rw-r--r--generic/tkScrollbar.h4
-rw-r--r--generic/tkStubInit.c5
-rw-r--r--generic/tkText.c11
-rw-r--r--generic/tkWindow.c16
24 files changed, 166 insertions, 122 deletions
diff --git a/generic/tk.decls b/generic/tk.decls
index ef1057d..d9b4a32 100644
--- a/generic/tk.decls
+++ b/generic/tk.decls
@@ -11,7 +11,7 @@
# See the file "license.terms" for information on usage and redistribution
# of this file, and for a DISCLAIMER OF ALL WARRANTIES.
#
-# RCS: @(#) $Id: tk.decls,v 1.13 2000/10/21 21:22:42 ericm Exp $
+# RCS: @(#) $Id: tk.decls,v 1.14 2000/11/22 01:49:37 ericm Exp $
library tk
@@ -1142,7 +1142,10 @@ declare 241 generic {
Tk_Window Tk_CreateAnonymousWindow (Tcl_Interp *interp, \
Tk_Window parent, char *screenName)
}
-
+declare 242 generic {
+ void Tk_SetClassProcs (Tk_Window tkwin, \
+ Tk_ClassProcs *procs, ClientData instanceData)
+}
# Define the platform specific public Tk interface. These functions are
# only available on the designated platform.
diff --git a/generic/tk.h b/generic/tk.h
index 206c864..d91da04 100644
--- a/generic/tk.h
+++ b/generic/tk.h
@@ -12,7 +12,7 @@
* See the file "license.terms" for information on usage and redistribution
* of this file, and for a DISCLAIMER OF ALL WARRANTIES.
*
- * RCS: @(#) $Id: tk.h,v 1.52 2000/10/05 18:31:25 ericm Exp $
+ * RCS: @(#) $Id: tk.h,v 1.53 2000/11/22 01:49:37 ericm Exp $
*/
#ifndef _TK
@@ -548,6 +548,51 @@ typedef struct Tk_FontMetrics {
#define TK_IGNORE_NEWLINES 16
/*
+ * Widget class procedures used to implement platform specific widget
+ * behavior.
+ */
+
+typedef Window (Tk_ClassCreateProc) _ANSI_ARGS_((Tk_Window tkwin,
+ Window parent, ClientData instanceData));
+typedef void (Tk_ClassWorldChangedProc) _ANSI_ARGS_((ClientData instanceData));
+typedef void (Tk_ClassModalProc) _ANSI_ARGS_((Tk_Window tkwin,
+ XEvent *eventPtr));
+
+typedef struct Tk_ClassProcs {
+ unsigned int size;
+ Tk_ClassWorldChangedProc *worldChangedProc;
+ /* Procedure to invoke when the widget needs to
+ * respond in some way to a change in the
+ * world (font changes, etc.) */
+ Tk_ClassCreateProc *createProc;
+ /* Procedure to invoke when the
+ * platform-dependent window needs to be
+ * created. */
+ Tk_ClassModalProc *modalProc;
+ /* Procedure to invoke after all bindings on a
+ * widget have been triggered in order to
+ * handle a modal loop. */
+} Tk_ClassProcs;
+
+/*
+ * Simple accessor for Tk_ClassProcs structure. Checks that the structure
+ * is not NULL, then checks the size field and returns either the requested
+ * field, if present, or NULL if the structure is too small to have the field
+ * (or NULL if the structure is NULL).
+ *
+ * A more general version of this function may be useful if other
+ * size-versioned structure pop up in the future:
+ *
+ * #define Tk_GetField(name, who, which) \
+ * (((who) == NULL) ? NULL :
+ * (((who)->size <= Tk_Offset(name, which)) ? NULL :(name)->which))
+ */
+
+#define Tk_GetClassProc(procs, which) \
+ (((procs) == NULL) ? NULL : \
+ (((procs)->size <= Tk_Offset(Tk_ClassProcs, which)) ? NULL:(procs)->which))
+
+/*
* Each geometry manager (the packer, the placer, etc.) is represented
* by a structure of the following form, which indicates procedures
* to invoke in the geometry manager to carry out certain functions.
diff --git a/generic/tkBind.c b/generic/tkBind.c
index e105d4d..71e5db1 100644
--- a/generic/tkBind.c
+++ b/generic/tkBind.c
@@ -11,7 +11,7 @@
* See the file "license.terms" for information on usage and redistribution
* of this file, and for a DISCLAIMER OF ALL WARRANTIES.
*
- * RCS: @(#) $Id: tkBind.c,v 1.13 2000/04/19 01:06:50 ericm Exp $
+ * RCS: @(#) $Id: tkBind.c,v 1.14 2000/11/22 01:49:37 ericm Exp $
*/
#include "tkPort.h"
@@ -1426,7 +1426,7 @@ Tk_BindEvent(bindingTable, eventPtr, tkwin, numObjects, objectPtr)
PendingBinding staticPending;
TkWindow *winPtr = (TkWindow *)tkwin;
PatternTableKey key;
-
+ Tk_ClassModalProc *modalProc;
/*
* Ignore events on windows that don't have names: these are windows
* like wrapper windows that shouldn't be visible to the
@@ -1805,7 +1805,10 @@ Tk_BindEvent(bindingTable, eventPtr, tkwin, numObjects, objectPtr)
winPtr->flags = (winPtr->flags & (unsigned int) ~TK_DEFER_MODAL)
| (flags & TK_DEFER_MODAL);
if (deferModal) {
- (*winPtr->classProcsPtr->modalProc)(tkwin, eventPtr);
+ modalProc = Tk_GetClassProc(winPtr->classProcsPtr, modalProc);
+ if (modalProc != NULL) {
+ (*modalProc)(tkwin, eventPtr);
+ }
}
}
diff --git a/generic/tkButton.c b/generic/tkButton.c
index ea2c10a..23bc057 100644
--- a/generic/tkButton.c
+++ b/generic/tkButton.c
@@ -11,7 +11,7 @@
* See the file "license.terms" for information on usage and redistribution
* of this file, and for a DISCLAIMER OF ALL WARRANTIES.
*
- * RCS: @(#) $Id: tkButton.c,v 1.11 2000/10/01 21:35:27 ericm Exp $
+ * RCS: @(#) $Id: tkButton.c,v 1.12 2000/11/22 01:49:37 ericm Exp $
*/
#include "tkButton.h"
@@ -658,7 +658,7 @@ ButtonCreate(clientData, interp, objc, objv, type)
Tk_SetClass(tkwin, classNames[type]);
butPtr = TkpCreateButton(tkwin);
- TkSetClassProcs(tkwin, &tkpButtonProcs, (ClientData) butPtr);
+ Tk_SetClassProcs(tkwin, &tkpButtonProcs, (ClientData) butPtr);
/*
* Initialize the data structure for the button.
diff --git a/generic/tkButton.h b/generic/tkButton.h
index 97cc1f0..6469d46 100644
--- a/generic/tkButton.h
+++ b/generic/tkButton.h
@@ -9,7 +9,7 @@
* See the file "license.terms" for information on usage and redistribution
* of this file, and for a DISCLAIMER OF ALL WARRANTIES.
*
- * RCS: @(#) $Id: tkButton.h,v 1.7 2000/05/17 21:17:20 ericm Exp $
+ * RCS: @(#) $Id: tkButton.h,v 1.8 2000/11/22 01:49:37 ericm Exp $
*/
#ifndef _TKBUTTON
@@ -287,7 +287,7 @@ typedef struct {
* Declaration of variables shared between the files in the button module.
*/
-extern TkClassProcs tkpButtonProcs;
+extern Tk_ClassProcs tkpButtonProcs;
/*
* Declaration of procedures used in the implementation of the button
diff --git a/generic/tkCanvas.c b/generic/tkCanvas.c
index 709375a..0820e02 100644
--- a/generic/tkCanvas.c
+++ b/generic/tkCanvas.c
@@ -12,7 +12,7 @@
* See the file "license.terms" for information on usage and redistribution
* of this file, and for a DISCLAIMER OF ALL WARRANTIES.
*
- * RCS: @(#) $Id: tkCanvas.c,v 1.14 2000/04/14 08:33:15 hobbs Exp $
+ * RCS: @(#) $Id: tkCanvas.c,v 1.15 2000/11/22 01:49:37 ericm Exp $
*/
/* #define USE_OLD_TAG_SEARCH 1 */
@@ -330,10 +330,9 @@ static Tk_Item * TagSearchNext _ANSI_ARGS_((TagSearch *searchPtr));
* that can be invoked from generic window code.
*/
-static TkClassProcs canvasClass = {
- NULL, /* createProc. */
- CanvasWorldChanged, /* geometryProc. */
- NULL /* modalProc. */
+static Tk_ClassProcs canvasClass = {
+ sizeof(Tk_ClassProcs), /* size */
+ CanvasWorldChanged, /* worldChangedProc */
};
@@ -467,7 +466,7 @@ Tk_CanvasObjCmd(clientData, interp, argc, argv)
Tcl_InitHashTable(&canvasPtr->idTable, TCL_ONE_WORD_KEYS);
Tk_SetClass(canvasPtr->tkwin, "Canvas");
- TkSetClassProcs(canvasPtr->tkwin, &canvasClass, (ClientData) canvasPtr);
+ Tk_SetClassProcs(canvasPtr->tkwin, &canvasClass, (ClientData) canvasPtr);
Tk_CreateEventHandler(canvasPtr->tkwin,
ExposureMask|StructureNotifyMask|FocusChangeMask,
CanvasEventProc, (ClientData) canvasPtr);
diff --git a/generic/tkDecls.h b/generic/tkDecls.h
index 31f5808..e4753e1 100644
--- a/generic/tkDecls.h
+++ b/generic/tkDecls.h
@@ -8,7 +8,7 @@
* See the file "license.terms" for information on usage and redistribution
* of this file, and for a DISCLAIMER OF ALL WARRANTIES.
*
- * RCS: @(#) $Id: tkDecls.h,v 1.13 2000/10/05 18:31:25 ericm Exp $
+ * RCS: @(#) $Id: tkDecls.h,v 1.14 2000/11/22 01:49:37 ericm Exp $
*/
#ifndef _TKDECLS
@@ -830,6 +830,10 @@ EXTERN void Tk_DeleteClientMessageHandler _ANSI_ARGS_((
EXTERN Tk_Window Tk_CreateAnonymousWindow _ANSI_ARGS_((
Tcl_Interp * interp, Tk_Window parent,
char * screenName));
+/* 242 */
+EXTERN void Tk_SetClassProcs _ANSI_ARGS_((Tk_Window tkwin,
+ Tk_ClassProcs * procs,
+ ClientData instanceData));
typedef struct TkStubHooks {
struct TkPlatStubs *tkPlatStubs;
@@ -1084,6 +1088,7 @@ typedef struct TkStubs {
void (*tk_CreateClientMessageHandler) _ANSI_ARGS_((Tk_ClientMessageProc * proc)); /* 239 */
void (*tk_DeleteClientMessageHandler) _ANSI_ARGS_((Tk_ClientMessageProc * proc)); /* 240 */
Tk_Window (*tk_CreateAnonymousWindow) _ANSI_ARGS_((Tcl_Interp * interp, Tk_Window parent, char * screenName)); /* 241 */
+ void (*tk_SetClassProcs) _ANSI_ARGS_((Tk_Window tkwin, Tk_ClassProcs * procs, ClientData instanceData)); /* 242 */
} TkStubs;
#ifdef __cplusplus
@@ -2062,6 +2067,10 @@ extern TkStubs *tkStubsPtr;
#define Tk_CreateAnonymousWindow \
(tkStubsPtr->tk_CreateAnonymousWindow) /* 241 */
#endif
+#ifndef Tk_SetClassProcs
+#define Tk_SetClassProcs \
+ (tkStubsPtr->tk_SetClassProcs) /* 242 */
+#endif
#endif /* defined(USE_TK_STUBS) && !defined(USE_TK_STUB_PROCS) */
diff --git a/generic/tkEntry.c b/generic/tkEntry.c
index f9031b9..4a01d12 100644
--- a/generic/tkEntry.c
+++ b/generic/tkEntry.c
@@ -12,7 +12,7 @@
* See the file "license.terms" for information on usage and redistribution
* of this file, and for a DISCLAIMER OF ALL WARRANTIES.
*
- * RCS: @(#) $Id: tkEntry.c,v 1.17 2000/05/29 01:43:14 hobbs Exp $
+ * RCS: @(#) $Id: tkEntry.c,v 1.18 2000/11/22 01:49:37 ericm Exp $
*/
#include "tkInt.h"
@@ -736,10 +736,9 @@ static int ComputeFormat _ANSI_ARGS_((Spinbox *sbPtr));
* that can be invoked from generic window code.
*/
-static TkClassProcs entryClass = {
- NULL, /* createProc. */
- EntryWorldChanged, /* geometryProc. */
- NULL /* modalProc. */
+static Tk_ClassProcs entryClass = {
+ sizeof(Tk_ClassProcs), /* size */
+ EntryWorldChanged, /* worldChangedProc */
};
@@ -839,7 +838,7 @@ Tk_EntryObjCmd(clientData, interp, objc, objv)
entryPtr->validate = VALIDATE_NONE;
Tk_SetClass(entryPtr->tkwin, "Entry");
- TkSetClassProcs(entryPtr->tkwin, &entryClass, (ClientData) entryPtr);
+ Tk_SetClassProcs(entryPtr->tkwin, &entryClass, (ClientData) entryPtr);
Tk_CreateEventHandler(entryPtr->tkwin,
ExposureMask|StructureNotifyMask|FocusChangeMask,
EntryEventProc, (ClientData) entryPtr);
@@ -3740,7 +3739,7 @@ Tk_SpinboxObjCmd(clientData, interp, objc, objv)
sbPtr->buRelief = TK_RELIEF_FLAT;
Tk_SetClass(entryPtr->tkwin, "Spinbox");
- TkSetClassProcs(entryPtr->tkwin, &entryClass, (ClientData) entryPtr);
+ Tk_SetClassProcs(entryPtr->tkwin, &entryClass, (ClientData) entryPtr);
Tk_CreateEventHandler(entryPtr->tkwin,
PointerMotionMask|ExposureMask|StructureNotifyMask|FocusChangeMask,
EntryEventProc, (ClientData) entryPtr);
diff --git a/generic/tkFont.c b/generic/tkFont.c