]> git.lyx.org Git - lyx.git/blob - src/frontends/gnome/GUrl.h
applying Martin Craig's gnome patch. Upgrading to gtkmm-2.0+ from the 1.3 developmen...
[lyx.git] / src / frontends / gnome / GUrl.h
1 // -*- C++ -*-
2 /**
3  * \file GUrl.h
4  * This file is part of LyX, the document processor.
5  * Licence details can be found in the file COPYING.
6  *
7  * \author Baruch Even
8  * \author Michael Koziarski
9  *
10  * Full author contact details are available in file CREDITS
11  */
12
13 #ifndef GURL_H
14 #define GURL_H
15
16 #ifdef __GNUG__
17 #pragma interface
18 #endif
19
20 #include "ControlUrl.h"
21 #include "GnomeBase.h"
22
23 namespace Gtk {
24 class Button;
25 class CheckButton;
26 class Entry;
27 }
28
29 /**
30  * This class implements the dialog to insert/modify urls.
31  */
32 class GUrl : public GnomeCB<ControlUrl> {
33 public:
34         ///
35         GUrl();
36         ///
37         ~GUrl();
38
39         void apply();
40         void update();
41
42 private:
43         /// Build the dialog
44         void build();
45
46         /// Returns true if the dialog input is in a valid state.
47         bool validate() const;
48
49         /// Do the connection of signals
50         void connect_signals();
51         /// Disconnect the signals.
52         void disconnect_signals();
53
54         /// generated by accessors.py
55         Gtk::Button * restore_btn() const;
56         /// gene rated by accessors.py
57         Gtk::Button * ok_btn() const;
58         /// generated by accessors.py
59         Gtk::Button * apply_btn() const;
60         /// generated by accessors.py
61         Gtk::Button * cancel_btn() const;
62         /// generated by accessors.py
63         Gtk::Entry * url() const;
64         /// generated by accessors.py
65         Gtk::Entry * name() const;
66         /// generated by accessors.py
67         Gtk::CheckButton * html_cb() const;
68
69         /// Keeps the connection to the input validator.
70         SigC::Connection slot_url_;
71         SigC::Connection slot_name_;
72         SigC::Connection slot_html_;
73 };
74
75 #endif