From c272baf6ef74d6b2b712003ac3116284029fc94b Mon Sep 17 00:00:00 2001 From: Matthias Clasen Date: Sun, 5 May 2002 20:10:38 +0000 Subject: [PATCH] Bump version to 2.1.0, binary, interface age 0. * configure.in: Bump version to 2.1.0, binary, interface age 0. * gtk/gtkcontainer.c (gtk_container_class_list_child_properties): (gtk_container_class_find_child_property): Document. * gtk/gtkwidget.c: * gtk/gtkwidget.h: New functions gtk_widget_class_list_child_properties and gtk_widget_class_find_child_property. (#80652) --- ChangeLog | 11 +++++++ ChangeLog.pre-2-10 | 11 +++++++ ChangeLog.pre-2-2 | 11 +++++++ ChangeLog.pre-2-4 | 11 +++++++ ChangeLog.pre-2-6 | 11 +++++++ ChangeLog.pre-2-8 | 11 +++++++ configure.in | 33 ++++++++++++++++---- docs/reference/ChangeLog | 5 +++ docs/reference/gtk/gtk-sections.txt | 3 ++ gtk/gtkcontainer.c | 19 +++++++++++- gtk/gtkwidget.c | 47 ++++++++++++++++++++++++++++- gtk/gtkwidget.h | 4 +++ 12 files changed, 169 insertions(+), 8 deletions(-) diff --git a/ChangeLog b/ChangeLog index b6bba94aa..5ee68ad7d 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,14 @@ +2002-05-05 Matthias Clasen + + * configure.in: Bump version to 2.1.0, binary, interface age 0. + + * gtk/gtkcontainer.c (gtk_container_class_list_child_properties): + (gtk_container_class_find_child_property): Document. + + * gtk/gtkwidget.c: + * gtk/gtkwidget.h: New functions gtk_widget_class_list_child_properties + and gtk_widget_class_find_child_property. (#80652) + Sun May 5 15:56:50 2002 Owen Taylor * configure.in: Fix problem with == in test argument. diff --git a/ChangeLog.pre-2-10 b/ChangeLog.pre-2-10 index b6bba94aa..5ee68ad7d 100644 --- a/ChangeLog.pre-2-10 +++ b/ChangeLog.pre-2-10 @@ -1,3 +1,14 @@ +2002-05-05 Matthias Clasen + + * configure.in: Bump version to 2.1.0, binary, interface age 0. + + * gtk/gtkcontainer.c (gtk_container_class_list_child_properties): + (gtk_container_class_find_child_property): Document. + + * gtk/gtkwidget.c: + * gtk/gtkwidget.h: New functions gtk_widget_class_list_child_properties + and gtk_widget_class_find_child_property. (#80652) + Sun May 5 15:56:50 2002 Owen Taylor * configure.in: Fix problem with == in test argument. diff --git a/ChangeLog.pre-2-2 b/ChangeLog.pre-2-2 index b6bba94aa..5ee68ad7d 100644 --- a/ChangeLog.pre-2-2 +++ b/ChangeLog.pre-2-2 @@ -1,3 +1,14 @@ +2002-05-05 Matthias Clasen + + * configure.in: Bump version to 2.1.0, binary, interface age 0. + + * gtk/gtkcontainer.c (gtk_container_class_list_child_properties): + (gtk_container_class_find_child_property): Document. + + * gtk/gtkwidget.c: + * gtk/gtkwidget.h: New functions gtk_widget_class_list_child_properties + and gtk_widget_class_find_child_property. (#80652) + Sun May 5 15:56:50 2002 Owen Taylor * configure.in: Fix problem with == in test argument. diff --git a/ChangeLog.pre-2-4 b/ChangeLog.pre-2-4 index b6bba94aa..5ee68ad7d 100644 --- a/ChangeLog.pre-2-4 +++ b/ChangeLog.pre-2-4 @@ -1,3 +1,14 @@ +2002-05-05 Matthias Clasen + + * configure.in: Bump version to 2.1.0, binary, interface age 0. + + * gtk/gtkcontainer.c (gtk_container_class_list_child_properties): + (gtk_container_class_find_child_property): Document. + + * gtk/gtkwidget.c: + * gtk/gtkwidget.h: New functions gtk_widget_class_list_child_properties + and gtk_widget_class_find_child_property. (#80652) + Sun May 5 15:56:50 2002 Owen Taylor * configure.in: Fix problem with == in test argument. diff --git a/ChangeLog.pre-2-6 b/ChangeLog.pre-2-6 index b6bba94aa..5ee68ad7d 100644 --- a/ChangeLog.pre-2-6 +++ b/ChangeLog.pre-2-6 @@ -1,3 +1,14 @@ +2002-05-05 Matthias Clasen + + * configure.in: Bump version to 2.1.0, binary, interface age 0. + + * gtk/gtkcontainer.c (gtk_container_class_list_child_properties): + (gtk_container_class_find_child_property): Document. + + * gtk/gtkwidget.c: + * gtk/gtkwidget.h: New functions gtk_widget_class_list_child_properties + and gtk_widget_class_find_child_property. (#80652) + Sun May 5 15:56:50 2002 Owen Taylor * configure.in: Fix problem with == in test argument. diff --git a/ChangeLog.pre-2-8 b/ChangeLog.pre-2-8 index b6bba94aa..5ee68ad7d 100644 --- a/ChangeLog.pre-2-8 +++ b/ChangeLog.pre-2-8 @@ -1,3 +1,14 @@ +2002-05-05 Matthias Clasen + + * configure.in: Bump version to 2.1.0, binary, interface age 0. + + * gtk/gtkcontainer.c (gtk_container_class_list_child_properties): + (gtk_container_class_find_child_property): Document. + + * gtk/gtkwidget.c: + * gtk/gtkwidget.h: New functions gtk_widget_class_list_child_properties + and gtk_widget_class_find_child_property. (#80652) + Sun May 5 15:56:50 2002 Owen Taylor * configure.in: Fix problem with == in test argument. diff --git a/configure.in b/configure.in index 41bad0a33..086896040 100644 --- a/configure.in +++ b/configure.in @@ -28,10 +28,10 @@ GLIB_AC_DIVERT_BEFORE_HELP([ # set GTK_BINARY_AGE and GTK_INTERFACE_AGE to 0. # GTK_MAJOR_VERSION=2 -GTK_MINOR_VERSION=0 -GTK_MICRO_VERSION=2 -GTK_INTERFACE_AGE=2 -GTK_BINARY_AGE=2 +GTK_MINOR_VERSION=1 +GTK_MICRO_VERSION=0 +GTK_INTERFACE_AGE=0 +GTK_BINARY_AGE=0 GTK_VERSION=$GTK_MAJOR_VERSION.$GTK_MINOR_VERSION.$GTK_MICRO_VERSION dnl This is the X.Y used in -lgtk-FOO-X.Y GTK_API_VERSION=2.0 @@ -633,6 +633,7 @@ dnl We allow people to disable image loaders explicitely, but if they don't we e dnl out so that people don't accidentally build without them. AC_ARG_WITH(libpng, [ --without-libpng disable PNG loader for gdk-pixbuf]) +AC_ARG_WITH(libmng, [ --without-libmng disable MNG loader for gdk-pixbuf]) AC_ARG_WITH(libjpeg, [ --without-libjpeg disable JPEG loader for gdk-pixbuf]) AC_ARG_WITH(libtiff, [ --without-libtiff disable TIFF loader for gdk-pixbuf]) @@ -736,9 +737,25 @@ dnl Test for libpng *** from CVS.]) fi +dnl Test for libmng + if test x$with_libmng != xno && test -z "$LIBMNG"; then + AC_CHECK_LIB(mng, mng_initialize, + [AC_CHECK_HEADER(libmng.h, + mng_ok=yes, + mng_ok=no)], + AC_MSG_WARN(*** MNG loader will not be built (MNG library not found) ***), -lz -lm) + AC_MSG_RESULT($mng_ok) + if test "$mng_ok" = yes; then + MNG='mng'; LIBMNG='-lmng -lz' + else + AC_MSG_WARN(*** MNG loader will not be built (MNG header file not found) ***) + fi + fi + AC_SUBST(LIBTIFF) AC_SUBST(LIBJPEG) AC_SUBST(LIBPNG) +AC_SUBST(LIBMNG) AM_CONDITIONAL(BUILD_DYNAMIC_MODULES, $dynworks) @@ -758,7 +775,7 @@ else fi fi -all_loaders="png,bmp,wbmp,gif,ico,jpeg,pnm,ras,tiff,xpm,tga" +all_loaders="png,mng,bmp,wbmp,gif,ico,jpeg,pnm,ras,tiff,xpm,tga" included_loaders="" # If no loaders specified, include all if test "x$with_included_loaders" = xyes ; then @@ -793,6 +810,7 @@ AC_TYPE_SIGNAL AM_CONDITIONAL(HAVE_TIFF, test "x$LIBTIFF" != x) AM_CONDITIONAL(HAVE_PNG, test "x$LIBPNG" != x) +AM_CONDITIONAL(HAVE_MNG, test "x$LIBMNG" != x) AM_CONDITIONAL(HAVE_JPEG, test "x$LIBJPEG" != x) if $dynworks ; then @@ -806,8 +824,11 @@ if $dynworks ; then if echo "$included_loaders" | grep "\(^\|\,\)png\(\$\|\,\)" > /dev/null; then STATIC_LIB_DEPS="$STATIC_LIB_DEPS $LIBPNG" fi + if echo "$included_loaders" | grep "\(^\|\,\)mng\(\$\|\,\)" > /dev/null; then + STATIC_LIB_DEPS="$STATIC_LIB_DEPS $LIBMNG" + fi else - STATIC_LIB_DEPS="$LIBTIFF $LIBJPEG $LIBPNG" + STATIC_LIB_DEPS="$LIBTIFF $LIBJPEG $LIBPNG $LIBMNG" fi # Checks to see if we should compile in MMX support (there will be diff --git a/docs/reference/ChangeLog b/docs/reference/ChangeLog index 17b88f436..2d4729fa9 100644 --- a/docs/reference/ChangeLog +++ b/docs/reference/ChangeLog @@ -1,3 +1,8 @@ +2002-05-05 Matthias Clasen + + * gtk/gtk-sections.txt: Add gtk_widget_class_find_style_property, + gtk_widget_class_list_style_properties and gtk_style_get_font_for_display. + 2002-05-03 Matthias Clasen * gdk/gdk-sections.txt: Remove gdk_screen_use_virtual_screen. diff --git a/docs/reference/gtk/gtk-sections.txt b/docs/reference/gtk/gtk-sections.txt index 222271445..d9bee58e0 100644 --- a/docs/reference/gtk/gtk-sections.txt +++ b/docs/reference/gtk/gtk-sections.txt @@ -3591,6 +3591,8 @@ gtk_widget_set_scroll_adjustments gtk_widget_mnemonic_activate gtk_widget_class_install_style_property gtk_widget_class_install_style_property_parser +gtk_widget_class_find_style_property +gtk_widget_class_list_style_properties gtk_widget_region_intersect gtk_widget_send_expose gtk_widget_style_get @@ -3867,6 +3869,7 @@ gtk_style_apply_default_pixmap gtk_style_lookup_icon_set gtk_style_render_icon gtk_style_get_font +gtk_style_get_font_for_display gtk_style_set_font gtk_draw_hline gtk_draw_vline diff --git a/gtk/gtkcontainer.c b/gtk/gtkcontainer.c index 3690a4b02..e02d3ef3e 100644 --- a/gtk/gtkcontainer.c +++ b/gtk/gtkcontainer.c @@ -653,6 +653,15 @@ gtk_container_class_install_child_property (GtkContainerClass *class, g_param_spec_pool_insert (_gtk_widget_child_property_pool, pspec, G_OBJECT_CLASS_TYPE (class)); } +/** + * gtk_container_class_find_child_property: + * @class: a #GtkContainerClass + * @property_name: the name of the child property to find + * @returns: the #GParamSpec of the child property or %NULL if @class has ho + * child property with that name. + * + * Finds a child property of a container class by name. + */ GParamSpec* gtk_container_class_find_child_property (GObjectClass *class, const gchar *property_name) @@ -666,7 +675,15 @@ gtk_container_class_find_child_property (GObjectClass *class, TRUE); } -GParamSpec** /* free result */ +/** + * gtk_container_class_list_child_properties: + * @class: a #GtkContainerClass + * @n_properties: location to return the number of child properties found + * @returns: an newly allocated array of #GParamSpec*. The array must be freed with g_free(). + * + * Returns all child properties of a container class. + */ +GParamSpec** gtk_container_class_list_child_properties (GObjectClass *class, guint *n_properties) { diff --git a/gtk/gtkwidget.c b/gtk/gtkwidget.c index 5ca8e1089..df5bbdb0f 100644 --- a/gtk/gtkwidget.c +++ b/gtk/gtkwidget.c @@ -395,7 +395,7 @@ gtk_widget_class_init (GtkWidgetClass *klass) g_object_class_install_property (gobject_class, PROP_PARENT, g_param_spec_object ("parent", - _("Parent widget"), + _("Parent widget"), _("The parent widget of this widget. Must be a Container widget."), GTK_TYPE_CONTAINER, G_PARAM_READWRITE)); @@ -6244,6 +6244,51 @@ gtk_widget_class_install_style_property (GtkWidgetClass *class, gtk_widget_class_install_style_property_parser (class, pspec, parser); } +/** + * gtk_widget_class_find_style_property: + * @class: a #GtkWidgetClass + * @property_name: the name of the style property to find + * @returns: the #GParamSpec of the style property or %NULL if @class has ho + * style property with that name. + * + * Finds a style property of a widget class by name. + */ +GParamSpec* +gtk_widget_class_find_style_property (GtkWidgetClass *class, + const gchar *property_name) +{ + g_return_val_if_fail (property_name != NULL, NULL); + + return g_param_spec_pool_lookup (style_property_spec_pool, + property_name, + G_OBJECT_CLASS_TYPE (class), + TRUE); +} + +/** + * gtk_widget_class_list_style_properties: + * @class: a #GtkWidgetClass + * @n_properties: location to return the number of style properties found + * @returns: an newly allocated array of #GParamSpec*. The array must be freed with g_free(). + * + * Returns all style properties of a widget class. + */ +GParamSpec** +gtk_widget_class_list_style_properties (GtkWidgetClass *class, + guint *n_properties) +{ + GParamSpec **pspecs; + guint n; + + pspecs = g_param_spec_pool_list (style_property_spec_pool, + G_OBJECT_CLASS_TYPE (class), + &n); + if (n_properties) + *n_properties = n; + + return pspecs; +} + /** * gtk_widget_style_get_property: * @widget: a #GtkWidget diff --git a/gtk/gtkwidget.h b/gtk/gtkwidget.h index 57d409e8a..3463c0ab3 100644 --- a/gtk/gtkwidget.h +++ b/gtk/gtkwidget.h @@ -697,6 +697,10 @@ void gtk_widget_class_install_style_property (GtkWidgetClass *klass, void gtk_widget_class_install_style_property_parser (GtkWidgetClass *klass, GParamSpec *pspec, GtkRcPropertyParser parser); +GParamSpec* gtk_widget_class_find_style_property (GtkWidgetClass *klass, + const gchar *property_name); +GParamSpec** gtk_widget_class_list_style_properties (GtkWidgetClass *klass, + guint *n_properties); void gtk_widget_style_get_property (GtkWidget *widget, const gchar *property_name, GValue *value);