def __init__(self, parent, name='IntroPage'):
     BaseConfigWidget.__init__(self, parent, name=name)
     numrows = 2
     numcols = 1
     margin = 5
     space = 7
     self.grid = QGridLayout(self, numrows, numcols,
                             margin, space, 'IntroPageLayout')
     lbl = QLabel(intro, self)
     self.grid.addWidget(lbl, 0, 0)
 def __init__(self, parent, name='DosboxPathPage'):
     BaseConfigWidget.__init__(self, parent, name=name)
     numrows = 2
     numcols = 1
     margin = 5
     space = 7
     self.grid = QGridLayout(self, numrows, numcols,
                             margin, space, 'DosboxPathPageLayout')
     lbl = QLabel(dosbox_path_lbl, self)
     lbl.setFrameStyle(lbl.Panel + lbl.Sunken)
     #lbl.setFrameStyle(lbl.Raised)
     self.grid.addWidget(lbl, 0, 0)
     self.dosbox_path_entry = ConfigKURLSelectWidget(self, 'Path to main dosbox area',
                                                     filetype='dir')
     self.grid.addWidget(self.dosbox_path_entry, 1, 0)
 def __init__(self, parent, name='ArchivePathsPage'):
     BaseConfigWidget.__init__(self, parent, name=name)
     numrows = 2
     numcols = 1
     margin = 5
     space = 7
     self.grid = QGridLayout(self, numrows, numcols,
                             margin, space, 'ArchivePathsPageLayout')
     lbl = QLabel(archive_paths_lbl, self)
     lbl.setFrameStyle(lbl.Panel + lbl.Sunken)
     #lbl.setFrameStyle(lbl.Raised)
     self.grid.addWidget(lbl, 0, 0)
     self.installed_entry = ConfigKURLSelectWidget(self, 'Path to "install" archives',
                                                   filetype='dir')
     self.tooltips.add(self.installed_entry,
                       "This is the path to the archives of fresh installs")
     self.grid.addWidget(self.installed_entry, 1, 0)
     self.extras_entry = ConfigKURLSelectWidget(self, 'Path to "extras" archives',
                                                filetype='dir')
     self.grid.addWidget(self.extras_entry, 2, 0)
示例#4
0
 def __init__(self, parent, name='BaseDosboxConfigWidget'):
     BaseConfigWidget.__init__(self, parent, name=name)
 def __init__(self, parent, name='SettingsWidget'):
     BaseConfigWidget.__init__(self, parent, name=name)
     numrows = 2
     numcols = 2
     margin = 7
     space = 10
     self.grid = QGridLayout(self, numrows, numcols,
                             margin, space, 'SettingsWidgetLayout')
     self.myconfig = self.app.myconfig
     for section in ['filemanagement', 'dosbox', 'externalactions', 'mainwindow']:
         self.localconfig.add_section(section)
         
     # filemanagement area
     self.filemanagement_groupbox = VerticalGroupBox(self, 'File Management')
     self.filemanagement_groupbox.setColumns(4)
     #self.grid.addWidget(self.filemanagement_groupbox, 0, 0)
     self.grid.addMultiCellWidget(self.filemanagement_groupbox, 0, 0, 0, 1)
     self.use_rdiff_backup_check = QCheckBox(self.filemanagement_groupbox)
     self.use_rdiff_backup_check.setText('Use rdiff-backup')
     self.use_rsync_check = QCheckBox(self.filemanagement_groupbox)
     self.use_rsync_check.setText('Use rsync')
     self.overwrite_extras_archives_check = QCheckBox(self.filemanagement_groupbox)
     self.overwrite_extras_archives_check.setText('Overwrite extras archives')
     self.archives_groupbox = VerticalGroupBox(self.filemanagement_groupbox,
                                               'Archive Paths')
     self.archives_groupbox.setColumns(2)
     #self.grid.addWidget(self.archives_groupbox, 0, 1)
     self.installed_archives_entry = ConfigKURLSelectWidget(self.archives_groupbox,
                                                            'Path to the "install" archives',
                                                            filetype='dir')
     self.extras_archives_entry = ConfigKURLSelectWidget(self.archives_groupbox,
                                                         'Path to the "extras" archives',
                                                         filetype='dir')
     # dosbox area
     self.dosbox_groupbox = VerticalGroupBox(self, 'Dosbox Options')
     self.dosbox_groupbox.setColumns(3)
     #self.grid.addWidget(self.dosbox_groupbox, 1, 0)
     self.grid.addMultiCellWidget(self.dosbox_groupbox, 1, 1, 0, 1)
     self.main_dosbox_path_entry = ConfigKURLSelectWidget(self.dosbox_groupbox,
                                                          'Path to dosbox area',
                                                          filetype='dir')
     self.dosbox_binary_entry = ConfigLineEditWidget(self.dosbox_groupbox,
                                                     'Dosbox executable')
     self.cdrive_is_main_check = QCheckBox(self.dosbox_groupbox)
     self.cdrive_is_main_check.setText('C: Drive is main dosbox path')
     # externalactions area
     self.externalactions_groupbox = VerticalGroupBox(self, 'External Actions')
     self.externalactions_groupbox.setColumns(2)
     self.grid.addWidget(self.externalactions_groupbox, 2, 0)
     self.launch_weblinks_entry = ConfigLineEditWidget(self.externalactions_groupbox,
                                                       'Command to handle weblink clicks')
     self.text_editor_entry = ConfigLineEditWidget(self.externalactions_groupbox,
                                                   'Text editor command')
     # mainwindow area
     self.mainwindow_groupbox = VerticalGroupBox(self, 'Main Window Options')
     self.mainwindow_groupbox.setColumns(3)
     self.grid.addWidget(self.mainwindow_groupbox, 2, 1)
     self.mainwindow_size_box = ConfigWinSizeWidget(self.mainwindow_groupbox,
                                                    'Size of main window')
     self.flat_tree_box = ConfigComboBoxWidget(self.mainwindow_groupbox,
                                               'Game list style', ['flat', 'tree'])
     self.name_title_box = ConfigComboBoxWidget(self.mainwindow_groupbox,
                                                'Game list entries', ['name', 'title'])