2 // Generated by gtkmmproc -- DO NOT MODIFY!
3 #ifndef _GTKMM_MESSAGEDIALOG_H
4 #define _GTKMM_MESSAGEDIALOG_H
12 * Copyright (C) 1998-2002 The gtkmm Development Team
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.
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.
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.
29 #include <gtkmm/dialog.h>
32 #ifndef DOXYGEN_SHOULD_SKIP_THIS
33 typedef struct _GtkMessageDialog GtkMessageDialog;
34 typedef struct _GtkMessageDialogClass GtkMessageDialogClass;
35 #endif /* DOXYGEN_SHOULD_SKIP_THIS */
39 { class MessageDialog_Class; } // namespace Gtk
44 /** @addtogroup gtkmmEnums Enums and Flags */
60 #ifndef DOXYGEN_SHOULD_SKIP_THIS
65 class Value<Gtk::MessageType> : public Glib::Value_Enum<Gtk::MessageType>
68 static GType value_type() G_GNUC_CONST;
72 #endif /* DOXYGEN_SHOULD_SKIP_THIS */
94 #ifndef DOXYGEN_SHOULD_SKIP_THIS
99 class Value<Gtk::ButtonsType> : public Glib::Value_Enum<Gtk::ButtonsType>
102 static GType value_type() G_GNUC_CONST;
106 #endif /* DOXYGEN_SHOULD_SKIP_THIS */
113 /** Convenient message window.
115 * Gtk::MessageDialog presents a dialog with an image representing the type
116 * of message (Error, Question, etc.) alongside some message text. It's
117 * simply a convenience widget; you could construct the equivalent of
118 * Gtk::MessageDialog from Gtk::Dialog without too much effort, but
119 * Gtk::MessageDialog saves typing.
124 class MessageDialog : public Dialog
127 #ifndef DOXYGEN_SHOULD_SKIP_THIS
128 typedef MessageDialog CppObjectType;
129 typedef MessageDialog_Class CppClassType;
130 typedef GtkMessageDialog BaseObjectType;
131 typedef GtkMessageDialogClass BaseClassType;
132 #endif /* DOXYGEN_SHOULD_SKIP_THIS */
134 virtual ~MessageDialog();
136 #ifndef DOXYGEN_SHOULD_SKIP_THIS
139 friend class MessageDialog_Class;
140 static CppClassType messagedialog_class_;
143 MessageDialog(const MessageDialog&);
144 MessageDialog& operator=(const MessageDialog&);
147 explicit MessageDialog(const Glib::ConstructParams& construct_params);
148 explicit MessageDialog(GtkMessageDialog* castitem);
150 #endif /* DOXYGEN_SHOULD_SKIP_THIS */
153 #ifndef DOXYGEN_SHOULD_SKIP_THIS
154 static GType get_type() G_GNUC_CONST;
155 static GType get_base_type() G_GNUC_CONST;
158 ///Provides access to the underlying C GtkObject.
159 GtkMessageDialog* gobj() { return reinterpret_cast<GtkMessageDialog*>(gobject_); }
161 ///Provides access to the underlying C GtkObject.
162 const GtkMessageDialog* gobj() const { return reinterpret_cast<GtkMessageDialog*>(gobject_); }
166 //C++ methods used to invoke GTK+ virtual functions:
169 //GTK+ Virtual Functions (override these to change behaviour):
171 //Default Signal Handlers::
178 explicit MessageDialog(const Glib::ustring& message, bool use_markup = false, MessageType type = MESSAGE_INFO, ButtonsType buttons = BUTTONS_OK, bool modal = false);
179 MessageDialog(Gtk::Window& parent, const Glib::ustring& message, bool use_markup = false, MessageType type = MESSAGE_INFO, ButtonsType buttons = BUTTONS_OK, bool modal = false);
182 /** @deprecated Use set_message(string, true);
185 /** Sets the text of the message dialog to be @a str , which is marked
186 * up with the Pango text markup
190 * @param str Markup string (see Pango markup format).
192 void set_markup(const Glib::ustring& str);
194 /** Sets the primary text of the message dialog.
196 * @param text The message.
197 * @param use_markup Whether @a message contains pango markup.
199 void set_message(const Glib::ustring& message, bool use_markup = false);
202 /** Sets the secondary text of the message dialog.
203 * Note that setting a secondary text makes the primary text become bold, unless you have provided explicit markup.
207 * @param text The message.
208 * @param use_markup Whether @a message contains pango markup.
210 void set_secondary_text(const Glib::ustring& text, bool use_markup = false);
220 /** @relates Gtk::MessageDialog
221 * @param object The C instance
222 * @param take_copy False if the result should take ownership of the C instance. True if it should take a new copy or ref.
223 * @result A C++ instance that wraps this C instance.
225 Gtk::MessageDialog* wrap(GtkMessageDialog* object, bool take_copy = false);
227 #endif /* _GTKMM_MESSAGEDIALOG_H */