diff options
author | jan.nijtmans <nijtmans@users.sourceforge.net> | 2024-06-10 20:46:00 (GMT) |
---|---|---|
committer | jan.nijtmans <nijtmans@users.sourceforge.net> | 2024-06-10 20:46:00 (GMT) |
commit | 0b10d3c445a80c34b182268ddd4886a69d8a9047 (patch) | |
tree | 37d0a5eecd479c27507bcac3f7367c99137456a5 | |
parent | 171e4042f5d12fffb74e16d70c99d46f72196541 (diff) | |
download | tk-0b10d3c445a80c34b182268ddd4886a69d8a9047.zip tk-0b10d3c445a80c34b182268ddd4886a69d8a9047.tar.gz tk-0b10d3c445a80c34b182268ddd4886a69d8a9047.tar.bz2 |
Fix indenting
-rw-r--r-- | generic/tkButton.c | 20 | ||||
-rw-r--r-- | macosx/tkMacOSXButton.c | 2 | ||||
-rw-r--r-- | win/tkWinButton.c | 16 |
3 files changed, 19 insertions, 19 deletions
diff --git a/generic/tkButton.c b/generic/tkButton.c index 2ec939e..68af116 100644 --- a/generic/tkButton.c +++ b/generic/tkButton.c @@ -783,7 +783,7 @@ ButtonWidgetObjCmd( Tcl_Obj *objPtr; if (objc < 2) { - Tcl_WrongNumArgs(interp, 1, objv, "option ?arg ...?"); + Tcl_WrongNumArgs(interp, 1, objv, "option ?arg ...?"); return TCL_ERROR; } result = Tcl_GetIndexFromObjStruct(interp, objv[1], commandNames[butPtr->type], @@ -1149,13 +1149,13 @@ ConfigureButton( valuePtr = Tcl_ObjGetVar2(interp, namePtr, NULL, TCL_GLOBAL_ONLY); butPtr->flags &= ~SELECTED; - butPtr->flags &= ~TRISTATED; + butPtr->flags &= ~TRISTATED; if (valuePtr != NULL) { const char *value = Tcl_GetString(valuePtr); if (strcmp(value, Tcl_GetString(butPtr->onValuePtr)) == 0) { butPtr->flags |= SELECTED; } else if (strcmp(value, - Tcl_GetString(butPtr->tristateValuePtr)) == 0) { + Tcl_GetString(butPtr->tristateValuePtr)) == 0) { butPtr->flags |= TRISTATED; /* @@ -1168,7 +1168,7 @@ ConfigureButton( Tcl_GetString(butPtr->offValuePtr)) == 0) { butPtr->flags &= ~TRISTATED; } - } + } } else { if (Tcl_ObjSetVar2(interp, namePtr, NULL, (butPtr->type == TYPE_CHECK_BUTTON) @@ -1678,7 +1678,7 @@ ButtonVarProc( return NULL; } butPtr->flags |= SELECTED; - butPtr->flags &= ~TRISTATED; + butPtr->flags &= ~TRISTATED; } else if (butPtr->offValuePtr && strcmp(value, Tcl_GetString(butPtr->offValuePtr)) == 0) { if (!(butPtr->flags & (SELECTED | TRISTATED))) { @@ -1686,11 +1686,11 @@ ButtonVarProc( } butPtr->flags &= ~(SELECTED | TRISTATED); } else if (strcmp(value, Tcl_GetString(butPtr->tristateValuePtr)) == 0) { - if (butPtr->flags & TRISTATED) { - return NULL; - } - butPtr->flags |= TRISTATED; - butPtr->flags &= ~SELECTED; + if (butPtr->flags & TRISTATED) { + return NULL; + } + butPtr->flags |= TRISTATED; + butPtr->flags &= ~SELECTED; } else if (butPtr->flags & (SELECTED | TRISTATED)) { butPtr->flags &= ~(SELECTED | TRISTATED); } else { diff --git a/macosx/tkMacOSXButton.c b/macosx/tkMacOSXButton.c index 7d231a6..c825920 100644 --- a/macosx/tkMacOSXButton.c +++ b/macosx/tkMacOSXButton.c @@ -194,7 +194,7 @@ TkpDisplayButton( } pixmap = (Pixmap) Tk_WindowId(tkwin); - Tk_GetPixelsFromObj(NULL, tkwin, butPtr->highlightWidthPtr, &butPtr->highlightWidth); + Tk_GetPixelsFromObj(NULL, tkwin, butPtr->highlightWidthPtr, &butPtr->highlightWidth); if (TkMacOSXComputeButtonDrawParams(butPtr, dpPtr)) { macButtonPtr->useTkText = 0; diff --git a/win/tkWinButton.c b/win/tkWinButton.c index 88b98c6..e0998b5 100644 --- a/win/tkWinButton.c +++ b/win/tkWinButton.c @@ -628,7 +628,7 @@ TkpDisplayButton( if (butPtr->type == TYPE_LABEL) { defaultWidth = butPtr->highlightWidth; - offset = 0; + offset = 0; } else if (butPtr->type == TYPE_BUTTON) { defaultWidth = ((butPtr->defaultState == DEFAULT_ACTIVE) ? butPtr->highlightWidth : 0); @@ -934,14 +934,14 @@ TkpDisplayButton( butPtr->borderWidth, relief); } if (defaultWidth != 0) { - int highlightColor; + int highlightColor; dc = TkWinGetDrawableDC(butPtr->display, pixmap, &state); - if (butPtr->type == TYPE_LABEL) { - highlightColor = (int) Tk_3DBorderColor(butPtr->highlightBorder)->pixel; - } else { - highlightColor = (int) butPtr->highlightColorPtr->pixel; - } + if (butPtr->type == TYPE_LABEL) { + highlightColor = (int) Tk_3DBorderColor(butPtr->highlightBorder)->pixel; + } else { + highlightColor = (int) butPtr->highlightColorPtr->pixel; + } TkWinFillRect(dc, 0, 0, Tk_Width(tkwin), defaultWidth, highlightColor); TkWinFillRect(dc, 0, 0, defaultWidth, Tk_Height(tkwin), @@ -1457,7 +1457,7 @@ ButtonProc( * causes all buttons to fire once a second, so we need to make sure * that we are not dealing with the chromium life check. */ - if (wParam != 0 || lParam != 0) { + if (wParam != 0 || lParam != 0) { int code; Tcl_Interp *interp = butPtr->info.interp; |