1997-11-24 22:37:52 +00:00
|
|
|
/* GTK - The GIMP Toolkit
|
|
|
|
* Copyright (C) 1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald
|
|
|
|
*
|
|
|
|
* This library is free software; you can redistribute it and/or
|
2000-07-26 11:33:08 +00:00
|
|
|
* modify it under the terms of the GNU Lesser General Public
|
1997-11-24 22:37:52 +00:00
|
|
|
* 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
|
2000-07-26 11:33:08 +00:00
|
|
|
* Lesser General Public License for more details.
|
1997-11-24 22:37:52 +00:00
|
|
|
*
|
2000-07-26 11:33:08 +00:00
|
|
|
* You should have received a copy of the GNU Lesser General Public
|
1998-04-13 02:02:47 +00:00
|
|
|
* License along with this library; if not, write to the
|
|
|
|
* Free Software Foundation, Inc., 59 Temple Place - Suite 330,
|
|
|
|
* Boston, MA 02111-1307, USA.
|
1997-11-24 22:37:52 +00:00
|
|
|
*/
|
1999-02-24 07:37:18 +00:00
|
|
|
|
|
|
|
/*
|
2000-07-26 11:33:08 +00:00
|
|
|
* Modified by the GTK+ Team and others 1997-2000. See the AUTHORS
|
1999-02-24 07:37:18 +00:00
|
|
|
* file for a list of people on the GTK+ Team. See the ChangeLog
|
|
|
|
* files for a list of changes. These files are distributed with
|
|
|
|
* GTK+ at ftp://ftp.gtk.org/pub/gtk/.
|
|
|
|
*/
|
|
|
|
|
2003-10-10 17:18:34 +00:00
|
|
|
#ifndef GTK_DISABLE_DEPRECATED
|
|
|
|
|
1997-11-24 22:37:52 +00:00
|
|
|
#ifndef __GTK_OPTION_MENU_H__
|
|
|
|
#define __GTK_OPTION_MENU_H__
|
|
|
|
|
|
|
|
|
|
|
|
#include <gdk/gdk.h>
|
|
|
|
#include <gtk/gtkbutton.h>
|
|
|
|
|
|
|
|
|
2005-03-20 07:01:23 +00:00
|
|
|
G_BEGIN_DECLS
|
1997-11-24 22:37:52 +00:00
|
|
|
|
1998-06-16 05:20:05 +00:00
|
|
|
#define GTK_TYPE_OPTION_MENU (gtk_option_menu_get_type ())
|
2002-10-09 23:55:27 +00:00
|
|
|
#define GTK_OPTION_MENU(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GTK_TYPE_OPTION_MENU, GtkOptionMenu))
|
|
|
|
#define GTK_OPTION_MENU_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GTK_TYPE_OPTION_MENU, GtkOptionMenuClass))
|
|
|
|
#define GTK_IS_OPTION_MENU(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GTK_TYPE_OPTION_MENU))
|
|
|
|
#define GTK_IS_OPTION_MENU_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), GTK_TYPE_OPTION_MENU))
|
|
|
|
#define GTK_OPTION_MENU_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), GTK_TYPE_OPTION_MENU, GtkOptionMenuClass))
|
1997-11-24 22:37:52 +00:00
|
|
|
|
|
|
|
|
|
|
|
typedef struct _GtkOptionMenu GtkOptionMenu;
|
|
|
|
typedef struct _GtkOptionMenuClass GtkOptionMenuClass;
|
|
|
|
|
|
|
|
struct _GtkOptionMenu
|
|
|
|
{
|
|
|
|
GtkButton button;
|
1998-06-16 05:20:05 +00:00
|
|
|
|
1997-11-24 22:37:52 +00:00
|
|
|
GtkWidget *menu;
|
|
|
|
GtkWidget *menu_item;
|
1998-06-16 05:20:05 +00:00
|
|
|
|
1997-11-24 22:37:52 +00:00
|
|
|
guint16 width;
|
|
|
|
guint16 height;
|
|
|
|
};
|
|
|
|
|
|
|
|
struct _GtkOptionMenuClass
|
|
|
|
{
|
|
|
|
GtkButtonClass parent_class;
|
Adapt to uscore-ification of gtktextiterprivate
2001-01-03 Havoc Pennington <hp@redhat.com>
* gtk/gtktextbtree.c: Adapt to uscore-ification of gtktextiterprivate
* gtk/gtktextdisplay.c (gtk_text_layout_draw): remove use
of private functions; remove inclusion of private headers.
* gtk/gtktextlayout.c (gtk_text_layout_get_iter_at_line): Add this
function, so we don't need private functions in gtktextdisplay.c
* gtk/gtktextiterprivate.h: underscore-ification
* gtk/gtkwidget.c: Clean up a bunch of docs that said "INTERNAL"
to instead say "only useful to implement widgets"
* gtk/gtkenums.h (GtkMovementStep): Rename GTK_MOVEMENT_CHARS,
GTK_MOVEMENT_POSITIONS to GTK_MOVEMENT_LOGICAL_POSITIONS,
GTK_MOVEMENT_VISUAL_POSITIONS. Resolves bug 40249.
* gdk/x11/gdkwindow-x11.c (gdk_window_impl_x11_set_colormap):
This function was completely broken
* gtk/testtext.c (line_numbers_expose): use gtk_paint_layout
* gtk/gtkvscale.c (gtk_vscale_draw_value): use gtk_paint_layout
* gtk/gtkvruler.c (gtk_vruler_draw_ticks): use gtk_paint_layout
* gtk/gtklabel.c (gtk_label_expose): use gtk_paint_layout
* gtk/gtkhscale.c (gtk_hscale_draw_value): use gtk_paint_layout
* gtk/gtkhruler.c (gtk_hruler_draw_ticks): use gtk_paint_layout
* gtk/gtkcellrenderertext.c (gtk_cell_renderer_text_render): use
gtk_paint_layout
* gtk/gtkaccellabel.c (gtk_accel_label_expose_event): use
gtk_paint_layout
* gtk/gtkstyle.h: Add draw/paint expander to draw tree expanders.
Progress on bug 40103. Add draw_layout to draw a PangoLayout.
(struct _GtkStyleClass): Remove draw_cross, draw_oval, draw_ramp,
which were not implemented.
* gtk/gtktextbuffer.h (struct _GtkTextBufferClass): Add
insert_pixbuf signal. Rename delete_text to delete_range since it
also deletes pixbufs and child anchors. This almost closes bug
40245 (still need to deal with child anchors)
* gtk/gtktextbuffer.c (gtk_text_buffer_class_init): Add
insert_pixbuf, change signal names as appropriate, change types of
signals taking marks/tags to have the specific type, not just
G_TYPE_OBJECT
* gtk/gtkmain.c (gtk_get_current_event_state): Add this function;
closes bug 40051
* gtk/gtkoptionmenu.c (gtk_option_menu_set_history): clean up
unnecessary remove_contents() call
(gtk_option_menu_class_init): add a "changed" signal, closes
bug 40039
(gtk_option_menu_update_contents): emit "changed" if the
active menu item changes
* gtk/gdk-pixbuf-loader.c (gdk_pixbuf_loader_frame_done): fix bad
cast to GtkObject, reported by Jonas Borgstrom
(gdk_pixbuf_loader_finalize): don't close the loader on finalize;
we can't do stuff with side effects in finalize. Instead, spew a
warning if the loader isn't closed.
* gdk/x11/gdkdrawable-x11.c (gdk_drawable_impl_x11_finalize): free
colormap in here, non-X ports probably need to sync to this change
* gdk/x11/gdkdrawable-x11.c (gdk_x11_set_colormap): remove
assertion that colormap != NULL, you can set the colormap to NULL
if you like.
* Makefile.am: remove gtk-config-2.0
* configure.in: Use pkg-config to locate GLib. Remove
separated-out GMODULE_LIBS, GMODULE_CFLAGS; these were not used,
and the gmodule libs/cflags were in GLIB_LIBS GLIB_CFLAGS anyhow.
Use pkg-config to locate Pango. Output correct Pango libs to
gdk-2.0.pc.in. Fix test for FREETYPE_CONFIG (typo fix).
* Makefile.am (pkgconfig_DATA): install only target-specific pc
files
(install-data-local): symlink gtk+-2.0.pc and gdk-2.0.pc to the
X11 pc files
* gtk+-2.0.pc.in (Requires): require the GDK for the current target
unref from here
2001-01-04 17:48:43 +00:00
|
|
|
|
|
|
|
void (*changed) (GtkOptionMenu *option_menu);
|
2002-02-23 20:22:05 +00:00
|
|
|
|
|
|
|
/* Padding for future expansion */
|
|
|
|
void (*_gtk_reserved1) (void);
|
|
|
|
void (*_gtk_reserved2) (void);
|
|
|
|
void (*_gtk_reserved3) (void);
|
|
|
|
void (*_gtk_reserved4) (void);
|
1997-11-24 22:37:52 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
|
2002-10-09 23:55:27 +00:00
|
|
|
GType gtk_option_menu_get_type (void) G_GNUC_CONST;
|
1997-11-24 22:37:52 +00:00
|
|
|
GtkWidget* gtk_option_menu_new (void);
|
|
|
|
GtkWidget* gtk_option_menu_get_menu (GtkOptionMenu *option_menu);
|
|
|
|
void gtk_option_menu_set_menu (GtkOptionMenu *option_menu,
|
|
|
|
GtkWidget *menu);
|
|
|
|
void gtk_option_menu_remove_menu (GtkOptionMenu *option_menu);
|
1999-12-03 20:15:32 +00:00
|
|
|
gint gtk_option_menu_get_history (GtkOptionMenu *option_menu);
|
1997-11-24 22:37:52 +00:00
|
|
|
void gtk_option_menu_set_history (GtkOptionMenu *option_menu,
|
2002-11-08 19:41:50 +00:00
|
|
|
guint index_);
|
1997-11-24 22:37:52 +00:00
|
|
|
|
|
|
|
|
2005-03-20 07:01:23 +00:00
|
|
|
G_END_DECLS
|
1997-11-24 22:37:52 +00:00
|
|
|
|
|
|
|
#endif /* __GTK_OPTION_MENU_H__ */
|
2003-10-10 17:18:34 +00:00
|
|
|
|
|
|
|
#endif /* GTK_DISABLE_DEPRECATED */
|