+ setSizePolicy(QSizePolicy::MinimumExpanding, QSizePolicy::Maximum);
+ MonitorEditWidget *edit = monitor->getEffectEdit();
+ edit->showVisibilityButton(true);
+ m_scene = edit->getScene();
+
+
+ /*
+ Setup of timeline and keyframe controls
+ */
+
+ ((QGridLayout *)(m_ui.widgetTimeWrapper->layout()))->addWidget(m_timePos, 1, 6);
+
+ QVBoxLayout *layout = new QVBoxLayout(m_ui.frameTimeline);
+ m_timeline = new KeyframeHelper(m_ui.frameTimeline);
+ layout->addWidget(m_timeline);
+ layout->setContentsMargins(0, 0, 0, 0);
+
+ m_ui.buttonPrevious->setIcon(KIcon("media-skip-backward"));
+ m_ui.buttonPrevious->setToolTip(i18n("Go to previous keyframe"));
+ m_ui.buttonNext->setIcon(KIcon("media-skip-forward"));
+ m_ui.buttonNext->setToolTip(i18n("Go to next keyframe"));
+ m_ui.buttonAddDelete->setIcon(KIcon("document-new"));
+ m_ui.buttonAddDelete->setToolTip(i18n("Add keyframe"));
+
+ m_ui.buttonSync->setIcon(KIcon("insert-link"));
+ m_ui.buttonSync->setToolTip(i18n("Synchronize with timeline cursor"));
+ m_ui.buttonSync->setChecked(KdenliveSettings::transitionfollowcursor());
+
+ connect(m_timeline, SIGNAL(positionChanged(int)), this, SLOT(slotPositionChanged(int)));
+ connect(m_timeline, SIGNAL(keyframeMoved(int)), this, SLOT(slotKeyframeMoved(int)));
+ connect(m_timeline, SIGNAL(addKeyframe(int)), this, SLOT(slotAddKeyframe(int)));
+ connect(m_timeline, SIGNAL(removeKeyframe(int)), this, SLOT(slotDeleteKeyframe(int)));
+ connect(m_timePos, SIGNAL(editingFinished()), this, SLOT(slotPositionChanged()));
+ connect(m_ui.buttonPrevious, SIGNAL(clicked()), this, SLOT(slotPreviousKeyframe()));
+ connect(m_ui.buttonNext, SIGNAL(clicked()), this, SLOT(slotNextKeyframe()));
+ connect(m_ui.buttonAddDelete, SIGNAL(clicked()), this, SLOT(slotAddDeleteKeyframe()));
+ connect(m_ui.buttonSync, SIGNAL(toggled(bool)), this, SLOT(slotSetSynchronize(bool)));
+
+ m_spinX = new DragValue(i18n("X"), 0, 0, -1, QString(), false, this);
+ m_spinX->setRange(-10000, 10000);
+ m_ui.horizontalLayout->addWidget(m_spinX);
+
+ m_spinY = new DragValue(i18n("Y"), 0, 0, -1, QString(), false, this);
+ m_spinY->setRange(-10000, 10000);
+ m_ui.horizontalLayout->addWidget(m_spinY);
+
+ m_spinWidth = new DragValue(i18n("W"), m_monitor->render->frameRenderWidth(), 0, -1, QString(), false, this);
+ m_spinWidth->setRange(1, 10000);
+ m_ui.horizontalLayout->addWidget(m_spinWidth);
+
+ m_spinHeight = new DragValue(i18n("H"), m_monitor->render->renderHeight(), 0, -1, QString(), false, this);
+ m_spinHeight->setRange(1, 10000);
+ m_ui.horizontalLayout->addWidget(m_spinHeight);
+ m_ui.horizontalLayout->addStretch(10);
+
+ m_spinSize = new DragValue(i18n("Size"), 100, 2, -1, i18n("%"), false, this);
+ m_spinSize->setRange(1, 10000);
+ m_ui.horizontalLayout2->addWidget(m_spinSize);
+
+ m_opacity = new DragValue(i18n("Opacity"), 100, 0, -1, i18n("%"), true, this);
+ m_ui.horizontalLayout2->addWidget(m_opacity);
+
+ /*
+ Setup of geometry controls
+ */
+
+ connect(m_spinX, SIGNAL(valueChanged(int)), this, SLOT(slotSetX(int)));
+ connect(m_spinY, SIGNAL(valueChanged(int)), this, SLOT(slotSetY(int)));
+ connect(m_spinWidth, SIGNAL(valueChanged(int)), this, SLOT(slotSetWidth(int)));
+ connect(m_spinHeight, SIGNAL(valueChanged(int)), this, SLOT(slotSetHeight(int)));
+
+ connect(m_spinSize, SIGNAL(valueChanged(double)), this, SLOT(slotResize(double)));
+
+ connect(m_opacity, SIGNAL(valueChanged(int)), this, SLOT(slotSetOpacity(int)));
+
+ QMenu *menu = new QMenu(this);
+ QAction *adjustSize = new QAction(i18n("Adjust to original size"), this);
+ connect(adjustSize, SIGNAL(triggered()), this, SLOT(slotAdjustToFrameSize()));
+ menu->addAction(adjustSize);
+ QAction *fitToWidth = new QAction(i18n("Fit to width"), this);
+ connect(fitToWidth, SIGNAL(triggered()), this, SLOT(slotFitToWidth()));
+ menu->addAction(fitToWidth);
+ QAction *fitToHeight = new QAction(i18n("Fit to height"), this);
+ connect(fitToHeight, SIGNAL(triggered()), this, SLOT(slotFitToHeight()));
+ menu->addAction(fitToHeight);
+ menu->addSeparator();
+
+ QAction *alignleft = new QAction(KIcon("kdenlive-align-left"), i18n("Align left"), this);
+ connect(alignleft, SIGNAL(triggered()), this, SLOT(slotMoveLeft()));
+ menu->addAction(alignleft);
+ QAction *alignhcenter = new QAction(KIcon("kdenlive-align-hor"), i18n("Center horizontally"), this);
+ connect(alignhcenter, SIGNAL(triggered()), this, SLOT(slotCenterH()));
+ menu->addAction(alignhcenter);
+ QAction *alignright = new QAction(KIcon("kdenlive-align-right"), i18n("Align right"), this);
+ connect(alignright, SIGNAL(triggered()), this, SLOT(slotMoveRight()));
+ menu->addAction(alignright);
+ QAction *aligntop = new QAction(KIcon("kdenlive-align-top"), i18n("Align top"), this);
+ connect(aligntop, SIGNAL(triggered()), this, SLOT(slotMoveTop()));
+ menu->addAction(aligntop);
+ QAction *alignvcenter = new QAction(KIcon("kdenlive-align-vert"), i18n("Center vertically"), this);
+ connect(alignvcenter, SIGNAL(triggered()), this, SLOT(slotCenterV()));
+ menu->addAction(alignvcenter);
+ QAction *alignbottom = new QAction(KIcon("kdenlive-align-bottom"), i18n("Align bottom"), this);
+ connect(alignbottom, SIGNAL(triggered()), this, SLOT(slotMoveBottom()));
+ menu->addAction(alignbottom);
+ m_ui.buttonOptions->setMenu(menu);
+
+ /*connect(m_ui.buttonMoveLeft, SIGNAL(clicked()), this, SLOT(slotMoveLeft()));
+ connect(m_ui.buttonCenterH, SIGNAL(clicked()), this, SLOT(slotCenterH()));
+ connect(m_ui.buttonMoveRight, SIGNAL(clicked()), this, SLOT(slotMoveRight()));
+ connect(m_ui.buttonMoveTop, SIGNAL(clicked()), this, SLOT(slotMoveTop()));
+ connect(m_ui.buttonCenterV, SIGNAL(clicked()), this, SLOT(slotCenterV()));
+ connect(m_ui.buttonMoveBottom, SIGNAL(clicked()), this, SLOT(slotMoveBottom()));*/
+
+
+ /*
+ Setup of configuration controls
+ */