summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--generic/tkDecls.h8
-rw-r--r--generic/tkIntDecls.h8
-rw-r--r--generic/tkIntPlatDecls.h8
-rw-r--r--generic/tkIntXlibDecls.h8
-rw-r--r--generic/tkPlatDecls.h8
-rw-r--r--generic/ttk/ttkDecls.h8
-rw-r--r--generic/ttk/ttkGenStubs.tcl8
7 files changed, 35 insertions, 21 deletions
diff --git a/generic/tkDecls.h b/generic/tkDecls.h
index 9f76a49..64c32cd 100644
--- a/generic/tkDecls.h
+++ b/generic/tkDecls.h
@@ -25,6 +25,10 @@
/* !BEGIN!: Do not edit below this line. */
+#ifdef __cplusplus
+extern "C" {
+#endif
+
/*
* Exported function declarations:
*/
@@ -1148,10 +1152,8 @@ typedef struct TkStubs {
void (*tk_CreateOldPhotoImageFormat) (const Tk_PhotoImageFormat *formatPtr); /* 273 */
} TkStubs;
-#ifdef __cplusplus
-extern "C" {
-#endif
extern const TkStubs *tkStubsPtr;
+
#ifdef __cplusplus
}
#endif
diff --git a/generic/tkIntDecls.h b/generic/tkIntDecls.h
index 586419c..3c37922 100644
--- a/generic/tkIntDecls.h
+++ b/generic/tkIntDecls.h
@@ -35,6 +35,10 @@ struct TkSharedText;
/* !BEGIN!: Do not edit below this line. */
+#ifdef __cplusplus
+extern "C" {
+#endif
+
/*
* Exported function declarations:
*/
@@ -765,10 +769,8 @@ typedef struct TkIntStubs {
void (*tkDrawAngledChars) (Display *display, Drawable drawable, GC gc, Tk_Font tkfont, const char *source, int numBytes, double x, double y, double angle); /* 184 */
} TkIntStubs;
-#ifdef __cplusplus
-extern "C" {
-#endif
extern const TkIntStubs *tkIntStubsPtr;
+
#ifdef __cplusplus
}
#endif
diff --git a/generic/tkIntPlatDecls.h b/generic/tkIntPlatDecls.h
index d6d136e..141f743 100644
--- a/generic/tkIntPlatDecls.h
+++ b/generic/tkIntPlatDecls.h
@@ -26,6 +26,10 @@
/* !BEGIN!: Do not edit below this line. */
+#ifdef __cplusplus
+extern "C" {
+#endif
+
/*
* Exported function declarations:
*/
@@ -410,10 +414,8 @@ typedef struct TkIntPlatStubs {
#endif /* X11 */
} TkIntPlatStubs;
-#ifdef __cplusplus
-extern "C" {
-#endif
extern const TkIntPlatStubs *tkIntPlatStubsPtr;
+
#ifdef __cplusplus
}
#endif
diff --git a/generic/tkIntXlibDecls.h b/generic/tkIntXlibDecls.h
index 70c63d5..8abda05 100644
--- a/generic/tkIntXlibDecls.h
+++ b/generic/tkIntXlibDecls.h
@@ -36,6 +36,10 @@ typedef int (*XAfterFunction) ( /* WARNING, this type not in Xlib spec */
/* !BEGIN!: Do not edit below this line. */
+#ifdef __cplusplus
+extern "C" {
+#endif
+
/*
* Exported function declarations:
*/
@@ -835,10 +839,8 @@ typedef struct TkIntXlibStubs {
#endif /* AQUA */
} TkIntXlibStubs;
-#ifdef __cplusplus
-extern "C" {
-#endif
extern const TkIntXlibStubs *tkIntXlibStubsPtr;
+
#ifdef __cplusplus
}
#endif
diff --git a/generic/tkPlatDecls.h b/generic/tkPlatDecls.h
index e59c014..88fa918 100644
--- a/generic/tkPlatDecls.h
+++ b/generic/tkPlatDecls.h
@@ -29,6 +29,10 @@ extern "C" {
/* !BEGIN!: Do not edit below this line. */
+#ifdef __cplusplus
+extern "C" {
+#endif
+
/*
* Exported function declarations:
*/
@@ -107,10 +111,8 @@ typedef struct TkPlatStubs {
#endif /* AQUA */
} TkPlatStubs;
-#ifdef __cplusplus
-extern "C" {
-#endif
extern const TkPlatStubs *tkPlatStubsPtr;
+
#ifdef __cplusplus
}
#endif
diff --git a/generic/ttk/ttkDecls.h b/generic/ttk/ttkDecls.h
index 5f7cb0c..6701724 100644
--- a/generic/ttk/ttkDecls.h
+++ b/generic/ttk/ttkDecls.h
@@ -23,6 +23,10 @@ extern const char *TtkInitializeStubs(
#define TTK_STUBS_EPOCH 0
#define TTK_STUBS_REVISION 31
+#ifdef __cplusplus
+extern "C" {
+#endif
+
/*
* Exported function declarations:
*/
@@ -178,10 +182,8 @@ typedef struct TtkStubs {
int (*ttk_GetOrientFromObj) (Tcl_Interp *interp, Tcl_Obj *objPtr, int *orient); /* 40 */
} TtkStubs;
-#ifdef __cplusplus
-extern "C" {
-#endif
extern const TtkStubs *ttkStubsPtr;
+
#ifdef __cplusplus
}
#endif
diff --git a/generic/ttk/ttkGenStubs.tcl b/generic/ttk/ttkGenStubs.tcl
index d8e9a8a..5e56951 100644
--- a/generic/ttk/ttkGenStubs.tcl
+++ b/generic/ttk/ttkGenStubs.tcl
@@ -769,6 +769,8 @@ proc genStubs::emitHeader {name} {
append text "#define ${CAPName}_STUBS_REVISION $revision\n"
}
+ append text "\n#ifdef __cplusplus\nextern \"C\" {\n#endif\n"
+
emitDeclarations $name text
if {[info exists hooks($name)]} {
@@ -796,8 +798,7 @@ proc genStubs::emitHeader {name} {
append text "} ${capName}Stubs;\n\n"
- append text "#ifdef __cplusplus\nextern \"C\" {\n#endif\n"
- append text "extern const ${capName}Stubs *${name}StubsPtr;\n"
+ append text "extern const ${capName}Stubs *${name}StubsPtr;\n\n"
append text "#ifdef __cplusplus\n}\n#endif\n"
emitMacros $name text
@@ -821,9 +822,10 @@ proc genStubs::emitInit {name textVar} {
variable hooks
variable interfaces
variable epoch
+ variable revision
upvar $textVar text
- set root 1
+ set root 1
set capName [string toupper [string index $name 0]]
append capName [string range $name 1 end]