4d314a231624fa61675df78ea4ee61fed6188c78
[goodguy/history.git] / cinelerra-5.0 / plugins / blondtheme / blondtheme.C
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 #include "bcsignals.h"
23 #include "clip.h"
24 #include "cwindowgui.h"
25 #include "blondtheme.h"
26 #include "edl.h"
27 #include "edlsession.h"
28 #include "mainmenu.h"
29 #include "mainsession.h"
30 #include "mbuttons.h"
31 #include "meterpanel.h"
32 #include "mwindow.h"
33 #include "mwindowgui.h"
34 #include "new.h"
35 #include "patchbay.h"
36 #include "preferencesthread.h"
37 #include "recordgui.h"
38 //#include "recordmonitor.h"
39 #include "setformat.h"
40 #include "statusbar.h"
41 #include "timebar.h"
42 #include "trackcanvas.h"
43 #include "vframe.h"
44 #include "vwindowgui.h"
45
46
47
48
49 PluginClient* new_plugin(PluginServer *server)
50 {
51         return new BlondThemeMain(server);
52 }
53
54
55
56
57
58
59
60 BlondThemeMain::BlondThemeMain(PluginServer *server)
61  : PluginTClient(server)
62 {
63 }
64
65 BlondThemeMain::~BlondThemeMain()
66 {
67 }
68
69 const char* BlondThemeMain::plugin_title()
70 {
71         return _("Blond-cv");
72 }
73
74 Theme* BlondThemeMain::new_theme()
75 {
76         theme = new BlondTheme;
77         extern unsigned char _binary_blondtheme_data_start[];
78         theme->set_data(_binary_blondtheme_data_start);
79         return theme;
80 }
81
82
83
84
85
86
87
88
89 BlondTheme::BlondTheme()
90  : Theme()
91 {
92 }
93
94 BlondTheme::~BlondTheme()
95 {
96 }
97
98 void BlondTheme::initialize()
99 {
100         BC_Resources *resources = BC_WindowBase::get_resources();
101         resources->generic_button_images = new_image_set(3, 
102                         "generic_up.png", 
103                         "generic_hi.png", 
104                         "generic_dn.png");
105         resources->horizontal_slider_data = new_image_set(6,
106                         "hslider_fg_up.png",
107                         "hslider_fg_hi.png",
108                         "hslider_fg_dn.png",
109                         "hslider_bg_up.png",
110                         "hslider_bg_hi.png",
111                         "hslider_bg_dn.png");
112         resources->progress_images = new_image_set(2,
113                         "progress_bg.png",
114                         "progress_hi.png");
115         resources->tumble_data = new_image_set(4,
116                 "tumble_up.png",
117                 "tumble_hi.png",
118                 "tumble_botdn.png",
119                 "tumble_topdn.png");
120         resources->listbox_button = new_image_set(4,
121                 "listbox_button_up.png",
122                 "listbox_button_hi.png",
123                 "listbox_button_dn.png",
124                 "listbox_button_hi.png");
125         resources->listbox_column = new_image_set(3,
126                 "listbox_column_up.png",
127                 "listbox_column_hi.png",
128                 "listbox_column_dn.png");
129         resources->pan_data = new_image_set(7,
130                         "pan_up.png", 
131                         "pan_hi.png", 
132                         "pan_popup.png", 
133                         "pan_channel.png", 
134                         "pan_stick.png", 
135                         "pan_channel_small.png", 
136                         "pan_stick_small.png");
137         resources->pan_text_color = WHITE;
138
139         resources->pot_images = new_image_set(3,
140                 "pot_up.png",
141                 "pot_hi.png",
142                 "pot_dn.png");
143
144         resources->text_default = 0x000000;
145         resources->text_background = 0xffffff;
146         resources->text_border1 = 0x4a484a; // (top outer)
147         resources->text_border2 = 0x000000; // (top inner)
148         resources->text_border3 = 0xacaeac; // (bottom inner)
149         resources->text_border4 = 0xffffff; // (bottom outer)
150         resources->text_inactive_highlight = 0xacacac;
151         resources->checkbox_images = new_image_set(5,
152                 "checkbox_up.png",
153                 "checkbox_uphi.png",
154                 "checkbox_checked.png",
155                 "checkbox_down.png",
156                 "checkbox_checkedhi.png");
157
158         resources->bg_color = BLOND;
159         resources->default_text_color = 0x000000;
160         resources->menu_title_text    = 0x000000;
161         resources->popup_title_text   = 0x000000;
162         resources->menu_item_text     = 0x000000;
163         resources->radial_images = new_image_set(5,
164                 "radial_up.png",
165                 "radial_uphi.png",
166                 "radial_checked.png",
167                 "radial_down.png",
168                 "radial_checkedhi.png");
169
170         resources->generic_button_margin = 15;
171         resources->pot_needle_color = resources->text_default;
172         resources->pot_offset = 1;
173         resources->progress_text = resources->text_default;
174         resources->meter_font_color = RED;
175         resources->xmeter_images = new_image_set(7, 
176                 "xmeter_normal.png",
177                 "xmeter_green.png",
178                 "xmeter_red.png",
179                 "xmeter_yellow.png",
180                 "xmeter_white.png",
181                 "xmeter_over.png",
182                 "downmix51_2.png");
183         resources->ymeter_images = new_image_set(7, 
184                 "ymeter_normal.png",
185                 "ymeter_green.png",
186                 "ymeter_red.png",
187                 "ymeter_yellow.png",
188                 "ymeter_white.png",
189                 "ymeter_over.png",
190                 "downmix51_2.png");
191
192         resources->menu_light = 0x00cacd;
193         resources->menu_highlighted = 0x9c95ff;
194         resources->menu_down = 0x007d7b;
195         resources->menu_up = 0x009594;
196         resources->menu_shadow = 0x004a4a;
197         resources->popupmenu_margin = 10;          // ugly
198         resources->popupmenu_triangle_margin = 15; // ugly
199         resources->hscroll_data = new_image_set(10,
200                         "hscroll_center_up.png",
201                         "hscroll_center_hi.png",
202                         "hscroll_center_dn.png",
203                         "hscroll_bg.png",
204                         "hscroll_back_up.png",
205                         "hscroll_back_hi.png",
206                         "hscroll_back_dn.png",
207                         "hscroll_fwd_up.png",
208                         "hscroll_fwd_hi.png",
209                         "hscroll_fwd_dn.png");
210
211         resources->listbox_title_color = 0x000000;
212         resources->vscroll_data = new_image_set(10,
213                         "vscroll_center_up.png",
214                         "vscroll_center_hi.png",
215                         "vscroll_center_dn.png",
216                         "vscroll_bg.png",
217                         "vscroll_back_up.png",
218                         "vscroll_back_hi.png",
219                         "vscroll_back_dn.png",
220                         "vscroll_fwd_up.png",
221                         "vscroll_fwd_hi.png",
222                         "vscroll_fwd_dn.png");
223
224         resources->listbox_title_margin = 0;
225         resources->listbox_title_hotspot = 5;  // No. of pixels around the borders to allow dragging
226         resources->listbox_border1 = 0x4a484a; // (top outer)
227         resources->listbox_border2 = 0x000000; // (top inner)
228         resources->listbox_border3 = 0xffe200; // (bottom inner)
229         resources->listbox_border4 = 0xffffff; // (bottom outer)
230         resources->listbox_highlighted = 0xeee6ee;
231         resources->listbox_inactive = 0xffffffff; // (background)
232         resources->listbox_bg = new_image("list_bg.png");
233         resources->listbox_text = 0x000000;
234         resources->ok_images = new_button("ok.png", 
235                         "generic_up.png",
236                         "generic_hi.png",
237                         "generic_dn.png");
238
239         resources->dirbox_margin = 50;
240         resources->filebox_margin = 101;
241         resources->file_color = 0x000000;
242         resources->directory_color = 0x0000ff;
243         resources->cancel_images = new_button("cancel.png", 
244                         "generic_up.png",
245                         "generic_hi.png",
246                         "generic_dn.png");
247
248
249         
250 // Record windows
251         rgui_batch = new_image("recordgui_batch.png");
252         rgui_controls = new_image("recordgui_controls.png");
253         rgui_list = new_image("recordgui_list.png");
254         rmonitor_panel = new_image("recordmonitor_panel.png");
255         rmonitor_meters = new_image("recordmonitor_meters.png");
256
257         resources->filebox_icons_images = new_button("icons.png",
258                 "fileboxbutton_up.png",
259                 "fileboxbutton_hi.png",
260                 "fileboxbutton_dn.png");
261
262         resources->filebox_text_images = new_button("text.png",
263                 "fileboxbutton_up.png",
264                 "fileboxbutton_hi.png",
265                 "fileboxbutton_dn.png");
266
267         resources->filebox_newfolder_images = new_button("folder.png",
268                 "fileboxbutton_up.png",
269                 "fileboxbutton_hi.png",
270                 "fileboxbutton_dn.png");
271
272         resources->filebox_updir_images = new_button("updir.png",
273                 "fileboxbutton_up.png",
274                 "fileboxbutton_hi.png",
275                 "fileboxbutton_dn.png");
276
277         resources->filebox_delete_images = new_button("delete.png",
278                 "fileboxbutton_up.png",
279                 "fileboxbutton_hi.png",
280                 "fileboxbutton_dn.png");
281
282         resources->filebox_reload_images = new_button("reload.png",
283                 "fileboxbutton_up.png",
284                 "fileboxbutton_hi.png",
285                 "fileboxbutton_dn.png");
286
287
288         resources->filebox_descend_images = new_button("openfolder.png",
289                 "generic_up.png", 
290                 "generic_hi.png", 
291                 "generic_dn.png");
292
293         resources->usethis_button_images = 
294                 resources->ok_images = new_button("ok.png",
295                 "generic_up.png", 
296                 "generic_hi.png", 
297                 "generic_dn.png");
298
299         new_button("ok.png",
300                 "generic_up.png", 
301                 "generic_hi.png", 
302                 "generic_dn.png",
303                 "new_ok_images");
304
305         resources->cancel_images = new_button("cancel.png",
306                 "generic_up.png", 
307                 "generic_hi.png", 
308                 "generic_dn.png");
309
310         new_button("cancel.png",
311                 "generic_up.png", 
312                 "generic_hi.png", 
313                 "generic_dn.png",
314                 "new_cancel_images");
315
316         resources->bar_data = new_image("bar", "bar.png");
317
318
319         resources->min_menu_w = 0;
320         resources->menu_popup_bg = 0;  // if (0) use menu_light, menu_up, menu_shadow
321         resources->menu_item_bg = 0;   // if (0) use menu_light, menu_highlighted, menu_down, menu_shadow
322         resources->menu_bar_bg = 0;    // if (0) use menu_light, menu_shadow, and height of MEDIUMFONT + 8
323         resources->menu_title_bg =  0; // if (0) use menu_light, menu_highlighted, menu_down, menu_shadow
324
325
326         resources->popupmenu_images = 0; // if (0) get_resources()->use generic_button_images
327
328         resources->toggle_highlight_bg = 0; // if (0) "Draw a plain box" as per bctoggle.C
329
330         resources->vertical_slider_data = new_image_set(6,
331                         "vertical_slider_fg_up.png",
332                         "vertical_slider_fg_hi.png",
333                         "vertical_slider_fg_dn.png",
334                         "vertical_slider_bg_up.png",
335                         "vertical_slider_bg_hi.png",
336                         "vertical_slider_bg_dn.png");
337         resources->listbox_expand = new_image_set(5,
338                 "listbox_expandup.png",
339                 "listbox_expanduphi.png",
340                 "listbox_expandchecked.png",
341                 "listbox_expanddn.png",
342                 "listbox_expandcheckedhi.png");
343         resources->listbox_up = new_image("listbox_up.png");
344         resources->listbox_dn = new_image("listbox_dn.png");
345
346 // MWindow
347         mbutton_left = new_image("mbutton_left.png");
348         mbutton_right = new_image("mbutton_right.png");
349         new_image("timebar_bg", "timebar_bg.png");
350         new_image("timebar_brender", "timebar_brender.png");
351         new_image("clock_bg", "mclock.png");
352         new_image("patchbay_bg", "patchbay_bg.png");
353         tracks_bg = new_image("tracks_bg.png");
354         zoombar_left = new_image("zoombar_left.png");
355         zoombar_right = new_image("zoombar_right.png");
356         statusbar_left = new_image("statusbar_left.png");
357         statusbar_right = new_image("statusbar_right.png");
358
359         new_button("pane.png", "pane_up.png", "pane_hi.png", "pane_dn.png", "pane");
360         new_image_set("xpane", 3, "xpane_up.png", "xpane_hi.png", "xpane_dn.png");
361         new_image_set("ypane", 3, "ypane_up.png", "ypane_hi.png", "ypane_dn.png");
362
363         new_button("prevtip.png", "tipbutton_up.png", "tipbutton_hi.png", "tipbutton_dn.png", "prev_tip");
364         new_button("nexttip.png", "tipbutton_up.png", "tipbutton_hi.png", "tipbutton_dn.png", "next_tip");
365         new_button("closetip.png", "tipbutton_up.png", "tipbutton_hi.png", "tipbutton_dn.png", "close_tip");
366         new_button("swap_extents.png",
367                 "editpanel_up.png",
368                 "editpanel_hi.png",
369                 "editpanel_dn.png",
370                 "swap_extents");
371         preferences_category_overlap = 0;
372         preferencescategory_x = 5;
373         preferencescategory_y = 5;
374         preferencestitle_x = 5;
375         preferencestitle_y = 10;
376         preferencesoptions_x = 5;
377         preferencesoptions_y = 0;
378 // CWindow
379         cpanel_bg = new_image("cpanel_bg.png");
380         cbuttons_left = new_image("cbuttons_left.png");
381         cbuttons_right = new_image("cbuttons_right.png");
382         cmeter_bg = new_image("cmeter_bg.png");
383
384         message_normal = resources->text_default;
385         audio_color = BLACK;
386         mtransport_margin = 11;
387         toggle_margin = 11;
388 // VWindow
389         vbuttons_left = new_image("vbuttons_left.png");
390         vbuttons_right = new_image("vbuttons_right.png");
391         vmeter_bg = new_image("vmeter_bg.png");
392
393         new_image("mbutton_bg", "mbutton_bg.png");
394         new_image("mbutton_blue", "mbutton_blue.png");
395         new_image("tracks_bg","tracks_bg.png");
396         new_image("zoombar_left","zoombar_left.png");
397         new_image("zoombar_right","zoombar_right.png");
398         new_image("statusbar_left","statusbar_left.png");
399         new_image("statusbar_right","statusbar_right.png");
400         preferences_bg = new_image("preferences_bg.png");
401
402         new_image_set("zoombar_menu", 3, "generic_up.png", "generic_hi.png", "generic_dn.png");
403         new_image_set("zoombar_tumbler", 4, "tumble_up.png", "tumble_hi.png", "tumble_bottom.png", "tumble_top.png");
404
405         new_image_set("mode_popup", 3, "generic_up.png", "generic_hi.png", "generic_dn.png");
406         new_image("mode_add", "mode_add.png");
407         new_image("mode_divide", "mode_divide.png");
408         new_image("mode_multiply", "mode_multiply.png");
409         new_image("mode_normal", "mode_normal.png");
410         new_image("mode_replace", "mode_replace.png");
411         new_image("mode_subtract", "mode_subtract.png");
412         new_image("mode_max", "mode_max.png");
413         new_image("mode_min", "mode_min.png");
414
415         new_bg = new_image("new_bg.png");
416         setformat_bg = new_image("setformat_bg2.png");
417
418         new_toggle("plugin_on.png", 
419                 "pluginbutton_hi.png", 
420                 "pluginbutton_hi.png", 
421                 "pluginbutton_select.png", 
422                 "pluginbutton_dn.png", 
423                 "pluginbutton_selecthi.png", 
424                 "plugin_on");
425
426         new_toggle("plugin_show.png", 
427                 "plugin_show.png", 
428                 "pluginbutton_hi.png", 
429                 "pluginbutton_select.png", 
430                 "pluginbutton_dn.png", 
431                 "pluginbutton_selecthi.png", 
432                 "plugin_show");
433         new_image("cpanel_bg", "cpanel_bg.png");
434         new_image("cbuttons_left", "cbuttons_left.png");
435         new_image("cbuttons_right", "cbuttons_right.png");
436         new_image("cmeter_bg", "cmeter_bg.png");
437         new_image("vbuttons_left", "vbuttons_left.png");
438         timebar_view_data = new_image("timebar_view.png");
439
440         new_image("preferences_bg", "preferences_bg.png");
441         setformat_w = 600;
442         setformat_h = 560;
443         setformat_x1 = 15;
444         setformat_x2 = 100;
445
446
447         new_image("new_bg", "new_bg.png");
448         new_image("setformat_bg", "setformat_bg2.png");
449         setformat_x3 = 315;
450         setformat_x4 = 415;
451         setformat_y1 = 20;
452         setformat_y2 = 85;
453         setformat_w = get_image("setformat_bg")->get_w();
454         setformat_h = get_image("setformat_bg")->get_h();
455         setformat_x4 = 425;
456         setformat_y3 = 125;
457         setformat_margin = 30;
458         setformat_channels_x = 25;
459         setformat_channels_y = 242;
460         setformat_channels_w = 250;
461         setformat_channels_h = 250;
462
463         loadfile_pad = 52;
464         browse_pad = 20;
465
466
467         new_image_set("playpatch_data", 
468                 5,
469                 "playpatch_up.png",
470                 "playpatch_hi.png",
471                 "playpatch_checked.png",
472                 "playpatch_dn.png",
473                 "playpatch_checkedhi.png");
474
475         new_image_set("recordpatch_data", 
476                 5,
477                 "recordpatch_up.png",
478                 "recordpatch_hi.png",
479                 "recordpatch_checked.png",
480                 "recordpatch_dn.png",
481                 "recordpatch_checkedhi.png");
482
483         new_image_set("gangpatch_data", 
484                 5,
485                 "gangpatch_up.png",
486                 "gangpatch_hi.png",
487                 "gangpatch_checked.png",
488                 "gangpatch_dn.png",
489                 "gangpatch_checkedhi.png");
490
491         new_image_set("drawpatch_data", 
492                 5,
493                 "drawpatch_up.png",
494                 "drawpatch_hi.png",
495                 "drawpatch_checked.png",
496                 "drawpatch_dn.png",
497                 "drawpatch_checkedhi.png");
498
499
500         new_image_set("mutepatch_data", 
501                 5,
502                 "mutepatch_up.png",
503                 "mutepatch_hi.png",
504                 "mutepatch_checked.png",
505                 "mutepatch_dn.png",
506                 "mutepatch_checkedhi.png");
507         build_icons();
508         build_bg_data();
509
510         new_image_set("expandpatch_data", 
511                 5,
512                 "expandpatch_up.png",
513                 "expandpatch_hi.png",
514                 "expandpatch_checked.png",
515                 "expandpatch_dn.png",
516                 "expandpatch_checkedhi.png");
517         new_image_set("drawpatch_data", 5, "drawpatch_up.png", "drawpatch_hi.png", "drawpatch_checked.png", "drawpatch_dn.png", "drawpatch_checkedhi.png");
518         new_image_set("expandpatch_data", 5, "expandpatch_up.png", "expandpatch_hi.png", "expandpatch_checked.png", "expandpatch_dn.png", "expandpatch_checkedhi.png");
519         new_image_set("gangpatch_data", 5, "gangpatch_up.png", "gangpatch_hi.png", "gangpatch_checked.png", "gangpatch_dn.png", "gangpatch_checkedhi.png");
520         new_image_set("mutepatch_data", 5, "mutepatch_up.png", "mutepatch_hi.png", "mutepatch_checked.png", "mutepatch_dn.png", "mutepatch_checkedhi.png");
521         new_image_set("playpatch_data", 5, "playpatch_up.png", "playpatch_hi.png", "playpatch_checked.png", "playpatch_dn.png", "playpatch_checkedhi.png");
522         new_image_set("recordpatch_data", 5, "recordpatch_up.png", "recordpatch_hi.png", "recordpatch_checked.png", "recordpatch_dn.png", "recordpatch_checkedhi.png");
523
524
525         build_overlays();
526
527
528
529
530         out_point = new_image_set(5,
531                 "out_up.png", 
532                 "out_hi.png", 
533                 "out_checked.png", 
534                 "out_dn.png", 
535                 "out_checkedhi.png");
536         in_point = new_image_set(5,
537                 "in_up.png", 
538                 "in_hi.png", 
539                 "in_checked.png", 
540                 "in_dn.png", 
541                 "in_checkedhi.png");
542
543         label_toggle = new_image_set(5,
544                 "labeltoggle_up.png", 
545                 "labeltoggle_uphi.png", 
546                 "label_checked.png", 
547                 "labeltoggle_dn.png", 
548                 "label_checkedhi.png");
549
550
551         statusbar_cancel_data = new_image_set(3,
552                 "statusbar_cancel_up.png",
553                 "statusbar_cancel_hi.png",
554                 "statusbar_cancel_dn.png");
555
556
557         VFrame *editpanel_up = new_image("editpanel_up.png");
558         VFrame *editpanel_hi = new_image("editpanel_hi.png");
559         VFrame *editpanel_dn = new_image("editpanel_dn.png");
560         VFrame *editpanel_checked = new_image("editpanel_checked.png");
561         VFrame *editpanel_checkedhi = new_image("editpanel_checkedhi.png");
562
563         new_image("panel_divider", "panel_divider.png");
564         new_button("bottom_justify.png", editpanel_up, editpanel_hi, editpanel_dn, "bottom_justify");
565         new_button("center_justify.png", editpanel_up, editpanel_hi, editpanel_dn, "center_justify");
566         new_button("channel.png", editpanel_up, editpanel_hi, editpanel_dn, "channel");
567
568
569         //bottom_justify = new_button("bottom_justify.png", editpanel_up, editpanel_hi, editpanel_dn);
570         //center_justify = new_button("center_justify.png", editpanel_up, editpanel_hi, editpanel_dn);
571         //channel_data = new_button("channel.png", editpanel_up, editpanel_hi, editpanel_dn);
572         new_button("copy.png", editpanel_up, editpanel_hi, editpanel_dn, "copy");
573         new_button("commercial.png", editpanel_up, editpanel_hi, editpanel_dn, "commercial");
574         new_button("cut.png", editpanel_up, editpanel_hi, editpanel_dn, "cut");
575         new_button("fit.png", editpanel_up, editpanel_hi, editpanel_dn, "fit");
576         new_button("fitautos.png", editpanel_up, editpanel_hi, editpanel_dn, "fitautos");
577         new_button("inpoint.png", editpanel_up, editpanel_hi, editpanel_dn, "inbutton");
578         new_button("label.png", editpanel_up, editpanel_hi, editpanel_dn, "labelbutton");
579         new_button("left_justify.png", editpanel_up, editpanel_hi, editpanel_dn, "left_justify");
580         new_button("magnify.png", editpanel_up, editpanel_hi, editpanel_dn, "magnify_button");
581         new_button("middle_justify.png", editpanel_up, editpanel_hi, editpanel_dn, "middle_justify");
582         new_button("nextlabel.png", editpanel_up, editpanel_hi, editpanel_dn, "nextlabel");
583         new_button("outpoint.png", editpanel_up, editpanel_hi, editpanel_dn, "outbutton");
584         over_button = new_button("over.png", editpanel_up, editpanel_hi, editpanel_dn);
585         overwrite_data = new_button("overwrite.png", editpanel_up, editpanel_hi, editpanel_dn);
586         new_button("paste.png", editpanel_up, editpanel_hi, editpanel_dn, "paste");
587         new_button("prevlabel.png", editpanel_up, editpanel_hi, editpanel_dn, "prevlabel");
588         new_button("nextedit.png", editpanel_up, editpanel_hi, editpanel_dn, "nextedit");
589         new_button("prevedit.png", editpanel_up, editpanel_hi, editpanel_dn, "prevedit");
590         new_button("redo.png", editpanel_up, editpanel_hi, editpanel_dn, "redo");
591         new_button("right_justify.png", editpanel_up, editpanel_hi, editpanel_dn, "right_justify");
592         splice_data = new_button("splice.png", editpanel_up, editpanel_hi, editpanel_dn);
593         new_button("toclip.png", editpanel_up, editpanel_hi, editpanel_dn, "toclip");
594         new_button("goto.png", editpanel_up, editpanel_hi, editpanel_dn, "goto");
595         new_button("top_justify.png", editpanel_up, editpanel_hi, editpanel_dn, "top_justify");
596         new_button("undo.png", editpanel_up, editpanel_hi, editpanel_dn, "undo");
597         //new_button("wrench.png", editpanel_up, editpanel_hi, editpanel_dn, "wrench");
598         //wrench_data = new_button("wrench.png", editpanel_up, editpanel_hi, editpanel_dn);
599
600 // CWindow icons
601         new_image("cwindow_inactive", "cwindow_inactive.png");
602         new_image("cwindow_active", "cwindow_active.png");
603
604 #define TRANSPORT_LEFT_IMAGES  "transport_left_up.png", "transport_left_hi.png", "transport_left_dn.png"
605 #define TRANSPORT_CENTER_IMAGES  "transport_center_up.png", "transport_center_hi.png", "transport_center_dn.png"
606 #define TRANSPORT_RIGHT_IMAGES  "transport_right_up.png", "transport_right_hi.png", "transport_right_dn.png"
607
608         new_button("end.png", TRANSPORT_RIGHT_IMAGES, "end");
609         new_button("fastfwd.png",TRANSPORT_CENTER_IMAGES, "fastfwd");
610         new_button("fastrev.png",TRANSPORT_CENTER_IMAGES, "fastrev");
611         new_button("play.png",TRANSPORT_CENTER_IMAGES, "play");
612         new_button("framefwd.png", TRANSPORT_CENTER_IMAGES, "framefwd");
613         new_button("framerev.png", TRANSPORT_CENTER_IMAGES, "framerev");
614         new_button("pause.png", TRANSPORT_CENTER_IMAGES, "pause");
615         new_button("record.png", TRANSPORT_CENTER_IMAGES, "record");
616         new_button("singleframe.png", TRANSPORT_CENTER_IMAGES, "recframe");
617         new_button("reverse.png", TRANSPORT_CENTER_IMAGES, "reverse");
618         new_button("rewind.png", TRANSPORT_LEFT_IMAGES, "rewind");
619         new_button("stop.png", TRANSPORT_CENTER_IMAGES, "stop");
620         new_button("stop.png", TRANSPORT_RIGHT_IMAGES, "stoprec");
621         new_image_set("batch_render_start",
622                 3,
623                 "batchstart_up.png",
624                 "batchstart_hi.png",
625                 "batchstart_dn.png");
626         new_image_set("batch_render_stop",
627                 3,
628                 "batchstop_up.png",
629                 "batchstop_hi.png",
630                 "batchstop_dn.png");
631         new_image_set("batch_render_cancel",
632                 3,
633                 "batchcancel_up.png",
634                 "batchcancel_hi.png",
635                 "batchcancel_dn.png");
636
637
638         new_toggle("arrow.png", editpanel_up, editpanel_hi, editpanel_checked, editpanel_dn, editpanel_checkedhi, "arrow");
639         new_toggle("autokeyframe.png", editpanel_up, editpanel_hi, editpanel_checked, editpanel_dn, editpanel_checkedhi, "autokeyframe");
640         new_image_set("category_button",
641                 3,
642                 "preferencesbutton_dn.png",
643                 "preferencesbutton_dnhi.png",
644                 "preferencesbutton_dnlo.png");
645         //camera_data = new_toggle("camera.png", editpanel_up, editpanel_hi, editpanel_checked, editpanel_dn, editpanel_checkedhi);
646         //crop_data = new_toggle("crop.png", editpanel_up, editpanel_hi, editpanel_checked, editpanel_dn, editpanel_checkedhi);
647         new_toggle("ibeam.png", editpanel_up, editpanel_hi, editpanel_checked, editpanel_dn, editpanel_checkedhi, "ibeam");
648         //magnify_data = new_toggle("magnify.png", editpanel_up, editpanel_hi, editpanel_checked, editpanel_dn, editpanel_checkedhi);
649         //mask_data = new_toggle("mask.png", editpanel_up, editpanel_hi, editpanel_checked, editpanel_dn, editpanel_checkedhi);
650         //proj_data = new_toggle("projector.png", editpanel_up, editpanel_hi, editpanel_checked, editpanel_dn, editpanel_checkedhi);
651         //protect_data = new_toggle("protect.png", editpanel_up, editpanel_hi, editpanel_checked, editpanel_dn, editpanel_checkedhi);
652         //show_meters = new_toggle("show_meters.png", editpanel_up, editpanel_hi, editpanel_checked, editpanel_dn, editpanel_checkedhi);
653         //titlesafe_data = new_toggle("titlesafe.png", editpanel_up, editpanel_hi, editpanel_checked, editpanel_dn, editpanel_checkedhi);
654         //tool_data = new_toggle("toolwindow.png", editpanel_up, editpanel_hi, editpanel_checked, editpanel_dn, editpanel_checkedhi);
655         new_toggle("eyedrop.png", 
656                 editpanel_up, 
657                 editpanel_hi, 
658                 editpanel_checked, 
659                 editpanel_dn, 
660                 editpanel_checkedhi, 
661                 "cwindow_eyedrop");
662
663         new_image_set("category_button_checked",
664                 3,
665                 "preferencesbutton_up.png",
666                 "preferencesbutton_uphi.png",
667                 "preferencesbutton_dnlo.png");
668
669
670
671
672
673
674         static VFrame **transport_bg = new_image_set(3,
675                 "transportup.png", 
676                 "transporthi.png", 
677                 "transportdn.png");
678         new_toggle("show_meters.png", editpanel_up, editpanel_hi, editpanel_checked, editpanel_dn, editpanel_checkedhi, "meters");
679         build_transport((char*)"end", get_image_data("end.png"), transport_bg, 2);
680         build_transport((char*)"fastfwd", get_image_data("fastfwd.png"), transport_bg, 1);
681         build_transport((char*)"fastrev", get_image_data("fastrev.png"), transport_bg, 1);
682         build_transport((char*)"play", get_image_data("play.png"), transport_bg, 1);
683         build_transport((char*)"framefwd", get_image_data("framefwd.png"), transport_bg, 1);
684         build_transport((char*)"framerev", get_image_data("framerev.png"), transport_bg, 1);
685         build_transport((char*)"pause", get_image_data("pause.png"), transport_bg, 1);
686         build_transport((char*)"record", get_image_data("record.png"), transport_bg, 1);
687         build_transport((char*)"singleframe", get_image_data("singleframe.png"), transport_bg, 1);
688         build_transport((char*)"reverse", get_image_data("reverse.png"), transport_bg, 1);
689         build_transport((char*)"rewind", get_image_data("rewind.png"), transport_bg, 0);
690         build_transport((char*)"stop", get_image_data("stop.png"), transport_bg, 1);
691         build_transport((char*)"stoprec", get_image_data("stoprec.png"), transport_bg, 2);
692
693         VFrame *cpanel_up = new_image("editpanel_up.png");
694         VFrame *cpanel_hi = new_image("editpanel_hi.png");
695         VFrame *cpanel_dn = new_image("editpanel_dn.png");
696         VFrame *cpanel_checked = new_image("editpanel_checked.png");
697         VFrame *cpanel_checkedhi = new_image("editpanel_checkedhi.png");
698         new_toggle("camera.png", cpanel_up, cpanel_hi, cpanel_checked, cpanel_dn, cpanel_checkedhi, "camera");
699         new_toggle("crop.png", cpanel_up, cpanel_hi, cpanel_checked, cpanel_dn, cpanel_checkedhi, "crop");
700         new_toggle("eyedrop.png", cpanel_up, cpanel_hi, cpanel_checked, cpanel_dn, cpanel_checkedhi, "eyedrop");
701         new_toggle("magnify.png", cpanel_up, cpanel_hi, cpanel_checked, cpanel_dn, cpanel_checkedhi, "magnify");
702         new_toggle("mask.png", cpanel_up, cpanel_hi, cpanel_checked, cpanel_dn, cpanel_checkedhi, "mask");
703         new_toggle("ruler.png", cpanel_up, cpanel_hi, cpanel_checked, cpanel_dn, cpanel_checkedhi, "ruler");
704         new_toggle("projector.png", cpanel_up, cpanel_hi, cpanel_checked, cpanel_dn, cpanel_checkedhi, "projector");
705         new_toggle("protect.png", cpanel_up, cpanel_hi, cpanel_checked, cpanel_dn, cpanel_checkedhi, "protect");
706         new_toggle("titlesafe.png", cpanel_up, cpanel_hi, cpanel_checked, cpanel_dn, cpanel_checkedhi, "titlesafe");
707         new_toggle("toolwindow.png", cpanel_up, cpanel_hi, cpanel_checked, cpanel_dn, cpanel_checkedhi, "tool");
708         // toggle for tangent mode (compositor/tool window)
709         new_toggle("tan_smooth.png", editpanel_up, editpanel_hi, editpanel_checked, editpanel_dn, editpanel_checkedhi, "tan_smooth");
710         new_toggle("tan_linear.png", editpanel_up, editpanel_hi, editpanel_checked, editpanel_dn, editpanel_checkedhi, "tan_linear");
711
712         flush_images();
713
714         new_toggle("blank30x30.png", 
715                    new_image("locklabels_locked.png"),
716                    new_image("locklabels_lockedhi.png"),
717                    new_image("locklabels_unlocked.png"),
718                    new_image("locklabels_dn.png"), // can't have seperate down for each!!??
719                    new_image("locklabels_unlockedhi.png"),
720                    "locklabels");
721         title_font = MEDIUMFONT_3D;
722         title_color = WHITE;
723         recordgui_fixed_color = YELLOW;
724         recordgui_variable_color = RED;
725         resources->medium_font = "-*-helvetica-bold-r-normal-*-14-*";
726
727         channel_position_color = MEYELLOW;
728         resources->meter_title_w = 25;
729
730         // (asset) edit info text color
731         edit_font_color = YELLOW;
732
733         //labels
734         resources->label_images = new_image_set(5,
735                 "radial_up.png", 
736                 "radial_hi.png", 
737                 "radial_checked.png", 
738                 "radial_dn.png", 
739                 "radial_checkedhi.png");
740
741         /*      resources->type_to_icon = new_image_set(5,
742             "file_folder.png",
743                 "file_unknown.png",
744                 "file_film.png",
745                 "file_sound.png",
746                 "file_column.png"); 
747    */
748 }
749
750
751 #define CWINDOW_METER_MARGIN 5
752 #define VWINDOW_METER_MARGIN 5
753
754
755 void BlondTheme::get_mwindow_sizes(MWindowGUI *gui, int w, int h)
756 {
757         mbuttons_x = 0;
758         mbuttons_y = gui->mainmenu->get_h();
759         mbuttons_w = w;
760         mbuttons_h = mbutton_left->get_h();
761         mclock_x = 10;
762         mclock_y = mbuttons_y + mbuttons_h + CWINDOW_METER_MARGIN;
763         mclock_w = get_image("clock_bg")->get_w() - 40;
764         mclock_h = get_image("clock_bg")->get_h();
765         mtimebar_x = get_image("patchbay_bg")->get_w();
766         mtimebar_y = mbuttons_y + mbuttons_h;
767         mtimebar_w = w - mtimebar_x;
768         mtimebar_h = get_image("timebar_bg")->get_h();
769         mstatus_x = 0;
770         mstatus_y = h - statusbar_left->get_h();
771         mstatus_w = w;
772         mstatus_h = statusbar_left->get_h();
773         mstatus_message_x = 10;
774         mstatus_message_y = 5;
775         mstatus_progress_x = mstatus_w - statusbar_cancel_data[0]->get_w() - 240;
776         mstatus_progress_y = mstatus_h - BC_WindowBase::get_resources()->progress_images[0]->get_h();
777         mstatus_progress_w = 230;
778         mstatus_cancel_x = mstatus_w - statusbar_cancel_data[0]->get_w();
779         mstatus_cancel_y = mstatus_h - statusbar_cancel_data[0]->get_h();
780         mzoom_x = 0;
781         mzoom_y = mstatus_y - zoombar_left->get_h();
782         mzoom_h = zoombar_left->get_h();
783         mzoom_w = w;
784         patchbay_x = 0;
785         patchbay_y = mtimebar_y + mtimebar_h;
786         patchbay_w = get_image("patchbay_bg")->get_w();
787         patchbay_h = mzoom_y - patchbay_y;
788         mcanvas_x = 0;
789         mcanvas_y = mtimebar_y + mtimebar_h;
790         mcanvas_w = w;
791         mcanvas_h = patchbay_h;
792         mhscroll_x = 0;
793         mhscroll_y = mcanvas_y + mcanvas_h;
794         mhscroll_w = w - BC_ScrollBar::get_span(SCROLL_VERT) - patchbay_w;
795         mvscroll_x = mcanvas_x + mcanvas_w;
796         mvscroll_y = mcanvas_y;
797         mvscroll_h = mcanvas_h;
798 }
799
800 void BlondTheme::get_cwindow_sizes(CWindowGUI *gui, int cwindow_controls)
801 {
802         if(cwindow_controls)
803         {
804                 ccomposite_x = 0;
805                 ccomposite_y = 5;
806                 ccomposite_w = cpanel_bg->get_w();
807                 ccomposite_h = mwindow->session->cwindow_h - cbuttons_left->get_h();
808                 cedit_x = 10;
809                 cedit_y = ccomposite_h + 17;
810                 ctransport_x = 10;
811                 ctransport_y = mwindow->session->cwindow_h - get_image_set("autokeyframe")[0]->get_h();
812                 ccanvas_x = ccomposite_x + ccomposite_w;
813                 ccanvas_y = 0;
814                 ccanvas_h = ccomposite_h;
815                 cstatus_x = 525;
816                 cstatus_y = mwindow->session->cwindow_h - 40;
817                 if(mwindow->edl->session->cwindow_meter)
818                 {
819                         cmeter_x = mwindow->session->cwindow_w - MeterPanel::get_meters_width(this,mwindow->edl->session->audio_channels, 
820                                 mwindow->edl->session->cwindow_meter);
821                         ccanvas_w = cmeter_x - ccanvas_x - 5;
822                 }
823                 else
824                 {
825                         cmeter_x = mwindow->session->cwindow_w;
826                         ccanvas_w = cmeter_x - ccanvas_x;
827                 }
828 SET_TRACE
829         }
830         else
831         {
832 SET_TRACE
833                 ccomposite_x = -get_image("cpanel_bg")->get_w();
834                 ccomposite_x = -cpanel_bg->get_w();
835                 ccomposite_y = 0;
836                 ccomposite_w = get_image("cpanel_bg")->get_w();
837                 ccomposite_h = mwindow->session->cwindow_h - get_image("cbuttons_left")->get_h();
838
839                 cedit_x = 10;
840                 cedit_y = mwindow->session->cwindow_h + 17;
841                 ctransport_x = 10;
842                 ctransport_y = cedit_y + 40;
843                 ccanvas_x = 0;
844                 ccanvas_y = 0;
845                 ccanvas_w = mwindow->session->cwindow_w;
846                 ccanvas_h = mwindow->session->cwindow_h;
847                 cmeter_x = mwindow->session->cwindow_w;
848                 cstatus_x = mwindow->session->cwindow_w;
849                 cstatus_y = mwindow->session->cwindow_h;
850 SET_TRACE
851         }
852
853 SET_TRACE
854
855         czoom_x = ctransport_x + PlayTransport::get_transport_width(mwindow) + 20;
856         czoom_y = ctransport_y + 5;
857
858
859         cmeter_y = 5;
860         cmeter_h = mwindow->session->cwindow_h - cmeter_y;
861
862         cslider_w = ccanvas_x + ccanvas_w - cslider_x - 5;
863         ctimebar_x = ccanvas_x;
864         ctimebar_y = ccanvas_y + ccanvas_h;
865         ctimebar_w = ccanvas_w;
866         ctimebar_h = 16;
867
868
869 // Not used
870         ctime_x = ctransport_x + PlayTransport::get_transport_width(mwindow);
871         ctime_y = ctransport_y;
872         cdest_x = czoom_x;
873         cdest_y = czoom_y + 30;
874 SET_TRACE
875 }
876
877
878 void BlondTheme::get_recordgui_sizes(RecordGUI *gui, int w, int h)
879 {
880         
881         recordgui_status_x = 10;
882         recordgui_status_y = 10;
883         recordgui_status_x2 = 160;
884         recordgui_batch_x = 310;
885         recordgui_batch_y = 10;
886         recordgui_batchcaption_x = recordgui_batch_x + 110;
887
888
889         recordgui_transport_x = recordgui_batch_x;
890         recordgui_transport_y = recordgui_batch_y + 150;
891
892         //recordgui_buttons_x = recordgui_batch_x - 50;
893         //recordgui_buttons_y = recordgui_transport_y + 40;
894         //recordgui_options_x = recordgui_buttons_x;
895         //recordgui_options_y = recordgui_buttons_y + 35;
896
897         recordgui_batches_x = 10;
898         recordgui_batches_y = 270;
899         recordgui_batches_w = w - 20;
900         recordgui_batches_h = h - recordgui_batches_y - 70;
901         recordgui_loadmode_x = w / 2 - loadmode_w / 2;
902         recordgui_loadmode_y = h - 60;
903
904         recordgui_controls_x = 10;
905         recordgui_controls_y = h - 40;
906 }
907 /*
908 void BlondTheme::get_rmonitor_sizes(int do_audio, 
909         int do_video,
910         int do_channel,
911         int do_interlace,
912         int do_avc,
913         int audio_channels)
914 {
915         Theme::get_rmonitor_sizes(do_audio,
916                 do_video,
917                 do_channel,
918                 do_interlace,
919                 do_avc,
920                 audio_channels);
921         if(!do_video && do_audio)
922         {
923                 rmonitor_meter_y -= 30;
924                 rmonitor_meter_h += 30;
925         }
926 }
927 */
928
929 void BlondTheme::get_vwindow_sizes(VWindowGUI *gui)
930 {
931         vmeter_y = 5;
932         vmeter_h = mwindow->session->vwindow_h - cmeter_y;
933         vcanvas_x = 0;
934         vcanvas_y = 0;
935         vcanvas_h = mwindow->session->vwindow_h - vbuttons_left->get_h();
936
937         if(mwindow->edl->session->vwindow_meter)
938         {
939                 rmonitor_meter_y -= 30;
940                 rmonitor_meter_h += 30;
941                 vmeter_x = mwindow->session->vwindow_w - 
942                         VWINDOW_METER_MARGIN - 
943                         MeterPanel::get_meters_width(this,
944                                 mwindow->edl->session->audio_channels, 
945                                 mwindow->edl->session->vwindow_meter);
946                 vcanvas_w = vmeter_x - vcanvas_x - VWINDOW_METER_MARGIN;
947         }
948         else
949         {
950                 vmeter_x = mwindow->session->vwindow_w;
951                 vcanvas_w = mwindow->session->vwindow_w;
952         }
953
954         vtimebar_x = vcanvas_x;
955         vtimebar_y = vcanvas_y + vcanvas_h;
956         vtimebar_w = vcanvas_w;
957         vtimebar_h = 16;
958
959         vslider_x = 10;
960         vslider_y = vtimebar_y + 25;
961         vslider_w = vtimebar_w - vslider_x;
962         vedit_x = 10;
963         vedit_y = vslider_y + BC_Slider::get_span(0);
964         vtransport_x = 10;
965         vtransport_y = mwindow->session->vwindow_h - 
966                 get_image_set("autokeyframe")[0]->get_h();
967         vtime_x = 380;
968         vtime_y = vedit_y + 10;
969         vtime_w = 125;
970 }
971
972
973
974
975
976 void BlondTheme::build_icons()
977 {
978         new_image("mwindow_icon", "heroine_icon.png");
979         new_image("vwindow_icon", "heroine_icon.png");
980         new_image("cwindow_icon", "heroine_icon.png");
981         new_image("awindow_icon", "heroine_icon.png");
982         new_image("record_icon", "heroine_icon.png");
983         new_image("clip_icon", "clip_icon.png");
984 }
985
986
987
988 void BlondTheme::build_bg_data()
989 {
990 // Audio settings
991         channel_bg_data = new VFrame(get_image_data("channel_bg.png"));
992         channel_position_data = new VFrame(get_image_data("channel_position.png"));
993
994 // Track bitmaps
995         new_image("resource1024", "resource1024.png");
996         new_image("resource512", "resource512.png");
997         new_image("resource256", "resource256.png");
998         new_image("resource128", "resource128.png");
999         new_image("resource64", "resource64.png");
1000         new_image("resource32", "resource32.png");
1001         new_image("plugin_bg_data", "plugin_bg.png");
1002         new_image("title_bg_data", "title_bg.png");
1003         new_image("vtimebar_bg_data", "vwindow_timebar.png");
1004 }
1005
1006
1007
1008 void BlondTheme::build_overlays()
1009 {
1010         keyframe_data = new VFrame(get_image_data("keyframe3.png"));
1011         camerakeyframe_data = new VFrame(get_image_data("camerakeyframe.png"));
1012         maskkeyframe_data = new VFrame(get_image_data("maskkeyframe.png"));
1013         modekeyframe_data = new VFrame(get_image_data("modekeyframe.png"));
1014         pankeyframe_data = new VFrame(get_image_data("pankeyframe.png"));
1015         projectorkeyframe_data = new VFrame(get_image_data("projectorkeyframe.png"));
1016 }
1017
1018
1019
1020
1021
1022
1023
1024
1025
1026 void BlondTheme::draw_rwindow_bg(RecordGUI *gui)
1027 {
1028 //      int y;
1029 //      int margin = 50;
1030 //      int margin2 = 80;
1031 //      gui->draw_9segment(recordgui_batch_x - margin,
1032 //              0,
1033 //              mwindow->session->rwindow_w - recordgui_status_x + margin,
1034 //              recordgui_buttons_y,
1035 //              rgui_batch);
1036 //      gui->draw_3segmenth(recordgui_options_x - margin2,
1037 //              recordgui_buttons_y - 5,
1038 //              mwindow->session->rwindow_w - recordgui_options_x + margin2,
1039 //              rgui_controls);
1040 //      y = recordgui_buttons_y - 5 + rgui_controls->get_h();
1041 //      gui->draw_9segment(0,
1042 //              y,
1043 //              mwindow->session->rwindow_w,
1044 //              mwindow->session->rwindow_h - y,
1045 //              rgui_list);
1046 }
1047
1048 void BlondTheme::draw_rmonitor_bg(RecordMonitorGUI *gui)
1049 {
1050 //      int margin = 45;
1051 //      int panel_w = 300;
1052 //      int x = rmonitor_meter_x - margin;
1053 //      int w = mwindow->session->rmonitor_w - x;
1054 //      if(w < rmonitor_meters->get_w()) w = rmonitor_meters->get_w();
1055 //      gui->clear_box(0, 
1056 //              0, 
1057 //              mwindow->session->rmonitor_w, 
1058 //              mwindow->session->rmonitor_h);
1059 //      gui->draw_9segment(x,
1060 //              0,
1061 //              w,
1062 //              mwindow->session->rmonitor_h,
1063 //              rmonitor_meters);
1064 }
1065
1066
1067
1068
1069
1070
1071 void BlondTheme::draw_mwindow_bg(MWindowGUI *gui)
1072 {
1073 // Button bar
1074         gui->draw_3segmenth(mbuttons_x, 
1075                 mbuttons_y, 
1076                 750, 
1077                 mbutton_left);
1078         gui->draw_3segmenth(mbuttons_x + 750, 
1079                 mbuttons_y, 
1080                 mbuttons_w - 500, 
1081                 mbutton_right);
1082
1083 // Clock
1084         gui->draw_3segmenth(0, 
1085                 mbuttons_y + mbutton_left->get_h(),
1086                 get_image("patchbay_bg")->get_w(), 
1087                 get_image("clock_bg"));
1088
1089 // Patchbay
1090         gui->draw_3segmentv(patchbay_x, 
1091                 patchbay_y, 
1092                 patchbay_h + 20, 
1093                 get_image("patchbay_bg"));
1094
1095 // Track canvas
1096         gui->draw_9segment(mcanvas_x, 
1097                 mcanvas_y, 
1098                 mcanvas_w, 
1099                 patchbay_h + 20, 
1100                 tracks_bg);
1101
1102 // Timebar
1103         gui->draw_3segmenth(mtimebar_x, 
1104                 mtimebar_y, 
1105                 mtimebar_w, 
1106                 get_image("timebar_bg"));
1107
1108 // Zoombar
1109         int zoombar_center = 710;
1110         gui->draw_3segmenth(mzoom_x, 
1111                 mzoom_y,
1112                 zoombar_center, 
1113                 zoombar_left);
1114         if(mzoom_w > zoombar_center)
1115                 gui->draw_3segmenth(mzoom_x + zoombar_center, 
1116                         mzoom_y, 
1117                         mzoom_w - zoombar_center, 
1118                         zoombar_right);
1119
1120 // Status
1121         gui->draw_3segmenth(mstatus_x, 
1122                 mstatus_y,
1123                 zoombar_center, 
1124                 statusbar_left);
1125
1126         if(mstatus_w > zoombar_center)
1127                 gui->draw_3segmenth(mstatus_x + zoombar_center, 
1128                         mstatus_y,
1129                         mstatus_w - zoombar_center, 
1130                         statusbar_right);
1131 }
1132
1133 void BlondTheme::draw_cwindow_bg(CWindowGUI *gui)
1134 {
1135         const int button_division = 570;
1136         gui->draw_3segmentv(0, 0, ccomposite_h, get_image("cpanel_bg"));
1137         gui->draw_3segmenth(0, ccomposite_h, button_division, get_image("cbuttons_left"));
1138         if(mwindow->edl->session->cwindow_meter)
1139         {
1140                 gui->draw_3segmenth(button_division, 
1141                         ccomposite_h, 
1142                         cmeter_x - CWINDOW_METER_MARGIN - button_division, 
1143                         get_image("cbuttons_right"));
1144                 gui->draw_9segment(cmeter_x - CWINDOW_METER_MARGIN, 
1145                         0, 
1146                         mwindow->session->cwindow_w - cmeter_x + CWINDOW_METER_MARGIN, 
1147                         mwindow->session->cwindow_h, 
1148                         get_image("cmeter_bg"));
1149         }
1150         else
1151         {
1152                 gui->draw_3segmenth(button_division, 
1153                         ccomposite_h, 
1154                         cmeter_x - CWINDOW_METER_MARGIN - button_division + 100, 
1155                         get_image("cbuttons_right"));
1156         }
1157 }
1158
1159 void BlondTheme::draw_vwindow_bg(VWindowGUI *gui)
1160 {
1161         const int button_division = 400;
1162         gui->draw_3segmenth(0, 
1163                 vcanvas_h, 
1164                 button_division, 
1165                 get_image("vbuttons_left"));
1166         if(mwindow->edl->session->vwindow_meter)
1167         {
1168                 gui->draw_3segmenth(button_division, 
1169                         vcanvas_h, 
1170                         vmeter_x - VWINDOW_METER_MARGIN - button_division, 
1171                         get_image("cbuttons_right"));
1172                 gui->draw_9segment(vmeter_x - VWINDOW_METER_MARGIN,
1173                         0,
1174                         mwindow->session->vwindow_w - vmeter_x + VWINDOW_METER_MARGIN, 
1175                         mwindow->session->vwindow_h, 
1176                         get_image("cmeter_bg"));
1177         }
1178         else
1179         {
1180                 gui->draw_3segmenth(button_division, 
1181                         vcanvas_h, 
1182                         vmeter_x - VWINDOW_METER_MARGIN - button_division + 100, 
1183                         get_image("cbuttons_right"));
1184         }
1185 }
1186
1187 void BlondTheme::get_preferences_sizes()
1188 {
1189 }
1190
1191
1192 void BlondTheme::draw_preferences_bg(PreferencesWindow *gui)
1193 {
1194         gui->draw_vframe(get_image("preferences_bg"), 0, 0);
1195 }
1196
1197 void BlondTheme::get_new_sizes(NewWindow *gui)
1198 {
1199 }
1200
1201 void BlondTheme::draw_new_bg(NewWindow *gui)
1202 {
1203         gui->draw_vframe(get_image("new_bg"), 0, 0);
1204 }
1205
1206 void BlondTheme::draw_setformat_bg(SetFormatWindow *gui)
1207 {
1208         gui->draw_vframe(get_image("setformat_bg"), 0, 0);
1209         gui->draw_vframe(setformat_bg, 0, 0);
1210 }
1211
1212
1213 // pmd: SUV (same), 1_2_2blond (nonexist)
1214 void BlondTheme::get_plugindialog_sizes()
1215 {
1216         int x = 10, y = 30;
1217         plugindialog_new_x = x;
1218         plugindialog_new_y = y;
1219         plugindialog_shared_x = mwindow->session->plugindialog_w / 3;
1220         plugindialog_shared_y = y;
1221         plugindialog_module_x = mwindow->session->plugindialog_w * 2 / 3;
1222         plugindialog_module_y = y;
1223
1224         plugindialog_new_w = plugindialog_shared_x - plugindialog_new_x - 10;
1225         plugindialog_new_h = mwindow->session->plugindialog_h - 120;
1226         plugindialog_shared_w = plugindialog_module_x - plugindialog_shared_x - 10;
1227         plugindialog_shared_h = mwindow->session->plugindialog_h - 120;
1228         plugindialog_module_w = mwindow->session->plugindialog_w - plugindialog_module_x - 10;
1229         plugindialog_module_h = mwindow->session->plugindialog_h - 120;
1230
1231         plugindialog_newattach_x = plugindialog_new_x + 20;
1232         plugindialog_newattach_y = plugindialog_new_y + plugindialog_new_h + 10;
1233         plugindialog_sharedattach_x = plugindialog_shared_x + 20;
1234         plugindialog_sharedattach_y = plugindialog_shared_y + plugindialog_shared_h + 10;
1235         plugindialog_moduleattach_x = plugindialog_module_x + 20;
1236         plugindialog_moduleattach_y = plugindialog_module_y + plugindialog_module_h + 10;
1237 }
1238
1239
1240
1241