[pitivi] Add an etched-in border around the title editor and clip properties
- From: Thibault Saunier <tsaunier src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [pitivi] Add an etched-in border around the title editor and clip properties
- Date: Tue, 27 Jan 2015 18:40:00 +0000 (UTC)
commit cc9df65f263a3398ca108ab4315b6d3e2f5766d3
Author: Alexandru Băluț <alexandru balut gmail com>
Date: Tue Dec 9 16:35:44 2014 +0100
Add an etched-in border around the title editor and clip properties
So they are consistent with the Transitions and Media Library panes.
data/ui/titleeditor.ui | 360 +++++++++++++++++++++++----------------------
pitivi/clipproperties.py | 21 ++--
2 files changed, 194 insertions(+), 187 deletions(-)
---
diff --git a/data/ui/titleeditor.ui b/data/ui/titleeditor.ui
index 35a06be..07f4357 100644
--- a/data/ui/titleeditor.ui
+++ b/data/ui/titleeditor.ui
@@ -90,228 +90,236 @@
</packing>
</child>
<child>
- <object class="GtkBox" id="editing_box">
+ <object class="GtkViewport" id="viewport1">
<property name="visible">True</property>
<property name="can_focus">False</property>
- <property name="orientation">vertical</property>
+ <property name="shadow_type">etched-in</property>
<child>
- <object class="GtkToolbar" id="toolbar">
+ <object class="GtkBox" id="editing_box">
<property name="visible">True</property>
<property name="can_focus">False</property>
- <property name="show_arrow">False</property>
- <property name="icon_size">1</property>
+ <property name="orientation">vertical</property>
<child>
- <object class="GtkToolItem" id="font">
- <property name="use_action_appearance">False</property>
+ <object class="GtkToolbar" id="toolbar">
<property name="visible">True</property>
<property name="can_focus">False</property>
+ <property name="show_arrow">False</property>
+ <property name="icon_size">1</property>
<child>
- <object class="GtkFontButton" id="fontbutton1">
+ <object class="GtkToolItem" id="font">
<property name="use_action_appearance">False</property>
<property name="visible">True</property>
- <property name="can_focus">True</property>
- <property name="receives_default">True</property>
- <property name="preview_text"/>
- <property name="show_preview_entry">False</property>
- <property name="title" translatable="yes">Choose a font</property>
- <signal name="font-set" handler="_fontButtonCb" swapped="no"/>
+ <property name="can_focus">False</property>
+ <child>
+ <object class="GtkFontButton" id="fontbutton1">
+ <property name="use_action_appearance">False</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">True</property>
+ <property name="font">Sans 12</property>
+ <property name="preview_text"/>
+ <property name="show_preview_entry">False</property>
+ <property name="title" translatable="yes">Choose a font</property>
+ <signal name="font-set" handler="_fontButtonCb" swapped="no"/>
+ </object>
+ </child>
</object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="homogeneous">True</property>
+ </packing>
</child>
- </object>
- <packing>
- <property name="expand">False</property>
- <property name="homogeneous">True</property>
- </packing>
- </child>
- <child>
- <object class="GtkToolItem" id="font_fore_color">
- <property name="use_action_appearance">False</property>
- <property name="visible">True</property>
- <property name="can_focus">False</property>
- <property name="has_tooltip">True</property>
- <property name="tooltip_markup" translatable="yes">Text color</property>
- <property name="tooltip_text" translatable="yes">Text color</property>
<child>
- <object class="GtkColorButton" id="fore_text_color">
+ <object class="GtkToolItem" id="font_fore_color">
<property name="use_action_appearance">False</property>
<property name="visible">True</property>
- <property name="can_focus">True</property>
- <property name="receives_default">True</property>
- <property name="use_alpha">True</property>
- <property name="title" translatable="yes">Pick a text color</property>
- <signal name="color-set" handler="_frontTextColorButtonCb" swapped="no"/>
+ <property name="can_focus">False</property>
+ <property name="has_tooltip">True</property>
+ <property name="tooltip_markup" translatable="yes">Text color</property>
+ <property name="tooltip_text" translatable="yes">Text color</property>
+ <child>
+ <object class="GtkColorButton" id="fore_text_color">
+ <property name="use_action_appearance">False</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">True</property>
+ <property name="use_alpha">True</property>
+ <property name="title" translatable="yes">Pick a text color</property>
+ <signal name="color-set" handler="_frontTextColorButtonCb" swapped="no"/>
+ </object>
+ </child>
</object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="homogeneous">False</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkToolItem" id="background_color">
+ <property name="use_action_appearance">False</property>
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="has_tooltip">True</property>
+ <property name="tooltip_markup" translatable="yes">Background color</property>
+ <property name="tooltip_text" translatable="yes">Background color</property>
+ <child>
+ <object class="GtkColorButton" id="back_color">
+ <property name="use_action_appearance">False</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">True</property>
+ <property name="use_alpha">True</property>
+ <property name="title" translatable="yes">Pick a background color</property>
+ <property name="rgba">rgb(255,255,255)</property>
+ <signal name="color-set" handler="_backgroundColorButtonCb" swapped="no"/>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="homogeneous">False</property>
+ </packing>
</child>
</object>
<packing>
<property name="expand">False</property>
- <property name="homogeneous">False</property>
+ <property name="fill">True</property>
+ <property name="position">0</property>
</packing>
</child>
<child>
- <object class="GtkToolItem" id="background_color">
- <property name="use_action_appearance">False</property>
+ <object class="GtkTextView" id="textview">
<property name="visible">True</property>
- <property name="can_focus">False</property>
- <property name="has_tooltip">True</property>
- <property name="tooltip_markup" translatable="yes">Background color</property>
- <property name="tooltip_text" translatable="yes">Background color</property>
- <child>
- <object class="GtkColorButton" id="back_color">
- <property name="use_action_appearance">False</property>
- <property name="visible">True</property>
- <property name="can_focus">True</property>
- <property name="receives_default">True</property>
- <property name="use_alpha">True</property>
- <property name="title" translatable="yes">Pick a background color</property>
- <property name="rgba">rgb(255,255,255)</property>
- <signal name="color-set" handler="_backgroundColorButtonCb" swapped="no"/>
- </object>
- </child>
+ <property name="can_focus">True</property>
+ <property name="margin_start">12</property>
+ <property name="margin_end">12</property>
+ <property name="margin_top">12</property>
+ <property name="margin_bottom">12</property>
+ <property name="wrap_mode">word</property>
</object>
<packing>
- <property name="expand">False</property>
- <property name="homogeneous">False</property>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
</packing>
</child>
- </object>
- <packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
- <property name="position">0</property>
- </packing>
- </child>
- <child>
- <object class="GtkTextView" id="textview">
- <property name="visible">True</property>
- <property name="can_focus">True</property>
- <property name="margin_start">12</property>
- <property name="margin_end">12</property>
- <property name="margin_top">12</property>
- <property name="margin_bottom">12</property>
- <property name="wrap_mode">word</property>
- </object>
- <packing>
- <property name="expand">True</property>
- <property name="fill">True</property>
- <property name="position">1</property>
- </packing>
- </child>
- <child>
- <object class="GtkExpander" id="expander1">
- <property name="visible">True</property>
- <property name="can_focus">True</property>
<child>
- <object class="GtkBox" id="box5">
+ <object class="GtkExpander" id="expander1">
<property name="visible">True</property>
- <property name="can_focus">False</property>
- <property name="orientation">vertical</property>
+ <property name="can_focus">True</property>
<child>
- <object class="GtkGrid" id="box4">
+ <object class="GtkBox" id="box5">
<property name="visible">True</property>
<property name="can_focus">False</property>
- <property name="margin_start">24</property>
- <property name="column_spacing">6</property>
- <child>
- <object class="GtkLabel" id="label6">
- <property name="visible">True</property>
- <property name="can_focus">False</property>
- <property name="xalign">0</property>
- <property name="label" translatable="yes">Horizontal alignment:</property>
- </object>
- <packing>
- <property name="left_attach">0</property>
- <property name="top_attach">0</property>
- </packing>
- </child>
+ <property name="orientation">vertical</property>
<child>
- <object class="GtkLabel" id="label2">
+ <object class="GtkGrid" id="box4">
<property name="visible">True</property>
<property name="can_focus">False</property>
- <property name="xalign">0</property>
- <property name="label" translatable="yes">Vertical alignment:</property>
- </object>
- <packing>
- <property name="left_attach">0</property>
- <property name="top_attach">1</property>
- </packing>
- </child>
- <child>
- <object class="GtkComboBoxText" id="halignment">
- <property name="visible">True</property>
- <property name="can_focus">False</property>
- <signal name="changed" handler="_updateSource" swapped="no"/>
- </object>
- <packing>
- <property name="left_attach">1</property>
- <property name="top_attach">0</property>
- </packing>
- </child>
- <child>
- <object class="GtkComboBoxText" id="valignment">
- <property name="visible">True</property>
- <property name="can_focus">False</property>
- <property name="active">1</property>
- <signal name="changed" handler="_updateSource" swapped="no"/>
- </object>
- <packing>
- <property name="left_attach">1</property>
- <property name="top_attach">1</property>
- </packing>
- </child>
- <child>
- <object class="GtkSpinButton" id="xpos">
- <property name="visible">True</property>
- <property name="can_focus">True</property>
- <property name="invisible_char">•</property>
- <property name="adjustment">position_x_adj</property>
- <property name="digits">2</property>
- <property name="numeric">True</property>
- <signal name="value-changed" handler="_updateSource" swapped="no"/>
- </object>
- <packing>
- <property name="left_attach">2</property>
- <property name="top_attach">0</property>
- </packing>
- </child>
- <child>
- <object class="GtkSpinButton" id="ypos">
- <property name="visible">True</property>
- <property name="can_focus">True</property>
- <property name="invisible_char">•</property>
- <property name="adjustment">position_y_adj</property>
- <property name="digits">2</property>
- <property name="numeric">True</property>
- <signal name="value-changed" handler="_updateSource" swapped="no"/>
+ <property name="margin_start">24</property>
+ <property name="column_spacing">6</property>
+ <child>
+ <object class="GtkLabel" id="label6">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">Horizontal alignment:</property>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label2">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">Vertical alignment:</property>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkComboBoxText" id="halignment">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <signal name="changed" handler="_updateSource" swapped="no"/>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="top_attach">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkComboBoxText" id="valignment">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="active">1</property>
+ <signal name="changed" handler="_updateSource" swapped="no"/>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="top_attach">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkSpinButton" id="xpos">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="invisible_char">•</property>
+ <property name="adjustment">position_x_adj</property>
+ <property name="digits">2</property>
+ <property name="numeric">True</property>
+ <signal name="value-changed" handler="_updateSource" swapped="no"/>
+ </object>
+ <packing>
+ <property name="left_attach">2</property>
+ <property name="top_attach">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkSpinButton" id="ypos">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="invisible_char">•</property>
+ <property name="adjustment">position_y_adj</property>
+ <property name="digits">2</property>
+ <property name="numeric">True</property>
+ <signal name="value-changed" handler="_updateSource" swapped="no"/>
+ </object>
+ <packing>
+ <property name="left_attach">2</property>
+ <property name="top_attach">1</property>
+ </packing>
+ </child>
</object>
<packing>
- <property name="left_attach">2</property>
- <property name="top_attach">1</property>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">0</property>
</packing>
</child>
</object>
- <packing>
- <property name="expand">True</property>
- <property name="fill">True</property>
- <property name="position">0</property>
- </packing>
+ </child>
+ <child type="label">
+ <object class="GtkLabel" id="label7">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">Advanced positioning</property>
+ </object>
</child>
</object>
- </child>
- <child type="label">
- <object class="GtkLabel" id="label7">
- <property name="visible">True</property>
- <property name="can_focus">False</property>
- <property name="xalign">0</property>
- <property name="label" translatable="yes">Advanced positioning</property>
- </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="position">2</property>
+ </packing>
</child>
</object>
- <packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
- <property name="position">2</property>
- </packing>
</child>
</object>
<packing>
diff --git a/pitivi/clipproperties.py b/pitivi/clipproperties.py
index 96b48e7..345a343 100644
--- a/pitivi/clipproperties.py
+++ b/pitivi/clipproperties.py
@@ -53,7 +53,7 @@ class ClipPropertiesError(Exception):
pass
-class ClipProperties(Gtk.ScrolledWindow, Loggable):
+class ClipProperties(Gtk.Box, Loggable):
"""
Widget for configuring the selected clip.
@@ -61,24 +61,18 @@ class ClipProperties(Gtk.ScrolledWindow, Loggable):
"""
def __init__(self, app):
- Gtk.ScrolledWindow.__init__(self)
+ Gtk.Box.__init__(self)
Loggable.__init__(self)
self.app = app
self.settings = app.settings
self._project = None
- self.set_policy(Gtk.PolicyType.NEVER, Gtk.PolicyType.AUTOMATIC)
-
- vbox = Gtk.Box()
- vbox.set_orientation(Gtk.Orientation.VERTICAL)
- vbox.set_spacing(SPACING)
- vbox.show()
- self.add(vbox)
+ self.set_orientation(Gtk.Orientation.VERTICAL)
self.infobar_box = Gtk.Box()
self.infobar_box.set_orientation(Gtk.Orientation.VERTICAL)
self.infobar_box.show()
- vbox.pack_start(self.infobar_box, False, False, 0)
+ self.pack_start(self.infobar_box, False, False, 0)
# Transformation boxed DISABLED
# self.transformation_expander = TransformationProperties(instance, instance.action_log)
@@ -89,7 +83,12 @@ class ClipProperties(Gtk.ScrolledWindow, Loggable):
self.effect_expander = EffectProperties(
app, effects_properties_manager, self)
self.effect_expander.set_vexpand(False)
- vbox.pack_start(self.effect_expander, True, True, 0)
+ viewport = Gtk.ScrolledWindow()
+ viewport.set_policy(Gtk.PolicyType.NEVER, Gtk.PolicyType.AUTOMATIC)
+ viewport.set_shadow_type(Gtk.ShadowType.ETCHED_IN)
+ viewport.set_visible(True)
+ viewport.add(self.effect_expander)
+ self.pack_start(viewport, True, True, 0)
def _setProject(self, project):
self._project = project
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]