summaryrefslogtreecommitdiffstats
path: root/generic/tkGC.c
diff options
context:
space:
mode:
authorjan.nijtmans <nijtmans@users.sourceforge.net>2019-12-20 10:41:43 (GMT)
committerjan.nijtmans <nijtmans@users.sourceforge.net>2019-12-20 10:41:43 (GMT)
commit2f89fa96c29e874b87523d628df15c62984dd9b7 (patch)
tree512c62f76a0e9be490f422d8aa6f866cd1c0c5c3 /generic/tkGC.c
parent22f8312f1177e98133c31e059d6f1ae948178f37 (diff)
downloadtk-2f89fa96c29e874b87523d628df15c62984dd9b7.zip
tk-2f89fa96c29e874b87523d628df15c62984dd9b7.tar.gz
tk-2f89fa96c29e874b87523d628df15c62984dd9b7.tar.bz2
Much more WIP: Appears to be working on UNIX, and for a bit part on Windows too.
Diffstat (limited to 'generic/tkGC.c')
-rw-r--r--generic/tkGC.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/generic/tkGC.c b/generic/tkGC.c
index 4caa046..47931a6 100644
--- a/generic/tkGC.c
+++ b/generic/tkGC.c
@@ -66,17 +66,17 @@ static void GCInit(TkDisplay *dispPtr);
GC
Tk_GetGC(
Tk_Window tkwin, /* Window in which GC will be used. */
- register unsigned long valueMask,
+ unsigned long valueMask,
/* 1 bits correspond to values specified in
* *valuesPtr; other values are set from
* defaults. */
- register XGCValues *valuePtr)
+ XGCValues *valuePtr)
/* Values are specified here for bits set in
* valueMask. */
{
ValueKey valueKey;
Tcl_HashEntry *valueHashPtr, *idHashPtr;
- register TkGC *gcPtr;
+ TkGC *gcPtr;
int isNew;
Drawable d, freeDrawable;
TkDisplay *dispPtr = ((TkWindow *) tkwin)->dispPtr;
@@ -218,7 +218,7 @@ Tk_GetGC(
valueHashPtr = Tcl_CreateHashEntry(&dispPtr->gcValueTable,
(char *) &valueKey, &isNew);
if (!isNew) {
- gcPtr = Tcl_GetHashValue(valueHashPtr);
+ gcPtr = (TkGC *)Tcl_GetHashValue(valueHashPtr);
gcPtr->refCount++;
return gcPtr->gc;
}
@@ -228,7 +228,7 @@ Tk_GetGC(
* and add a new structure to the database.
*/
- gcPtr = ckalloc(sizeof(TkGC));
+ gcPtr = (TkGC *)ckalloc(sizeof(TkGC));
/*
* Find or make a drawable to use to specify the screen and depth of the
@@ -291,7 +291,7 @@ Tk_FreeGC(
GC gc) /* Graphics context to be released. */
{
Tcl_HashEntry *idHashPtr;
- register TkGC *gcPtr;
+ TkGC *gcPtr;
TkDisplay *dispPtr = TkGetDisplay(display);
if (!dispPtr->gcInit) {
@@ -311,7 +311,7 @@ Tk_FreeGC(
if (idHashPtr == NULL) {
Tcl_Panic("Tk_FreeGC received unknown gc argument");
}
- gcPtr = Tcl_GetHashValue(idHashPtr);
+ gcPtr = (TkGC *)Tcl_GetHashValue(idHashPtr);
if (gcPtr->refCount-- <= 1) {
XFreeGC(gcPtr->display, gcPtr->gc);
Tcl_DeleteHashEntry(gcPtr->valueHashPtr);
@@ -347,7 +347,7 @@ TkGCCleanup(
for (entryPtr = Tcl_FirstHashEntry(&dispPtr->gcIdTable, &search);
entryPtr != NULL; entryPtr = Tcl_NextHashEntry(&search)) {
- gcPtr = Tcl_GetHashValue(entryPtr);
+ gcPtr = (TkGC *)Tcl_GetHashValue(entryPtr);
XFreeGC(gcPtr->display, gcPtr->gc);
Tcl_DeleteHashEntry(gcPtr->valueHashPtr);