sketcher add alpha/fill, add alpha to vframe draw_pixel, crikey tweaks
[goodguy/cinelerra.git] / cinelerra-5.1 / cinelerra / cpanel.h
1
2 /*
3  * CINELERRA
4  * Copyright (C) 2008 Adam Williams <broadcast at earthling dot net>
5  *
6  * This program is free software; you can redistribute it and/or modify
7  * it under the terms of the GNU General Public License as published by
8  * the Free Software Foundation; either version 2 of the License, or
9  * (at your option) any later version.
10  *
11  * This program is distributed in the hope that it will be useful,
12  * but WITHOUT ANY WARRANTY; without even the implied warranty of
13  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
14  * GNU General Public License for more details.
15  *
16  * You should have received a copy of the GNU General Public License
17  * along with this program; if not, write to the Free Software
18  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
19  *
20  */
21
22 #ifndef CPANEL_H
23 #define CPANEL_H
24
25 #include "cwindowgui.inc"
26 #include "cpanel.inc"
27 #include "edl.inc"
28 #include "guicast.h"
29 #include "mwindow.inc"
30
31 class CPanel
32 {
33 public:
34         CPanel(MWindow *mwindow, CWindowGUI *subwindow, int x, int y, int w, int h);
35         ~CPanel();
36
37         void create_objects();
38         void reposition_buttons(int x, int y, int h);
39         void set_operation(int value);
40
41         MWindow *mwindow;
42         CWindowGUI *subwindow;
43         CPanelZoom *cpanel_zoom;
44
45         int x, y, w, h;
46
47         BC_Toggle* operation[CPANEL_OPERATIONS];
48 };
49
50 class CPanelMask : public BC_Toggle
51 {
52 public:
53         CPanelMask(MWindow *mwindow, CPanel *gui, int x, int y);
54         ~CPanelMask();
55         int handle_event();
56         MWindow *mwindow;
57         CPanel *gui;
58 };
59
60 class CPanelRuler : public BC_Toggle
61 {
62 public:
63         CPanelRuler(MWindow *mwindow, CPanel *gui, int x, int y);
64         ~CPanelRuler();
65         int handle_event();
66         MWindow *mwindow;
67         CPanel *gui;
68 };
69
70 class CPanelTitleSafe : public BC_Toggle
71 {
72 public:
73         CPanelTitleSafe(MWindow *mwindow, CPanel *gui, int x, int y);
74         ~CPanelTitleSafe();
75         int handle_event();
76         MWindow *mwindow;
77         CPanel *gui;
78 };
79
80 class CPanelErase : public BC_Toggle
81 {
82 public:
83         CPanelErase(MWindow *mwindow, CPanel *gui, int x, int y);
84         ~CPanelErase();
85         int handle_event();
86         MWindow *mwindow;
87         CPanel *gui;
88 };
89
90 class CPanelAntierase : public BC_Toggle
91 {
92 public:
93         CPanelAntierase(MWindow *mwindow, CPanel *gui, int x, int y);
94         ~CPanelAntierase();
95         int handle_event();
96         MWindow *mwindow;
97         CPanel *gui;
98 };
99
100 class CPanelProtect : public BC_Toggle
101 {
102 public:
103         CPanelProtect(MWindow *mwindow, CPanel *gui, int x, int y);
104         ~CPanelProtect();
105         int handle_event();
106         MWindow *mwindow;
107         CPanel *gui;
108 };
109
110 class CPanelMagnify : public BC_Toggle
111 {
112 public:
113         CPanelMagnify(MWindow *mwindow, CPanel *gui, int x, int y);
114         ~CPanelMagnify();
115         int handle_event();
116         MWindow *mwindow;
117         CPanel *gui;
118 };
119
120 class CPanelCamera : public BC_Toggle
121 {
122 public:
123         CPanelCamera(MWindow *mwindow, CPanel *gui, int x, int y);
124         ~CPanelCamera();
125         int handle_event();
126         MWindow *mwindow;
127         CPanel *gui;
128 };
129
130 class CPanelProj : public BC_Toggle
131 {
132 public:
133         CPanelProj(MWindow *mwindow, CPanel *gui, int x, int y);
134         ~CPanelProj();
135         int handle_event();
136         MWindow *mwindow;
137         CPanel *gui;
138 };
139
140 class CPanelCrop : public BC_Toggle
141 {
142 public:
143         CPanelCrop(MWindow *mwindow, CPanel *gui, int x, int y);
144         ~CPanelCrop();
145         int handle_event();
146         MWindow *mwindow;
147         CPanel *gui;
148 };
149
150 class CPanelEyedrop : public BC_Toggle
151 {
152 public:
153         CPanelEyedrop(MWindow *mwindow, CPanel *gui, int x, int y);
154         ~CPanelEyedrop();
155         int handle_event();
156         MWindow *mwindow;
157         CPanel *gui;
158 };
159
160 class CPanelToolWindow : public BC_Toggle
161 {
162 public:
163         CPanelToolWindow(MWindow *mwindow, CPanel *gui, int x, int y);
164         ~CPanelToolWindow();
165         int handle_event();
166         int set_shown(int shown);
167         MWindow *mwindow;
168         CPanel *gui;
169 };
170
171 class CPanelZoom : public BC_FSlider
172 {
173 public:
174         CPanelZoom(MWindow *mwindow, CPanel *gui, int x, int y, int h);
175         ~CPanelZoom();
176         char *get_caption();
177         int handle_event();
178         int set_shown(int shown);
179         int show_window(int flush=1) { return 0; }
180         int hide_window(int flush=1) { return 0; }
181         int show(int flush=1) { return BC_SubWindow::show_window(flush); }
182         int hide(int flush=1) { return BC_SubWindow::hide_window(flush); }
183         void update(float zoom);
184         MWindow *mwindow;
185         CPanel *gui;
186 };
187
188 #endif