def __init__(self, argv, locale=None, gui=True): cfgactions.install() i18n.install(locale) qtcompat.install() qtutils.install() icons.install() self.notifier = QtCore.QObject() self.notifier.connect(self.notifier, SIGNAL('update_files()'), self._update_files, Qt.QueuedConnection) # Call _update_files when inotify detects changes inotify.observer(self._update_files_notifier) if gui: self._app = current(tuple(argv)) self._app.setWindowIcon(icons.cola()) self._app.setStyleSheet(""" QMainWindow::separator { width: 3px; height: 3px; } QMainWindow::separator:hover { background: white; } """) else: self._app = QtCore.QCoreApplication(argv)
def __init__(self, argv, locale=None, gui=True, git_path=None): cfgactions.install() i18n.install(locale) qtcompat.install() qtutils.install() # Call _update_files when inotify detects changes inotify.observer(_update_files) # Add the default style dir so that we find our icons icon_dir = resources.icon_dir() qtcompat.add_search_path(os.path.basename(icon_dir), icon_dir) if gui: self._app = instance(tuple(argv), git_path) self._app.setWindowIcon(qtutils.git_icon()) else: self._app = QtCore.QCoreApplication(argv) self._app.setStyleSheet(""" QMainWindow::separator { width: 3px; height: 3px; } QMainWindow::separator:hover { background: white; } """)
def __init__(self, argv, locale=None, gui=True): cfgactions.install() i18n.install(locale) qtcompat.install() qtutils.install() self.notifier = QtCore.QObject() self.notifier.connect(self.notifier, SIGNAL("update_files()"), self._update_files, Qt.QueuedConnection) # Call _update_files when inotify detects changes inotify.observer(self._update_files_notifier) # Add the default style dir so that we find our icons icon_dir = resources.icon_dir() qtcompat.add_search_path(os.path.basename(icon_dir), icon_dir) if gui: self._app = current(tuple(argv)) self._app.setWindowIcon(qtutils.git_icon()) self._app.setStyleSheet( """ QMainWindow::separator { width: 3px; height: 3px; } QMainWindow::separator:hover { background: white; } """ ) else: self._app = QtCore.QCoreApplication(argv)
def __init__(self, argv, locale=None, gui=True, git_path=None): cfgactions.install() i18n.install(locale) qtcompat.install() qtutils.install() self.notifier = QtCore.QObject() self.notifier.connect(self.notifier, SIGNAL('update_files'), self._update_files) # Call _update_files when inotify detects changes inotify.observer(self._update_files_notifier) # Add the default style dir so that we find our icons icon_dir = resources.icon_dir() qtcompat.add_search_path(os.path.basename(icon_dir), icon_dir) if gui: self._app = current(tuple(argv), git_path) self._app.setWindowIcon(qtutils.git_icon()) self._app.setStyleSheet(""" QMainWindow::separator { width: 3px; height: 3px; } QMainWindow::separator:hover { background: white; } """) else: self._app = QtCore.QCoreApplication(argv)