<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> <html><head><meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1"> <title>Gtk::Dialog class Reference</title> <link href="doxygen.css" rel="stylesheet" type="text/css"> </head> <body bgcolor="#ffffff"> <table border="0" width="100%"> <tr> <td width="10%" height="40"><img src="../../images/gtkmm_logo.gif" alt="logo" border="0" width="100%" height="100%"/></td> <td width="90%" height="40"><img src="../../images/top.gif" alt="top" width="100%" height="40"/></td> </tr> </table> <center> <a class="qindex" href="../../index.html">Main Page</a> <a href="group__Widgets.html">Widgets</a> <a class="qindex" href="namespaces.html"> Namespaces</a> <a href="../../tutorial/html/index.html"> Book</a> </center> <hr width="100%"/> <!-- Generated by Doxygen 1.3-rc1 --> <h1>Gtk::Dialog Class Reference<br> <small> [<a class="el" href="group__Dialogs.html">Dialogs</a>]</small> </h1>Create popup windows. <a href="#_details">More...</a> <p> Inheritance diagram for Gtk::Dialog:<p><center><img src="classGtk_1_1Dialog__inherit__graph.png" border="0" usemap="#Gtk_1_1Dialog__inherit__map" alt="Inheritance graph"></center> <map name="Gtk_1_1Dialog__inherit__map"> <area href="classGtk_1_1ColorSelectionDialog.html" shape="rect" coords="7,572,167,590" alt=""> <area href="classGtk_1_1FileSelection.html" shape="rect" coords="191,572,305,590" alt=""> <area href="classGtk_1_1FontSelectionDialog.html" shape="rect" coords="329,572,484,590" alt=""> <area href="classGtk_1_1InputDialog.html" shape="rect" coords="508,572,612,590" alt=""> <area href="classGtk_1_1MessageDialog.html" shape="rect" coords="636,572,761,590" alt=""> <area href="classGtk_1_1Window.html" shape="rect" coords="364,433,449,452" alt=""> <area href="classGtk_1_1Bin.html" shape="rect" coords="379,364,435,382" alt=""> <area href="classGtk_1_1Container.html" shape="rect" coords="359,294,455,313" alt=""> <area href="classGtk_1_1Widget.html" shape="rect" coords="368,225,445,244" alt=""> <area href="classGtk_1_1Object.html" shape="rect" coords="368,156,445,174" alt=""> <area href="classGlib_1_1Object.html" shape="rect" coords="367,86,447,105" alt=""> <area href="classGlib_1_1ObjectBase.html" shape="rect" coords="352,17,461,36" alt=""> </map> <center><font size="2">[<a href="graph_legend.html">legend</a>]</font></center><a href="classGtk_1_1Dialog-members.html">List of all members.</a><table border=0 cellpadding=0 cellspacing=0> <tr><td></td></tr> <tr><td colspan=2><br><h2>Public Methods</h2></td></tr> <tr><td nowrap align=right valign=top>virtual </td><td valign=bottom><a class="el" href="classGtk_1_1Dialog.html#a0">~Dialog</a> ()</td></tr> <tr><td nowrap align=right valign=top>GtkDialog* </td><td valign=bottom><a class="el" href="classGtk_1_1Dialog.html#a1">gobj</a> ()</td></tr> <tr><td nowrap align=right valign=top>const GtkDialog* </td><td valign=bottom><a class="el" href="classGtk_1_1Dialog.html#a2">gobj</a> () const</td></tr> <tr><td nowrap align=right valign=top> </td><td valign=bottom><a class="el" href="classGtk_1_1Dialog.html#a3">Dialog</a> ()</td></tr> <tr><td nowrap align=right valign=top> </td><td valign=bottom><a class="el" href="classGtk_1_1Dialog.html#a4">Dialog</a> (const <a class="el" href="classGlib_1_1ustring.html">Glib::ustring</a>& title, bool modal=false, bool use_separator=false)</td></tr> <tr><td nowrap align=right valign=top> </td><td valign=bottom><a class="el" href="classGtk_1_1Dialog.html#a5">Dialog</a> (const <a class="el" href="classGlib_1_1ustring.html">Glib::ustring</a>& title, <a class="el" href="classGtk_1_1Window.html">Gtk::Window</a>& parent, bool modal=false, bool use_separator=false)</td></tr> <tr><td nowrap align=right valign=top>void </td><td valign=bottom><a class="el" href="classGtk_1_1Dialog.html#a6">add_action_widget</a> (<a class="el" href="classGtk_1_1Widget.html">Widget</a>& child, int response_id)</td></tr> <tr><td> </td><td><font size=-1><em>Adds an activatable widget to the action area of a Gtk::Dialog, connecting a signal handler that will emit the "response" signal on the dialog when the widget is activated.</em> <a href="#a6"></a><em></em></font><br><br></td></tr> <tr><td nowrap align=right valign=top><a class="el" href="classGtk_1_1Button.html">Button</a>* </td><td valign=bottom><a class="el" href="classGtk_1_1Dialog.html#a7">add_button</a> (const <a class="el" href="classGlib_1_1ustring.html">Glib::ustring</a>& button_text, int response_id)</td></tr> <tr><td> </td><td><font size=-1><em>Adds a button with the given text (or a stock button, if <em>button_text</em> is a stock ID) and sets things up so that clicking the button will emit the "response" signal with the given <em>response_id</em> .</em> <a href="#a7"></a><em></em></font><br><br></td></tr> <tr><td nowrap align=right valign=top><a class="el" href="classGtk_1_1Button.html">Button</a>* </td><td valign=bottom><a class="el" href="classGtk_1_1Dialog.html#a8">add_button</a> (const <a class="el" href="classGtk_1_1StockID.html">Gtk::StockID</a>& stock_id, int response_id)</td></tr> <tr><td> </td><td><font size=-1><em>Adds a button with the given text (or a stock button, if <em>button_text</em> is a stock ID) and sets things up so that clicking the button will emit the "response" signal with the given <em>response_id</em> .</em> <a href="#a8"></a><em></em></font><br><br></td></tr> <tr><td nowrap align=right valign=top>void </td><td valign=bottom><a class="el" href="classGtk_1_1Dialog.html#a9">set_response_sensitive</a> (int response_id, bool setting=true)</td></tr> <tr><td> </td><td><font size=-1><em>Calls <code>gtk_widget_set_sensitive (widget, <em>setting</em> )</code> for each widget in the dialog's action area with the given <em>response_id</em> .</em> <a href="#a9"></a><em></em></font><br><br></td></tr> <tr><td nowrap align=right valign=top>void </td><td valign=bottom><a class="el" href="classGtk_1_1Dialog.html#a10">set_default_response</a> (int response_id)</td></tr> <tr><td> </td><td><font size=-1><em>Sets the last widget in the dialog's action area with the given <em>response_id</em> as the default widget for the dialog.</em> <a href="#a10"></a><em></em></font><br><br></td></tr> <tr><td nowrap align=right valign=top>void </td><td valign=bottom><a class="el" href="classGtk_1_1Dialog.html#a11">set_has_separator</a> (bool setting=true)</td></tr> <tr><td> </td><td><font size=-1><em>Sets whether the dialog has a separator above the buttons.</em> <a href="#a11"></a><em></em></font><br><br></td></tr> <tr><td nowrap align=right valign=top>bool </td><td valign=bottom><a class="el" href="classGtk_1_1Dialog.html#a12">get_has_separator</a> () const</td></tr> <tr><td> </td><td><font size=-1><em>Accessor for whether the dialog has a separator.</em> <a href="#a12"></a><em></em></font><br><br></td></tr> <tr><td nowrap align=right valign=top>void </td><td valign=bottom><a class="el" href="classGtk_1_1Dialog.html#a13">response</a> (int response_id)</td></tr> <tr><td> </td><td><font size=-1><em>Emits the "response" signal with the given response ID.</em> <a href="#a13"></a><em></em></font><br><br></td></tr> <tr><td nowrap align=right valign=top>int </td><td valign=bottom><a class="el" href="classGtk_1_1Dialog.html#a14">run</a> ()</td></tr> <tr><td> </td><td><font size=-1><em>Blocks in a recursive main loop until the <em>dialog</em> emits the response signal.</em> <a href="#a14"></a><em></em></font><br><br></td></tr> <tr><td nowrap align=right valign=top><a class="el" href="classGtk_1_1VBox.html">VBox</a>* </td><td valign=bottom><a class="el" href="classGtk_1_1Dialog.html#a15">get_vbox</a> ()</td></tr> <tr><td nowrap align=right valign=top>const <a class="el" href="classGtk_1_1VBox.html">VBox</a>* </td><td valign=bottom><a class="el" href="classGtk_1_1Dialog.html#a16">get_vbox</a> () const</td></tr> <tr><td nowrap align=right valign=top><a class="el" href="classGtk_1_1HButtonBox.html">HButtonBox</a>* </td><td valign=bottom><a class="el" href="classGtk_1_1Dialog.html#a17">get_action_area</a> ()</td></tr> <tr><td nowrap align=right valign=top>const <a class="el" href="classGtk_1_1HButtonBox.html">HButtonBox</a>* </td><td valign=bottom><a class="el" href="classGtk_1_1Dialog.html#a18">get_action_area</a> () const</td></tr> <tr><td nowrap align=right valign=top><a class="el" href="classGlib_1_1PropertyProxy.html">Glib::PropertyProxy</a><bool> </td><td valign=bottom><a class="el" href="classGtk_1_1Dialog.html#a19">property_has_separator</a> ()</td></tr> <tr><td nowrap align=right valign=top><a class="el" href="classGlib_1_1SignalProxy1.html">Glib::SignalProxy1</a>< void,<br> int > </td><td valign=bottom><a class="el" href="classGtk_1_1Dialog.html#a20">signal_response</a> ()</td></tr> <tr><td nowrap align=right valign=top><a class="el" href="classGlib_1_1SignalProxy0.html">Glib::SignalProxy0</a><void> </td><td valign=bottom><a class="el" href="classGtk_1_1Dialog.html#a21">signal_close</a> ()</td></tr> <tr><td colspan=2><br><h2>Protected Methods</h2></td></tr> <tr><td nowrap align=right valign=top>virtual void </td><td valign=bottom><a class="el" href="classGtk_1_1Dialog.html#b0">on_response</a> (int response_id)</td></tr> <tr><td nowrap align=right valign=top>virtual void </td><td valign=bottom><a class="el" href="classGtk_1_1Dialog.html#b1">on_close</a> ()</td></tr> <tr><td nowrap align=right valign=top>void </td><td valign=bottom><a class="el" href="classGtk_1_1Dialog.html#b2">construct_</a> (bool modal, bool use_separator)</td></tr> <tr><td colspan=2><br><h2>Related Functions</h2></td></tr> <tr><td colspan=2>(Note that these are not member functions.)<br><br></td></tr> <tr><td nowrap align=right valign=top>Gtk::Dialog* </td><td valign=bottom><a class="el" href="classGtk_1_1Dialog.html#k0">wrap</a> (GtkDialog* object, bool take_copy=false)</td></tr> </table> <hr><a name="_details"></a><h2>Detailed Description</h2> Create popup windows. <p> <a class="el" href="classGtk_1_1Dialog.html">Dialog</a> boxes are a convenient way to prompt the user for a small amount of input, eg. to display a message, ask a question, or anything else that does not require extensive effort on the user's part. <p> gtkmm treats a dialog as a window split vertically. The top section is a <a class="el" href="classGtk_1_1VBox.html">Gtk::VBox</a>, and is where widgets such as a <a class="el" href="classGtk_1_1Label.html">Gtk::Label</a> or a <a class="el" href="classGtk_1_1Entry.html">Gtk::Entry</a> should be packed. The bottom area is known as the action_area. This is generally used for packing buttons into the dialog which may perform functions such as cancel, ok, or apply. The two areas are separated by a <a class="el" href="classGtk_1_1HSeparator.html">Gtk::HSeparator</a>. <p> The dialog can be 'modal' (that is, one which freezes the rest of the application from user input) - this can be specified in the Gtk::Dialog constructor. <p> When adding buttons using <a class="el" href="classGtk_1_1Dialog.html#a7">add_button()</a>, clicking the button will emit <a class="el" href="classGtk_1_1Dialog.html#a20">signal_response()</a> with a "response id" you specified. You are encouraged to use the <a class="el" href="group__gtkmmEnums.html#a60">Gtk::ResponseType</a> enum. If a dialog receives a delete event, the "response" signal will be emitted with a response id of <a class="el" href="group__gtkmmEnums.html#a60a16">Gtk::RESPONSE_NONE</a>. <p> If you want to block waiting for a dialog to return before returning control flow to your code, you can call <a class="el" href="classGtk_1_1Dialog.html#a14">run()</a>. This function enters a recursive main loop and waits for the user to respond to the dialog, returning the response ID corresponding to the button the user clicked. <p> <hr><h2>Constructor & Destructor Documentation</h2> <a name="a0" doxytag="Gtk::Dialog::~Dialog"></a><p> <table width="100%" cellpadding="2" cellspacing="0" border="0"> <tr> <td class="md"> <table cellpadding="0" cellspacing="0" border="0"> <tr> <td class="md" nowrap valign="top"> virtual Gtk::Dialog::~Dialog </td> <td class="md" valign="top">(</td> <td class="mdname1" valign="top" nowrap> </td> <td class="md" valign="top">) </td> <td class="md" nowrap><code> [virtual]</code></td> </tr> </table> </td> </tr> </table> <table cellspacing=5 cellpadding=0 border=0> <tr> <td> </td> <td> <p> </td> </tr> </table> <a name="a3" doxytag="Gtk::Dialog::Dialog"></a><p> <table width="100%" cellpadding="2" cellspacing="0" border="0"> <tr> <td class="md"> <table cellpadding="0" cellspacing="0" border="0"> <tr> <td class="md" nowrap valign="top"> Gtk::Dialog::Dialog </td> <td class="md" valign="top">(</td> <td class="mdname1" valign="top" nowrap> </td> <td class="md" valign="top">) </td> <td class="md" nowrap></td> </tr> </table> </td> </tr> </table> <table cellspacing=5 cellpadding=0 border=0> <tr> <td> </td> <td> <p> </td> </tr> </table> <a name="a4" doxytag="Gtk::Dialog::Dialog"></a><p> <table width="100%" cellpadding="2" cellspacing="0" border="0"> <tr> <td class="md"> <table cellpadding="0" cellspacing="0" border="0"> <tr> <td class="md" nowrap valign="top"> Gtk::Dialog::Dialog </td> <td class="md" valign="top">(</td> <td class="md" nowrap valign="top">const <a class="el" href="classGlib_1_1ustring.html">Glib::ustring</a>& </td> <td class="mdname" nowrap> <em>title</em>, </td> </tr> <tr> <td></td> <td></td> <td class="md" nowrap>bool </td> <td class="mdname" nowrap> <em>modal</em> = false, </td> </tr> <tr> <td></td> <td></td> <td class="md" nowrap>bool </td> <td class="mdname" nowrap> <em>use_separator</em> = false</td> </tr> <tr> <td></td> <td class="md">) </td> <td class="md" colspan="2"><code> [explicit]</code></td> </tr> </table> </td> </tr> </table> <table cellspacing=5 cellpadding=0 border=0> <tr> <td> </td> <td> <p> </td> </tr> </table> <a name="a5" doxytag="Gtk::Dialog::Dialog"></a><p> <table width="100%" cellpadding="2" cellspacing="0" border="0"> <tr> <td class="md"> <table cellpadding="0" cellspacing="0" border="0"> <tr> <td class="md" nowrap valign="top"> Gtk::Dialog::Dialog </td> <td class="md" valign="top">(</td> <td class="md" nowrap valign="top">const <a class="el" href="classGlib_1_1ustring.html">Glib::ustring</a>& </td> <td class="mdname" nowrap> <em>title</em>, </td> </tr> <tr> <td></td> <td></td> <td class="md" nowrap><a class="el" href="classGtk_1_1Window.html">Gtk::Window</a>& </td> <td class="mdname" nowrap> <em>parent</em>, </td> </tr> <tr> <td></td> <td></td> <td class="md" nowrap>bool </td> <td class="mdname" nowrap> <em>modal</em> = false, </td> </tr> <tr> <td></td> <td></td> <td class="md" nowrap>bool </td> <td class="mdname" nowrap> <em>use_separator</em> = false</td> </tr> <tr> <td></td> <td class="md">) </td> <td class="md" colspan="2"></td> </tr> </table> </td> </tr> </table> <table cellspacing=5 cellpadding=0 border=0> <tr> <td> </td> <td> <p> </td> </tr> </table> <hr><h2>Member Function Documentation</h2> <a name="a6" doxytag="Gtk::Dialog::add_action_widget"></a><p> <table width="100%" cellpadding="2" cellspacing="0" border="0"> <tr> <td class="md"> <table cellpadding="0" cellspacing="0" border="0"> <tr> <td class="md" nowrap valign="top"> void Gtk::Dialog::add_action_widget </td> <td class="md" valign="top">(</td> <td class="md" nowrap valign="top"><a class="el" href="classGtk_1_1Widget.html">Widget</a>& </td> <td class="mdname" nowrap> <em>child</em>, </td> </tr> <tr> <td></td> <td></td> <td class="md" nowrap>int </td> <td class="mdname" nowrap> <em>response_id</em></td> </tr> <tr> <td></td> <td class="md">) </td> <td class="md" colspan="2"></td> </tr> </table> </td> </tr> </table> <table cellspacing=5 cellpadding=0 border=0> <tr> <td> </td> <td> <p> Adds an activatable widget to the action area of a Gtk::Dialog, connecting a signal handler that will emit the "response" signal on the dialog when the widget is activated. <p> The widget is appended to the end of the dialog's action area. If you want to add a non-activatable widget, simply pack it into the <code>action_area</code> field of the Gtk::Dialog struct. <dl compact><dt><b>Parameters:</b></dt><dd> <table border="0" cellspacing="2" cellpadding="0"> <tr><td valign=top><em>child</em> </td><td>An activatable widget. </td></tr> <tr><td valign=top><em>response_id</em> </td><td>Response ID for <em>child</em> . </td></tr> </table> </dl> </td> </tr> </table> <a name="a8" doxytag="Gtk::Dialog::add_button"></a><p> <table width="100%" cellpadding="2" cellspacing="0" border="0"> <tr> <td class="md"> <table cellpadding="0" cellspacing="0" border="0"> <tr> <td class="md" nowrap valign="top"> <a class="el" href="classGtk_1_1Button.html">Button</a>* Gtk::Dialog::add_button </td> <td class="md" valign="top">(</td> <td class="md" nowrap valign="top">const <a class="el" href="classGtk_1_1StockID.html">Gtk::StockID</a>& </td> <td class="mdname" nowrap> <em>stock_id</em>, </td> </tr> <tr> <td></td> <td></td> <td class="md" nowrap>int </td> <td class="mdname" nowrap> <em>response_id</em></td> </tr> <tr> <td></td> <td class="md">) </td> <td class="md" colspan="2"></td> </tr> </table> </td> </tr> </table> <table cellspacing=5 cellpadding=0 border=0> <tr> <td> </td> <td> <p> Adds a button with the given text (or a stock button, if <em>button_text</em> is a stock ID) and sets things up so that clicking the button will emit the "response" signal with the given <em>response_id</em> . <p> The button is appended to the end of the dialog's action area. The button widget is returned, but usually you don't need it. <dl compact><dt><b>Parameters:</b></dt><dd> <table border="0" cellspacing="2" cellpadding="0"> <tr><td valign=top><em>button_text</em> </td><td>Text of button, or stock ID. </td></tr> <tr><td valign=top><em>response_id</em> </td><td>Response ID for the button. </td></tr> </table> </dl> <dl compact><dt><b>Returns:</b></dt><dd>The button widget that was added. </dd></dl> </td> </tr> </table> <a name="a7" doxytag="Gtk::Dialog::add_button"></a><p> <table width="100%" cellpadding="2" cellspacing="0" border="0"> <tr> <td class="md"> <table cellpadding="0" cellspacing="0" border="0"> <tr> <td class="md" nowrap valign="top"> <a class="el" href="classGtk_1_1Button.html">Button</a>* Gtk::Dialog::add_button </td> <td class="md" valign="top">(</td> <td class="md" nowrap valign="top">const <a class="el" href="classGlib_1_1ustring.html">Glib::ustring</a>& </td> <td class="mdname" nowrap> <em>button_text</em>, </td> </tr> <tr> <td></td> <td></td> <td class="md" nowrap>int </td> <td class="mdname" nowrap> <em>response_id</em></td> </tr> <tr> <td></td> <td class="md">) </td> <td class="md" colspan="2"></td> </tr> </table> </td> </tr> </table> <table cellspacing=5 cellpadding=0 border=0> <tr> <td> </td> <td> <p> Adds a button with the given text (or a stock button, if <em>button_text</em> is a stock ID) and sets things up so that clicking the button will emit the "response" signal with the given <em>response_id</em> . <p> The button is appended to the end of the dialog's action area. The button widget is returned, but usually you don't need it. <dl compact><dt><b>Parameters:</b></dt><dd> <table border="0" cellspacing="2" cellpadding="0"> <tr><td valign=top><em>button_text</em> </td><td>Text of button, or stock ID. </td></tr> <tr><td valign=top><em>response_id</em> </td><td>Response ID for the button. </td></tr> </table> </dl> <dl compact><dt><b>Returns:</b></dt><dd>The button widget that was added. </dd></dl> </td> </tr> </table> <a name="b2" doxytag="Gtk::Dialog::construct_"></a><p> <table width="100%" cellpadding="2" cellspacing="0" border="0"> <tr> <td class="md"> <table cellpadding="0" cellspacing="0" border="0"> <tr> <td class="md" nowrap valign="top"> void Gtk::Dialog::construct_ </td> <td class="md" valign="top">(</td> <td class="md" nowrap valign="top">bool </td> <td class="mdname" nowrap> <em>modal</em>, </td> </tr> <tr> <td></td> <td></td> <td class="md" nowrap>bool </td> <td class="mdname" nowrap> <em>use_separator</em></td> </tr> <tr> <td></td> <td class="md">) </td> <td class="md" colspan="2"><code> [protected]</code></td> </tr> </table> </td> </tr> </table> <table cellspacing=5 cellpadding=0 border=0> <tr> <td> </td> <td> <p> </td> </tr> </table> <a name="a18" doxytag="Gtk::Dialog::get_action_area"></a><p> <table width="100%" cellpadding="2" cellspacing="0" border="0"> <tr> <td class="md"> <table cellpadding="0" cellspacing="0" border="0"> <tr> <td class="md" nowrap valign="top"> const <a class="el" href="classGtk_1_1HButtonBox.html">HButtonBox</a>* Gtk::Dialog::get_action_area </td> <td class="md" valign="top">(</td> <td class="mdname1" valign="top" nowrap> </td> <td class="md" valign="top">) </td> <td class="md" nowrap> const</td> </tr> </table> </td> </tr> </table> <table cellspacing=5 cellpadding=0 border=0> <tr> <td> </td> <td> <p> <p> Reimplemented in <a class="el" href="classGtk_1_1FileSelection.html#a34">Gtk::FileSelection</a>. </td> </tr> </table> <a name="a17" doxytag="Gtk::Dialog::get_action_area"></a><p> <table width="100%" cellpadding="2" cellspacing="0" border="0"> <tr> <td class="md"> <table cellpadding="0" cellspacing="0" border="0"> <tr> <td class="md" nowrap valign="top"> <a class="el" href="classGtk_1_1HButtonBox.html">HButtonBox</a>* Gtk::Dialog::get_action_area </td> <td class="md" valign="top">(</td> <td class="mdname1" valign="top" nowrap> </td> <td class="md" valign="top">) </td> <td class="md" nowrap></td> </tr> </table> </td> </tr> </table> <table cellspacing=5 cellpadding=0 border=0> <tr> <td> </td> <td> <p> <p> Reimplemented in <a class="el" href="classGtk_1_1FileSelection.html#a33">Gtk::FileSelection</a>. </td> </tr> </table> <a name="a12" doxytag="Gtk::Dialog::get_has_separator"></a><p> <table width="100%" cellpadding="2" cellspacing="0" border="0"> <tr> <td class="md"> <table cellpadding="0" cellspacing="0" border="0"> <tr> <td class="md" nowrap valign="top"> bool Gtk::Dialog::get_has_separator </td> <td class="md" valign="top">(</td> <td class="mdname1" valign="top" nowrap> </td> <td class="md" valign="top">) </td> <td class="md" nowrap> const</td> </tr> </table> </td> </tr> </table> <table cellspacing=5 cellpadding=0 border=0> <tr> <td> </td> <td> <p> Accessor for whether the dialog has a separator. <p> <dl compact><dt><b>Returns:</b></dt><dd><code>true</code> if the dialog has a separator. </dd></dl> </td> </tr> </table> <a name="a16" doxytag="Gtk::Dialog::get_vbox"></a><p> <table width="100%" cellpadding="2" cellspacing="0" border="0"> <tr> <td class="md"> <table cellpadding="0" cellspacing="0" border="0"> <tr> <td class="md" nowrap valign="top"> const <a class="el" href="classGtk_1_1VBox.html">VBox</a>* Gtk::Dialog::get_vbox </td> <td class="md" valign="top">(</td> <td class="mdname1" valign="top" nowrap> </td> <td class="md" valign="top">) </td> <td class="md" nowrap> const</td> </tr> </table> </td> </tr> </table> <table cellspacing=5 cellpadding=0 border=0> <tr> <td> </td> <td> <p> </td> </tr> </table> <a name="a15" doxytag="Gtk::Dialog::get_vbox"></a><p> <table width="100%" cellpadding="2" cellspacing="0" border="0"> <tr> <td class="md"> <table cellpadding="0" cellspacing="0" border="0"> <tr> <td class="md" nowrap valign="top"> <a class="el" href="classGtk_1_1VBox.html">VBox</a>* Gtk::Dialog::get_vbox </td> <td class="md" valign="top">(</td> <td class="mdname1" valign="top" nowrap> </td> <td class="md" valign="top">) </td> <td class="md" nowrap></td> </tr> </table> </td> </tr> </table> <table cellspacing=5 cellpadding=0 border=0> <tr> <td> </td> <td> <p> </td> </tr> </table> <a name="a2" doxytag="Gtk::Dialog::gobj"></a><p> <table width="100%" cellpadding="2" cellspacing="0" border="0"> <tr> <td class="md"> <table cellpadding="0" cellspacing="0" border="0"> <tr> <td class="md" nowrap valign="top"> const GtkDialog* Gtk::Dialog::gobj </td> <td class="md" valign="top">(</td> <td class="mdname1" valign="top" nowrap> </td> <td class="md" valign="top">) </td> <td class="md" nowrap> const<code> [inline]</code></td> </tr> </table> </td> </tr> </table> <table cellspacing=5 cellpadding=0 border=0> <tr> <td> </td> <td> <p> <p> Reimplemented from <a class="el" href="classGtk_1_1Window.html#a2">Gtk::Window</a>. <p> Reimplemented in <a class="el" href="classGtk_1_1ColorSelectionDialog.html#a2">Gtk::ColorSelectionDialog</a>, <a class="el" href="classGtk_1_1FileSelection.html#a2">Gtk::FileSelection</a>, <a class="el" href="classGtk_1_1FontSelectionDialog.html#a2">Gtk::FontSelectionDialog</a>, <a class="el" href="classGtk_1_1InputDialog.html#a2">Gtk::InputDialog</a>, and <a class="el" href="classGtk_1_1MessageDialog.html#a2">Gtk::MessageDialog</a>. </td> </tr> </table> <a name="a1" doxytag="Gtk::Dialog::gobj"></a><p> <table width="100%" cellpadding="2" cellspacing="0" border="0"> <tr> <td class="md"> <table cellpadding="0" cellspacing="0" border="0"> <tr> <td class="md" nowrap valign="top"> GtkDialog* Gtk::Dialog::gobj </td> <td class="md" valign="top">(</td> <td class="mdname1" valign="top" nowrap> </td> <td class="md" valign="top">) </td> <td class="md" nowrap><code> [inline]</code></td> </tr> </table> </td> </tr> </table> <table cellspacing=5 cellpadding=0 border=0> <tr> <td> </td> <td> <p> <p> Reimplemented from <a class="el" href="classGtk_1_1Window.html#a1">Gtk::Window</a>. <p> Reimplemented in <a class="el" href="classGtk_1_1ColorSelectionDialog.html#a1">Gtk::ColorSelectionDialog</a>, <a class="el" href="classGtk_1_1FileSelection.html#a1">Gtk::FileSelection</a>, <a class="el" href="classGtk_1_1FontSelectionDialog.html#a1">Gtk::FontSelectionDialog</a>, <a class="el" href="classGtk_1_1InputDialog.html#a1">Gtk::InputDialog</a>, and <a class="el" href="classGtk_1_1MessageDialog.html#a1">Gtk::MessageDialog</a>. </td> </tr> </table> <a name="b1" doxytag="Gtk::Dialog::on_close"></a><p> <table width="100%" cellpadding="2" cellspacing="0" border="0"> <tr> <td class="md"> <table cellpadding="0" cellspacing="0" border="0"> <tr> <td class="md" nowrap valign="top"> virtual void Gtk::Dialog::on_close </td> <td class="md" valign="top">(</td> <td class="mdname1" valign="top" nowrap> </td> <td class="md" valign="top">) </td> <td class="md" nowrap><code> [protected, virtual]</code></td> </tr> </table> </td> </tr> </table> <table cellspacing=5 cellpadding=0 border=0> <tr> <td> </td> <td> <p> </td> </tr> </table> <a name="b0" doxytag="Gtk::Dialog::on_response"></a><p> <table width="100%" cellpadding="2" cellspacing="0" border="0"> <tr> <td class="md"> <table cellpadding="0" cellspacing="0" border="0"> <tr> <td class="md" nowrap valign="top"> virtual void Gtk::Dialog::on_response </td> <td class="md" valign="top">(</td> <td class="md" nowrap valign="top">int </td> <td class="mdname1" valign="top" nowrap> <em>response_id</em> </td> <td class="md" valign="top">) </td> <td class="md" nowrap><code> [protected, virtual]</code></td> </tr> </table> </td> </tr> </table> <table cellspacing=5 cellpadding=0 border=0> <tr> <td> </td> <td> <p> </td> </tr> </table> <a name="a19" doxytag="Gtk::Dialog::property_has_separator"></a><p> <table width="100%" cellpadding="2" cellspacing="0" border="0"> <tr> <td class="md"> <table cellpadding="0" cellspacing="0" border="0"> <tr> <td class="md" nowrap valign="top"> <a class="el" href="classGlib_1_1PropertyProxy.html">Glib::PropertyProxy</a><bool> Gtk::Dialog::property_has_separator </td> <td class="md" valign="top">(</td> <td class="mdname1" valign="top" nowrap> </td> <td class="md" valign="top">) </td> <td class="md" nowrap></td> </tr> </table> </td> </tr> </table> <table cellspacing=5 cellpadding=0 border=0> <tr> <td> </td> <td> <p> </td> </tr> </table> <a name="a13" doxytag="Gtk::Dialog::response"></a><p> <table width="100%" cellpadding="2" cellspacing="0" border="0"> <tr> <td class="md"> <table cellpadding="0" cellspacing="0" border="0"> <tr> <td class="md" nowrap valign="top"> void Gtk::Dialog::response </td> <td class="md" valign="top">(</td> <td class="md" nowrap valign="top">int </td> <td class="mdname1" valign="top" nowrap> <em>response_id</em> </td> <td class="md" valign="top">) </td> <td class="md" nowrap></td> </tr> </table> </td> </tr> </table> <table cellspacing=5 cellpadding=0 border=0> <tr> <td> </td> <td> <p> Emits the "response" signal with the given response ID. <p> Used to indicate that the user has responded to the dialog in some way; typically either you or <a class="el" href="classGtk_1_1Dialog.html#a14">run()</a> will be monitoring the "response" signal and take appropriate action. <dl compact><dt><b>Parameters:</b></dt><dd> <table border="0" cellspacing="2" cellpadding="0"> <tr><td valign=top><em>response_id</em> </td><td>Response ID. </td></tr> </table> </dl> </td> </tr> </table> <a name="a14" doxytag="Gtk::Dialog::run"></a><p> <table width="100%" cellpadding="2" cellspacing="0" border="0"> <tr> <td class="md"> <table cellpadding="0" cellspacing="0" border="0"> <tr> <td class="md" nowrap valign="top"> int Gtk::Dialog::run </td> <td class="md" valign="top">(</td> <td class="mdname1" valign="top" nowrap> </td> <td class="md" valign="top">) </td> <td class="md" nowrap></td> </tr> </table> </td> </tr> </table> <table cellspacing=5 cellpadding=0 border=0> <tr> <td> </td> <td> <p> Blocks in a recursive main loop until the <em>dialog</em> emits the response signal. <p> It returns the response ID from the "response" signal emission. Before entering the recursive main loop, <a class="el" href="classGtk_1_1Dialog.html#a14">run()</a> calls <a class="el" href="classGtk_1_1Widget.html#a4">Gtk::Widget::show()</a> on the dialog for you. Note that you still need to show any children of the dialog yourself. <p> If the dialog receives "delete_event", <a class="el" href="classGtk_1_1Dialog.html#a14">Gtk::Dialog::run()</a> will return <a class="el" href="group__gtkmmEnums.html#a60a19">Gtk::RESPONSE_DELETE_EVENT</a>. Also, during <a class="el" href="classGtk_1_1Dialog.html#a14">Gtk::Dialog::run()</a> the dialog will be modal. You can force <a class="el" href="classGtk_1_1Dialog.html#a14">Gtk::Dialog::run()</a> to return at any time by calling <a class="el" href="classGtk_1_1Dialog.html#a13">Gtk::Dialog::response()</a> to emit the "response" signal. <p> After <a class="el" href="classGtk_1_1Dialog.html#a14">Gtk::Dialog::run()</a> returns, you are responsible for hiding or destroying the dialog if you wish to do so. <p> Typical usage of this function might be: <div class="fragment"><pre> <tt><span class="keywordtype">int</span></tt> result = dialog.run(); <span class="keywordflow">switch</span> (result) { <span class="keywordflow">case</span> GTK_RESPONSE_ACCEPT: do_application_specific_something (&lt;!-- --&gt;); <span class="keywordflow">break</span>; <span class="keywordflow">default</span>: do_nothing_since_dialog_was_cancelled (&lt;!-- --&gt;); <span class="keywordflow">break</span>; } </pre></div><dl compact><dt><b>Returns:</b></dt><dd>Response ID. </dd></dl> </td> </tr> </table> <a name="a10" doxytag="Gtk::Dialog::set_default_response"></a><p> <table width="100%" cellpadding="2" cellspacing="0" border="0"> <tr> <td class="md"> <table cellpadding="0" cellspacing="0" border="0"> <tr> <td class="md" nowrap valign="top"> void Gtk::Dialog::set_default_response </td> <td class="md" valign="top">(</td> <td class="md" nowrap valign="top">int </td> <td class="mdname1" valign="top" nowrap> <em>response_id</em> </td> <td class="md" valign="top">) </td> <td class="md" nowrap></td> </tr> </table> </td> </tr> </table> <table cellspacing=5 cellpadding=0 border=0> <tr> <td> </td> <td> <p> Sets the last widget in the dialog's action area with the given <em>response_id</em> as the default widget for the dialog. <p> Pressing "Enter" normally activates the default widget. <dl compact><dt><b>Parameters:</b></dt><dd> <table border="0" cellspacing="2" cellpadding="0"> <tr><td valign=top><em>response_id</em> </td><td>A response ID. </td></tr> </table> </dl> </td> </tr> </table> <a name="a11" doxytag="Gtk::Dialog::set_has_separator"></a><p> <table width="100%" cellpadding="2" cellspacing="0" border="0"> <tr> <td class="md"> <table cellpadding="0" cellspacing="0" border="0"> <tr> <td class="md" nowrap valign="top"> void Gtk::Dialog::set_has_separator </td> <td class="md" valign="top">(</td> <td class="md" nowrap valign="top">bool </td> <td class="mdname1" valign="top" nowrap> <em>setting</em> = true </td> <td class="md" valign="top">) </td> <td class="md" nowrap></td> </tr> </table> </td> </tr> </table> <table cellspacing=5 cellpadding=0 border=0> <tr> <td> </td> <td> <p> Sets whether the dialog has a separator above the buttons. <p> <code>true</code> by default. <dl compact><dt><b>Parameters:</b></dt><dd> <table border="0" cellspacing="2" cellpadding="0"> <tr><td valign=top><em>setting</em> </td><td><code>true</code> to have a separator. </td></tr> </table> </dl> </td> </tr> </table> <a name="a9" doxytag="Gtk::Dialog::set_response_sensitive"></a><p> <table width="100%" cellpadding="2" cellspacing="0" border="0"> <tr> <td class="md"> <table cellpadding="0" cellspacing="0" border="0"> <tr> <td class="md" nowrap valign="top"> void Gtk::Dialog::set_response_sensitive </td> <td class="md" valign="top">(</td> <td class="md" nowrap valign="top">int </td> <td class="mdname" nowrap> <em>response_id</em>, </td> </tr> <tr> <td></td> <td></td> <td class="md" nowrap>bool </td> <td class="mdname" nowrap> <em>setting</em> = true</td> </tr> <tr> <td></td> <td class="md">) </td> <td class="md" colspan="2"></td> </tr> </table> </td> </tr> </table> <table cellspacing=5 cellpadding=0 border=0> <tr> <td> </td> <td> <p> Calls <code>gtk_widget_set_sensitive (widget, <em>setting</em> )</code> for each widget in the dialog's action area with the given <em>response_id</em> . <p> A convenient way to sensitize/desensitize dialog buttons. <dl compact><dt><b>Parameters:</b></dt><dd> <table border="0" cellspacing="2" cellpadding="0"> <tr><td valign=top><em>response_id</em> </td><td>A response ID. </td></tr> <tr><td valign=top><em>setting</em> </td><td><code>true</code> for sensitive. </td></tr> </table> </dl> </td> </tr> </table> <a name="a21" doxytag="Gtk::Dialog::signal_close"></a><p> <table width="100%" cellpadding="2" cellspacing="0" border="0"> <tr> <td class="md"> <table cellpadding="0" cellspacing="0" border="0"> <tr> <td class="md" nowrap valign="top"> <a class="el" href="classGlib_1_1SignalProxy0.html">Glib::SignalProxy0</a><void> Gtk::Dialog::signal_close </td> <td class="md" valign="top">(</td> <td class="mdname1" valign="top" nowrap> </td> <td class="md" valign="top">) </td> <td class="md" nowrap></td> </tr> </table> </td> </tr> </table> <table cellspacing=5 cellpadding=0 border=0> <tr> <td> </td> <td> <p> <dl compact><dt><b>Prototype:</b></dt><dd><code>void close()</code> </dd></dl> </td> </tr> </table> <a name="a20" doxytag="Gtk::Dialog::signal_response"></a><p> <table width="100%" cellpadding="2" cellspacing="0" border="0"> <tr> <td class="md"> <table cellpadding="0" cellspacing="0" border="0"> <tr> <td class="md" nowrap valign="top"> <a class="el" href="classGlib_1_1SignalProxy1.html">Glib::SignalProxy1</a><void,int> Gtk::Dialog::signal_response </td> <td class="md" valign="top">(</td> <td class="mdname1" valign="top" nowrap> </td> <td class="md" valign="top">) </td> <td class="md" nowrap></td> </tr> </table> </td> </tr> </table> <table cellspacing=5 cellpadding=0 border=0> <tr> <td> </td> <td> <p> <dl compact><dt><b>Prototype:</b></dt><dd><code>void response(int response_id)</code> </dd></dl> </td> </tr> </table> <hr><h2>Friends And Related Function Documentation</h2> <a name="k0" doxytag="Gtk::Dialog::wrap"></a><p> <table width="100%" cellpadding="2" cellspacing="0" border="0"> <tr> <td class="md"> <table cellpadding="0" cellspacing="0" border="0"> <tr> <td class="md" nowrap valign="top"> Gtk::Dialog* wrap </td> <td class="md" valign="top">(</td> <td class="md" nowrap valign="top">GtkDialog* </td> <td class="mdname" nowrap> <em>object</em>, </td> </tr> <tr> <td></td> <td></td> <td class="md" nowrap>bool </td> <td class="mdname" nowrap> <em>take_copy</em> = false</td> </tr> <tr> <td></td> <td class="md">) </td> <td class="md" colspan="2"><code> [related]</code></td> </tr> </table> </td> </tr> </table> <table cellspacing=5 cellpadding=0 border=0> <tr> <td> </td> <td> <p> </td> </tr> </table> <hr>The documentation for this class was generated from the following file:<ul> <li><a class="el" href="dialog_8h.html">dialog.h</a></ul> <hr><address><small> Generated for gtkmm by <a href="http://www.doxygen.org/index.html"> Doxygen</a> 1.3-rc1 © 1997-2001</small></address> </body> </html>