Exemplo n.º 1
0
 def load(self):
     design_file = os.path.join(
         get_base_dir(True), "designer_files", "MultiStandWidget.ui")
     uic.loadUi(design_file, self)
     self.setWindowTitle("MuseLib Multistand View: " + self.file)
     self.pageValue.valueChanged.connect(self.pageValChanged)
     self.zoomInBtn.clicked.connect(self.zoomIn)
     self.zoomOutBtn.clicked.connect(self.zoomOut)
Exemplo n.º 2
0
 def load(self):
     design_file = os.path.join(get_base_dir(True), "designer_files",
                                "MultiStandWidget.ui")
     uic.loadUi(design_file, self)
     self.setWindowTitle("MuseLib Multistand View: " + self.file)
     self.pageValue.valueChanged.connect(self.pageValChanged)
     self.zoomInBtn.clicked.connect(self.zoomIn)
     self.zoomOutBtn.clicked.connect(self.zoomOut)
Exemplo n.º 3
0
 def __init__(self, app):
     self.wifi = True
     self.lastQuery = ""
     QtCore.QObject.__init__(self)
     self.meta = {}
     self.meta["collections"] = []
     if getattr(sys, "frozen", False):
         self.gui_folder = os.path.join(get_base_dir(True),
                                        "implementation", "primaries",
                                        "GUI")
     else:
         self.gui_folder = get_base_dir(True)
     self.theme_folder = os.path.join(self.gui_folder, "themes")
     self.design_folder = os.path.join(self.gui_folder, "designer_files")
     self.meta["theme"] = "ubuntu"
     self.meta["path"] = None
     self.LoadMeta()
     self.folder = None
     self.load_windows()
     self.updateStatusBar("hello, world")
Exemplo n.º 4
0
 def __init__(self, app):
     self.wifi = True
     self.lastQuery = ""
     QtCore.QObject.__init__(self)
     self.meta = {}
     self.meta["collections"] = []
     if getattr(sys, "frozen", False):
         self.gui_folder = os.path.join(get_base_dir(True),
                                        "implementation",
                                        "primaries",
                                        "GUI")
     else:
         self.gui_folder = get_base_dir(True)
     self.theme_folder = os.path.join(self.gui_folder, "themes")
     self.design_folder = os.path.join(self.gui_folder, "designer_files")
     self.meta["theme"] = "ubuntu"
     self.meta["path"] = None
     self.LoadMeta()
     self.folder = None
     self.load_windows()
     self.updateStatusBar("hello, world")
Exemplo n.º 5
0
 def testParseThemePathWithCSS(self):
     line = 'background: url(/themes/zoom-out.png) center no-repeat;'
     expected_path = os.path.join(helpers.get_base_dir(True), 'themes',
                                  "zoom-out.png")
     if sys.platform == 'win32':
         expected = "background: url('" + \
             expected_path + '\') center no-repeat;'
     else:
         expected = "background: url(" + \
             expected_path + ') center no-repeat;'
     cleaned_path = helpers.cleanPath(line)
     self.assertEqual(
         expected, helpers.parseThemePath(cleaned_path, self.theme_folder))
Exemplo n.º 6
0
    def __init__(self, parent=None, message="", title="mbox"):
        QtGui.QWidget.__init__(self, parent)

        self.setGeometry(300, 300, 250, 150)
        self.setWindowTitle(title)
        designer_file = os.path.join(
            get_base_dir(
                return_this_dir=True),
            'designer_files',
            'MessageBox.ui')
        uic.loadUi(designer_file, self)
        self.errorLabel.setText(message)
        self.okBtn.clicked.connect(self.close)
Exemplo n.º 7
0
 def testParseThemePathWithCSS(self):
     line = 'background: url(/themes/zoom-out.png) center no-repeat;'
     expected_path = os.path.join(
         helpers.get_base_dir(True), 'themes', "zoom-out.png")
     if sys.platform == 'win32':
         expected = "background: url('" + \
             expected_path + '\') center no-repeat;'
     else:
         expected = "background: url(" + \
             expected_path + ') center no-repeat;'
     cleaned_path = helpers.cleanPath(line)
     self.assertEqual(
         expected,
         helpers.parseThemePath(
             cleaned_path,
             self.theme_folder))
Exemplo n.º 8
0
 def setUp(self):
     self.theme_folder = os.path.join(helpers.get_base_dir(True), 'themes')
Exemplo n.º 9
0
 def setUp(self):
     self.theme_folder = os.path.join(helpers.get_base_dir(True), 'themes')