Skip to content

Commit

Permalink
Merge pull request metabrainz#654 from samj1912/picard1012
Browse files Browse the repository at this point in the history
PICARD-1012: Change QToolButtons to QPushButtons for GUI uniformity
  • Loading branch information
zas authored Mar 13, 2017
2 parents c628849 + 38bbe97 commit 9c20d93
Show file tree
Hide file tree
Showing 4 changed files with 40 additions and 26 deletions.
8 changes: 4 additions & 4 deletions picard/ui/ui_options_interface.py
Original file line number Diff line number Diff line change
Expand Up @@ -93,13 +93,13 @@ def setupUi(self, InterfaceOptionsPage):
self.edit_box_layout = QtGui.QHBoxLayout(self.edit_button_box)
self.edit_box_layout.setMargin(0)
self.edit_box_layout.setObjectName(_fromUtf8("edit_box_layout"))
self.add_button = QtGui.QToolButton(self.edit_button_box)
self.add_button = QtGui.QPushButton(self.edit_button_box)
self.add_button.setObjectName(_fromUtf8("add_button"))
self.edit_box_layout.addWidget(self.add_button)
self.insert_separator_button = QtGui.QToolButton(self.edit_button_box)
self.insert_separator_button = QtGui.QPushButton(self.edit_button_box)
self.insert_separator_button.setObjectName(_fromUtf8("insert_separator_button"))
self.edit_box_layout.addWidget(self.insert_separator_button)
spacerItem1 = QtGui.QSpacerItem(60, 20, QtGui.QSizePolicy.MinimumExpanding, QtGui.QSizePolicy.Minimum)
spacerItem1 = QtGui.QSpacerItem(50, 20, QtGui.QSizePolicy.MinimumExpanding, QtGui.QSizePolicy.Minimum)
self.edit_box_layout.addItem(spacerItem1)
self.up_button = QtGui.QToolButton(self.edit_button_box)
self.up_button.setArrowType(QtCore.Qt.UpArrow)
Expand All @@ -109,7 +109,7 @@ def setupUi(self, InterfaceOptionsPage):
self.down_button.setArrowType(QtCore.Qt.DownArrow)
self.down_button.setObjectName(_fromUtf8("down_button"))
self.edit_box_layout.addWidget(self.down_button)
self.remove_button = QtGui.QToolButton(self.edit_button_box)
self.remove_button = QtGui.QPushButton(self.edit_button_box)
self.remove_button.setObjectName(_fromUtf8("remove_button"))
self.edit_box_layout.addWidget(self.remove_button)
self.verticalLayout.addWidget(self.edit_button_box)
Expand Down
11 changes: 7 additions & 4 deletions picard/ui/ui_options_script.py
Original file line number Diff line number Diff line change
Expand Up @@ -44,11 +44,14 @@ def setupUi(self, ScriptingOptionsPage):
self.verticalLayout_3.setMargin(0)
self.verticalLayout_3.setSpacing(6)
self.verticalLayout_3.setObjectName(_fromUtf8("verticalLayout_3"))
self.add_script = QtGui.QToolButton(self.groupBox)
self.add_script.setToolButtonStyle(QtCore.Qt.ToolButtonTextOnly)
self.add_script.setAutoRaise(False)
self.horizontalLayout = QtGui.QHBoxLayout()
self.horizontalLayout.setObjectName(_fromUtf8("horizontalLayout"))
self.add_script = QtGui.QPushButton(self.groupBox)
self.add_script.setObjectName(_fromUtf8("add_script"))
self.verticalLayout_3.addWidget(self.add_script)
self.horizontalLayout.addWidget(self.add_script)
spacerItem = QtGui.QSpacerItem(40, 20, QtGui.QSizePolicy.Expanding, QtGui.QSizePolicy.Minimum)
self.horizontalLayout.addItem(spacerItem)
self.verticalLayout_3.addLayout(self.horizontalLayout)
self.splitter = QtGui.QSplitter(self.groupBox)
self.splitter.setOrientation(QtCore.Qt.Horizontal)
self.splitter.setChildrenCollapsible(False)
Expand Down
8 changes: 4 additions & 4 deletions ui/options_interface.ui
Original file line number Diff line number Diff line change
Expand Up @@ -151,7 +151,7 @@
<number>0</number>
</property>
<item>
<widget class="QToolButton" name="add_button">
<widget class="QPushButton" name="add_button">
<property name="toolTip">
<string>Add a new button to Toolbar</string>
</property>
Expand All @@ -161,7 +161,7 @@
</widget>
</item>
<item>
<widget class="QToolButton" name="insert_separator_button">
<widget class="QPushButton" name="insert_separator_button">
<property name="toolTip">
<string>Insert a separator</string>
</property>
Expand All @@ -180,7 +180,7 @@
</property>
<property name="sizeHint" stdset="0">
<size>
<width>60</width>
<width>50</width>
<height>20</height>
</size>
</property>
Expand Down Expand Up @@ -213,7 +213,7 @@
</widget>
</item>
<item>
<widget class="QToolButton" name="remove_button">
<widget class="QPushButton" name="remove_button">
<property name="toolTip">
<string>Remove button from toolbar</string>
</property>
Expand Down
39 changes: 25 additions & 14 deletions ui/options_script.ui
Original file line number Diff line number Diff line change
Expand Up @@ -63,20 +63,31 @@
<number>0</number>
</property>
<item>
<widget class="QToolButton" name="add_script">
<property name="toolTip">
<string>Add new script</string>
</property>
<property name="text">
<string>Add new script</string>
</property>
<property name="toolButtonStyle">
<enum>Qt::ToolButtonTextOnly</enum>
</property>
<property name="autoRaise">
<bool>false</bool>
</property>
</widget>
<layout class="QHBoxLayout" name="horizontalLayout">
<item>
<widget class="QPushButton" name="add_script">
<property name="toolTip">
<string>Add new script</string>
</property>
<property name="text">
<string>Add new script</string>
</property>
</widget>
</item>
<item>
<spacer name="horizontalSpacer">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>40</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
</layout>
</item>
<item>
<widget class="QSplitter" name="splitter">
Expand Down

0 comments on commit 9c20d93

Please sign in to comment.