Add a "file_selection_new()" routine that does all the positioning (GTK+
[metze/wireshark/wip.git] / gtk / dlg_utils.h
1 /* dlg_utils.h
2  * Declarations of utilities to use when constructing dialogs
3  *
4  * $Id: dlg_utils.h,v 1.7 2003/09/24 08:43:34 guy Exp $
5  *
6  * Ethereal - Network traffic analyzer
7  * By Gerald Combs <gerald@ethereal.com>
8  * Copyright 1998 Gerald Combs
9  *
10  * This program is free software; you can redistribute it and/or
11  * modify it under the terms of the GNU General Public License
12  * as published by the Free Software Foundation; either version 2
13  * of the License, or (at your option) any later version.
14  *
15  * This program is distributed in the hope that it will be useful,
16  * but WITHOUT ANY WARRANTY; without even the implied warranty of
17  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
18  * GNU General Public License for more details.
19  *
20  * You should have received a copy of the GNU General Public License
21  * along with this program; if not, write to the Free Software
22  * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
23  */
24
25 #ifndef __DLG_UTILS_H__
26 #define __DLG_UTILS_H__
27
28 /* Create a dialog box window that belongs to Ethereal's main window. */
29 GtkWidget *dlg_window_new(const gchar *);
30
31 /* Create a file selection dialog box window that belongs to Ethereal's
32    main window. */
33 GtkWidget *file_selection_new(const gchar *);
34
35 /* Set the "activate" signal for a widget to call a routine to
36    activate the "OK" button for a dialog box. */
37 void dlg_set_activate(GtkWidget *widget, GtkWidget *ok_button);
38
39 /* Set the "key_press_event" signal for a top-level dialog window to
40    call a routine to activate the "Cancel" button for a dialog box if
41    the key being pressed is the <Esc> key. */
42 void dlg_set_cancel(GtkWidget *widget, GtkWidget *cancel_button);
43
44 GtkWidget *dlg_radio_button_new_with_label_with_mnemonic(GSList *group,
45     const gchar *label, GtkAccelGroup *accel_group);
46 GtkWidget *dlg_check_button_new_with_label_with_mnemonic(const gchar *label,
47     GtkAccelGroup *accel_group);
48
49 #endif