Fix bugs in previous commit that caused FTBFS in synfig and ETL FTBFS with older...
[synfig.git] / synfig-studio / tags / synfigstudio_0_61_07 / src / gtkmm / render.h
1 /* === S Y N F I G ========================================================= */
2 /*!     \file gtkmm/render.h
3 **      \brief Template Header
4 **
5 **      $Id$
6 **
7 **      \legal
8 **      Copyright (c) 2002-2005 Robert B. Quattlebaum Jr., Adrian Bentley
9 **      Copyright (c) 2007 Chris Moore
10 **
11 **      This package is free software; you can redistribute it and/or
12 **      modify it under the terms of the GNU General Public License as
13 **      published by the Free Software Foundation; either version 2 of
14 **      the License, or (at your option) any later version.
15 **
16 **      This package is distributed in the hope that it will be useful,
17 **      but WITHOUT ANY WARRANTY; without even the implied warranty of
18 **      MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
19 **      General Public License for more details.
20 **      \endlegal
21 */
22 /* ========================================================================= */
23
24 /* === S T A R T =========================================================== */
25
26 #ifndef __SYNFIG_STUDIO_GTKMM_RENDER_H
27 #define __SYNFIG_STUDIO_GTKMM_RENDER_H
28
29 /* === H E A D E R S ======================================================= */
30
31 #include <gtkmm/dialog.h>
32 #include <gtkmm/tooltips.h>
33 #include <gtkmm/table.h>
34 #include <gtkmm/entry.h>
35 #include <gtkmm/adjustment.h>
36 #include <gtkmm/spinbutton.h>
37 #include <gtkmm/checkbutton.h>
38 #include <gtkmm/tooltips.h>
39 #include <gtkmm/optionmenu.h>
40
41 #include <synfig/string.h>
42
43 #include <synfigapp/canvasinterface.h>
44
45 #include "renddesc.h"
46
47 /* === M A C R O S ========================================================= */
48
49 /* === T Y P E D E F S ===================================================== */
50
51 /* === C L A S S E S & S T R U C T S ======================================= */
52
53 namespace studio
54 {
55 class AsyncRenderer;
56
57 class RenderSettings : public Gtk::Dialog
58 {
59         Gtk::Tooltips tooltips;
60
61         etl::handle<synfigapp::CanvasInterface> canvas_interface_;
62         Widget_RendDesc widget_rend_desc;
63
64         Gtk::Entry entry_filename;
65
66         Gtk::Adjustment adjustment_quality;
67         Gtk::SpinButton entry_quality;
68
69         Gtk::Adjustment adjustment_antialias;
70         Gtk::SpinButton entry_antialias;
71
72         Gtk::CheckButton toggle_single_frame;
73
74         Gtk::OptionMenu optionmenu_target;
75         Gtk::Menu *menu_target;
76
77         synfig::String target_name;
78
79         void set_target(synfig::String name);
80
81         etl::handle<AsyncRenderer> async_renderer;
82
83 public:
84         RenderSettings(Gtk::Window& parent,etl::handle<synfigapp::CanvasInterface> canvas_interface);
85         ~RenderSettings();
86         void set_entry_filename();
87
88 private:
89
90         void on_rend_desc_changed();
91         void on_single_frame_toggle();
92         void on_choose_pressed();
93         void on_render_pressed();
94         void on_cancel_pressed();
95
96         void on_finished();
97 }; // END of class RenderSettings
98
99 }; // END of namespace studio
100
101
102 /* === E N D =============================================================== */
103
104 #endif