Commit 70b3b3e6 authored by Owen Taylor's avatar Owen Taylor Committed by Owen Taylor

Try to guess if we can use the mb* functions safely. (For glibc, they do

Tue Mar 17 01:55:00 1998  Owen Taylor  <owt1@cornell.edu>

	* gtk/gtkmain.c gtk/gtkentry.c: Try to guess if we can
	  use the mb* functions safely. (For glibc, they do
	  UTF-8). Heuristic is (X_LOCALE && locale != C/POSIX)
	  || (mblen("\xc0", MB_CUR_MAX) == 1).

	(From: "Richard Lloyd" <rkl@csc.liv.ac.uk>)

	* gdk/gdk.c (gdk_ic_get_attr): Use an intermediate
	  variable to avoid taking the address of the result
	  of va_arg.

	* gtk/gtkentry.c gtk/gtkeditable.c gtkobject.c
	  gtk/testselection.c: signedness fixups

	* gtk/gtkcontainer.c: Fixed implicit cast between
	  gpointer and func pointer by changing.

	* gtk/gtkcombo.c, gtk/gtkentry.c, gtk/gtktext.c:
	  static void forward declaration vs. void actual fixed

	* gtk/testgtk.c: Limit total number of tree items to 10,000
parent a783d668
Tue Mar 17 01:55:00 1998 Owen Taylor <owt1@cornell.edu>
* gtk/gtkmain.c gtk/gtkentry.c: Try to guess if we can
use the mb* functions safely. (For glibc, they do
UTF-8). Heuristic is (X_LOCALE && locale != C/POSIX)
|| (mblen("\xc0", MB_CUR_MAX) == 1).
(From: "Richard Lloyd" <rkl@csc.liv.ac.uk>)
* gdk/gdk.c (gdk_ic_get_attr): Use an intermediate
variable to avoid taking the address of the result
of va_arg.
* gtk/gtkentry.c gtk/gtkeditable.c gtkobject.c
gtk/testselection.c: signedness fixups
* gtk/gtkcontainer.c: Fixed implicit cast between
gpointer and func pointer by changing.
* gtk/gtkcombo.c, gtk/gtkentry.c, gtk/gtktext.c:
static void forward declaration vs. void actual fixed
* gtk/testgtk.c: Limit total number of tree items to 10,000
Mon Mar 16 21:14:52 1998 Owen Taylor <owt1@cornell.edu>
* gdk/gdkvisual.c: Put visual names into #ifdef G_ENABLE_DEBUG
gtk-jbuhler-980315-0.patch
* gdk/gdkcc.c: Changed DEBUG => G_ENABLE_DEBUG, eliminate
unused variable warnings.
Tue Mar 17 16:19:47 1998 Tim Janik <timj@gimp.org>
* gdk/gdk.c:
......@@ -52,7 +84,6 @@ Mon Mar 16 18:19:31 GMT 1998 Tony Gale <gale@gimp.org>
- new question on updating progressbars
- update all the links to gtk.org
>>>>>>> 1.255
Mon Mar 16 09:15:03 GMT 1998 Tony Gale <gale@gimp.org>
* docs/gtk_tut.sgml:
......
Tue Mar 17 01:55:00 1998 Owen Taylor <owt1@cornell.edu>
* gtk/gtkmain.c gtk/gtkentry.c: Try to guess if we can
use the mb* functions safely. (For glibc, they do
UTF-8). Heuristic is (X_LOCALE && locale != C/POSIX)
|| (mblen("\xc0", MB_CUR_MAX) == 1).
(From: "Richard Lloyd" <rkl@csc.liv.ac.uk>)
* gdk/gdk.c (gdk_ic_get_attr): Use an intermediate
variable to avoid taking the address of the result
of va_arg.
* gtk/gtkentry.c gtk/gtkeditable.c gtkobject.c
gtk/testselection.c: signedness fixups
* gtk/gtkcontainer.c: Fixed implicit cast between
gpointer and func pointer by changing.
* gtk/gtkcombo.c, gtk/gtkentry.c, gtk/gtktext.c:
static void forward declaration vs. void actual fixed
* gtk/testgtk.c: Limit total number of tree items to 10,000
Mon Mar 16 21:14:52 1998 Owen Taylor <owt1@cornell.edu>
* gdk/gdkvisual.c: Put visual names into #ifdef G_ENABLE_DEBUG
gtk-jbuhler-980315-0.patch
* gdk/gdkcc.c: Changed DEBUG => G_ENABLE_DEBUG, eliminate
unused variable warnings.
Tue Mar 17 16:19:47 1998 Tim Janik <timj@gimp.org>
* gdk/gdk.c:
......@@ -52,7 +84,6 @@ Mon Mar 16 18:19:31 GMT 1998 Tony Gale <gale@gimp.org>
- new question on updating progressbars
- update all the links to gtk.org
>>>>>>> 1.255
Mon Mar 16 09:15:03 GMT 1998 Tony Gale <gale@gimp.org>
* docs/gtk_tut.sgml:
......
Tue Mar 17 01:55:00 1998 Owen Taylor <owt1@cornell.edu>
* gtk/gtkmain.c gtk/gtkentry.c: Try to guess if we can
use the mb* functions safely. (For glibc, they do
UTF-8). Heuristic is (X_LOCALE && locale != C/POSIX)
|| (mblen("\xc0", MB_CUR_MAX) == 1).
(From: "Richard Lloyd" <rkl@csc.liv.ac.uk>)
* gdk/gdk.c (gdk_ic_get_attr): Use an intermediate
variable to avoid taking the address of the result
of va_arg.
* gtk/gtkentry.c gtk/gtkeditable.c gtkobject.c
gtk/testselection.c: signedness fixups
* gtk/gtkcontainer.c: Fixed implicit cast between
gpointer and func pointer by changing.
* gtk/gtkcombo.c, gtk/gtkentry.c, gtk/gtktext.c:
static void forward declaration vs. void actual fixed
* gtk/testgtk.c: Limit total number of tree items to 10,000
Mon Mar 16 21:14:52 1998 Owen Taylor <owt1@cornell.edu>
* gdk/gdkvisual.c: Put visual names into #ifdef G_ENABLE_DEBUG
gtk-jbuhler-980315-0.patch
* gdk/gdkcc.c: Changed DEBUG => G_ENABLE_DEBUG, eliminate
unused variable warnings.
Tue Mar 17 16:19:47 1998 Tim Janik <timj@gimp.org>
* gdk/gdk.c:
......@@ -52,7 +84,6 @@ Mon Mar 16 18:19:31 GMT 1998 Tony Gale <gale@gimp.org>
- new question on updating progressbars
- update all the links to gtk.org
>>>>>>> 1.255
Mon Mar 16 09:15:03 GMT 1998 Tony Gale <gale@gimp.org>
* docs/gtk_tut.sgml:
......
Tue Mar 17 01:55:00 1998 Owen Taylor <owt1@cornell.edu>
* gtk/gtkmain.c gtk/gtkentry.c: Try to guess if we can
use the mb* functions safely. (For glibc, they do
UTF-8). Heuristic is (X_LOCALE && locale != C/POSIX)
|| (mblen("\xc0", MB_CUR_MAX) == 1).
(From: "Richard Lloyd" <rkl@csc.liv.ac.uk>)
* gdk/gdk.c (gdk_ic_get_attr): Use an intermediate
variable to avoid taking the address of the result
of va_arg.
* gtk/gtkentry.c gtk/gtkeditable.c gtkobject.c
gtk/testselection.c: signedness fixups
* gtk/gtkcontainer.c: Fixed implicit cast between
gpointer and func pointer by changing.
* gtk/gtkcombo.c, gtk/gtkentry.c, gtk/gtktext.c:
static void forward declaration vs. void actual fixed
* gtk/testgtk.c: Limit total number of tree items to 10,000
Mon Mar 16 21:14:52 1998 Owen Taylor <owt1@cornell.edu>
* gdk/gdkvisual.c: Put visual names into #ifdef G_ENABLE_DEBUG
gtk-jbuhler-980315-0.patch
* gdk/gdkcc.c: Changed DEBUG => G_ENABLE_DEBUG, eliminate
unused variable warnings.
Tue Mar 17 16:19:47 1998 Tim Janik <timj@gimp.org>
* gdk/gdk.c:
......@@ -52,7 +84,6 @@ Mon Mar 16 18:19:31 GMT 1998 Tony Gale <gale@gimp.org>
- new question on updating progressbars
- update all the links to gtk.org
>>>>>>> 1.255
Mon Mar 16 09:15:03 GMT 1998 Tony Gale <gale@gimp.org>
* docs/gtk_tut.sgml:
......
Tue Mar 17 01:55:00 1998 Owen Taylor <owt1@cornell.edu>
* gtk/gtkmain.c gtk/gtkentry.c: Try to guess if we can
use the mb* functions safely. (For glibc, they do
UTF-8). Heuristic is (X_LOCALE && locale != C/POSIX)
|| (mblen("\xc0", MB_CUR_MAX) == 1).
(From: "Richard Lloyd" <rkl@csc.liv.ac.uk>)
* gdk/gdk.c (gdk_ic_get_attr): Use an intermediate
variable to avoid taking the address of the result
of va_arg.
* gtk/gtkentry.c gtk/gtkeditable.c gtkobject.c
gtk/testselection.c: signedness fixups
* gtk/gtkcontainer.c: Fixed implicit cast between
gpointer and func pointer by changing.
* gtk/gtkcombo.c, gtk/gtkentry.c, gtk/gtktext.c:
static void forward declaration vs. void actual fixed
* gtk/testgtk.c: Limit total number of tree items to 10,000
Mon Mar 16 21:14:52 1998 Owen Taylor <owt1@cornell.edu>
* gdk/gdkvisual.c: Put visual names into #ifdef G_ENABLE_DEBUG
gtk-jbuhler-980315-0.patch
* gdk/gdkcc.c: Changed DEBUG => G_ENABLE_DEBUG, eliminate
unused variable warnings.
Tue Mar 17 16:19:47 1998 Tim Janik <timj@gimp.org>
* gdk/gdk.c:
......@@ -52,7 +84,6 @@ Mon Mar 16 18:19:31 GMT 1998 Tony Gale <gale@gimp.org>
- new question on updating progressbars
- update all the links to gtk.org
>>>>>>> 1.255
Mon Mar 16 09:15:03 GMT 1998 Tony Gale <gale@gimp.org>
* docs/gtk_tut.sgml:
......
Tue Mar 17 01:55:00 1998 Owen Taylor <owt1@cornell.edu>
* gtk/gtkmain.c gtk/gtkentry.c: Try to guess if we can
use the mb* functions safely. (For glibc, they do
UTF-8). Heuristic is (X_LOCALE && locale != C/POSIX)
|| (mblen("\xc0", MB_CUR_MAX) == 1).
(From: "Richard Lloyd" <rkl@csc.liv.ac.uk>)
* gdk/gdk.c (gdk_ic_get_attr): Use an intermediate
variable to avoid taking the address of the result
of va_arg.
* gtk/gtkentry.c gtk/gtkeditable.c gtkobject.c
gtk/testselection.c: signedness fixups
* gtk/gtkcontainer.c: Fixed implicit cast between
gpointer and func pointer by changing.
* gtk/gtkcombo.c, gtk/gtkentry.c, gtk/gtktext.c:
static void forward declaration vs. void actual fixed
* gtk/testgtk.c: Limit total number of tree items to 10,000
Mon Mar 16 21:14:52 1998 Owen Taylor <owt1@cornell.edu>
* gdk/gdkvisual.c: Put visual names into #ifdef G_ENABLE_DEBUG
gtk-jbuhler-980315-0.patch
* gdk/gdkcc.c: Changed DEBUG => G_ENABLE_DEBUG, eliminate
unused variable warnings.
Tue Mar 17 16:19:47 1998 Tim Janik <timj@gimp.org>
* gdk/gdk.c:
......@@ -52,7 +84,6 @@ Mon Mar 16 18:19:31 GMT 1998 Tony Gale <gale@gimp.org>
- new question on updating progressbars
- update all the links to gtk.org
>>>>>>> 1.255
Mon Mar 16 09:15:03 GMT 1998 Tony Gale <gale@gimp.org>
* docs/gtk_tut.sgml:
......
Tue Mar 17 01:55:00 1998 Owen Taylor <owt1@cornell.edu>
* gtk/gtkmain.c gtk/gtkentry.c: Try to guess if we can
use the mb* functions safely. (For glibc, they do
UTF-8). Heuristic is (X_LOCALE && locale != C/POSIX)
|| (mblen("\xc0", MB_CUR_MAX) == 1).
(From: "Richard Lloyd" <rkl@csc.liv.ac.uk>)
* gdk/gdk.c (gdk_ic_get_attr): Use an intermediate
variable to avoid taking the address of the result
of va_arg.
* gtk/gtkentry.c gtk/gtkeditable.c gtkobject.c
gtk/testselection.c: signedness fixups
* gtk/gtkcontainer.c: Fixed implicit cast between
gpointer and func pointer by changing.
* gtk/gtkcombo.c, gtk/gtkentry.c, gtk/gtktext.c:
static void forward declaration vs. void actual fixed
* gtk/testgtk.c: Limit total number of tree items to 10,000
Mon Mar 16 21:14:52 1998 Owen Taylor <owt1@cornell.edu>
* gdk/gdkvisual.c: Put visual names into #ifdef G_ENABLE_DEBUG
gtk-jbuhler-980315-0.patch
* gdk/gdkcc.c: Changed DEBUG => G_ENABLE_DEBUG, eliminate
unused variable warnings.
Tue Mar 17 16:19:47 1998 Tim Janik <timj@gimp.org>
* gdk/gdk.c:
......@@ -52,7 +84,6 @@ Mon Mar 16 18:19:31 GMT 1998 Tony Gale <gale@gimp.org>
- new question on updating progressbars
- update all the links to gtk.org
>>>>>>> 1.255
Mon Mar 16 09:15:03 GMT 1998 Tony Gale <gale@gimp.org>
* docs/gtk_tut.sgml:
......
......@@ -3430,6 +3430,7 @@ gdk_ic_new (GdkWindow* client_window,
GdkIMStyle style, ...)
{
va_list list;
void *argsptr;
GdkICPrivate *private;
XVaNestedList preedit_attr;
......@@ -3440,7 +3441,8 @@ gdk_ic_new (GdkWindow* client_window,
private = g_new (GdkICPrivate, 1);
va_start (list, style);
preedit_attr = (XVaNestedList) & (va_arg (list, void *));
argsptr = va_arg (list, void *);
preedit_attr = (XVaNestedList)&argsptr;
va_end (list);
private->style = gdk_im_decide_style (style);
......@@ -3500,6 +3502,7 @@ void
gdk_ic_set_values (GdkIC ic, ...)
{
va_list list;
void *argsptr;
XVaNestedList args;
GdkICPrivate *private;
......@@ -3508,7 +3511,8 @@ gdk_ic_set_values (GdkIC ic, ...)
private = (GdkICPrivate *) ic;
va_start (list, ic);
args = (XVaNestedList) & (va_arg (list, void *));
argsptr = va_arg (list, void *);
args = (XVaNestedList)&argsptr;
va_end (list);
XSetICValues (private->xic, XNVaNestedList, args, NULL);
......@@ -3518,6 +3522,7 @@ void
gdk_ic_get_values (GdkIC ic, ...)
{
va_list list;
void *argsptr;
XVaNestedList args;
GdkICPrivate *private;
......@@ -3526,7 +3531,8 @@ gdk_ic_get_values (GdkIC ic, ...)
private = (GdkICPrivate *) ic;
va_start (list, ic);
args = (XVaNestedList) & (va_arg (list, void *));
argsptr = va_arg (list, void *);
args = (XVaNestedList)&argsptr;
va_end (list);
XGetICValues (private->xic, XNVaNestedList, args, NULL);
......@@ -3536,6 +3542,7 @@ void
gdk_ic_set_attr (GdkIC ic, const char *target, ...)
{
va_list list;
void *argsptr;
XVaNestedList attr;
GdkICPrivate *private;
......@@ -3545,7 +3552,8 @@ gdk_ic_set_attr (GdkIC ic, const char *target, ...)
private = (GdkICPrivate *) ic;
va_start (list, target);
attr = (XVaNestedList) & (va_arg (list, void *));
argsptr = va_arg (list, void *);
attr = (XVaNestedList)&argsptr;
va_end (list);
XSetICValues (private->xic, target, attr, NULL);
......@@ -3555,6 +3563,7 @@ void
gdk_ic_get_attr (GdkIC ic, const char *target, ...)
{
va_list list;
void *argsptr;
XVaNestedList attr;
GdkICPrivate *private;
......@@ -3564,7 +3573,8 @@ gdk_ic_get_attr (GdkIC ic, const char *target, ...)
private = (GdkICPrivate *) ic;
va_start (list, target);
attr = (XVaNestedList) & (va_arg (list, void *));
argsptr = va_arg (list, void *);
attr = (XVaNestedList)&argsptr;
va_end (list);
XGetICValues (private->xic, target, attr, NULL);
......
......@@ -851,8 +851,9 @@ gdk_color_context_get_pixels (GdkColorContext *cc,
gint bad_alloc = FALSE;
gint failed[MAX_IMAGE_COLORS], allocated[MAX_IMAGE_COLORS];
GdkColor defs[MAX_IMAGE_COLORS], cmap[MAX_IMAGE_COLORS];
#ifdef G_ENABLE_DEBUG
gint exact_col = 0, subst_col = 0, close_col = 0, black_col = 0;
#endif
g_assert (cc != NULL);
g_assert (reds != NULL);
g_assert (greens != NULL);
......@@ -934,7 +935,7 @@ gdk_color_context_get_pixels (GdkColorContext *cc,
return;
}
#ifdef DEBUG
#ifdef G_ENABLE_DEBUG
exact_col = ncols;
#endif
......@@ -1012,7 +1013,7 @@ gdk_color_context_get_pixels (GdkColorContext *cc,
defs[i] = cmap[close];
defs[i].pixel = colors[i];
allocated[ncols++] = colors[i];
#ifdef DEBUG
#ifdef G_ENABLE_DEBUG
close_col++;
#endif
} else
......@@ -1086,14 +1087,14 @@ gdk_color_context_get_pixels (GdkColorContext *cc,
defs[i].pixel = cc->black_pixel;
defs[i].red = defs[i].green = defs[i].blue = 0;
#ifdef DEBUG
#ifdef G_ENABLE_DEBUG
black_col++;
#endif
}
else
{
defs[i] = defs[close];
#ifdef DEBUG
#ifdef G_ENABLE_DEBUG
subst_col++;
#endif
}
......@@ -1123,7 +1124,9 @@ gdk_color_context_get_pixels_incremental (GdkColorContext *cc,
gint bad_alloc = FALSE;
gint failed[MAX_IMAGE_COLORS], allocated[MAX_IMAGE_COLORS];
GdkColor defs[MAX_IMAGE_COLORS], cmap[MAX_IMAGE_COLORS];
#ifdef G_ENABLE_DEBUG
gint exact_col = 0, subst_col = 0, close_col = 0, black_col = 0;
#endif
g_assert (cc != NULL);
g_assert (reds != NULL);
......@@ -1204,7 +1207,7 @@ gdk_color_context_get_pixels_incremental (GdkColorContext *cc,
return;
}
#ifdef DEBUG
#ifdef G_ENABLE_DEBUG
exact_col = ncols;
#endif
......@@ -1276,7 +1279,7 @@ gdk_color_context_get_pixels_incremental (GdkColorContext *cc,
defs[i] = cmap[close];
defs[i].pixel = colors[i];
allocated[ncols++] = colors[i];
#ifdef DEBUG
#ifdef G_ENABLE_DEBUG
close_col++;
#endif
}
......@@ -1348,14 +1351,14 @@ gdk_color_context_get_pixels_incremental (GdkColorContext *cc,
defs[i].pixel = cc->black_pixel;
defs[i].red = defs[i].green = defs[i].blue = 0;
#ifdef DEBUG
#ifdef G_ENABLE_DEBUG
black_col++;
#endif
}
else
{
defs[i] = defs[close];
#ifdef DEBUG
#ifdef G_ENABLE_DEBUG
subst_col++;
#endif
}
......
......@@ -40,6 +40,8 @@ static gint navailable_depths;
static GdkVisualType available_types[6];
static gint navailable_types;
#ifdef G_ENABLE_DEBUG
static gchar* visual_names[] =
{
"static gray",
......@@ -50,6 +52,8 @@ static gchar* visual_names[] =
"direct color",
};
#endif /* G_ENABLE_DEBUG */
static GHashTable *visual_hash = NULL;
void
......
......@@ -851,8 +851,9 @@ gdk_color_context_get_pixels (GdkColorContext *cc,
gint bad_alloc = FALSE;
gint failed[MAX_IMAGE_COLORS], allocated[MAX_IMAGE_COLORS];
GdkColor defs[MAX_IMAGE_COLORS], cmap[MAX_IMAGE_COLORS];
#ifdef G_ENABLE_DEBUG
gint exact_col = 0, subst_col = 0, close_col = 0, black_col = 0;
#endif
g_assert (cc != NULL);
g_assert (reds != NULL);
g_assert (greens != NULL);
......@@ -934,7 +935,7 @@ gdk_color_context_get_pixels (GdkColorContext *cc,
return;
}
#ifdef DEBUG
#ifdef G_ENABLE_DEBUG
exact_col = ncols;
#endif
......@@ -1012,7 +1013,7 @@ gdk_color_context_get_pixels (GdkColorContext *cc,
defs[i] = cmap[close];
defs[i].pixel = colors[i];
allocated[ncols++] = colors[i];
#ifdef DEBUG
#ifdef G_ENABLE_DEBUG
close_col++;
#endif
} else
......@@ -1086,14 +1087,14 @@ gdk_color_context_get_pixels (GdkColorContext *cc,
defs[i].pixel = cc->black_pixel;
defs[i].red = defs[i].green = defs[i].blue = 0;
#ifdef DEBUG
#ifdef G_ENABLE_DEBUG
black_col++;
#endif
}
else
{
defs[i] = defs[close];
#ifdef DEBUG
#ifdef G_ENABLE_DEBUG
subst_col++;
#endif
}
......@@ -1123,7 +1124,9 @@ gdk_color_context_get_pixels_incremental (GdkColorContext *cc,
gint bad_alloc = FALSE;
gint failed[MAX_IMAGE_COLORS], allocated[MAX_IMAGE_COLORS];
GdkColor defs[MAX_IMAGE_COLORS], cmap[MAX_IMAGE_COLORS];
#ifdef G_ENABLE_DEBUG
gint exact_col = 0, subst_col = 0, close_col = 0, black_col = 0;
#endif
g_assert (cc != NULL);
g_assert (reds != NULL);
......@@ -1204,7 +1207,7 @@ gdk_color_context_get_pixels_incremental (GdkColorContext *cc,
return;
}
#ifdef DEBUG
#ifdef G_ENABLE_DEBUG
exact_col = ncols;
#endif
......@@ -1276,7 +1279,7 @@ gdk_color_context_get_pixels_incremental (GdkColorContext *cc,
defs[i] = cmap[close];
defs[i].pixel = colors[i];
allocated[ncols++] = colors[i];
#ifdef DEBUG
#ifdef G_ENABLE_DEBUG
close_col++;
#endif
}
......@@ -1348,14 +1351,14 @@ gdk_color_context_get_pixels_incremental (GdkColorContext *cc,
defs[i].pixel = cc->black_pixel;
defs[i].red = defs[i].green = defs[i].blue = 0;
#ifdef DEBUG
#ifdef G_ENABLE_DEBUG
black_col++;
#endif
}
else
{
defs[i] = defs[close];
#ifdef DEBUG
#ifdef G_ENABLE_DEBUG
subst_col++;
#endif
}
......
......@@ -3430,6 +3430,7 @@ gdk_ic_new (GdkWindow* client_window,
GdkIMStyle style, ...)
{
va_list list;
void *argsptr;
GdkICPrivate *private;
XVaNestedList preedit_attr;
......@@ -3440,7 +3441,8 @@ gdk_ic_new (GdkWindow* client_window,
private = g_new (GdkICPrivate, 1);
va_start (list, style);
preedit_attr = (XVaNestedList) & (va_arg (list, void *));
argsptr = va_arg (list, void *);
preedit_attr = (XVaNestedList)&argsptr;
va_end (list);
private->style = gdk_im_decide_style (style);
......@@ -3500,6 +3502,7 @@ void
gdk_ic_set_values (GdkIC ic, ...)
{
va_list list;
void *argsptr;
XVaNestedList args;
GdkICPrivate *private;
......@@ -3508,7 +3511,8 @@ gdk_ic_set_values (GdkIC ic, ...)
private = (GdkICPrivate *) ic;
va_start (list, ic);
args = (XVaNestedList) & (va_arg (list, void *));
argsptr = va_arg (list, void *);
args = (XVaNestedList)&argsptr;
va_end (list);
XSetICValues (private->xic, XNVaNestedList, args, NULL);
......@@ -3518,6 +3522,7 @@ void
gdk_ic_get_values (GdkIC ic, ...)
{
va_list list;
void *argsptr;
XVaNestedList args;
GdkICPrivate *private;
......@@ -3526,7 +3531,8 @@ gdk_ic_get_values (GdkIC ic, ...)
private = (GdkICPrivate *) ic;
va_start (list, ic);
args = (XVaNestedList) & (va_arg (list, void *));
argsptr = va_arg (list, void *);
args = (XVaNestedList)&argsptr;
va_end (list);
XGetICValues (private->xic, XNVaNestedList, args, NULL);
......@@ -3536,6 +3542,7 @@ void
gdk_ic_set_attr (GdkIC ic, const char *target, ...)
{
va_list list;
void *argsptr;
XVaNestedList attr;
GdkICPrivate *private;
......@@ -3545,7 +3552,8 @@ gdk_ic_set_attr (GdkIC ic, const char *target, ...)
private = (GdkICPrivate *) ic;
va_start (list, target);
attr = (XVaNestedList) & (va_arg (list, void *));
argsptr = va_arg (list, void *);
attr = (XVaNestedList)&argsptr;
va_end (list);
XSetICValues (private->xic, target, attr, NULL);
......@@ -3555,6 +3563,7 @@ void
gdk_ic_get_attr (GdkIC ic, const char *target, ...)
{
va_list list;
void *argsptr;
XVaNestedList attr;
GdkICPrivate *private;
......@@ -3564,7 +3573,8 @@ gdk_ic_get_attr (GdkIC ic, const char *target, ...)
private = (GdkICPrivate *) ic;
va_start (list, target);
attr = (XVaNestedList) & (va_arg (list, void *));
argsptr = va_arg (list, void *);
attr = (XVaNestedList)&argsptr;
va_end (list);
XGetICValues (private->xic, target, attr, NULL);
......
......@@ -40,6 +40,8 @@ static gint navailable_depths;
static GdkVisualType available_types[6];
static gint navailable_types;
#ifdef G_ENABLE_DEBUG
static gchar* visual_names[] =
{
"static gray",
......@@ -50,6 +52,8 @@ static gchar* visual_names[] =
"direct color",
};
#endif /* G_ENABLE_DEBUG */
static GHashTable *visual_hash = NULL;
void
......
......@@ -71,7 +71,7 @@ static void gtk_combo_size_allocate (GtkWidget *widget,
static GtkHBoxClass *parent_class = NULL;
void
static void
gtk_combo_class_init (GtkComboClass * klass)
{
GtkObjectClass *oclass;
......@@ -437,7 +437,7 @@ gtk_combo_list_key_press (GtkWidget * widget, GdkEventKey * event, GtkCombo * co
return FALSE;
}
void
static void
gtk_combo_init (GtkCombo * combo)
{
GtkWidget *arrow;
......
......@@ -42,7 +42,7 @@ typedef void (*GtkContainerSignal1) (GtkObject *object,
gpointer arg1,
gpointer data);
typedef void (*GtkContainerSignal2) (GtkObject *object,
gpointer arg1,
GtkFunction arg1,
gpointer arg2,
gpointer data);
typedef gint (*GtkContainerSignal3) (GtkObject *object,
......
......@@ -23,7 +23,8 @@ extern "C" {
#endif /* __cplusplus */
typedef enum {
GTK_DEBUG_OBJECTS = 1<<0
GTK_DEBUG_OBJECTS = 1<<0,
GTK_DEBUG_MISC = 1<<1
} GtkDebugFlag;
#ifdef G_ENABLE_DEBUG
......
......@@ -360,7 +360,7 @@ gtk_editable_selection_handler (GtkWidget *widget,
{
gtk_selection_data_set (selection_data,
GDK_SELECTION_TYPE_STRING,
8*sizeof(gchar), str, length);
8*sizeof(gchar), (guchar *)str, length);
}
else if (selection_data->target == text_atom ||
selection_data->target == ctext_atom)
......@@ -441,7 +441,8 @@ gtk_editable_selection_received (GtkWidget *widget,
case STRING:
selection_data->data[selection_data->length] = 0;
gtk_editable_insert_text (editable, selection_data->data,
strlen (selection_data->data), &tmp_pos);
strlen ((gchar *)selection_data->data),
&tmp_pos);
editable->current_pos = tmp_pos;
break;
case CTEXT:
......
......@@ -26,6 +26,7 @@
#include "gtkmain.h"
#include "gtkselection.h"
#include "gtksignal.h"
#include "gtkprivate.h"
#define MIN_ENTRY_WIDTH 150
#define DRAW_TIMEOUT 20
......@@ -861,7 +862,6 @@ gtk_entry_key_press (GtkWidget *widget,
gint return_val;
gint key;
guint initial_pos;
guint tmp_pos;
gint extend_selection;
gint extend_start;
......@@ -995,6 +995,8 @@ gtk_entry_key_press (GtkWidget *widget,
}
if (event->length > 0)
{
gint tmp_pos;
extend_selection = FALSE;
gtk_editable_delete_selection (editable);
......@@ -1508,7 +1510,7 @@ gtk_entry_update_text (GtkEditable *editable,
gtk_entry_queue_draw (GTK_ENTRY(editable));