def __init__(self, parent=None): """ Args: flow: What part of setup is the user entering into? """ super(CreateSoftware, self).__init__(parent) self.logger = logging.getLogger('menu.' + self.__class__.__name__) self.logger.info('Workplace creation starting...') self.setObjectName('launcher_{0}'.format(self.__class__.__name__)) self.parent = parent self.armada_root_path = definitions.ROOT_PATH # self.setAttribute(QtCore.Qt.WA_DeleteOnClose) self.installEventFilter(self) self.setStyleSheet(resource.style_sheet('setup')) self.sizeHint() # GUI ---------------------------------- self.btn_back = QtWidgets.QPushButton() self.btn_back.setIcon(resource.color_svg('arrow_left', 128, '#9E9E9E')) self.btn_back.setIconSize(QtCore.QSize(30, 30)) self.btn_back.setFixedHeight(30) self.btn_back.setStyleSheet(resource.style_sheet('push_button_w_icon')) self.tb_welcome = QtWidgets.QLabel() self.tb_welcome.setText(""" <p style="font-size:30px;font-weight: normal;">Almost there!</p>""" ) self.tb_welcome.setWordWrap(True) self.tb_description = QtWidgets.QLabel() self.tb_description.setStyleSheet(""" background-color: transparent; font: 12px; font-weight: normal""" ) self.tb_description.setText(""" <p>Let's make sure we have the right path for each software.</p>""" ) self.tb_description.setWordWrap(True) # Input # scroll area self.scrollArea = QtWidgets.QScrollArea() self.scrollArea.setWidgetResizable(True) self.scrollArea.setStyleSheet('background-color: #00000000;') self.content = QtWidgets.QWidget() self.content.setStyleSheet('background-color: #00000000;') self.scrollArea.setWidget(self.content) layout = QtWidgets.QVBoxLayout(self.content) layout.setContentsMargins(0, 0, 0, 0) layout.setSpacing(20) supported_software = ['maya', 'houdini', 'blender'] for item in supported_software: software_card = SoftwareCard(self, item) layout.addWidget(software_card) self.btn_next = QtWidgets.QPushButton('Next') self.btn_next.setFixedWidth(100) self.btn_next.setStyleSheet(''' QPushButton{ Background:#2e7a78; height: 30px; font: 12px "Roboto-Thin" } QPushButton:hover{ Background: #369593; } QPushButton:hover:pressed{ Background: #2e7a78; } QPushButton:pressed{ Background: #2a615f; } QPushButton:disabled{ Background: #3b3b3b; }''' ) self.btn_next.setFixedSize(100, 40) # Layout -------------------------------------------- btn_back_layout = QtWidgets.QVBoxLayout() btn_back_layout.addWidget(self.btn_back) btn_back_layout.setAlignment(QtCore.Qt.AlignTop) btn_back_layout.setContentsMargins(0, 0, 0, 0) btn_back_layout.setSpacing(0) description_layout = QtWidgets.QVBoxLayout() description_layout.addWidget(self.tb_welcome) description_layout.addWidget(self.tb_description) description_layout.setAlignment(QtCore.Qt.AlignTop) description_layout.setContentsMargins(0, 0, 0, 0) description_layout.setSpacing(30) input_layout = QtWidgets.QVBoxLayout() input_layout.addWidget(self.scrollArea) btn_layout = QtWidgets.QVBoxLayout() btn_layout.addWidget(self.btn_next) btn_layout.setAlignment(QtCore.Qt.AlignTop) btn_layout.setContentsMargins(0, 0, 0, 0) btn_layout.setSpacing(0) contents_layout = QtWidgets.QVBoxLayout() contents_layout.addLayout(description_layout) contents_layout.addLayout(input_layout) contents_layout.addLayout(btn_layout) contents_layout.addStretch() contents_layout.setAlignment(QtCore.Qt.AlignTop) contents_layout.setContentsMargins(0, 0, 0, 0) contents_layout.setSpacing(50) # disclaimer_layout = QtWidgets.QVBoxLayout() # disclaimer_layout.addWidget(self.lbl_disclaimer) # disclaimer_layout.setAlignment(QtCore.Qt.AlignBottom | QtCore.Qt.AlignCenter) # disclaimer_layout.setContentsMargins(0, 20, 0, 20) # disclaimer_layout.setSpacing(0) self.main_layout = QtWidgets.QHBoxLayout() self.main_layout.addLayout(btn_back_layout) self.main_layout.addLayout(contents_layout) # self.main_layout.addLayout(disclaimer_layout) # self.main_layout.setAlignment(QtCore.Qt.AlignBottom) self.main_layout.setContentsMargins(20, 20, 60, 20) self.main_layout.setSpacing(10) self.setLayout(self.main_layout)
def __init__(self, parent=None): """ Args: flow: What part of setup is the user entering into? """ super(CreateWorkspace, self).__init__(parent) self.logger = logging.getLogger('menu.' + self.__class__.__name__) self.logger.info('Workplace creation starting...') self.setObjectName('launcher_{0}'.format(self.__class__.__name__)) self.parent = parent self.armada_root_path = definitions.ROOT_PATH # self.setAttribute(QtCore.Qt.WA_DeleteOnClose) self.installEventFilter(self) self.setStyleSheet(resource.style_sheet('setup')) self.sizeHint() # GUI ----------------------------------------------- self.btn_back = QtWidgets.QPushButton() self.btn_back.setIcon(resource.color_svg('arrow_left', 128, '#9E9E9E')) self.btn_back.setIconSize(QtCore.QSize(30, 30)) self.btn_back.setFixedHeight(30) self.btn_back.setStyleSheet(resource.style_sheet('push_button_w_icon')) self.tb_welcome = QtWidgets.QLabel() self.tb_description = QtWidgets.QLabel() self.tb_description.setStyleSheet(""" background-color: transparent; font: 12px; font-weight: normal """) self.tb_description.setText(""" <p>A <b>workspace</b> is where all of your projects will be stored. <p>Name it after the company you work for, a series of projects you're starting, or the type of work you'll be doing.</p> <p>You can change the name later, but it's strongly advised that you don't!</p>""" ) self.tb_description.setWordWrap(True) # Mount point self.lbl_mount_point = QtWidgets.QLabel( 'Choose an empty directory to mount your workspace to') self.le_mount_point = QtWidgets.QLineEdit() self.le_mount_point.setPlaceholderText('e.g D:/OneDrive/Work') self.le_mount_point.setMinimumHeight(40) regexp = QtCore.QRegExp("^[a-zA-Z0-9_/:]+$", QtCore.Qt.CaseInsensitive) validator = QtGui.QRegExpValidator(regexp) self.le_mount_point.setValidator(validator) self.btn_mount_browse = QtWidgets.QPushButton("Browse") self.btn_mount_browse.setMinimumWidth(100) self.hline_mount_point = QtWidgets.QFrame() self.hline_mount_point.setFixedHeight(1) self.hline_mount_point.setSizePolicy(QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Fixed) self.hline_mount_point.setStyleSheet("background-color: #636363;") # Workspace name self.lbl_workspace = QtWidgets.QLabel( 'What should we call this workspace?') self.le_workspace = QtWidgets.QLineEdit() self.le_workspace.setPlaceholderText( 'e.g. Knufflebeast, Junior Year Projects, Solo Show, Research and Development, etc.' ) self.le_workspace.setMinimumHeight(40) regexp = QtCore.QRegExp("^[a-zA-Z0-9-_ ]+$", QtCore.Qt.CaseInsensitive) validator = QtGui.QRegExpValidator(regexp) self.le_workspace.setValidator(validator) self.hline_workspace = QtWidgets.QFrame() self.hline_workspace.setFixedHeight(1) self.hline_workspace.setSizePolicy(QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Fixed) self.hline_workspace.setStyleSheet("background-color: #636363;") # # Full path name # self.lbl_full_path = QtWidgets.QLabel('Full mount point path') # # self.lbl_path_example = QtWidgets.QLabel() # self.lbl_path_example.setWordWrap(True) # self.lbl_path_example.setStyleSheet(""" # background-color: transparent; # font: 12px; # font-weight: normal""" # ) # self.hline_full_path = QtWidgets.QFrame() # self.hline_full_path.setFixedHeight(1) # self.hline_full_path.setSizePolicy(QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Fixed) # self.hline_full_path.setStyleSheet("background-color: #636363;") self.btn_next = QtWidgets.QPushButton('Next') self.btn_next.setStyleSheet(''' QPushButton{ Background:#2e7a78; height: 30px; font: 12px "Roboto-Thin" } QPushButton:hover{ Background: #369593; } QPushButton:hover:pressed{ Background: #2e7a78; } QPushButton:pressed{ Background: #2a615f; } QPushButton:disabled{ Background: #3b3b3b; }''') self.btn_next.setFixedSize(100, 40) self.btn_next.setEnabled(False) # self.lbl_disclaimer = QtWidgets.QTextBrowser() # self.lbl_disclaimer.setReadOnly(True) # self.lbl_disclaimer.setText('Armada Pipeline does not store passwords or account data at this time. Your acocunt is stored locally and only used to add another degree of flexibility project') # self.lbl_disclaimer.setMinimumSize(100, 50) # Layout -------------------------------------------- btn_back_layout = QtWidgets.QVBoxLayout() btn_back_layout.addWidget(self.btn_back) btn_back_layout.setAlignment(QtCore.Qt.AlignTop) btn_back_layout.setContentsMargins(0, 0, 0, 0) btn_back_layout.setSpacing(0) description_layout = QtWidgets.QVBoxLayout() description_layout.addWidget(self.tb_welcome) description_layout.addWidget(self.tb_description) description_layout.setAlignment(QtCore.Qt.AlignTop) description_layout.setContentsMargins(0, 0, 0, 0) description_layout.setSpacing(30) mount_layout = QtWidgets.QHBoxLayout() mount_layout.addWidget(self.le_mount_point) mount_layout.addWidget(self.btn_mount_browse) mount_layout.setContentsMargins(0, 0, 0, 0) mount_layout.setSpacing(0) input_layout = QtWidgets.QVBoxLayout() input_layout.addWidget(self.lbl_mount_point) input_layout.addSpacing(10) input_layout.addLayout(mount_layout) input_layout.addWidget(self.hline_mount_point) input_layout.addSpacing(20) input_layout.addWidget(self.lbl_workspace) input_layout.addSpacing(10) input_layout.addWidget(self.le_workspace) input_layout.addWidget(self.hline_workspace) # input_layout.addSpacing(20) # input_layout.addWidget(self.lbl_full_path) # input_layout.addSpacing(10) # input_layout.addWidget(self.lbl_path_example) input_layout.setAlignment(QtCore.Qt.AlignTop) input_layout.setContentsMargins(0, 0, 0, 0) input_layout.setSpacing(0) btn_layout = QtWidgets.QVBoxLayout() btn_layout.addWidget(self.btn_next) btn_layout.setAlignment(QtCore.Qt.AlignTop) btn_layout.setContentsMargins(0, 0, 0, 0) btn_layout.setSpacing(0) contents_layout = QtWidgets.QVBoxLayout() contents_layout.addLayout(description_layout) contents_layout.addLayout(input_layout) contents_layout.addLayout(btn_layout) contents_layout.addStretch() contents_layout.setAlignment(QtCore.Qt.AlignTop) contents_layout.setContentsMargins(0, 0, 0, 0) contents_layout.setSpacing(50) # disclaimer_layout = QtWidgets.QVBoxLayout() # disclaimer_layout.addWidget(self.lbl_disclaimer) # disclaimer_layout.setAlignment(QtCore.Qt.AlignBottom | QtCore.Qt.AlignCenter) # disclaimer_layout.setContentsMargins(0, 20, 0, 20) # disclaimer_layout.setSpacing(0) self.main_layout = QtWidgets.QHBoxLayout() self.main_layout.addLayout(btn_back_layout) self.main_layout.addLayout(contents_layout) # self.main_layout.addLayout(disclaimer_layout) # self.main_layout.setAlignment(QtCore.Qt.AlignBottom) self.main_layout.setContentsMargins(20, 20, 60, 20) self.main_layout.setSpacing(10) self.setLayout(self.main_layout) # Connections ----------------------------------- self.le_workspace.textChanged.connect(self.check_le_state) self.le_mount_point.textChanged.connect(self.check_le_state) self.btn_mount_browse.clicked.connect(self.on_browse_pressed)
def __init__(self, parent=None): super(BreadcrumbStartupSteps, self).__init__(parent) self.logger = logging.getLogger('launcher.gui.' + self.__class__.__name__) self.logger.info('Building main tab tab...') self.setObjectName('launcher_{0}'.format(self.__class__.__name__)) self.parent = parent self.setMinimumHeight(37) self.setDrawBase(False) # Removes line under and between base of tabs self.setIconSize(QtCore.QSize(24, 24)) self.setStyleSheet(""" QTabBar{ font: 10px "Segoe UI"; background-color: rgba(90, 90, 90, 0); } QTabBar::tab { font: 10px "Segoe UI"; background-color: rgba(90, 90, 90, 0); spacing:5; } QTabBar::tab::selected{ color: #FFFFFF; font: 10px "Segoe UI bold"; background-color: #2c998e; } QTabBar::tab:hover:selected{ color: #FFFFFF; background-color: #2c998e; } QTabBar::tab::!selected{ color: #FFFFFF; background-color: #5a5a5a; } QTabBar::tab:hover{ color: #FFFFFF; background-color: #999998; } QTabBar::tab:disabled{ color: #FFFFFF; background-color: rgba(0, 0, 0, 0); padding-right: -9px; padding-left: -9px; } QTabBar::tear { width: 0px; } QTabBar::scroller{ width: 0; } """) tab = self.addTab('ABOUT YOU') icon = resource.color_svg('arrow_right', 128, '#a6a6a6') tab = self.addTab(icon, '') self.setTabEnabled(tab, False) self.addTab('CREATE WORKSPACE') icon = resource.color_svg('arrow_right', 128, '#a6a6a6') tab = self.addTab(icon, '') self.setTabEnabled(tab, False) self.addTab('ADD YOUR FIRST PROJECT')
def __init__(self, parent=None): """ Args: flow: What part of setup is the user entering into? """ super(CreateUsername, self).__init__(parent) self.logger = logging.getLogger('menu.' + self.__class__.__name__) self.logger.info('Workplace creation starting...') self.setObjectName('launcher_{0}'.format(self.__class__.__name__)) self.parent = parent self.armada_root_path = definitions.ROOT_PATH # self.setAttribute(QtCore.Qt.WA_DeleteOnClose) self.installEventFilter(self) self.setStyleSheet(resource.style_sheet('setup')) self.sizeHint() # GUI ---------------------------------- self.btn_back = QtWidgets.QPushButton() self.btn_back.setIcon(resource.color_svg('arrow_left', 128, '#9E9E9E')) self.btn_back.setIconSize(QtCore.QSize(30, 30)) self.btn_back.setFixedHeight(30) self.btn_back.setStyleSheet(resource.style_sheet('push_button_w_icon')) self.btn_back.hide() self.tb_welcome = QtWidgets.QLabel() self.tb_welcome.setText(""" <p style="font-size:30px;font-weight: normal;">Welcome aboard!</p>""") self.tb_description = QtWidgets.QLabel() self.tb_description.setStyleSheet(""" "font: 12px;font-weight: normal; color: #CFCFCF; """) # Input self.lbl_username = QtWidgets.QLabel("What's your full name?") self.le_username = QtWidgets.QLineEdit() self.le_username.setMinimumHeight(40) regexp = QtCore.QRegExp("^[a-zA-Z0-9- ]+$", QtCore.Qt.CaseInsensitive) validator = QtGui.QRegExpValidator(regexp) self.le_username.setValidator(validator) self.hline_username = QtWidgets.QFrame() self.hline_username.setFixedHeight(1) self.hline_username.setSizePolicy(QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Fixed) self.hline_username.setStyleSheet("background-color: #636363;") self.btn_next = QtWidgets.QPushButton('Next') self.btn_next.setFixedWidth(100) self.btn_next.setStyleSheet(''' QPushButton{ Background:#2e7a78; height: 30px; font: 12px "Roboto-Thin" } QPushButton:hover{ Background: #369593; } QPushButton:hover:pressed{ Background: #2e7a78; } QPushButton:pressed{ Background: #2a615f; } QPushButton:disabled{ Background: #3b3b3b; }''') self.btn_next.setFixedSize(100, 40) self.btn_next.setEnabled(False) # self.lbl_disclaimer = QtWidgets.QTextBrowser() # self.lbl_disclaimer.setReadOnly(True) # self.lbl_disclaimer.setText('Armada Pipeline does not store passwords or account data at this time. Your acocunt is stored locally and only used to add another degree of flexibility project') # self.lbl_disclaimer.setMinimumSize(100, 50) # Layout -------------------------------------------- btn_back_layout = QtWidgets.QVBoxLayout() btn_back_layout.addWidget(self.btn_back) btn_back_layout.setAlignment(QtCore.Qt.AlignTop) btn_back_layout.setContentsMargins(0, 0, 0, 0) btn_back_layout.setSpacing(0) description_layout = QtWidgets.QVBoxLayout() description_layout.addWidget(self.tb_welcome) description_layout.addWidget(self.tb_description) description_layout.setAlignment(QtCore.Qt.AlignTop) description_layout.setContentsMargins(0, 0, 0, 0) description_layout.setSpacing(30) input_layout = QtWidgets.QVBoxLayout() input_layout.addWidget(self.lbl_username) input_layout.addSpacing(10) input_layout.addWidget(self.le_username) input_layout.addWidget(self.hline_username) input_layout.setAlignment(QtCore.Qt.AlignTop) input_layout.setContentsMargins(0, 0, 0, 0) input_layout.setSpacing(0) btn_layout = QtWidgets.QVBoxLayout() btn_layout.addWidget(self.btn_next) btn_layout.setAlignment(QtCore.Qt.AlignTop) btn_layout.setContentsMargins(0, 0, 0, 0) btn_layout.setSpacing(0) contents_layout = QtWidgets.QVBoxLayout() contents_layout.addLayout(description_layout) contents_layout.addLayout(input_layout) contents_layout.addLayout(btn_layout) contents_layout.addStretch() contents_layout.setAlignment(QtCore.Qt.AlignTop) contents_layout.setContentsMargins(0, 0, 0, 0) contents_layout.setSpacing(50) self.main_layout = QtWidgets.QHBoxLayout() self.main_layout.addLayout(btn_back_layout) self.main_layout.addLayout(contents_layout) self.main_layout.setContentsMargins(60, 20, 60, 20) self.main_layout.setSpacing(10) self.setLayout(self.main_layout) # Connections ----------------------------------- self.le_username.textChanged.connect(self.check_le_state)
def __init__(self, parent=None): """ Args: flow: What part of setup is the user entering into? """ super(CreateStructureWorkflow, self).__init__(parent) self.logger = logging.getLogger('menu.' + self.__class__.__name__) self.logger.info('Workplace creation starting...') self.setObjectName('launcher_{0}'.format(self.__class__.__name__)) self.parent = parent self.armada_root_path = definitions.ROOT_PATH # self.setAttribute(QtCore.Qt.WA_DeleteOnClose) self.installEventFilter(self) self.setStyleSheet(resource.style_sheet('setup')) self.sizeHint() # GUI ---------------------------------- self.btn_back = QtWidgets.QPushButton() self.btn_back.setIcon(resource.color_svg('arrow_left', 128, '#9E9E9E')) self.btn_back.setIconSize(QtCore.QSize(30, 30)) self.btn_back.setFixedHeight(30) self.btn_back.setStyleSheet(resource.style_sheet('push_button_w_icon')) self.tb_welcome = QtWidgets.QLabel() self.tb_welcome.setText(""" <p style="font-size:30px;font-weight: normal;">How should we organize this project?</p>""" ) self.tb_welcome.setWordWrap(True) self.tb_description = QtWidgets.QLabel() self.tb_description.setStyleSheet(""" background-color: transparent; font: 12px; font-weight: normal""") self.tb_description.setText(""" <p>Each project utilizes a set of rules called a <b>structure</b> to enforce folder/file locations and naming conventions. <p>Once configured a structure automatically makes sure everyone adheres to the ruleset so you can focus on what you do best: Makin art!</p>""" ) self.tb_description.setWordWrap(True) # Input self.lbl_structure_workflow = QtWidgets.QLabel( "Choose a structure workflow") self.lw_items = QtWidgets.QListWidget() self.lw_items.setViewMode(QtWidgets.QListView.IconMode) # self.lw_items.setMaximumHeight(50) # self.lw_items.setResizeMode(QtWidgets.QListView.Fixed) self.lw_items.setUniformItemSizes(True) self.lw_items.setSizeAdjustPolicy(QtWidgets.QListWidget.AdjustIgnored) self.lw_items.setMovement(self.lw_items.Static) self.lw_items.setSizeAdjustPolicy( QtWidgets.QAbstractScrollArea.AdjustToContents) self.lw_items.setSizePolicy(QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Expanding) self.lw_items.setFlow(QtWidgets.QListView.LeftToRight) # self.lw_items.setSpacing(5) self.lw_items.setMinimumHeight(100) self.lw_items.setStyleSheet(""" QListView{ show-decoration-selected: 0; background: #262626; color:rgb(218,218,218) ; font:12px "Roboto-Thin"; border: none; height: 200px; outline: 0; padding-left: 10; padding-right: 10; } """) # Structure workflow options builtin_icon = resource.color_svg('folder_folder', 1024, '#F9D085') lw_item = QtWidgets.QListWidgetItem(builtin_icon, 'Built In Structure') lw_item.setSizeHint(self.lw_items.sizeHint()) self.lw_items.addItem(lw_item) custom_icon = resource.color_svg('structure_create', 1024, '#7D7D7D') lw_item = QtWidgets.QListWidgetItem(custom_icon, 'Custom Structure') lw_item.setSizeHint(self.lw_items.sizeHint()) # lw_item.setFlags(QtCore.Qt.ItemIsSelectable) # TODO: enable when custom structures workflow is figured out self.lw_items.addItem(lw_item) self.lbl_structure_description = QtWidgets.QLabel() self.lbl_structure_description.setWordWrap(True) self.lbl_structure_description.setStyleSheet(""" background-color: transparent; font: 12px; font-weight: normal""") self.hline_username = QtWidgets.QFrame() self.hline_username.setFixedHeight(1) self.hline_username.setSizePolicy(QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Fixed) self.hline_username.setStyleSheet("background-color: #636363;") self.btn_next = QtWidgets.QPushButton('Next') self.btn_next.setFixedWidth(100) self.btn_next.setStyleSheet(''' QPushButton{ Background:#2e7a78; height: 30px; font: 12px "Roboto-Thin" } QPushButton:hover{ Background: #369593; } QPushButton:hover:pressed{ Background: #2e7a78; } QPushButton:pressed{ Background: #2a615f; } QPushButton:disabled{ Background: #3b3b3b; }''') self.btn_next.setFixedSize(100, 40) self.btn_next.setEnabled(False) # self.lbl_disclaimer = QtWidgets.QTextBrowser() # self.lbl_disclaimer.setReadOnly(True) # self.lbl_disclaimer.setText('Armada Pipeline does not store passwords or account data at this time. Your acocunt is stored locally and only used to add another degree of flexibility project') # self.lbl_disclaimer.setMinimumSize(100, 50) # Layout -------------------------------------------- btn_back_layout = QtWidgets.QVBoxLayout() btn_back_layout.addWidget(self.btn_back) btn_back_layout.setAlignment(QtCore.Qt.AlignTop) btn_back_layout.setContentsMargins(0, 0, 0, 0) btn_back_layout.setSpacing(0) description_layout = QtWidgets.QVBoxLayout() description_layout.addWidget(self.tb_welcome) description_layout.addWidget(self.tb_description) description_layout.setAlignment(QtCore.Qt.AlignTop) description_layout.setContentsMargins(0, 0, 0, 0) description_layout.setSpacing(30) input_layout = QtWidgets.QVBoxLayout() input_layout.addWidget(self.lbl_structure_workflow) input_layout.addWidget(self.lw_items) input_layout.addWidget(self.lbl_structure_description) input_layout.setAlignment(QtCore.Qt.AlignTop) input_layout.setContentsMargins(0, 0, 0, 0) input_layout.setSpacing(10) btn_layout = QtWidgets.QVBoxLayout() btn_layout.addWidget(self.btn_next) btn_layout.setAlignment(QtCore.Qt.AlignTop) btn_layout.setContentsMargins(0, 0, 0, 0) btn_layout.setSpacing(0) contents_layout = QtWidgets.QVBoxLayout() contents_layout.addLayout(description_layout) contents_layout.addLayout(input_layout) contents_layout.addLayout(btn_layout) contents_layout.addStretch() contents_layout.setAlignment(QtCore.Qt.AlignTop) contents_layout.setContentsMargins(0, 0, 0, 0) contents_layout.setSpacing(50) self.main_layout = QtWidgets.QHBoxLayout() self.main_layout.addLayout(btn_back_layout) self.main_layout.addLayout(contents_layout) self.main_layout.setContentsMargins(20, 20, 60, 20) self.main_layout.setSpacing(10) self.setLayout(self.main_layout) # Connections ----------------------------------- # self.btn_next.clicked.connect(self._on_next) self.lw_items.itemClicked.connect(self._lw_sel_changed)