2 /* This file is part of
3 * =================================================
5 * LyX, The Document Processor
6 * Copyright 1995 Matthias Ettrich.
7 * Copyright 1995-2000 The LyX Team.
9 * =================================================
21 #include "ControlUrl.h"
22 #include "GnomeBase.h"
31 * This class implements the dialog to insert/modify urls.
33 class FormUrl : public FormCB<ControlUrl> {
36 FormUrl(ControlUrl & c);
47 /// Returns true if the dialog input is in a valid state.
48 bool validate() const;
50 /// Do the connection of signals
51 void connect_signals();
52 /// Disconnect the signals.
53 void disconnect_signals();
55 void OKClicked() { OKButton(); }
56 void CancelClicked() { CancelButton(); }
57 void ApplyClicked() { ApplyButton(); }
58 void RestoreClicked() { RestoreButton(); }
59 void InputChanged() { bc().valid(validate()); }
62 Gtk::Entry * url() const;
64 Gtk::Entry * name() const;
65 /// The html type checkbutton
66 Gtk::CheckButton * html() const;
68 Gtk::Button * ok_btn() const;
70 Gtk::Button * cancel_btn() const;
72 Gtk::Button * apply_btn() const;
73 /// The restore button
74 Gtk::Button * restore_btn() const;
76 /// Keeps the connection to the input validator.
77 SigC::Connection slot_url_;
78 SigC::Connection slot_name_;
79 SigC::Connection slot_html_;