Code

58d0dba5d328555f7c3ca32781e6fb3d5cc48b4c
[inkscape.git] / src / ui / previewholder.h
2 #ifndef SEEN_PREVIEW_HOLDER_H
3 #define SEEN_PREVIEW_HOLDER_H
4 /*
5  * A simple interface for previewing representations.
6  *
7  * Authors:
8  *   Jon A. Cruz
9  *
10  * Copyright (C) 2005 Jon A. Cruz
11  *
12  * Released under GNU GPL, read the file 'COPYING' for more information
13  */
16 #include <gtkmm/box.h>
17 #include <gtkmm/bin.h>
18 #include <gtkmm/table.h>
19 #include "previewfillable.h"
21 namespace Inkscape {
22 namespace UI {
24 class PreviewHolder : public Gtk::VBox, public PreviewFillable
25 {
26 public:
27     PreviewHolder();
28     virtual ~PreviewHolder();
30     virtual void clear();
31     virtual void addPreview( Previewable* preview );
32     virtual void setStyle(Gtk::BuiltinIconSize size, ViewType view);
33     virtual void setOrientation( Gtk::AnchorType how );
34     virtual Gtk::BuiltinIconSize getPreviewSize() const { return _baseSize; }
35     virtual ViewType getPreviewType() const { return _view; }
37 private:
38     void rebuildUI();
40     std::vector<Previewable*> items;
41     Gtk::Bin *_scroller;
42     Gtk::Table *_insides;
43     Gtk::Box *_zee0;
44     Gtk::Box *_zee1;
45     Gtk::Box *_zee2;
46     Gtk::AnchorType _anchor;
47     Gtk::BuiltinIconSize _baseSize;
48     ViewType _view;
49 };
51 } //namespace UI
52 } //namespace Inkscape
54 #endif // SEEN_PREVIEW_HOLDER_H
56 /*
57   Local Variables:
58   mode:c++
59   c-file-style:"stroustrup"
60   c-file-offsets:((innamespace . 0)(inline-open . 0)(case-label . +))
61   indent-tabs-mode:nil
62   fill-column:99
63   End:
64 */
65 // vim: filetype=cpp:expandtab:shiftwidth=4:tabstop=8:softtabstop=4:encoding=utf-8:textwidth=99 :