def __init__(self, parent=None): PylintWidget.__init__(self, parent=parent, max_entries=CONF.get(self.ID, 'max_entries')) PluginMixin.__init__(self, parent) self.set_font(get_font(self.ID))
def __init__(self, parent=None, path=None): ExplorerWidget.__init__(self, parent=parent, path=path, name_filters=CONF.get(self.ID, 'name_filters'), valid_types=CONF.get(self.ID, 'valid_filetypes'), show_all=CONF.get(self.ID, 'show_all'), show_toolbar=CONF.get(self.ID, 'show_toolbar'), show_icontext=CONF.get(self.ID, 'show_icontext')) PluginMixin.__init__(self, parent) self.set_font(get_font(self.ID)) self.connect(self, SIGNAL("open_file(QString)"), self.open_file)
def __init__(self, parent=None, path=None): ExplorerWidget.__init__( self, parent=parent, path=path, name_filters=CONF.get(self.ID, "name_filters"), valid_types=CONF.get(self.ID, "valid_filetypes"), show_all=CONF.get(self.ID, "show_all"), show_toolbar=CONF.get(self.ID, "show_toolbar"), show_icontext=CONF.get(self.ID, "show_icontext"), ) PluginMixin.__init__(self, parent) self.set_font(get_font(self.ID)) self.connect(self, SIGNAL("open_file(QString)"), self.open_file)
def __init__(self, parent): self.interpreter = None self.namespace = None self.filename = None truncate = CONF.get(self.ID, 'truncate') inplace = CONF.get(self.ID, 'inplace') minmax = CONF.get(self.ID, 'minmax') collvalue = CONF.get(self.ID, 'collvalue') DictEditorTableView.__init__(self, parent, None, names=True, truncate=truncate, inplace=inplace, minmax=minmax, collvalue=collvalue) PluginMixin.__init__(self, parent) self.setup_io() self.load_temp_namespace() self.setFont(get_font(self.ID))
def __init__(self, parent=None): supported_encodings = CONF.get(self.ID, 'supported_encodings') search_path = CONF.get(self.ID, 'search_path', None) self.search_text_samples = CONF.get(self.ID, 'search_text_samples') search_text = CONF.get(self.ID, 'search_text') search_text = [txt for txt in search_text \ if txt not in self.search_text_samples] search_text += self.search_text_samples search_text_regexp = CONF.get(self.ID, 'search_text_regexp') include = CONF.get(self.ID, 'include') include_regexp = CONF.get(self.ID, 'include_regexp') exclude = CONF.get(self.ID, 'exclude') exclude_regexp = CONF.get(self.ID, 'exclude_regexp') FindInFilesWidget.__init__(self, parent, search_text, search_text_regexp, search_path, include, include_regexp, exclude, exclude_regexp, supported_encodings) PluginMixin.__init__(self, parent) self.connect(self, SIGNAL('toggle_visibility(bool)'), self.toggle)
def __init__(self, parent, workdir=None): QToolBar.__init__(self, parent) PluginMixin.__init__(self, parent) self.setWindowTitle(self.get_widget_title()) # Toolbar title self.setObjectName(self.get_widget_title()) # Used to save Window state self.addWidget( QLabel(self.tr("Working directory:")+" ") ) # Previous dir action self.history = [] self.histindex = None self.previous_action = create_action(self, "previous", None, get_icon('previous.png'), self.tr('Back'), triggered=self.previous_directory) self.addAction(self.previous_action) # Next dir action self.history = [] self.histindex = None self.next_action = create_action(self, "next", None, get_icon('next.png'), self.tr('Next'), triggered=self.next_directory) self.addAction(self.next_action) # Enable/disable previous/next actions self.connect(self, SIGNAL("set_previous_enabled(bool)"), self.previous_action.setEnabled) self.connect(self, SIGNAL("set_next_enabled(bool)"), self.next_action.setEnabled) # Path combo box adjust = CONF.get('shell', 'working_dir_adjusttocontents', False) self.pathedit = PathComboBox(self, adjust_to_contents=adjust) self.pathedit.setToolTip(self.tr("Working directory")) self.connect(self.pathedit, SIGNAL("open_dir(QString)"), self.pathedit_activated) self.pathedit.setMaxCount(CONF.get('shell', 'working_dir_history')) wdhistory = self.load_wdhistory( workdir ) if workdir is None: if wdhistory: workdir = wdhistory[0] else: workdir = "." self.chdir(workdir) self.pathedit.addItems( wdhistory ) self.refresh() self.addWidget(self.pathedit) # Browse action browse_action = create_action(self, "browse", None, get_std_icon('DirOpenIcon'), self.tr('Browse a working directory'), triggered=self.select_directory) self.addAction(browse_action) # Parent dir action parent_action = create_action(self, "parent", None, get_icon('up.png'), self.tr('Change to parent directory'), triggered=self.parent_directory) self.addAction(parent_action)
def __init__(self, parent, workdir=None): QToolBar.__init__(self, parent) PluginMixin.__init__(self, parent) self.setWindowTitle(self.get_widget_title()) # Toolbar title self.setObjectName( self.get_widget_title()) # Used to save Window state self.addWidget(QLabel(self.tr("Working directory:") + " ")) # Previous dir action self.history = [] self.histindex = None self.previous_action = create_action(self, "previous", None, get_icon('previous.png'), self.tr('Back'), triggered=self.previous_directory) self.addAction(self.previous_action) # Next dir action self.history = [] self.histindex = None self.next_action = create_action(self, "next", None, get_icon('next.png'), self.tr('Next'), triggered=self.next_directory) self.addAction(self.next_action) # Enable/disable previous/next actions self.connect(self, SIGNAL("set_previous_enabled(bool)"), self.previous_action.setEnabled) self.connect(self, SIGNAL("set_next_enabled(bool)"), self.next_action.setEnabled) # Path combo box adjust = CONF.get('shell', 'working_dir_adjusttocontents', False) self.pathedit = PathComboBox(self, adjust_to_contents=adjust) self.pathedit.setToolTip(self.tr("Working directory")) self.connect(self.pathedit, SIGNAL("open_dir(QString)"), self.pathedit_activated) self.pathedit.setMaxCount(CONF.get('shell', 'working_dir_history')) wdhistory = self.load_wdhistory(workdir) if workdir is None: if wdhistory: workdir = wdhistory[0] else: workdir = "." self.chdir(workdir) self.pathedit.addItems(wdhistory) self.refresh() self.addWidget(self.pathedit) # Browse action browse_action = create_action(self, "browse", None, get_std_icon('DirOpenIcon'), self.tr('Browse a working directory'), triggered=self.select_directory) self.addAction(browse_action) # Parent dir action parent_action = create_action(self, "parent", None, get_icon('up.png'), self.tr('Change to parent directory'), triggered=self.parent_directory) self.addAction(parent_action)