Code

Fixing scrollbar size for embeded color swatches.
[inkscape.git] / src / ui / widget / page-sizer.h
1 /** \file
2  * \brief Widget for specifying page size; part of Document Preferences dialog.
3  *
4  * Author:
5  *   Ralf Stephan <ralf@ark.in-berlin.de>
6  *
7  * Copyright (C) 2005 Authors
8  *
9  * Released under GNU GPL.  Read the file 'COPYING' for more information.
10  */
12 #ifndef INKSCAPE_UI_WIDGET_PAGE_SIZER__H
13 #define INKSCAPE_UI_WIDGET_PAGE_SIZER__H
15 #include <sigc++/sigc++.h>
16 #include <gtkmm/box.h>
17 #include "ui/widget/registry.h"
18 #include "ui/widget/registered-widget.h"
20 namespace Gtk {
21     class OptionMenu;
22     class RadioButton;
23 }
25 namespace Inkscape {    
26     namespace UI {
27         namespace Widget {
29 /// Widget containing all widgets for specifying page size.
30 class PageSizer : public Gtk::VBox {
31 public:
32     PageSizer();
33     virtual ~PageSizer();
34     void init (Registry& reg);
35     void setDim (double w, double h, bool update = false);
36     bool                 _landscape;
38 protected:
39     void setDoc (double w, double h);
40     int find_paper_size (double w, double h) const;
41     void on_portrait();
42     void on_landscape();
43     void on_value_changed();
44     
45     RegisteredUnitMenu   _rum;
46     RegisteredScalarUnit _rusw, _rush;
47     Gtk::OptionMenu     *_omenu_size;
48     Gtk::RadioButton    *_rb_port, *_rb_land;
49     sigc::connection     _portrait_connection, _landscape_connection;
50     sigc::connection     _changedw_connection, _changedh_connection;
51     Registry             *_wr;
52 };
54 }}}
56 #endif /* INKSCAPE_UI_WIDGET_PAGE_SIZER__H */
58 /*
59   Local Variables:
60   mode:c++
61   c-file-style:"stroustrup"
62   c-file-offsets:((innamespace . 0)(inline-open . 0))
63   indent-tabs-mode:nil
64   fill-column:99
65   End:
66 */
67 // vim: filetype=c++:expandtab:shiftwidth=4:tabstop=8:softtabstop=4 :