1 /* === S Y N F I G ========================================================= */
2 /*! \file gtkmm/renddesc.cpp
3 ** \brief Template File
8 ** Copyright (c) 2002-2005 Robert B. Quattlebaum Jr., Adrian Bentley
10 ** This package is free software; you can redistribute it and/or
11 ** modify it under the terms of the GNU General Public License as
12 ** published by the Free Software Foundation; either version 2 of
13 ** the License, or (at your option) any later version.
15 ** This package is distributed in the hope that it will be useful,
16 ** but WITHOUT ANY WARRANTY; without even the implied warranty of
17 ** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
18 ** General Public License for more details.
21 /* ========================================================================= */
23 /* === H E A D E R S ======================================================= */
33 #include <gtkmm/label.h>
34 #include <gtkmm/frame.h>
35 #include <gtkmm/alignment.h>
36 #include <gtkmm/box.h>
38 #include <synfig/general.h>
39 //#include <gtkmm/seperator.h>
43 /* === U S I N G =========================================================== */
47 using namespace synfig;
48 using namespace studio;
50 /* === M A C R O S ========================================================= */
52 #ifndef SYNFIG_MAX_PIXEL_WIDTH
53 #define SYNFIG_MAX_PIXEL_WIDTH (~(1<<31))
56 #ifndef SYNFIG_MAX_PIXEL_HEIGHT
57 #define SYNFIG_MAX_PIXEL_HEIGHT (~(1<<31))
65 #define DPM2DPI(x) ((x)/39.3700787402)
66 #define DPI2DPM(x) ((x)*39.3700787402)
70 #define METERS2INCHES(x) ((x)*39.3700787402)
71 #define INCHES2METERS(x) ((x)/39.3700787402)
74 /* === G L O B A L S ======================================================= */
76 /* === P R O C E D U R E S ================================================= */
78 /* === M E T H O D S ======================================================= */
80 Widget_RendDesc::Widget_RendDesc():
82 adjustment_width(1,1,SYNFIG_MAX_PIXEL_WIDTH),
83 adjustment_height(1,1,SYNFIG_MAX_PIXEL_HEIGHT),
84 adjustment_xres(0,0,10000000),
85 adjustment_yres(0,0,10000000),
86 adjustment_phy_width(0,0,10000000),
87 adjustment_phy_height(0,0,10000000),
88 adjustment_fps(0,0,10000000),
89 adjustment_span(0,0,10000000)
96 Gtk::Label *image_tab_label = manage(new Gtk::Label(_("Image")));
97 Gtk::Label *time_tab_label = manage(new Gtk::Label(_("Time")));
98 Gtk::Label *other_tab_label = manage(new Gtk::Label(_("Other")));
99 Gtk::Widget *imageTab = create_image_tab();
100 Gtk::Widget *timeTab = create_time_tab();
101 Gtk::Widget *otherTab = create_other_tab();
102 append_page(*imageTab, *image_tab_label);
103 append_page(*timeTab, *time_tab_label);
104 append_page(*otherTab, *other_tab_label);
107 Widget_RendDesc::~Widget_RendDesc()
111 void Widget_RendDesc::set_rend_desc(const synfig::RendDesc &rend_desc)
113 if(update_lock)return;
115 rend_desc_=rend_desc;
120 Widget_RendDesc::refresh()
122 UpdateLock lock(update_lock);
123 adjustment_width.set_value(rend_desc_.get_w());
124 adjustment_height.set_value(rend_desc_.get_h());
125 adjustment_phy_width.set_value(METERS2INCHES(rend_desc_.get_physical_w()));
126 adjustment_phy_height.set_value(METERS2INCHES(rend_desc_.get_physical_h()));
127 adjustment_xres.set_value(DPM2DPI(rend_desc_.get_x_res()));
128 adjustment_yres.set_value(DPM2DPI(rend_desc_.get_y_res()));
129 entry_start_time->set_fps(rend_desc_.get_frame_rate());
130 entry_start_time->set_value(rend_desc_.get_time_start());
131 entry_end_time->set_fps(rend_desc_.get_frame_rate());
132 entry_end_time->set_value(rend_desc_.get_time_end());
134 adjustment_fps.set_value(rend_desc_.get_frame_rate());
135 adjustment_span.set_value(rend_desc_.get_span());
136 entry_tl->set_value(rend_desc_.get_tl());
137 entry_br->set_value(rend_desc_.get_br());
138 entry_focus->set_value(rend_desc_.get_focus());
140 toggle_px_aspect->set_active((bool)(rend_desc_.get_flags()&RendDesc::PX_ASPECT));
141 toggle_px_width->set_active((bool)(rend_desc_.get_flags()&RendDesc::PX_W));
142 toggle_px_height->set_active((bool)(rend_desc_.get_flags()&RendDesc::PX_H));
144 toggle_im_aspect->set_active((bool)(rend_desc_.get_flags()&RendDesc::IM_ASPECT));
145 toggle_im_width->set_active((bool)(rend_desc_.get_flags()&RendDesc::IM_W));
146 toggle_im_height->set_active((bool)(rend_desc_.get_flags()&RendDesc::IM_H));
147 toggle_im_span->set_active((bool)(rend_desc_.get_flags()&RendDesc::IM_SPAN));
150 void Widget_RendDesc::apply_rend_desc(const synfig::RendDesc &rend_desc)
152 set_rend_desc(rend_desc);
155 const synfig::RendDesc &
156 Widget_RendDesc::get_rend_desc()
162 Widget_RendDesc::on_width_changed()
164 if(update_lock)return;
165 UpdateLock lock(update_lock);
166 rend_desc_.set_w(round_to_int(adjustment_width.get_value()));
172 Widget_RendDesc::on_lock_changed()
174 if(update_lock)return;
175 UpdateLock lock(update_lock);
177 #define DO_TOGGLE(x,y) if(toggle_ ## x->get_active()) \
178 rend_desc_.set_flags(rend_desc_.get_flags()|RendDesc:: y); \
180 rend_desc_.set_flags(rend_desc_.get_flags()&~RendDesc:: y)
182 DO_TOGGLE(px_aspect,PX_ASPECT);
183 DO_TOGGLE(px_width,PX_W);
184 DO_TOGGLE(px_height,PX_H);
186 DO_TOGGLE(im_aspect,IM_ASPECT);
187 DO_TOGGLE(im_width,IM_W);
188 DO_TOGGLE(im_height,IM_H);
189 DO_TOGGLE(im_span,IM_SPAN);
198 Widget_RendDesc::on_height_changed()
200 if(update_lock)return;
201 UpdateLock lock(update_lock);
202 rend_desc_.set_h(round_to_int(adjustment_height.get_value()));
208 Widget_RendDesc::on_phy_width_changed()
210 if(update_lock)return;
211 UpdateLock lock(update_lock);
212 rend_desc_.set_physical_w(INCHES2METERS(adjustment_phy_width.get_value()));
218 Widget_RendDesc::on_phy_height_changed()
220 if(update_lock)return;
221 UpdateLock lock(update_lock);
222 rend_desc_.set_physical_h(INCHES2METERS(adjustment_phy_height.get_value()));
228 Widget_RendDesc::on_xres_changed()
230 if(update_lock)return;
231 UpdateLock lock(update_lock);
232 rend_desc_.set_x_res(DPI2DPM(adjustment_xres.get_value()));
238 Widget_RendDesc::on_yres_changed()
240 if(update_lock)return;
241 UpdateLock lock(update_lock);
242 rend_desc_.set_y_res(DPI2DPM(adjustment_yres.get_value()));
248 Widget_RendDesc::on_start_time_changed()
250 if(update_lock)return;
251 UpdateLock lock(update_lock);
252 rend_desc_.set_time_start(entry_start_time->get_value());
258 Widget_RendDesc::on_end_time_changed()
260 if(update_lock)return;
261 UpdateLock lock(update_lock);
262 rend_desc_.set_time_end(entry_end_time->get_value());
269 Widget_RendDesc::on_start_frame_changed()
271 if(update_lock)return;
272 UpdateLock lock(update_lock);
273 rend_desc_.set_frame_start((int)(adjustment_start_frame.get_value()+0.5));
279 Widget_RendDesc::on_end_frame_changed()
281 if(update_lock)return;
282 UpdateLock lock(update_lock);
283 rend_desc_.set_frame_end((int)(adjustment_end_frame.get_value()+0.5));
290 Widget_RendDesc::on_fps_changed()
292 if(update_lock)return;
293 UpdateLock lock(update_lock);
294 rend_desc_.set_frame_rate((int)(adjustment_fps.get_value()+0.5));
300 Widget_RendDesc::on_tl_changed()
302 if(update_lock)return;
303 UpdateLock lock(update_lock);
304 rend_desc_.set_tl(entry_tl->get_value());
310 Widget_RendDesc::on_br_changed()
312 if(update_lock)return;
313 UpdateLock lock(update_lock);
314 rend_desc_.set_br(entry_br->get_value());
320 Widget_RendDesc::on_focus_changed()
322 if(update_lock)return;
323 UpdateLock lock(update_lock);
324 rend_desc_.set_focus(entry_focus->get_value());
330 Widget_RendDesc::on_span_changed()
332 if(update_lock)return;
333 UpdateLock lock(update_lock);
334 rend_desc_.set_span(adjustment_span.get_value());
340 Widget_RendDesc::disable_time_section()
342 time_frame->set_sensitive(false);
345 Gtk::Table::TableList &list=time_table->children();
346 Gtk::Table::TableList::iterator iter;
347 for(iter=list.begin();iter!=list.end();iter++)
348 iter->get_widget()->set_sensitive(false);
353 Widget_RendDesc::enable_time_section()
355 time_frame->set_sensitive(true);
358 Gtk::Table::TableList &list=time_table->children();
359 Gtk::Table::TableList::iterator iter;
360 for(iter=list.begin();iter!=list.end();iter++)
361 iter->get_widget()->set_sensitive(true);
367 Widget_RendDesc::create_widgets()
369 entry_width=manage(new Gtk::SpinButton(adjustment_width,1,0));
370 entry_width->set_alignment(1);
371 entry_height=manage(new Gtk::SpinButton(adjustment_height,1,0));
372 entry_height->set_alignment(1);
373 entry_xres=manage(new Gtk::SpinButton(adjustment_xres,0.5,1));
374 entry_xres->set_alignment(1);
375 entry_yres=manage(new Gtk::SpinButton(adjustment_yres,0.5,1));
376 entry_yres->set_alignment(1);
377 entry_phy_width=manage(new Gtk::SpinButton(adjustment_phy_width,0.25,2));
378 entry_phy_width->set_alignment(1);
379 entry_phy_height=manage(new Gtk::SpinButton(adjustment_phy_height,0.25,2));
380 entry_phy_height->set_alignment(1);
381 entry_span=manage(new Gtk::SpinButton(adjustment_span,0.1,4));
382 entry_span->set_alignment(1);
383 entry_tl=manage(new Widget_Vector());
384 entry_br=manage(new Widget_Vector());
385 entry_fps=manage(new Gtk::SpinButton(adjustment_fps,1,5));
386 entry_start_time=manage(new Widget_Time());
387 entry_end_time=manage(new Widget_Time());
388 //entry_start_frame=manage(new Gtk::SpinButton(adjustment_start_frame,1,0));
389 //entry_end_frame=manage(new Gtk::SpinButton(adjustment_end_frame,1,0));
390 entry_focus=manage(new Widget_Vector());
391 toggle_px_aspect=manage(new Gtk::CheckButton(_("_Pixel Aspect"), true));
392 toggle_px_aspect->set_alignment(0, 0.5);
393 toggle_px_width=manage(new Gtk::CheckButton(_("Pi_xel Width"), true));
394 toggle_px_width->set_alignment(0, 0.5);
395 toggle_px_height=manage(new Gtk::CheckButton(_("Pix_el Height"), true));
396 toggle_px_height->set_alignment(0, 0.5);
397 toggle_im_aspect=manage(new Gtk::CheckButton(_("Image _Aspect"), true));
398 toggle_im_aspect->set_alignment(0, 0.5);
399 toggle_im_width=manage(new Gtk::CheckButton(_("Image _Width"), true));
400 toggle_im_width->set_alignment(0, 0.5);
401 toggle_im_height=manage(new Gtk::CheckButton(_("Image _Height"), true));
402 toggle_im_height->set_alignment(0, 0.5);
403 toggle_im_span=manage(new Gtk::CheckButton(_("Image _Span"), true));
404 toggle_im_span->set_alignment(0, 0.5);
405 time_frame=manage(new Gtk::Frame(_("Time")));
409 Widget_RendDesc::connect_signals()
411 entry_width->signal_value_changed().connect(sigc::mem_fun(*this,&studio::Widget_RendDesc::on_width_changed));
412 entry_height->signal_value_changed().connect(sigc::mem_fun(*this,&studio::Widget_RendDesc::on_height_changed));
413 entry_xres->signal_value_changed().connect(sigc::mem_fun(*this,&studio::Widget_RendDesc::on_xres_changed));
414 entry_yres->signal_value_changed().connect(sigc::mem_fun(*this,&studio::Widget_RendDesc::on_yres_changed));
415 entry_phy_width->signal_value_changed().connect(sigc::mem_fun(*this,&studio::Widget_RendDesc::on_phy_width_changed));
416 entry_phy_height->signal_value_changed().connect(sigc::mem_fun(*this,&studio::Widget_RendDesc::on_phy_height_changed));
417 entry_span->signal_value_changed().connect(sigc::mem_fun(*this,&studio::Widget_RendDesc::on_span_changed));
418 entry_tl->signal_value_changed().connect(sigc::mem_fun(*this,&studio::Widget_RendDesc::on_tl_changed));
419 entry_br->signal_value_changed().connect(sigc::mem_fun(*this,&studio::Widget_RendDesc::on_br_changed));
420 entry_fps->signal_value_changed().connect(sigc::mem_fun(*this,&studio::Widget_RendDesc::on_fps_changed));
421 entry_start_time->signal_value_changed().connect(sigc::mem_fun(*this,&studio::Widget_RendDesc::on_start_time_changed));
422 entry_end_time->signal_value_changed().connect(sigc::mem_fun(*this,&studio::Widget_RendDesc::on_end_time_changed));
423 //entry_start_frame->signal_value_changed().connect(sigc::mem_fun(*this,&studio::Widget_RendDesc::on_start_frame_changed));
424 //entry_end_frame->signal_value_changed().connect(sigc::mem_fun(*this,&studio::Widget_RendDesc::on_end_frame_changed));
425 entry_focus->signal_value_changed().connect(sigc::mem_fun(*this,&studio::Widget_RendDesc::on_focus_changed));
426 toggle_px_aspect->signal_toggled().connect(sigc::mem_fun(*this, &studio::Widget_RendDesc::on_lock_changed));
427 toggle_px_width->signal_toggled().connect(sigc::mem_fun(*this, &studio::Widget_RendDesc::on_lock_changed));
428 toggle_px_height->signal_toggled().connect(sigc::mem_fun(*this, &studio::Widget_RendDesc::on_lock_changed));
429 toggle_im_aspect->signal_toggled().connect(sigc::mem_fun(*this, &studio::Widget_RendDesc::on_lock_changed));
430 toggle_im_width->signal_toggled().connect(sigc::mem_fun(*this, &studio::Widget_RendDesc::on_lock_changed));
431 toggle_im_height->signal_toggled().connect(sigc::mem_fun(*this, &studio::Widget_RendDesc::on_lock_changed));
432 toggle_im_span->signal_toggled().connect(sigc::mem_fun(*this, &studio::Widget_RendDesc::on_lock_changed));
436 Widget_RendDesc::create_image_tab()
438 Gtk::Alignment *paddedPanel = manage(new Gtk::Alignment(0, 0, 1, 1));
439 paddedPanel->set_padding(12, 12, 12, 12);
441 Gtk::VBox *panelBox = manage(new Gtk::VBox(false, 12));
442 paddedPanel->add(*panelBox);
444 Gtk::Frame *imageFrame = manage(new Gtk::Frame(_("Image Size")));
445 imageFrame->set_shadow_type(Gtk::SHADOW_NONE);
446 ((Gtk::Label *) imageFrame->get_label_widget())->set_markup(_("<b>Image Size</b>"));
447 panelBox->pack_start(*imageFrame, false, false, 0);
449 Gtk::Alignment *tablePadding = manage(new Gtk::Alignment(0, 0, 1, 1));
450 tablePadding->set_padding(6, 0, 24, 0);
451 Gtk::Table *imageSizeTable = manage(new Gtk::Table(2, 6, false));
452 imageSizeTable->set_row_spacings(6);
453 imageSizeTable->set_col_spacings(12);
454 tablePadding->add(*imageSizeTable);
455 imageFrame->add(*tablePadding);
457 Gtk::Label *size_width_label = manage(new Gtk::Label(_("_Width"), 0, 0.5, true));
458 size_width_label->set_mnemonic_widget(*entry_width);
460 Gtk::Label *size_height_label = manage(new Gtk::Label(_("_Height"), 0, 0.5, true));
461 size_height_label->set_mnemonic_widget(*entry_height);
463 Gtk::Label *size_xres_label = manage(new Gtk::Label(_("_XRes"), 0, 0.5, true));
464 size_xres_label->set_mnemonic_widget(*entry_xres);
466 Gtk::Label *size_yres_label = manage(new Gtk::Label(_("_YRes"), 0, 0.5, true));
467 size_yres_label->set_mnemonic_widget(*entry_yres);
469 Gtk::Label *size_physwidth_label = manage(new Gtk::Label(_("_Physical Width"), 0, 0.5, true));
470 size_physwidth_label->set_mnemonic_widget(*entry_phy_width);
472 Gtk::Label *size_physheight_label = manage(new Gtk::Label(_("Phy_sical Height"), 0, 0.5, true));
473 size_physheight_label->set_mnemonic_widget(*entry_phy_height);
475 Gtk::Label *size_span = manage(new Gtk::Label(_("I_mage Span"), 0, 0.5, true));
476 size_span->set_mnemonic_widget(*entry_span);
478 imageSizeTable->attach(*size_width_label, 0, 1, 0, 1, Gtk::SHRINK|Gtk::FILL, Gtk::EXPAND|Gtk::FILL, 0, 0);
479 imageSizeTable->attach(*size_height_label, 0, 1, 1, 2, Gtk::SHRINK|Gtk::FILL, Gtk::EXPAND|Gtk::FILL, 0, 0);
480 imageSizeTable->attach(*entry_width, 1, 2, 0, 1, Gtk::EXPAND|Gtk::FILL, Gtk::EXPAND|Gtk::FILL, 0, 0);
481 imageSizeTable->attach(*entry_height, 1, 2, 1, 2, Gtk::EXPAND|Gtk::FILL, Gtk::EXPAND|Gtk::FILL, 0, 0);
483 imageSizeTable->attach(*size_xres_label, 2, 3, 0, 1, Gtk::SHRINK | Gtk::FILL, Gtk::EXPAND | Gtk::FILL, 0, 0);
484 imageSizeTable->attach(*size_yres_label, 2, 3, 1, 2, Gtk::SHRINK | Gtk::FILL, Gtk::EXPAND | Gtk::FILL, 0, 0);
485 imageSizeTable->attach(*entry_xres, 3, 4, 0, 1, Gtk::EXPAND | Gtk::FILL, Gtk::EXPAND | Gtk::FILL, 0, 0);
486 imageSizeTable->attach(*entry_yres, 3, 4, 1, 2, Gtk::EXPAND | Gtk::FILL, Gtk::EXPAND | Gtk::FILL, 0, 0);
488 imageSizeTable->attach(*size_physwidth_label, 4, 5, 0, 1, Gtk::SHRINK | Gtk::FILL, Gtk::EXPAND | Gtk::FILL, 0, 0);
489 imageSizeTable->attach(*size_physheight_label, 4, 5, 1, 2, Gtk::SHRINK | Gtk::FILL, Gtk::EXPAND | Gtk::FILL, 0, 0);
490 imageSizeTable->attach(*entry_phy_width, 5, 6, 0, 1, Gtk::EXPAND | Gtk::FILL, Gtk::EXPAND | Gtk::FILL, 0, 0);
491 imageSizeTable->attach(*entry_phy_height, 5, 6, 1, 2, Gtk::EXPAND | Gtk::FILL, Gtk::EXPAND | Gtk::FILL, 0, 0);
493 imageSizeTable->attach(*size_span, 0, 1, 2, 3, Gtk::SHRINK|Gtk::FILL, Gtk::EXPAND|Gtk::FILL, 0, 0);
494 imageSizeTable->attach(*entry_span, 1, 2, 2, 3, Gtk::EXPAND|Gtk::FILL, Gtk::EXPAND|Gtk::FILL, 0, 0);
496 Gtk::Frame *imageAreaFrame = manage(new Gtk::Frame(_("Image Area")));
497 imageAreaFrame->set_shadow_type(Gtk::SHADOW_NONE);
498 ((Gtk::Label *) imageAreaFrame->get_label_widget())->set_markup(_("<b>Image Area</b>"));
499 panelBox->pack_start(*imageAreaFrame, false, false, 0);
501 Gtk::Alignment *imageAreaPadding = manage(new Gtk::Alignment(0, 0, 1, 1));
502 imageAreaPadding->set_padding(6, 0, 24, 0);
503 imageAreaFrame->add(*imageAreaPadding);
505 Gtk::Table *imageAreaTable = manage(new Gtk::Table(2, 2, false));
506 imageAreaTable->set_row_spacings(6);
507 imageAreaTable->set_col_spacings(12);
508 imageAreaPadding->add(*imageAreaTable);
510 Gtk::Label *imageAreaTopLeftLabel = manage(new Gtk::Label(_("_Top Left"), 0, 0.5, true));
511 imageAreaTopLeftLabel->set_mnemonic_widget(*entry_tl);
513 Gtk::Label *imageAreaBottomRightLabel = manage(new Gtk::Label(_("_Bottom Right"), 0, 0.5, true));
514 imageAreaBottomRightLabel->set_mnemonic_widget(*entry_br);
516 imageAreaTable->attach(*imageAreaTopLeftLabel, 0, 1, 0, 1, Gtk::SHRINK | Gtk::FILL, Gtk::EXPAND | Gtk::FILL, 0, 0);
517 imageAreaTable->attach(*imageAreaBottomRightLabel, 0, 1, 1, 2, Gtk::SHRINK | Gtk::FILL, Gtk::EXPAND | Gtk::FILL, 0, 0);
518 imageAreaTable->attach(*entry_tl, 1, 2, 0, 1, Gtk::EXPAND | Gtk::FILL, Gtk::EXPAND | Gtk::FILL, 0, 0);
519 imageAreaTable->attach(*entry_br, 1, 2, 1, 2, Gtk::EXPAND | Gtk::FILL, Gtk::EXPAND | Gtk::FILL, 0, 0);
521 paddedPanel->show_all();
526 Widget_RendDesc::create_time_tab()
528 Gtk::Alignment *paddedPanel = manage(new Gtk::Alignment(0, 0, 1, 1));
529 paddedPanel->set_padding(12, 12, 12, 12);
531 Gtk::VBox *panelBox = manage(new Gtk::VBox(false, 12)); // for future widgets
532 paddedPanel->add(*panelBox);
534 Gtk::Frame *time_frame = manage(new Gtk::Frame("Time Settings"));
535 time_frame->set_shadow_type(Gtk::SHADOW_NONE);
536 ((Gtk::Label *) time_frame->get_label_widget())->set_markup("<b>Time Settings</b>");
537 panelBox->pack_start(*time_frame, false, false, 0);
539 Gtk::Alignment *timeFramePadding = manage(new Gtk::Alignment(0, 0, 1, 1));
540 timeFramePadding->set_padding(6, 0, 24, 0);
541 time_frame->add(*timeFramePadding);
543 Gtk::Table *timeFrameTable = manage(new Gtk::Table(3, 2, false));
544 timeFrameTable->set_row_spacings(6);
545 timeFrameTable->set_col_spacings(12);
546 timeFramePadding->add(*timeFrameTable);
548 Gtk::Label *timeFPSLabel = manage(new Gtk::Label(_("_Frames per second"), 0, 0.5, true));
549 timeFPSLabel->set_mnemonic_widget(*entry_fps);
550 timeFrameTable->attach(*timeFPSLabel, 0, 1, 0, 1, Gtk::EXPAND | Gtk::FILL, Gtk::EXPAND | Gtk::FILL, 0, 0);
551 timeFrameTable->attach(*entry_fps, 1, 2, 0, 1, Gtk::EXPAND | Gtk::FILL, Gtk::EXPAND | Gtk::FILL, 0, 0);
553 Gtk::Label *timeStartLabel = manage(new Gtk::Label(_("_Start Time"), 0, 0.5, true));
554 timeStartLabel->set_mnemonic_widget(*entry_start_time);
555 timeFrameTable->attach(*timeStartLabel, 0, 1, 1, 2, Gtk::EXPAND | Gtk::FILL, Gtk::EXPAND | Gtk::FILL, 0, 0);
556 timeFrameTable->attach(*entry_start_time, 1, 2, 1, 2, Gtk::EXPAND | Gtk::FILL, Gtk::EXPAND | Gtk::FILL, 0, 0);
558 Gtk::Label *timeEndLabel = manage(new Gtk::Label(_("_End Time"), 0, 0.5, true));
559 timeEndLabel->set_mnemonic_widget(*entry_end_time);
560 timeFrameTable->attach(*timeEndLabel, 0, 1, 2, 3, Gtk::EXPAND | Gtk::FILL, Gtk::EXPAND | Gtk::FILL, 0, 0);
561 timeFrameTable->attach(*entry_end_time, 1, 2, 2, 3, Gtk::EXPAND | Gtk::FILL, Gtk::EXPAND | Gtk::FILL, 0, 0);
563 paddedPanel->show_all();
568 Widget_RendDesc::create_other_tab()
570 Gtk::Alignment *paddedPanel = manage(new Gtk::Alignment(0, 0, 1, 1));
571 paddedPanel->set_padding(12, 12, 12, 12);
573 Gtk::VBox *panelBox = manage(new Gtk::VBox(false, 12));
574 paddedPanel->add(*panelBox);
576 Gtk::Frame *lockFrame = manage(new Gtk::Frame(_("Locks and Links")));
577 lockFrame->set_shadow_type(Gtk::SHADOW_NONE);
578 ((Gtk::Label *) lockFrame->get_label_widget())->set_markup(_("<b>Locks and Links</b>"));
579 panelBox->pack_start(*lockFrame, false, false, 0);
581 Gtk::Alignment *lockPadding = manage(new Gtk::Alignment(0, 0, 1, 1));
582 lockPadding->set_padding(6, 0, 24, 0);
583 lockFrame->add(*lockPadding);
585 Gtk::Table *lockTable = manage(new Gtk::Table(2, 4, false));
586 lockTable->set_row_spacings(6);
587 lockTable->set_col_spacings(12);
588 lockPadding->add(*lockTable);
590 lockTable->attach(*toggle_im_width, 0, 1, 0, 1, Gtk::EXPAND | Gtk::FILL, Gtk::EXPAND | Gtk::FILL, 0, 0);
591 lockTable->attach(*toggle_im_height, 1, 2, 0, 1, Gtk::EXPAND | Gtk::FILL, Gtk::EXPAND | Gtk::FILL, 0, 0);
592 lockTable->attach(*toggle_im_aspect, 2, 3, 0, 1, Gtk::EXPAND | Gtk::FILL, Gtk::EXPAND | Gtk::FILL, 0, 0);
593 lockTable->attach(*toggle_im_span, 3, 4, 0, 1, Gtk::EXPAND | Gtk::FILL, Gtk::EXPAND | Gtk::FILL, 0, 0);
595 lockTable->attach(*toggle_px_width, 0, 1, 1, 2, Gtk::EXPAND | Gtk::FILL, Gtk::EXPAND | Gtk::FILL, 0, 0);
596 lockTable->attach(*toggle_px_height, 1, 2, 1, 2, Gtk::EXPAND | Gtk::FILL, Gtk::EXPAND | Gtk::FILL, 0, 0);
597 lockTable->attach(*toggle_px_aspect, 2, 3, 1, 2, Gtk::EXPAND | Gtk::FILL, Gtk::EXPAND | Gtk::FILL, 0, 0);
599 Gtk::Frame *focusFrame = manage(new Gtk::Frame(_("Focus Point")));
600 focusFrame->set_shadow_type(Gtk::SHADOW_NONE);
601 ((Gtk::Label *) focusFrame->get_label_widget())->set_markup(_("<b>Focus Point</b>"));
602 panelBox->pack_start(*focusFrame, false, false, 0);
604 Gtk::Alignment *focusPadding = manage(new Gtk::Alignment(0, 0, 1, 1));
605 focusPadding->set_padding(6, 0, 24, 0);
606 focusFrame->add(*focusPadding);
608 Gtk::HBox *focusBox = manage(new Gtk::HBox(false, 12));
609 focusPadding->add(*focusBox);
611 Gtk::Label *focusLabel = manage(new Gtk::Label(_("_Focus Point"), 0, 0.5, true));
612 focusLabel->set_mnemonic_widget(*entry_focus);
613 focusBox->pack_start(*focusLabel, false, false, 0);
614 focusBox->pack_start(*entry_focus, true, true, 0);
616 paddedPanel->show_all();