Navigation Menu

Skip to content

Commit

Permalink
[processing] align the "Iterate over layer" button (#4796)
Browse files Browse the repository at this point in the history
  • Loading branch information
DelazJ authored and nirvn committed Jul 3, 2017
1 parent b811761 commit b57cd0d
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
3 changes: 2 additions & 1 deletion python/plugins/processing/gui/ParametersPanel.py
Expand Up @@ -41,7 +41,7 @@
QgsProcessingParameterFeatureSink,
QgsProcessingParameterVectorOutput)
from qgis.PyQt import uic
from qgis.PyQt.QtCore import QCoreApplication
from qgis.PyQt.QtCore import QCoreApplication, Qt
from qgis.PyQt.QtWidgets import (QWidget, QHBoxLayout, QToolButton,
QLabel, QCheckBox)
from qgis.PyQt.QtGui import QIcon
Expand Down Expand Up @@ -121,6 +121,7 @@ def initWidgets(self):
button.setToolTip(self.tr('Iterate over this layer, creating a separate output for every feature in the layer'))
button.setCheckable(True)
layout.addWidget(button)
layout.setAlignment(button, Qt.AlignTop)
self.iterateButtons[param.name()] = button
button.toggled.connect(self.buttonToggled)
widget = QWidget()
Expand Down
4 changes: 3 additions & 1 deletion python/plugins/processing/gui/wrappers.py
Expand Up @@ -89,7 +89,7 @@
QgsMapLayerComboBox,
QgsProjectionSelectionWidget,
)
from qgis.PyQt.QtCore import pyqtSignal, QObject, QVariant
from qgis.PyQt.QtCore import pyqtSignal, QObject, QVariant, Qt
from qgis.utils import iface

from processing.gui.NumberInputPanel import NumberInputPanel, ModellerNumberInputPanel
Expand Down Expand Up @@ -762,11 +762,13 @@ def createWidget(self):
layout.setSpacing(2)
self.combo = QgsMapLayerComboBox()
layout.addWidget(self.combo)
layout.setAlignment(self.combo, Qt.AlignTop)
btn = QToolButton()
btn.setText('...')
btn.setToolTip(self.tr("Select file"))
btn.clicked.connect(self.selectFile)
layout.addWidget(btn)
layout.setAlignment(btn, Qt.AlignTop)

vl = QVBoxLayout()
vl.setMargin(0)
Expand Down

0 comments on commit b57cd0d

Please sign in to comment.