summaryrefslogtreecommitdiffstats
path: root/generic/tkGet.c
diff options
context:
space:
mode:
Diffstat (limited to 'generic/tkGet.c')
-rw-r--r--generic/tkGet.c34
1 files changed, 17 insertions, 17 deletions
diff --git a/generic/tkGet.c b/generic/tkGet.c
index 9fc0d50..bd63971 100644
--- a/generic/tkGet.c
+++ b/generic/tkGet.c
@@ -35,10 +35,10 @@ static void FreeUidThreadExitProc(ClientData clientData);
* used by Tk_GetAnchorFromObj and Tk_GetJustifyFromObj.
*/
-static CONST char *anchorStrings[] = {
+static const char *const anchorStrings[] = {
"n", "ne", "e", "se", "s", "sw", "w", "nw", "center", NULL
};
-static CONST char *justifyStrings[] = {
+static const char *const justifyStrings[] = {
"left", "right", "center", NULL
};
@@ -101,7 +101,7 @@ Tk_GetAnchorFromObj(
int
Tk_GetAnchor(
Tcl_Interp *interp, /* Use this for error reporting. */
- CONST char *string, /* String describing a direction. */
+ const char *string, /* String describing a direction. */
Tk_Anchor *anchorPtr) /* Where to store Tk_Anchor corresponding to
* string. */
{
@@ -173,7 +173,7 @@ Tk_GetAnchor(
*--------------------------------------------------------------
*/
-CONST char *
+const char *
Tk_NameOfAnchor(
Tk_Anchor anchor) /* Anchor for which identifying string is
* desired. */
@@ -214,7 +214,7 @@ Tk_NameOfAnchor(
int
Tk_GetJoinStyle(
Tcl_Interp *interp, /* Use this for error reporting. */
- CONST char *string, /* String describing a justification style. */
+ const char *string, /* String describing a justification style. */
int *joinPtr) /* Where to store join style corresponding to
* string. */
{
@@ -258,7 +258,7 @@ Tk_GetJoinStyle(
*--------------------------------------------------------------
*/
-CONST char *
+const char *
Tk_NameOfJoinStyle(
int join) /* Join style for which identifying string is
* desired. */
@@ -293,7 +293,7 @@ Tk_NameOfJoinStyle(
int
Tk_GetCapStyle(
Tcl_Interp *interp, /* Use this for error reporting. */
- CONST char *string, /* String describing a justification style. */
+ const char *string, /* String describing a justification style. */
int *capPtr) /* Where to store cap style corresponding to
* string. */
{
@@ -337,7 +337,7 @@ Tk_GetCapStyle(
*--------------------------------------------------------------
*/
-CONST char *
+const char *
Tk_NameOfCapStyle(
int cap) /* Cap style for which identifying string is
* desired. */
@@ -409,7 +409,7 @@ Tk_GetJustifyFromObj(
int
Tk_GetJustify(
Tcl_Interp *interp, /* Use this for error reporting. */
- CONST char *string, /* String describing a justification style. */
+ const char *string, /* String describing a justification style. */
Tk_Justify *justifyPtr) /* Where to store Tk_Justify corresponding to
* string. */
{
@@ -454,7 +454,7 @@ Tk_GetJustify(
*--------------------------------------------------------------
*/
-CONST char *
+const char *
Tk_NameOfJustify(
Tk_Justify justify) /* Justification style for which identifying
* string is desired. */
@@ -487,8 +487,9 @@ static void
FreeUidThreadExitProc(
ClientData clientData) /* Not used. */
{
- ThreadSpecificData *tsdPtr = (ThreadSpecificData *)
+ ThreadSpecificData *tsdPtr =
Tcl_GetThreadData(&dataKey, sizeof(ThreadSpecificData));
+
Tcl_DeleteHashTable(&tsdPtr->uidTable);
tsdPtr->initialized = 0;
}
@@ -517,10 +518,10 @@ FreeUidThreadExitProc(
Tk_Uid
Tk_GetUid(
- CONST char *string) /* String to convert. */
+ const char *string) /* String to convert. */
{
int dummy;
- ThreadSpecificData *tsdPtr = (ThreadSpecificData *)
+ ThreadSpecificData *tsdPtr =
Tcl_GetThreadData(&dataKey, sizeof(ThreadSpecificData));
Tcl_HashTable *tablePtr = &tsdPtr->uidTable;
@@ -559,7 +560,7 @@ Tk_GetScreenMM(
Tk_Window tkwin, /* Window whose screen determines conversion
* from centimeters and other absolute
* units. */
- CONST char *string, /* String describing a screen distance. */
+ const char *string, /* String describing a screen distance. */
double *doublePtr) /* Place to store converted result. */
{
char *end;
@@ -633,7 +634,7 @@ Tk_GetPixels(
Tk_Window tkwin, /* Window whose screen determines conversion
* from centimeters and other absolute
* units. */
- CONST char *string, /* String describing a number of pixels. */
+ const char *string, /* String describing a number of pixels. */
int *intPtr) /* Place to store converted result. */
{
double d;
@@ -658,7 +659,6 @@ Tk_GetPixels(
* string.
*
* Results:
-
* The return value is a standard Tcl return result. If TCL_OK is
* returned, then everything went well and the pixel distance is stored
* at *doublePtr; otherwise TCL_ERROR is returned and an error message is
@@ -676,7 +676,7 @@ TkGetDoublePixels(
Tk_Window tkwin, /* Window whose screen determines conversion
* from centimeters and other absolute
* units. */
- CONST char *string, /* String describing a number of pixels. */
+ const char *string, /* String describing a number of pixels. */
double *doublePtr) /* Place to store converted result. */
{
char *end;