(self)
frm_lyt = QFormLayout()
        frm_lyt.setContentsMargins(10, 10, 10, 10)

        _label = QLabel('Script to load (optional)')
        frm_lyt.addRow(_label)

        user_script_path = QLineEdit()
        load_button = QPushButton('...')

        frm_lyt.addRow(load_button, user_script_path)

        main_wrap.addLayout(frm_lyt)
frm_lyt = QFormLayout()
        frm_lyt.setContentsMargins(10, 10, 10, 10)
frm_lyt = QFormLayout () frm_lyt . setContentsMargins ( 10 10 10 10 )
def setup_ui(self):
        main_wrap = QVBoxLayout(self)
        main_wrap.setContentsMargins(0, 0, 0, 0)

        self.desktop_geom = qApp.desktop().availableGeometry()
        self.setFixedSize(self.desktop_geom.width() * .6,
                          self.desktop_geom.height() * .5)

        if self.device is None:
            self._dev_bar = DeviceBar(self, self.device_type)
            self._dev_bar.onDeviceUpdated.connect(self._update_device)
            self._dev_bar.onDeviceChanged.connect(self._changed_device)
            main_wrap.addWidget(self._dev_bar)

        """frm_lyt = QFormLayout()
        frm_lyt.setContentsMargins(10, 10, 10, 10)

        _label = QLabel('Script to load (optional)')
        frm_lyt.addRow(_label)

        user_script_path = QLineEdit()
        load_button = QPushButton('...')

        frm_lyt.addRow(load_button, user_script_path)

        main_wrap.addLayout(frm_lyt)"""

        # procs/spawns lists
        spawns_vbox = QVBoxLayout()

        spawns_label = QLabel('SPAWN')
        spawns_label.setFont(QFont('Anton', 20, QFont.Normal))
        spawns_vbox.addWidget(spawns_label)
        self.spawn_list = SpawnsList(device=self.device)
        self.spawn_list.onProcessSelected.connect(self._spawn_selected)
        self.spawn_list.onRefreshError.connect(self._on_spawn_error)
        spawns_vbox.addWidget(self.spawn_list)

        procs_vbox = QVBoxLayout()
        procs_label = QLabel('PROCS')
        procs_label.setFont(QFont('Anton', 20, QFont.Normal))
        procs_vbox.addWidget(procs_label)

        self.proc_list = ProcessList(device=self.device)
        self.proc_list.onProcessSelected.connect(self._pid_selected)
        self.proc_list.onRefreshError.connect(self._on_proc_error)
        procs_vbox.addWidget(self.proc_list)

        inner_hbox = QHBoxLayout()
        inner_hbox.setContentsMargins(10, 10, 10, 10)
        inner_hbox.addLayout(spawns_vbox)
        inner_hbox.addLayout(procs_vbox)

        vbox = QVBoxLayout()
        vbox.setContentsMargins(0, 0, 0, 0)
        # vbox.addWidget(self._dev_bar)
        main_wrap.addLayout(inner_hbox)

        # center
        self.setGeometry(
            QStyle.alignedRect(Qt.LeftToRight, Qt.AlignCenter, self.size(), qApp.desktop().availableGeometry()))
def setup_ui ( self ) : main_wrap = QVBoxLayout ( self ) main_wrap . setContentsMargins ( 0 , 0 , 0 , 0 ) self . desktop_geom = qApp . desktop ( ) . availableGeometry ( ) self . setFixedSize ( self . desktop_geom . width ( ) * .6 , self . desktop_geom . height ( ) * .5 ) if self . device is None : self . _dev_bar = DeviceBar ( self , self . device_type ) self . _dev_bar . onDeviceUpdated . connect ( self . _update_device ) self . _dev_bar . onDeviceChanged . connect ( self . _changed_device ) main_wrap . addWidget ( self . _dev_bar ) # procs/spawns lists spawns_vbox = QVBoxLayout ( ) spawns_label = QLabel ( 'SPAWN' ) spawns_label . setFont ( QFont ( 'Anton' , 20 , QFont . Normal ) ) spawns_vbox . addWidget ( spawns_label ) self . spawn_list = SpawnsList ( device = self . device ) self . spawn_list . onProcessSelected . connect ( self . _spawn_selected ) self . spawn_list . onRefreshError . connect ( self . _on_spawn_error ) spawns_vbox . addWidget ( self . spawn_list ) procs_vbox = QVBoxLayout ( ) procs_label = QLabel ( 'PROCS' ) procs_label . setFont ( QFont ( 'Anton' , 20 , QFont . Normal ) ) procs_vbox . addWidget ( procs_label ) self . proc_list = ProcessList ( device = self . device ) self . proc_list . onProcessSelected . connect ( self . _pid_selected ) self . proc_list . onRefreshError . connect ( self . _on_proc_error ) procs_vbox . addWidget ( self . proc_list ) inner_hbox = QHBoxLayout ( ) inner_hbox . setContentsMargins ( 10 , 10 , 10 , 10 ) inner_hbox . addLayout ( spawns_vbox ) inner_hbox . addLayout ( procs_vbox ) vbox = QVBoxLayout ( ) vbox . setContentsMargins ( 0 , 0 , 0 , 0 ) # vbox.addWidget(self._dev_bar) main_wrap . addLayout ( inner_hbox ) # center self . setGeometry ( QStyle . alignedRect ( Qt . LeftToRight , Qt . AlignCenter , self . size ( ) , qApp . desktop ( ) . availableGeometry ( ) ) )