Install ardour as a binary, a script and a set of shared
[ardour.git] / libs / gtkmm2 / gtk / gtkmm / radiomenuitem.h
1 // -*- c++ -*-
2 // Generated by gtkmmproc -- DO NOT MODIFY!
3 #ifndef _GTKMM_RADIOMENUITEM_H
4 #define _GTKMM_RADIOMENUITEM_H
5
6 #include <glibmm.h>
7
8 /* $Id$ */
9
10 /* radiomenuitem.h
11  * 
12  * Copyright (C) 1998-2002 The gtkmm Development Team
13  *
14  * This library is free software; you can redistribute it and/or
15  * modify it under the terms of the GNU Library General Public
16  * License as published by the Free Software Foundation; either
17  * version 2 of the License, or (at your option) any later version.
18  *
19  * This library is distributed in the hope that it will be useful,
20  * but WITHOUT ANY WARRANTY; without even the implied warranty of
21  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
22  * Library General Public License for more details.
23  *
24  * You should have received a copy of the GNU Library General Public
25  * License along with this library; if not, write to the Free
26  * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
27  */
28
29 #include <gtkmm/checkmenuitem.h>
30 #include <gtkmm/radiobutton.h>
31
32
33 #ifndef DOXYGEN_SHOULD_SKIP_THIS
34 typedef struct _GtkRadioMenuItem GtkRadioMenuItem;
35 typedef struct _GtkRadioMenuItemClass GtkRadioMenuItemClass;
36 #endif /* DOXYGEN_SHOULD_SKIP_THIS */
37
38
39 namespace Gtk
40 { class RadioMenuItem_Class; } // namespace Gtk
41 namespace Gtk
42 {
43
44 class RadioMenuItem;
45
46 /** A CheckMenuItem that belongs to a group.
47  * At each instant exactly one of the menu items from a group is selected.
48  * @ingroup Menus
49  * @ingroup Widgets
50  */
51
52 class RadioMenuItem : public CheckMenuItem
53 {
54   public:
55 #ifndef DOXYGEN_SHOULD_SKIP_THIS
56   typedef RadioMenuItem CppObjectType;
57   typedef RadioMenuItem_Class CppClassType;
58   typedef GtkRadioMenuItem BaseObjectType;
59   typedef GtkRadioMenuItemClass BaseClassType;
60 #endif /* DOXYGEN_SHOULD_SKIP_THIS */
61
62   virtual ~RadioMenuItem();
63
64 #ifndef DOXYGEN_SHOULD_SKIP_THIS
65
66 private:
67   friend class RadioMenuItem_Class;
68   static CppClassType radiomenuitem_class_;
69
70   // noncopyable
71   RadioMenuItem(const RadioMenuItem&);
72   RadioMenuItem& operator=(const RadioMenuItem&);
73
74 protected:
75   explicit RadioMenuItem(const Glib::ConstructParams& construct_params);
76   explicit RadioMenuItem(GtkRadioMenuItem* castitem);
77
78 #endif /* DOXYGEN_SHOULD_SKIP_THIS */
79
80 public:
81 #ifndef DOXYGEN_SHOULD_SKIP_THIS
82   static GType get_type()      G_GNUC_CONST;
83   static GType get_base_type() G_GNUC_CONST;
84 #endif
85
86   ///Provides access to the underlying C GtkObject.
87   GtkRadioMenuItem*       gobj()       { return reinterpret_cast<GtkRadioMenuItem*>(gobject_); }
88
89   ///Provides access to the underlying C GtkObject.
90   const GtkRadioMenuItem* gobj() const { return reinterpret_cast<GtkRadioMenuItem*>(gobject_); }
91
92
93 public:
94   //C++ methods used to invoke GTK+ virtual functions:
95
96 protected:
97   //GTK+ Virtual Functions (override these to change behaviour):
98
99   //Default Signal Handlers::
100   virtual void on_group_changed();
101
102
103 private:
104
105 public:
106   
107   typedef RadioButtonGroup Group;
108
109   RadioMenuItem(Group& groupx);
110   
111   RadioMenuItem(Group& groupx, const Glib::ustring& label, bool mnemonic = false);
112   
113
114   //We ignore the _new_*_from_widget() functions because they are just the same as calling get_group() and set_group() ourselves.
115   
116                     
117   Group get_group();
118   
119   void set_group(Group& group);
120   void reset_group();
121
122   
123   Glib::SignalProxy0< void > signal_group_changed();
124
125
126 protected:
127   void constructor(const Group& group);
128
129
130 };
131
132 } /* namspace Gtk */
133
134
135 namespace Glib
136 {
137   /** @relates Gtk::RadioMenuItem
138    * @param object The C instance
139    * @param take_copy False if the result should take ownership of the C instance. True if it should take a new copy or ref.
140    * @result A C++ instance that wraps this C instance.
141    */
142   Gtk::RadioMenuItem* wrap(GtkRadioMenuItem* object, bool take_copy = false);
143 }
144 #endif /* _GTKMM_RADIOMENUITEM_H */
145