summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--generic/tkImgPhInstance.c2
-rw-r--r--generic/tkStubInit.c3
-rw-r--r--generic/ttk/ttkStubInit.c8
-rw-r--r--macosx/tkMacOSXBitmap.c2
-rw-r--r--macosx/tkMacOSXButton.c2
-rw-r--r--macosx/tkMacOSXDialog.c2
-rw-r--r--macosx/tkMacOSXDraw.c2
-rw-r--r--macosx/tkMacOSXEvent.c2
-rw-r--r--macosx/tkMacOSXImage.c7
-rw-r--r--macosx/tkMacOSXTest.c3
-rw-r--r--macosx/ttkMacOSXTheme.c7
-rw-r--r--unix/tkUnixFont.c4
-rw-r--r--unix/tkUnixInit.c6
13 files changed, 39 insertions, 11 deletions
diff --git a/generic/tkImgPhInstance.c b/generic/tkImgPhInstance.c
index ddbdb9e..81b196c 100644
--- a/generic/tkImgPhInstance.c
+++ b/generic/tkImgPhInstance.c
@@ -26,7 +26,7 @@
/*
* Declaration for internal Xlib function used here:
*/
-#if !defined(_WIN32) && !defined(__CYGWIN__) && !defined(MAC_OSX_TCL)
+#if !defined(_WIN32) && !defined(__CYGWIN__) && !defined(MAC_OSX_TK)
#ifdef __cplusplus
extern "C" {
#endif
diff --git a/generic/tkStubInit.c b/generic/tkStubInit.c
index cfd4db6..451e1c2 100644
--- a/generic/tkStubInit.c
+++ b/generic/tkStubInit.c
@@ -228,6 +228,9 @@ TkPutImage(
unsigned int width, unsigned int height)
/* Dimensions of subimage. */
{
+ (void)colors;
+ (void)ncolors;
+
return XPutImage(display, d, gc, image, src_x, src_y, dest_x, dest_y, width, height);
}
#endif /* MAC_OSX_TCL */
diff --git a/generic/ttk/ttkStubInit.c b/generic/ttk/ttkStubInit.c
index c7f1b2a..31cdaa8 100644
--- a/generic/ttk/ttkStubInit.c
+++ b/generic/ttk/ttkStubInit.c
@@ -12,6 +12,14 @@ MODULE_SCOPE const TtkStubs ttkStubs;
#define Ttk_GetOrientFromObj 0
#endif
+#ifdef __GNUC__
+/*
+ * The rest of this file shouldn't warn about deprecated functions; they're
+ * there because we intend them to be so and know that this file is OK to
+ * touch those fields.
+ */
+#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
+#endif
/* !BEGIN!: Do not edit below this line. */
const TtkStubs ttkStubs = {
diff --git a/macosx/tkMacOSXBitmap.c b/macosx/tkMacOSXBitmap.c
index 0731de3..d75a164 100644
--- a/macosx/tkMacOSXBitmap.c
+++ b/macosx/tkMacOSXBitmap.c
@@ -44,7 +44,7 @@ static BuiltInIcon builtInIcons[] = {
{"stop", kAlertStopIcon},
{"note", kAlertNoteIcon},
{"caution", kAlertCautionIcon},
- {NULL}
+ {NULL, 0}
};
#define builtInIconSize 32
diff --git a/macosx/tkMacOSXButton.c b/macosx/tkMacOSXButton.c
index ec1ccf2..865234f 100644
--- a/macosx/tkMacOSXButton.c
+++ b/macosx/tkMacOSXButton.c
@@ -95,6 +95,8 @@ static void PulseDefaultButtonProc(ClientData clientData);
const Tk_ClassProcs tkpButtonProcs = {
sizeof(Tk_ClassProcs), /* size */
TkButtonWorldChanged, /* worldChangedProc */
+ NULL,
+ NULL
};
static int bCount;
diff --git a/macosx/tkMacOSXDialog.c b/macosx/tkMacOSXDialog.c
index e6fa179..455362a 100644
--- a/macosx/tkMacOSXDialog.c
+++ b/macosx/tkMacOSXDialog.c
@@ -198,6 +198,8 @@ getFileURL(
@implementation TKApplication(TKDialog)
- (BOOL)panel:(id)sender shouldEnableURL:(NSURL *)url {
+ (void)sender;
+ (void)url;
return YES;
}
diff --git a/macosx/tkMacOSXDraw.c b/macosx/tkMacOSXDraw.c
index 724f637..82b433a 100644
--- a/macosx/tkMacOSXDraw.c
+++ b/macosx/tkMacOSXDraw.c
@@ -73,6 +73,7 @@ TkMacOSXInitCGDrawing(
int limit)
{
static Boolean initialized = FALSE;
+ (void)enable;
if (!initialized) {
initialized = TRUE;
@@ -866,6 +867,7 @@ XFillPolygon(
MacDrawable *macWin = (MacDrawable *) d;
TkMacOSXDrawingContext dc;
int i;
+ (void)shape;
display->request++;
if (!TkMacOSXSetupDrawingContext(d, gc, 1, &dc)) {
diff --git a/macosx/tkMacOSXEvent.c b/macosx/tkMacOSXEvent.c
index 1b9e077..af68eb6 100644
--- a/macosx/tkMacOSXEvent.c
+++ b/macosx/tkMacOSXEvent.c
@@ -133,6 +133,8 @@ XSync(
Display *display,
Bool discard)
{
+ (void)discard;
+
if (display) {
display->request++;
}
diff --git a/macosx/tkMacOSXImage.c b/macosx/tkMacOSXImage.c
index 0d8be32..a8c7922 100644
--- a/macosx/tkMacOSXImage.c
+++ b/macosx/tkMacOSXImage.c
@@ -21,6 +21,8 @@ int
_XInitImageFuncPtrs(
XImage *image)
{
+ (void)image;
+
return 0;
}
@@ -42,6 +44,9 @@ _XInitImageFuncPtrs(
*/
static void ReleaseData(void *info, const void *data, size_t size) {
+ (void)data;
+ (void)size;
+
ckfree(info);
}
@@ -176,6 +181,7 @@ XGetImage(
unsigned int scalefactor=1, scaled_height=height, scaled_width=width;
NSWindow *win = TkMacOSXDrawableWindow(drawable);
static enum {unknown, no, yes} has_retina = unknown;
+ (void)plane_mask;
if (win && has_retina == unknown) {
#ifdef __clang__
@@ -451,6 +457,7 @@ XCreateImage(
int bytes_per_line)
{
XImage *ximage;
+ (void)visual;
display->request++;
ximage = ckalloc(sizeof(XImage));
diff --git a/macosx/tkMacOSXTest.c b/macosx/tkMacOSXTest.c
index c353efe..59320a0 100644
--- a/macosx/tkMacOSXTest.c
+++ b/macosx/tkMacOSXTest.c
@@ -145,7 +145,7 @@ TkTestLogDisplay(void) {
/* ARGSUSED */
static int
PressButtonObjCmd(
- ClientData clientData,
+ ClientData dummy,
Tcl_Interp *interp,
int objc,
Tcl_Obj *const objv[])
@@ -157,6 +157,7 @@ PressButtonObjCmd(
NSArray *screens = [NSScreen screens];
CGFloat ScreenHeight = 0;
enum {X=1, Y};
+ (void)dummy;
if (screens && [screens count]) {
ScreenHeight = [[screens objectAtIndex:0] frame].size.height;
diff --git a/macosx/ttkMacOSXTheme.c b/macosx/ttkMacOSXTheme.c
index d609447..83f48db 100644
--- a/macosx/ttkMacOSXTheme.c
+++ b/macosx/ttkMacOSXTheme.c
@@ -169,7 +169,7 @@ static inline CGRect BoxToRect(
*/
static Ttk_StateTable ThemeStateTable[] = {
- {kThemeStateActive, TTK_STATE_ALTERNATE | TTK_STATE_BACKGROUND},
+ {kThemeStateActive, TTK_STATE_ALTERNATE | TTK_STATE_BACKGROUND, 0},
{kThemeStateUnavailable, TTK_STATE_DISABLED, 0},
{kThemeStatePressed, TTK_STATE_PRESSED, 0},
{kThemeStateInactive, TTK_STATE_BACKGROUND, 0},
@@ -257,6 +257,7 @@ static void GetBackgroundColor(
{
TkWindow *winPtr = (TkWindow *) tkwin;
TkWindow *masterPtr = (TkWindow *) TkGetGeomMaster(tkwin);
+ (void)context;
while (masterPtr && masterPtr->privatePtr) {
if (masterPtr->privatePtr->flags & TTK_HAS_CONTRASTING_BG) {
@@ -1046,6 +1047,7 @@ static void DrawDarkSeparator(
NSColor *fillColor = [NSColor colorWithColorSpace: deviceRGB
components: fill
count:4];
+ (void)tkwin;
CGContextSetFillColorWithColor(context, CGCOLOR(fillColor));
CGContextFillRect(context, bounds);
@@ -1170,6 +1172,7 @@ static void DrawDarkListHeader(
{
NSColorSpace *deviceRGB = [NSColorSpace deviceRGBColorSpace];
NSColor *stroke;
+ (void)tkwin;
CGContextSetStrokeColorSpace(context, deviceRGB.CGColorSpace);
CGFloat x = bounds.origin.x, y = bounds.origin.y;
@@ -1231,7 +1234,7 @@ static ThemeButtonParams
ListHeaderParams =
{kThemeListHeaderButton, kThemeMetricListHeaderHeight};
static Ttk_StateTable ButtonValueTable[] = {
- {kThemeButtonOff, TTK_STATE_ALTERNATE | TTK_STATE_BACKGROUND},
+ {kThemeButtonOff, TTK_STATE_ALTERNATE | TTK_STATE_BACKGROUND, 0},
{kThemeButtonMixed, TTK_STATE_ALTERNATE, 0},
{kThemeButtonOn, TTK_STATE_SELECTED, 0},
{kThemeButtonOff, 0, 0}
diff --git a/unix/tkUnixFont.c b/unix/tkUnixFont.c
index 800d1e5..c1e9264 100644
--- a/unix/tkUnixFont.c
+++ b/unix/tkUnixFont.c
@@ -848,7 +848,7 @@ TkpGetFontFamilies(
Tk_Window tkwin) /* For display to query. */
{
int i, isNew, numNames;
- const char *family, **nameList;
+ char *family, **nameList;
Tcl_HashTable familyTable;
Tcl_HashEntry *hPtr;
Tcl_HashSearch search;
@@ -857,7 +857,7 @@ TkpGetFontFamilies(
Tcl_InitHashTable(&familyTable, TCL_STRING_KEYS);
nameList = ListFonts(Tk_Display(tkwin), "*", &numNames);
for (i = 0; i < numNames; i++) {
- const char *familyEnd;
+ char *familyEnd;
family = strchr(nameList[i] + 1, '-');
if (family == NULL) {
diff --git a/unix/tkUnixInit.c b/unix/tkUnixInit.c
index 6fa7970..0965c01 100644
--- a/unix/tkUnixInit.c
+++ b/unix/tkUnixInit.c
@@ -14,7 +14,7 @@
#ifdef HAVE_COREFOUNDATION
static int GetLibraryPath(Tcl_Interp *interp);
#else
-#define GetLibraryPath(dummy) (void)0
+#define GetLibraryPath(dummy) (void)dummy
#endif /* HAVE_COREFOUNDATION */
/*
@@ -37,10 +37,8 @@ static int GetLibraryPath(Tcl_Interp *interp);
int
TkpInit(
- Tcl_Interp *dummy)
+ Tcl_Interp *interp)
{
- (void)dummy;
-
TkCreateXEventSource();
GetLibraryPath(interp);
return TCL_OK;