4 * Copyright (C) 1997-2014 Adam Williams <broadcast at earthling dot net>
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.
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.
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
22 #include "cwindowgui.h"
24 #include "edlsession.h"
27 #include "mainsession.h"
28 #include "microtheme.h"
30 #include "mwindowgui.h"
31 #include "statusbar.h"
33 #include "trackcanvas.h"
36 PluginClient* new_plugin(PluginServer *server)
38 return new MicroThemeMain(server);
42 MicroThemeMain::MicroThemeMain(PluginServer *server)
43 : PluginTClient(server)
47 MicroThemeMain::~MicroThemeMain()
52 char* MicroThemeMain::plugin_title()
54 return _("Microscopic");
57 Theme* MicroThemeMain::new_theme()
59 return theme = new MicroTheme;
66 MicroTheme::MicroTheme()
70 MicroTheme::~MicroTheme()
74 void MicroTheme::initialize()
76 //printf("MicroTheme::initialize 1\n");
77 mwindow_icon = new VFramePng(get_image("mwindow_icon.png"));
78 vwindow_icon = new VFramePng(get_image("mwindow_icon.png"));
79 cwindow_icon = new VFramePng(get_image("mwindow_icon.png"));
80 awindow_icon = new VFramePng(get_image("mwindow_icon.png"));
81 record_icon = new VFramePng(get_image("mwindow_icon.png"));
82 clip_icon = new VFramePng(get_image("clip_icon.png"));
85 static VFrame *default_patchbay_bg = new VFramePng(get_image("patchbay_bg.png"));
87 BC_WindowBase::get_resources()->bg_color = WHITE;
88 BC_WindowBase::get_resources()->menu_light = WHITE;
89 BC_WindowBase::get_resources()->menu_highlighted = WHITE;
90 BC_WindowBase::get_resources()->menu_down = LTGREY;
91 BC_WindowBase::get_resources()->menu_up = WHITE;
92 BC_WindowBase::get_resources()->menu_shadow = MEGREY;
93 BC_WindowBase::get_resources()->medium_font = "-*-helvetica-medium-r-normal-*-10-*";
95 static VFrame* default_listbox_bg = new VFramePng(get_image("patchbay_bg.png"));
96 BC_WindowBase::get_resources()->listbox_bg = default_listbox_bg;
97 BC_WindowBase::get_resources()->button_light = WHITE;
98 BC_WindowBase::get_resources()->button_up = WHITE;
101 static VFrame *default_cancel_images[] =
103 new VFramePng(get_image("cancel_up.png")), new VFramePng(get_image("cancel_hi.png")), new VFramePng(get_image("cancel_dn.png"))
105 BC_WindowBase::get_resources()->cancel_images = default_cancel_images;
107 static VFrame *default_ok_images[] =
109 new VFramePng(get_image("ok_up.png")), new VFramePng(get_image("ok_hi.png")), new VFramePng(get_image("ok_dn.png"))
111 BC_WindowBase::get_resources()->ok_images = default_ok_images;
113 static VFrame *default_button_images[] =
115 new VFramePng(get_image("generic_up.png")), new VFramePng(get_image("generic_hi.png")), new VFramePng(get_image("generic_dn.png"))
117 BC_WindowBase::get_resources()->generic_button_images = default_button_images;
119 static VFrame *default_tumble_images[] =
121 new VFramePng(get_image("tumble_up.png")), new VFramePng(get_image("tumble_hi.png")), new VFramePng(get_image("tumble_bottomdn.png")), new VFramePng(get_image("tumble_topdn.png"))
123 BC_WindowBase::get_resources()->tumble_data = default_tumble_images;
125 static VFrame *default_checkbox_images[] =
127 new VFramePng(get_image("checkbox_up.png")), new VFramePng(get_image("checkbox_hi.png")), new VFramePng(get_image("checkbox_checked.png")), new VFramePng(get_image("checkbox_dn.png")), new VFramePng(get_image("checkbox_checkedhi.png"))
129 BC_WindowBase::get_resources()->checkbox_images = default_checkbox_images;
131 static VFrame *default_radial_images[] =
133 new VFramePng(get_image("radial_up.png")), new VFramePng(get_image("radial_hi.png")), new VFramePng(get_image("radial_checked.png")), new VFramePng(get_image("radial_dn.png")), new VFramePng(get_image("radial_checkedhi.png"))
135 BC_WindowBase::get_resources()->radial_images = default_radial_images;
137 static VFrame* default_xmeter_data[] =
139 new VFramePng(get_image("xmeter_normal.png")),
140 new VFramePng(get_image("xmeter_green.png")),
141 new VFramePng(get_image("xmeter_red.png")),
142 new VFramePng(get_image("xmeter_yellow.png")),
143 new VFramePng(get_image("over_horiz.png"))
144 new VFramePng(get_image("downmix51_2.png"))
147 static VFrame* default_ymeter_data[] =
149 new VFramePng(get_image("ymeter_normal.png")),
150 new VFramePng(get_image("ymeter_green.png")),
151 new VFramePng(get_image("ymeter_red.png")),
152 new VFramePng(get_image("ymeter_yellow.png")),
153 new VFramePng(get_image("over_vert.png"))
154 new VFramePng(get_image("downmix51_2.png"))
156 BC_WindowBase::get_resources()->xmeter_images = default_xmeter_data;
157 BC_WindowBase::get_resources()->ymeter_images = default_ymeter_data;
158 BC_WindowBase::get_resources()->meter_font = SMALLFONT;
159 BC_WindowBase::get_resources()->meter_font_color = BLACK;
160 BC_WindowBase::get_resources()->meter_title_w = 25;
161 BC_WindowBase::get_resources()->meter_3d = 0;
163 static VFrame* default_pan_data[] =
165 new VFramePng(get_image("pan_up.png")),
166 new VFramePng(get_image("pan_hi.png")),
167 new VFramePng(get_image("pan_popup.png")),
168 new VFramePng(get_image("pan_channel.png")),
169 new VFramePng(get_image("pan_stick.png")),
170 new VFramePng(get_image("pan_channel_small.png")),
171 new VFramePng(get_image("pan_stick_small.png"))
173 BC_WindowBase::get_resources()->pan_data = default_pan_data;
174 BC_WindowBase::get_resources()->pan_text_color = BLACK;
176 static VFrame *default_hscroll_data[] =
178 new VFramePng(get_image("hscroll_handle_up.png")),
179 new VFramePng(get_image("hscroll_handle_hi.png")),
180 new VFramePng(get_image("hscroll_handle_dn.png")),
181 new VFramePng(get_image("hscroll_handle_bg.png")),
182 new VFramePng(get_image("hscroll_left_up.png")),
183 new VFramePng(get_image("hscroll_left_hi.png")),
184 new VFramePng(get_image("hscroll_left_dn.png")),
185 new VFramePng(get_image("hscroll_right_up.png")),
186 new VFramePng(get_image("hscroll_right_hi.png")),
187 new VFramePng(get_image("hscroll_right_dn.png"))
189 static VFrame *default_vscroll_data[] =
191 new VFramePng(get_image("vscroll_handle_up.png")),
192 new VFramePng(get_image("vscroll_handle_hi.png")),
193 new VFramePng(get_image("vscroll_handle_dn.png")),
194 new VFramePng(get_image("vscroll_handle_bg.png")),
195 new VFramePng(get_image("vscroll_left_up.png")),
196 new VFramePng(get_image("vscroll_left_hi.png")),
197 new VFramePng(get_image("vscroll_left_dn.png")),
198 new VFramePng(get_image("vscroll_right_up.png")),
199 new VFramePng(get_image("vscroll_right_hi.png")),
200 new VFramePng(get_image("vscroll_right_dn.png"))
202 BC_WindowBase::get_resources()->hscroll_data = default_hscroll_data;
203 BC_WindowBase::get_resources()->vscroll_data = default_vscroll_data;
205 channel_bg_data = new VFramePng(get_image("channel_bg.png"));
206 channel_position_data = new VFramePng(get_image("channel_position.png"));
207 channel_position_color = BLACK;
208 recordgui_fixed_color = BLACK;
209 recordgui_variable_color = RED;
211 patchbay_bg = default_patchbay_bg;
212 resource1024_bg_data = new VFramePng(get_image("resource1024.png"));
213 resource512_bg_data = new VFramePng(get_image("resource512.png"));
214 resource256_bg_data = new VFramePng(get_image("resource256.png"));
215 resource128_bg_data = new VFramePng(get_image("resource128.png"));
216 resource64_bg_data = new VFramePng(get_image("resource64.png"));
217 resource32_bg_data = new VFramePng(get_image("resource32.png"));
218 plugin_bg_data = new VFramePng(get_image("plugin_bg.png"));
219 title_bg_data = new VFramePng(get_image("title_bg.png"));
220 timebar_bg_data = new VFramePng(get_image("timebar_bg.png"));
221 vtimebar_bg_data = new VFramePng(get_image("vwindow_timebar.png"));
222 new_button("pane.png", "pane_up.png", "pane_hi.png", "pane_dn.png", "pane");
224 keyframe_data = new VFramePng(get_image("keyframe3.png"));
225 camerakeyframe_data = new VFramePng(get_image("camerakeyframe.png"));
226 maskkeyframe_data = new VFramePng(get_image("maskkeyframe.png"));
227 modekeyframe_data = new VFramePng(get_image("modekeyframe.png"));
228 pankeyframe_data = new VFramePng(get_image("pankeyframe.png"));
229 projectorkeyframe_data = new VFramePng(get_image("projectorkeyframe.png"));
231 VFrame editpanel_up(get_image("editpanel_up.png"));
232 VFrame editpanel_hi(get_image("editpanel_hi.png"));
233 VFrame editpanel_dn(get_image("editpanel_dn.png"));
234 VFrame editpanel_checked(get_image("editpanel_checked.png"));
235 VFrame editpanel_checkedhi(get_image("editpanel_checkedhi.png"));
237 static VFrame *default_inpoint[] = { new VFramePng(get_image("out_up.png")), new VFramePng(get_image("out_hi.png")), new VFramePng(get_image("out_checked.png")), new VFramePng(get_image("out_dn.png")), new VFramePng(get_image("out_checkedhi.png")) };
238 static VFrame *default_labeltoggle[] = { new VFramePng(get_image("labeltoggle_up.png")), new VFramePng(get_image("labeltoggle_uphi.png")), new VFramePng(get_image("label_checked.png")), new VFramePng(get_image("labeltoggle_dn.png")), new VFramePng(get_image("label_checkedhi.png")) };
239 static VFrame *default_ffmpegtoggle[] = { new VFramePng(get_image("ff_up.png")), new VFramePng(get_image("ff_hi.png")), new VFramePng(get_image("ff_checked.png")), new VFramePng(get_image("ff_down.png")), new VFramePng(get_image("ff_checkedhi.png")) };
240 static VFrame *default_shbtndata[] = { new VFramePng(get_image("shbtn_up.png")), new VFramePng(get_image("shbtn_hi.png")), new VFramePng(get_image("shbtn_dn.png")), };
241 static VFrame *default_outpoint[] = { new VFramePng(get_image("in_up.png")), new VFramePng(get_image("in_hi.png")), new VFramePng(get_image("in_checked.png")), new VFramePng(get_image("in_dn.png")), new VFramePng(get_image("in_checkedhi.png")) };
242 static VFrame *transport_bg[] = { new VFramePng(get_image("transportup.png")), new VFramePng(get_image("transporthi.png")), new VFramePng(get_image("transportdn.png")) };
243 static VFrame *patches_bg[] = { new VFramePng(get_image("patches_up.png")), new VFramePng(get_image("patches_hi.png")), new VFramePng(get_image("patches_checked.png")), new VFramePng(get_image("patches_dn.png")), new VFramePng(get_image("patches_checkedhi.png")) };
245 build_button(BC_WindowBase::get_resources()->filebox_updir_images, get_image("filebox_updir.png"), &editpanel_up, &editpanel_hi, &editpanel_dn);
246 build_button(BC_WindowBase::get_resources()->filebox_newfolder_images, get_image("filebox_newfolder.png"), &editpanel_up, &editpanel_hi, &editpanel_dn);
247 build_button(BC_WindowBase::get_resources()->filebox_icons_images, get_image("filebox_icons.png"), &editpanel_up, &editpanel_hi, &editpanel_dn);
248 build_button(BC_WindowBase::get_resources()->filebox_text_images, get_image("filebox_text.png"), &editpanel_up, &editpanel_hi, &editpanel_dn);
250 build_button(BC_WindowBase::get_resources()->listbox_button, get_image("listbox_button.png"), &editpanel_up, &editpanel_hi, &editpanel_dn, &editpanel_hi);
251 build_button(bottom_justify, get_image("bottom_justify.png"), &editpanel_up, &editpanel_hi, &editpanel_dn);
252 build_button(center_justify, get_image("center_justify.png"), &editpanel_up, &editpanel_hi, &editpanel_dn);
253 build_button(copy_data, get_image("copy.png"), &editpanel_up, &editpanel_hi, &editpanel_dn);
254 build_button(cut_data, get_image("cut.png"), &editpanel_up, &editpanel_hi, &editpanel_dn);
255 build_button(fit_data, get_image("fit.png"), &editpanel_up, &editpanel_hi, &editpanel_dn);
256 build_button(in_data, get_image("outpoint.png"), &editpanel_up, &editpanel_hi, &editpanel_dn);
257 build_button(indelete_data, get_image("clearinpoint.png"), &editpanel_up, &editpanel_hi, &editpanel_dn);
258 build_button(labelbutton_data, get_image("label.png"), &editpanel_up, &editpanel_hi, &editpanel_dn);
259 build_button(left_justify, get_image("left_justify.png"), &editpanel_up, &editpanel_hi, &editpanel_dn);
260 build_button(magnify_button_data, get_image("magnify.png"), &editpanel_up, &editpanel_hi, &editpanel_dn);
261 build_button(middle_justify, get_image("middle_justify.png"), &editpanel_up, &editpanel_hi, &editpanel_dn);
262 build_button(nextlabel_data, get_image("nextlabel.png"), &editpanel_up, &editpanel_hi, &editpanel_dn);
263 build_button(out_data, get_image("inpoint.png"), &editpanel_up, &editpanel_hi, &editpanel_dn);
264 build_button(outdelete_data, get_image("clearoutpoint.png"), &editpanel_up, &editpanel_hi, &editpanel_dn);
265 build_button(over_button, get_image("over.png"), &editpanel_up, &editpanel_hi, &editpanel_dn);
266 build_button(overwrite_data, get_image("overwrite.png"), &editpanel_up, &editpanel_hi, &editpanel_dn);
267 build_button(paste_data, get_image("paste.png"), &editpanel_up, &editpanel_hi, &editpanel_dn);
268 build_button(prevlabel_data, get_image("prevlabel.png"), &editpanel_up, &editpanel_hi, &editpanel_dn);
269 build_button(redo_data, get_image("redo.png"), &editpanel_up, &editpanel_hi, &editpanel_dn);
270 build_button(right_justify, get_image("right_justify.png"), &editpanel_up, &editpanel_hi, &editpanel_dn);
271 build_button(splice_data, get_image("splice.png"), &editpanel_up, &editpanel_hi, &editpanel_dn);
272 build_button(statusbar_cancel_data, get_image("cancel_small.png"), &editpanel_up, &editpanel_hi, &editpanel_dn);
273 build_button(toclip_data, get_image("toclip.png"), &editpanel_up, &editpanel_hi, &editpanel_dn);
274 build_button(top_justify, get_image("top_justify.png"), &editpanel_up, &editpanel_hi, &editpanel_dn);
275 build_button(undo_data, get_image("undo.png"), &editpanel_up, &editpanel_hi, &editpanel_dn);
276 build_toggle(arrow_data, get_image("arrow.png"), &editpanel_up, &editpanel_hi, &editpanel_checked, &editpanel_dn, &editpanel_checkedhi);
277 build_toggle(autokeyframe_data, get_image("autokeyframe.png"), &editpanel_up, &editpanel_hi, &editpanel_checked, &editpanel_dn, &editpanel_checkedhi);
278 build_toggle(camera_data, get_image("camera.png"), &editpanel_up, &editpanel_hi, &editpanel_checked, &editpanel_dn, &editpanel_checkedhi);
279 build_toggle(crop_data, get_image("crop.png"), &editpanel_up, &editpanel_hi, &editpanel_checked, &editpanel_dn, &editpanel_checkedhi);
280 build_toggle(ibeam_data, get_image("ibeam.png"), &editpanel_up, &editpanel_hi, &editpanel_checked, &editpanel_dn, &editpanel_checkedhi);
281 build_toggle(magnify_data, get_image("magnify.png"), &editpanel_up, &editpanel_hi, &editpanel_checked, &editpanel_dn, &editpanel_checkedhi);
282 build_toggle(mask_data, get_image("mask.png"), &editpanel_up, &editpanel_hi, &editpanel_checked, &editpanel_dn, &editpanel_checkedhi);
283 build_toggle(proj_data, get_image("projector.png"), &editpanel_up, &editpanel_hi, &editpanel_checked, &editpanel_dn, &editpanel_checkedhi);
284 build_toggle(protect_data, get_image("protect.png"), &editpanel_up, &editpanel_hi, &editpanel_checked, &editpanel_dn, &editpanel_checkedhi);
285 build_toggle(show_meters, get_image("show_meters.png"), &editpanel_up, &editpanel_hi, &editpanel_checked, &editpanel_dn, &editpanel_checkedhi);
286 build_toggle(titlesafe_data, get_image("titlesafe.png"), &editpanel_up, &editpanel_hi, &editpanel_checked, &editpanel_dn, &editpanel_checkedhi);
287 build_toggle(tool_data, get_image("toolwindow.png"), &editpanel_up, &editpanel_hi, &editpanel_checked, &editpanel_dn, &editpanel_checkedhi);
288 build_transport(duplex_data, get_image("duplex.png"), transport_bg, 1);
289 build_transport(end_data, get_image("end.png"), transport_bg, 2);
290 build_transport(fastfwd_data, get_image("fastfwd.png"), transport_bg, 1);
291 build_transport(fastrev_data, get_image("fastrev.png"), transport_bg, 1);
292 build_transport(forward_data, get_image("play.png"), transport_bg, 1);
293 build_transport(framefwd_data, get_image("framefwd.png"), transport_bg, 1);
294 build_transport(framefwd_data, get_image("framefwd.png"), transport_bg, 1);
295 build_transport(framerev_data, get_image("framerev.png"), transport_bg, 1);
296 build_transport(rec_data, get_image("record.png"), transport_bg, 1);
297 build_transport(recframe_data, get_image("singleframe.png"), transport_bg, 1);
298 build_transport(reverse_data, get_image("reverse.png"), transport_bg, 1);
299 build_transport(rewind_data, get_image("rewind.png"), transport_bg, 0);
300 build_transport(stop_data, get_image("stop.png"), transport_bg, 1);
301 build_transport(stoprec_data, get_image("stoprec.png"), transport_bg, 2);
303 build_patches(playpatch_data, get_image("playpatch.png"), patches_bg, 0);
304 build_patches(recordpatch_data, get_image("recordpatch.png"), patches_bg, 1);
305 build_patches(gangpatch_data, get_image("gangpatch.png"), patches_bg, 1);
306 build_patches(drawpatch_data, get_image("drawpatch.png"), patches_bg, 1);
307 build_patches(mutepatch_data, get_image("mutepatch.png"), patches_bg, 2);
309 static VFrame *default_expandpatch_data[] =
311 new VFramePng(get_image("expandpatch_up.png")),
312 new VFramePng(get_image("expandpatch_hi.png")),
313 new VFramePng(get_image("expandpatch_checked.png")),
314 new VFramePng(get_image("expandpatch_dn.png")),
315 new VFramePng(get_image("expandpatch_checkedhi.png"))
317 expandpatch_data = default_expandpatch_data;
319 build_button(channel_data, get_image("channel.png"), &editpanel_up, &editpanel_hi, &editpanel_dn);
320 build_button(wrench_data, get_image("wrench.png"), &editpanel_up, &editpanel_hi, &editpanel_dn);
321 in_point = default_inpoint;
322 label_toggle = default_labeltoggle;
323 ffmpeg_toggle = default_ffmpegtoggle;
324 shbtn_data = default_shbtndata;
325 out_point = default_outpoint;
327 fade_h = BC_WindowBase::get_resources()->horizontal_slider_data[0]->get_h();
328 mode_h = BC_WindowBase::get_resources()->generic_button_images[0]->get_h();
329 meter_h = BC_WindowBase::get_resources()->xmeter_images[0]->get_h();
330 pan_h = BC_WindowBase::get_resources()->pan_data[PAN_UP]->get_h();
331 play_h = playpatch_data[0]->get_h();
335 title_font = MEDIUMFONT;
340 //printf("MicroTheme::initialize 2\n");
343 void MicroTheme::draw_mwindow_bg(MWindowGUI *gui)
345 gui->clear_box(0, 0, gui->get_w(), gui->get_h());
348 void MicroTheme::get_cwindow_sizes(CWindowGUI *gui)
350 //printf("Theme::get_cwindow_sizes 1 %p\n", mwindow);
357 ccomposite_w = protect_data[0]->get_w();
358 ccomposite_h = mwindow->session->cwindow_h - ccomposite_y;
359 ccanvas_x = ccomposite_x + ccomposite_w;
361 //printf("Theme::get_cwindow_sizes 1\n");
364 if(mwindow->edl->session->cwindow_meter)
366 cmeter_x = mwindow->session->cwindow_w - MeterPanel::get_meters_width(mwindow->edl->session->audio_channels,
367 mwindow->edl->session->cwindow_meter);
368 ccanvas_w = cmeter_x - ccanvas_x - 5;
372 cmeter_x = mwindow->session->cwindow_w;
373 ccanvas_w = cmeter_x - ccanvas_x;
375 //printf("Theme::get_cwindow_sizes 1\n");
378 cmeter_h = mwindow->session->cwindow_h - cmeter_y;
380 cedit_y = mwindow->session->cwindow_h - autokeyframe_data[0]->get_h();
381 //printf("Theme::get_cwindow_sizes 1\n");
383 ctransport_y = cedit_y - forward_data[0]->get_h();
384 ccanvas_h = ctransport_y - 5;
385 //printf("Theme::get_cwindow_sizes 1\n");
386 ctime_x = ctransport_x + PlayTransport::get_transport_width(mwindow);
387 ctime_y = ctransport_y;
388 // czoom_x = ctime_x + 150;
389 czoom_x = ctransport_x + PlayTransport::get_transport_width(mwindow) + 20;
390 //printf("Theme::get_cwindow_sizes 1\n");
393 cdest_y = czoom_y + 30;
394 //printf("Theme::get_cwindow_sizes 2\n");
398 void MicroTheme::get_vwindow_sizes(VWindowGUI *gui)
402 if(mwindow->edl->session->vwindow_meter)
404 vmeter_x = mwindow->session->vwindow_w -
405 MeterPanel::get_meters_width(mwindow->edl->session->audio_channels,
406 mwindow->edl->session->vwindow_meter);
407 vcanvas_w = vmeter_x - vcanvas_x - 5;
411 vmeter_x = mwindow->session->vwindow_w;
412 vcanvas_w = mwindow->session->vwindow_w;
416 vedit_y = mwindow->session->vwindow_h - autokeyframe_data[0]->get_h();
418 vtransport_y = vedit_y - forward_data[0]->get_h();
420 vslider_y = vtransport_y -
421 BC_WindowBase::get_resources()->horizontal_slider_data[0]->get_h();
422 vslider_w = vcanvas_w - vslider_x - 5;
424 vtimebar_y = vslider_y - 20;
425 vtimebar_w = vcanvas_w - vcanvas_x;
428 vcanvas_h = vtimebar_y;
431 vmeter_h = mwindow->session->vwindow_h - cmeter_y;
435 vtime_x = vtransport_x + PlayTransport::get_transport_width(mwindow) + 5;
436 vtime_y = vtransport_y;
438 vzoom_x = vtime_x + 150;
445 #define PATCHBAY_W 100
447 void MicroTheme::get_mwindow_sizes(MWindowGUI *gui, int w, int h)
450 mbuttons_y = gui->mainmenu->get_h();
452 mbuttons_h = arrow_data[0]->get_h() + 4;
454 mclock_y = mbuttons_y + mbuttons_h;
455 mclock_w = PATCHBAY_W - 10;
456 mclock_h = timebar_bg_data->get_h();
457 mtimebar_x = PATCHBAY_W;
458 mtimebar_y = mclock_y;
459 mtimebar_w = w - mtimebar_x;
460 mtimebar_h = timebar_bg_data->get_h();
462 mstatus_y = h - statusbar_cancel_data[0]->get_h();
464 mstatus_h = statusbar_cancel_data[0]->get_h();
465 mstatus_progress_x = mstatus_w - statusbar_cancel_data[0]->get_w() - 240;
466 mstatus_progress_y = mstatus_h - BC_WindowBase::get_resources()->progress_images[0]->get_h();
467 mstatus_progress_w = 230;
468 mstatus_cancel_x = mstatus_w - statusbar_cancel_data[0]->get_w();
469 mstatus_cancel_y = mstatus_h - statusbar_cancel_data[0]->get_h();
471 mzoom_y = mstatus_y - ZOOM_H;
475 patchbay_y = mtimebar_y + mtimebar_h;
476 patchbay_w = PATCHBAY_W;
477 patchbay_h = mzoom_y - patchbay_y;
478 mcanvas_x = patchbay_x + patchbay_w;
479 mcanvas_y = patchbay_y;
480 mcanvas_w = w - patchbay_w;
481 mcanvas_h = patchbay_h;
484 void MicroTheme::get_recordgui_sizes(RecordGUI *gui, int w, int h)
486 recordgui_status_x = 5;
487 recordgui_status_y = 5;
488 recordgui_status_x2 = 100;
489 recordgui_batch_x = 220;
490 recordgui_batch_y = 5;
491 recordgui_batchcaption_x = recordgui_batch_x + 70;
494 recordgui_transport_x = recordgui_batch_x;
495 recordgui_transport_y = recordgui_batch_y + 150;
497 recordgui_buttons_x = 220;
498 recordgui_buttons_y = recordgui_transport_y + 30;
499 recordgui_options_x = 220;
500 recordgui_options_y = recordgui_buttons_y + 30;
502 recordgui_batches_x = 10;
503 recordgui_batches_y = 250;
504 recordgui_batches_w = w - 20;
505 recordgui_batches_h = h - recordgui_batches_y - 70;
506 recordgui_loadmode_x = w / 2 - loadmode_w / 2;
507 recordgui_loadmode_y = h - 50;
509 recordgui_controls_x = 10;
510 recordgui_controls_y = h - 30;