gtk2/gtk/gtkstatusbar.h
Tim Janik af18ab4305 complete api change to honour message contexts. unfortunaltely this also
Sun Mar  1 22:59:09 1998  Tim Janik  <timj@gimp.org>

        * gtk/gtkstatusbar.h:
        * gtk/gtkstatusbar.c: complete api change to honour message contexts.
        unfortunaltely this also involved argument changes on the signal
        emissions which will not be caught by the compiler. your callbacks
        should look like:
        void  message_text_popped (GtkStatusbar   *statusbar,
                                   guint           context_id,
                                   const gchar    *text,
                                   gpointer        func_data);

        * gtk/gtkwidget.c (gtk_widget_set_rc_style): eliminated bug about
        initial signal emission.
        (gtk_widget_set_parent): don't ensure style, just call
        gtk_widget_set_style_recurse.
        (gtk_widget_set_style_recurse): only change a widget's rc styles if
        if there has already been a lookup.

        * gtk/testgtk.c: adaptions for statusbar widget.
        substituted notebook pixmaps with pixmaps from fvwm, since
        we don't know where the originals came from.

        * gtk/gtkobject.c (gtk_object_data_destroy): call the destroy
        notifier with the objects data, not its internal structure.

        * gtk/gtkspinbutton.c (gtk_spin_button_button_press): small
        fix from lars.
1998-03-01 23:29:40 +00:00

92 lines
2.6 KiB
C

/* GTK - The GIMP Toolkit
* Copyright (C) 1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald
* GtkStatusbar Copyright (C) 1998 Shawn T. Amundson
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Library General Public
* License as published by the Free Software Foundation; either
* version 2 of the License, or (at your option) any later version.
*
* This library is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Library General Public License for more details.
*
* You should have received a copy of the GNU Library General Public
* License along with this library; if not, write to the Free
* Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*/
#ifndef __GTK_STATUSBAR_H__
#define __GTK_STATUSBAR_H_
#include <gtk/gtkhbox.h>
#ifdef __cplusplus
extern "C" {
#endif /* __cplusplus */
#define GTK_STATUSBAR(obj) GTK_CHECK_CAST (obj, gtk_statusbar_get_type (), GtkStatusbar)
#define GTK_STATUSBAR_CLASS(klass) GTK_CHECK_CLASS_CAST (klass, gtk_statusbar_get_type (), GtkStatusbarClass)
#define GTK_IS_STATUSBAR(obj) GTK_CHECK_TYPE (obj, gtk_statusbar_get_type ())
typedef struct _GtkStatusbar GtkStatusbar;
typedef struct _GtkStatusbarClass GtkStatusbarClass;
typedef struct _GtkStatusbarMsg GtkStatusbarMsg;
struct _GtkStatusbar
{
GtkHBox parent_widget;
GtkWidget *frame;
GtkWidget *label;
GSList *messages;
GSList *keys;
guint seq_context_id;
guint seq_message_id;
};
struct _GtkStatusbarClass
{
GtkHBoxClass parent_class;
GMemChunk *messages_mem_chunk;
void (*text_pushed) (GtkStatusbar *statusbar,
guint context_id,
const gchar *text);
void (*text_popped) (GtkStatusbar *statusbar,
guint context_id,
const gchar *text);
};
struct _GtkStatusbarMsg
{
gchar *text;
guint context_id;
guint message_id;
};
guint gtk_statusbar_get_type (void);
GtkWidget* gtk_statusbar_new (void);
guint gtk_statusbar_get_context_id (GtkStatusbar *statusbar,
const gchar *context_description);
/* Returns message_id used for gtk_statusbar_remove */
guint gtk_statusbar_push (GtkStatusbar *statusbar,
guint context_id,
const gchar *text);
void gtk_statusbar_pop (GtkStatusbar *statusbar,
guint context_id);
void gtk_statusbar_remove (GtkStatusbar *statusbar,
guint context_id,
guint message_id);
#ifdef __cplusplus
}
#endif /* __cplusplus */
#endif /* __GTK_STATUSBAR_H_ */