~canonical-dx-team/ubuntu/maverick/gtk+2.0/menuproxy

« back to all changes in this revision

Viewing changes to gtk/gtkactiongroup.h

  • Committer: Bazaar Package Importer
  • Author(s): Sebastien Bacher
  • Date: 2007-05-04 12:24:25 UTC
  • mfrom: (1.1.21 upstream)
  • Revision ID: james.westby@ubuntu.com-20070504122425-0m8midgzrp40y8w2
Tags: 2.10.12-1ubuntu1
* Sync with Debian
* New upstream version:
  Fixed bugs:
  - 379414 file chooser warnings when changing path in the entry
  - 418585 GtkFileChooserDefault sizing code is not DPI independent
  - 419568 Crash in search if start with special letter
  - 435062 build dies with icon cache validation
  - 379399 Segfault to call gtk_print_operation_run twice.
  - 387889 cups backend has problems when there are too many printers
  - 418531 invalid read to gtkicontheme.c gtk_icon_theme_lookup_icon...
  - 423916 crash in color scheme code
  - 424042 Segmentation fault while quickly pressing Alt+arrows
  - 415260 Protect against negative indices when setting values in G...
  - 419171 XGetVisualInfo() may not set nxvisuals
  - 128852 Gdk cursors don't look good on win32
  - 344657 Ctrl-H doesn't toggle "Show Hidden Files" setting
  - 345345 PrintOperation::paginate is not emitted for class handler
  - 347567 GtkPrintOperation::end-print is not emitted if it's cance...
  - 369112 gtk_ui_manager_add_ui should accept unnamed separator
  - 392015 Selected menu item invisible on Windows Vista
  - 399253 MS-Windows Theme Bottom Tab placement rendering glitches
  - 399425 gtk_input_dialog_fill_axes() adds child to gtkscrolledwin...
  - 403251 [patch] little memory leak in GtkPrintJob
  - 403267 [patch] memory leak in GtkPageSetupUnixDialog
  - 403470 MS-Windows Theme tab placement other than on top leaks a ...
  - 404506 Windows system fonts that have multi-byte font names cann...
  - 405089 Incorrect window placement for GtkEventBox private window
  - 405515 Minor leak in gtkfilesystemmodel.c
  - 405539 gdk_pixbuf_save() for PNG saver can return FALSE without ...
  - 415681 gdk_window_clear_area includes an extra line and column o...
  - 418219 GtkRecentChooser should apply filter before sorting and c...
  - 418403 Scroll to printer after selecting it from settings
  - 421985 _gtk_print_operation_platform_backend_launch_preview
  - 421990 gtk_print_job_get_surface
  - 421993 gtk_print_operation_init
  - 423064 Conditional jump or move depends on uninitialised value(s...
  - 423722 Fix printing header in gtk-demo
  - 424168 gtk_print_operation_run on async preview
  - 425655 Don't install gtk+-unix-print-2.0.pc on non-UNIX platforms
  - 425786 GDK segfaults if XineramaQueryScreens fails
  - 428665 Lpr Backend gets stuck in infinite loop during gtk_enumer...
  - 429902 GtkPrintOperation leaks cairo contextes
  - 431997 First delay of GdkPixbufAnimationIter is wrong
  - 433242 Inconsistent scroll arrow position calculations
  - 433972 Placing gtk.Expander inside a gtk.TextView() changes gtk....
  - 434261 _gtk_toolbar_elide_underscores incorrectly handles some s...
  - 383354 ctrl-L should make 'Location' entry disappear
  - 418673 gtk_recent_manager_add_item
  - 429732 gtk_accel_group_finalize accesses invalid memory
  - 435028 WM_CLIENT_LEADER is wrong on the leader_window
  - 431067 Background of the header window is not updated
  - 338843 add recent files support inside the ui manager
  - 148535 add drop shadow to menus, tooltips, etc. under Windows XP
* debian/control.in:
  - Conflicts on ubuntulooks (<= 0.9.11-1)
* debian/patches/15_default-fallback-icon-theme.patch:
  - patch from Debian, fallback on gnome icon theme

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/*
 
2
 * GTK - The GIMP Toolkit
 
3
 * Copyright (C) 1998, 1999 Red Hat, Inc.
 
4
 * All rights reserved.
 
5
 *
 
6
 * This Library is free software; you can redistribute it and/or
 
7
 * modify it under the terms of the GNU Library General Public License as
 
8
 * published by the Free Software Foundation; either version 2 of the
 
9
 * License, or (at your option) any later version.
 
10
 *
 
11
 * This Library is distributed in the hope that it will be useful,
 
12
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 
13
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 
14
 * Library General Public License for more details.
 
15
 *
 
16
 * You should have received a copy of the GNU Library General Public
 
17
 * License along with the Gnome Library; see the file COPYING.LIB.  If not,
 
18
 * write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
 
19
 * Boston, MA 02111-1307, USA.
 
20
 */
 
21
 
 
22
/* 
 
23
 * Author: James Henstridge <james@daa.com.au>
 
24
 *
 
25
 * Modified by the GTK+ Team and others 2003.  See the AUTHORS
 
26
 * file for a list of people on the GTK+ Team.  See the ChangeLog
 
27
 * files for a list of changes.  These files are distributed with
 
28
 * GTK+ at ftp://ftp.gtk.org/pub/gtk/. 
 
29
 */
 
30
#ifndef __GTK_ACTION_GROUP_H__
 
31
#define __GTK_ACTION_GROUP_H__
 
32
 
 
33
#include <gtk/gtkaction.h>
 
34
#include <gtk/gtkitemfactory.h> /* for GtkTranslateFunc */
 
35
 
 
36
G_BEGIN_DECLS
 
37
 
 
38
#define GTK_TYPE_ACTION_GROUP              (gtk_action_group_get_type ())
 
39
#define GTK_ACTION_GROUP(obj)              (G_TYPE_CHECK_INSTANCE_CAST ((obj), GTK_TYPE_ACTION_GROUP, GtkActionGroup))
 
40
#define GTK_ACTION_GROUP_CLASS(vtable)     (G_TYPE_CHECK_CLASS_CAST ((vtable), GTK_TYPE_ACTION_GROUP, GtkActionGroupClass))
 
41
#define GTK_IS_ACTION_GROUP(obj)           (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GTK_TYPE_ACTION_GROUP))
 
42
#define GTK_IS_ACTION_GROUP_CLASS(vtable)  (G_TYPE_CHECK_CLASS_TYPE ((vtable), GTK_TYPE_ACTION_GROUP))
 
43
#define GTK_ACTION_GROUP_GET_CLASS(inst)   (G_TYPE_INSTANCE_GET_CLASS ((inst), GTK_TYPE_ACTION_GROUP, GtkActionGroupClass))
 
44
 
 
45
typedef struct _GtkActionGroup        GtkActionGroup;
 
46
typedef struct _GtkActionGroupPrivate GtkActionGroupPrivate;
 
47
typedef struct _GtkActionGroupClass   GtkActionGroupClass;
 
48
typedef struct _GtkActionEntry        GtkActionEntry;
 
49
typedef struct _GtkToggleActionEntry  GtkToggleActionEntry;
 
50
typedef struct _GtkRadioActionEntry   GtkRadioActionEntry;
 
51
 
 
52
struct _GtkActionGroup
 
53
{
 
54
  GObject parent;
 
55
 
 
56
  /*< private >*/
 
57
 
 
58
  GtkActionGroupPrivate *private_data;
 
59
};
 
60
 
 
61
struct _GtkActionGroupClass
 
62
{
 
63
  GObjectClass parent_class;
 
64
 
 
65
  GtkAction *(* get_action) (GtkActionGroup *action_group,
 
66
                             const gchar    *action_name);
 
67
 
 
68
  /* Padding for future expansion */
 
69
  void (*_gtk_reserved1) (void);
 
70
  void (*_gtk_reserved2) (void);
 
71
  void (*_gtk_reserved3) (void);
 
72
  void (*_gtk_reserved4) (void);
 
73
};
 
74
 
 
75
struct _GtkActionEntry 
 
76
{
 
77
  const gchar     *name;
 
78
  const gchar     *stock_id;
 
79
  const gchar     *label;
 
80
  const gchar     *accelerator;
 
81
  const gchar     *tooltip;
 
82
  GCallback  callback;
 
83
};
 
84
 
 
85
struct _GtkToggleActionEntry 
 
86
{
 
87
  const gchar     *name;
 
88
  const gchar     *stock_id;
 
89
  const gchar     *label;
 
90
  const gchar     *accelerator;
 
91
  const gchar     *tooltip;
 
92
  GCallback  callback;
 
93
  gboolean   is_active;
 
94
};
 
95
 
 
96
struct _GtkRadioActionEntry 
 
97
{
 
98
  const gchar *name;
 
99
  const gchar *stock_id;
 
100
  const gchar *label;
 
101
  const gchar *accelerator;
 
102
  const gchar *tooltip;
 
103
  gint   value; 
 
104
};
 
105
 
 
106
GType           gtk_action_group_get_type                (void) G_GNUC_CONST;
 
107
GtkActionGroup *gtk_action_group_new                     (const gchar                *name);
 
108
G_CONST_RETURN gchar *gtk_action_group_get_name          (GtkActionGroup             *action_group);
 
109
gboolean        gtk_action_group_get_sensitive           (GtkActionGroup             *action_group);
 
110
void            gtk_action_group_set_sensitive           (GtkActionGroup             *action_group,
 
111
                                                          gboolean                    sensitive);
 
112
gboolean        gtk_action_group_get_visible             (GtkActionGroup             *action_group);
 
113
void            gtk_action_group_set_visible             (GtkActionGroup             *action_group,
 
114
                                                          gboolean                    visible);
 
115
GtkAction      *gtk_action_group_get_action              (GtkActionGroup             *action_group,
 
116
                                                          const gchar                *action_name);
 
117
GList          *gtk_action_group_list_actions            (GtkActionGroup             *action_group);
 
118
void            gtk_action_group_add_action              (GtkActionGroup             *action_group,
 
119
                                                          GtkAction                  *action);
 
120
void            gtk_action_group_add_action_with_accel   (GtkActionGroup             *action_group,
 
121
                                                          GtkAction                  *action,
 
122
                                                          const gchar                *accelerator);
 
123
void            gtk_action_group_remove_action           (GtkActionGroup             *action_group,
 
124
                                                          GtkAction                  *action);
 
125
void            gtk_action_group_add_actions             (GtkActionGroup             *action_group,
 
126
                                                          const GtkActionEntry       *entries,
 
127
                                                          guint                       n_entries,
 
128
                                                          gpointer                    user_data);
 
129
void            gtk_action_group_add_toggle_actions      (GtkActionGroup             *action_group,
 
130
                                                          const GtkToggleActionEntry *entries,
 
131
                                                          guint                       n_entries,
 
132
                                                          gpointer                    user_data);
 
133
void            gtk_action_group_add_radio_actions       (GtkActionGroup             *action_group,
 
134
                                                          const GtkRadioActionEntry  *entries,
 
135
                                                          guint                       n_entries,
 
136
                                                          gint                        value,
 
137
                                                          GCallback                   on_change,
 
138
                                                          gpointer                    user_data);
 
139
void            gtk_action_group_add_actions_full        (GtkActionGroup             *action_group,
 
140
                                                          const GtkActionEntry       *entries,
 
141
                                                          guint                       n_entries,
 
142
                                                          gpointer                    user_data,
 
143
                                                          GDestroyNotify              destroy);
 
144
void            gtk_action_group_add_toggle_actions_full (GtkActionGroup             *action_group,
 
145
                                                          const GtkToggleActionEntry *entries,
 
146
                                                          guint                       n_entries,
 
147
                                                          gpointer                    user_data,
 
148
                                                          GDestroyNotify              destroy);
 
149
void            gtk_action_group_add_radio_actions_full  (GtkActionGroup             *action_group,
 
150
                                                          const GtkRadioActionEntry  *entries,
 
151
                                                          guint                       n_entries,
 
152
                                                          gint                        value,
 
153
                                                          GCallback                   on_change,
 
154
                                                          gpointer                    user_data,
 
155
                                                          GDestroyNotify              destroy);
 
156
void            gtk_action_group_set_translate_func      (GtkActionGroup             *action_group,
 
157
                                                          GtkTranslateFunc            func,
 
158
                                                          gpointer                    data,
 
159
                                                          GtkDestroyNotify            notify);
 
160
void            gtk_action_group_set_translation_domain  (GtkActionGroup             *action_group,
 
161
                                                          const gchar                *domain);
 
162
G_CONST_RETURN gchar *gtk_action_group_translate_string  (GtkActionGroup             *action_group,
 
163
                                                          const gchar                *string);
 
164
 
 
165
/* Protected for use by GtkAction */
 
166
void _gtk_action_group_emit_connect_proxy    (GtkActionGroup *action_group,
 
167
                                              GtkAction      *action,
 
168
                                              GtkWidget      *proxy);
 
169
void _gtk_action_group_emit_disconnect_proxy (GtkActionGroup *action_group,
 
170
                                              GtkAction      *action,
 
171
                                              GtkWidget      *proxy);
 
172
void _gtk_action_group_emit_pre_activate     (GtkActionGroup *action_group,
 
173
                                              GtkAction      *action);
 
174
void _gtk_action_group_emit_post_activate    (GtkActionGroup *action_group,
 
175
                                              GtkAction      *action);
 
176
 
 
177
G_END_DECLS
 
178
 
 
179
#endif  /* __GTK_ACTION_GROUP_H__ */