Changed layout of settings screen to make it fit back on 1024x600 screens
This commit is contained in:
@@ -138,14 +138,15 @@ class GreeterMessage(QtWidgets.QFrame):
|
|||||||
|
|
||||||
class CaptureMessage(QtWidgets.QFrame):
|
class CaptureMessage(QtWidgets.QFrame):
|
||||||
|
|
||||||
def __init__(self, num_picture, num_x, num_y):
|
def __init__(self, num_picture, num_x, num_y, skip_last):
|
||||||
|
|
||||||
super().__init__()
|
super().__init__()
|
||||||
self.setObjectName('PoseMessage')
|
self.setObjectName('PoseMessage')
|
||||||
|
|
||||||
if num_x * num_y > 1:
|
num_pictures = max(num_x * num_y - int(skip_last), 1)
|
||||||
|
if num_pictures > 1:
|
||||||
self._text = 'Picture {} of {}...'.format(num_picture,
|
self._text = 'Picture {} of {}...'.format(num_picture,
|
||||||
num_x * num_y)
|
num_pictures)
|
||||||
else:
|
else:
|
||||||
self._text = 'Taking a photo...'
|
self._text = 'Taking a photo...'
|
||||||
|
|
||||||
@@ -462,7 +463,6 @@ class Settings(QtWidgets.QFrame):
|
|||||||
|
|
||||||
layout = QtWidgets.QVBoxLayout()
|
layout = QtWidgets.QVBoxLayout()
|
||||||
layout.addWidget(self.createTabs())
|
layout.addWidget(self.createTabs())
|
||||||
# layout.addStretch(1)
|
|
||||||
layout.addWidget(self.createButtons())
|
layout.addWidget(self.createButtons())
|
||||||
self.setLayout(layout)
|
self.setLayout(layout)
|
||||||
|
|
||||||
@@ -704,14 +704,19 @@ class Settings(QtWidgets.QFrame):
|
|||||||
lay_file.addWidget(bg)
|
lay_file.addWidget(bg)
|
||||||
lay_file.addWidget(file_button)
|
lay_file.addWidget(file_button)
|
||||||
|
|
||||||
|
lay_checkbox = QtWidgets.QHBoxLayout()
|
||||||
|
lay_checkbox.addWidget(keep_pictures)
|
||||||
|
lay_checkbox.addStretch(1)
|
||||||
|
lay_checkbox.addWidget(QtWidgets.QLabel('Omit last picture:'))
|
||||||
|
lay_checkbox.addWidget(skip_last)
|
||||||
|
|
||||||
layout = QtWidgets.QFormLayout()
|
layout = QtWidgets.QFormLayout()
|
||||||
layout.addRow('Number of shots per picture:', lay_num)
|
layout.addRow('Number of shots per picture:', lay_num)
|
||||||
layout.addRow('Size of assembled picture [px]:', lay_size)
|
layout.addRow('Size of assembled picture [px]:', lay_size)
|
||||||
layout.addRow('Min. distance between shots [px]:', lay_dist)
|
layout.addRow('Min. distance between shots [px]:', lay_dist)
|
||||||
layout.addRow('Output directory (strftime possible):', lay_dir)
|
layout.addRow('Output directory (strftime possible):', lay_dir)
|
||||||
layout.addRow('Basename of files (strftime possible):', basename)
|
layout.addRow('Basename of files (strftime possible):', basename)
|
||||||
layout.addRow('Keep single shots:', keep_pictures)
|
layout.addRow('Keep single shots:', lay_checkbox)
|
||||||
layout.addRow('Omit last picture:', skip_last)
|
|
||||||
layout.addRow('Background image:', lay_file)
|
layout.addRow('Background image:', lay_file)
|
||||||
|
|
||||||
widget = QtWidgets.QWidget()
|
widget = QtWidgets.QWidget()
|
||||||
|
|||||||
@@ -205,7 +205,9 @@ class PyQt5Gui(GuiSkeleton):
|
|||||||
|
|
||||||
num_pic = (self._cfg.getInt('Picture', 'num_x'),
|
num_pic = (self._cfg.getInt('Picture', 'num_x'),
|
||||||
self._cfg.getInt('Picture', 'num_y'))
|
self._cfg.getInt('Picture', 'num_y'))
|
||||||
self._setWidget(Frames.CaptureMessage(state.num_picture, *num_pic))
|
skip_last = self._cfg.getBool('Picture', 'skip_last')
|
||||||
|
self._setWidget(Frames.CaptureMessage(state.num_picture, *num_pic,
|
||||||
|
skip_last))
|
||||||
|
|
||||||
def showAssemble(self, state):
|
def showAssemble(self, state):
|
||||||
|
|
||||||
|
|||||||
@@ -190,6 +190,16 @@ QTabBar::tab:selected {
|
|||||||
background-color: #33ffffff;
|
background-color: #33ffffff;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
QGroupBox {
|
||||||
|
background-color: transparent;
|
||||||
|
border-style: outset;
|
||||||
|
border-width: 1px;
|
||||||
|
border-radius: 15px;
|
||||||
|
border-color: #eeeeee;
|
||||||
|
margin: 0px;
|
||||||
|
padding: 4px;
|
||||||
|
}
|
||||||
|
|
||||||
QTabWidget QWidget {
|
QTabWidget QWidget {
|
||||||
color: #333333;
|
color: #333333;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -169,6 +169,7 @@ QTabWidget::pane {
|
|||||||
border-color: #eeeeee;
|
border-color: #eeeeee;
|
||||||
color: #333333;
|
color: #333333;
|
||||||
padding: 10px;
|
padding: 10px;
|
||||||
|
margin: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
QTabWidget::tab-bar {
|
QTabWidget::tab-bar {
|
||||||
@@ -189,6 +190,16 @@ QTabBar::tab:selected {
|
|||||||
background-color: #66ffffff;
|
background-color: #66ffffff;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
QGroupBox {
|
||||||
|
background-color: transparent;
|
||||||
|
border-style: outset;
|
||||||
|
border-width: 1px;
|
||||||
|
border-radius: 15px;
|
||||||
|
border-color: #eeeeee;
|
||||||
|
margin: 0px;
|
||||||
|
padding: 4px;
|
||||||
|
}
|
||||||
|
|
||||||
QTabWidget QWidget {
|
QTabWidget QWidget {
|
||||||
color: #333333;
|
color: #333333;
|
||||||
font-size: 30px;
|
font-size: 30px;
|
||||||
|
|||||||
Reference in New Issue
Block a user