Exemplo n.º 1
0
 def timeToUpdateTheColors_(self, sender):
     syntaxAttrs = getSyntaxTextAttributes()
     syntaxAttrs["string"][NSForegroundColorAttributeName] = self.stringsColorWell.color()
     syntaxAttrs["keyword"][NSForegroundColorAttributeName] = self.keywordsColorWell.color()
     syntaxAttrs["identifier"][NSForegroundColorAttributeName] = self.funcClassColorWell.color()
     syntaxAttrs["comment"][NSForegroundColorAttributeName] = self.commentsColorWell.color()
     setSyntaxTextAttributes(syntaxAttrs)
Exemplo n.º 2
0
    def awakeFromNib(self):
        self.textFontChanged_(None)
        syntaxAttrs = syntaxAttrs = getSyntaxTextAttributes()
        self.stringsColorWell.setColor_(syntaxAttrs["string"][NSForegroundColorAttributeName])
        self.keywordsColorWell.setColor_(syntaxAttrs["keyword"][NSForegroundColorAttributeName])
        self.funcClassColorWell.setColor_(syntaxAttrs["identifier"][NSForegroundColorAttributeName])
        self.commentsColorWell.setColor_(syntaxAttrs["comment"][NSForegroundColorAttributeName])

        nc = NSNotificationCenter.defaultCenter()
        nc.addObserver_selector_name_object_(self, "textFontChanged:", "PyDETextFontChanged", None)
Exemplo n.º 3
0
 def timeToUpdateTheColors_(self, sender):
     syntaxAttrs = getSyntaxTextAttributes()
     syntaxAttrs["string"][
         NSForegroundColorAttributeName] = self.stringsColorWell.color()
     syntaxAttrs["keyword"][
         NSForegroundColorAttributeName] = self.keywordsColorWell.color()
     syntaxAttrs["identifier"][
         NSForegroundColorAttributeName] = self.funcClassColorWell.color()
     syntaxAttrs["comment"][
         NSForegroundColorAttributeName] = self.commentsColorWell.color()
     setSyntaxTextAttributes(syntaxAttrs)
Exemplo n.º 4
0
    def awakeFromNib(self):
        self.textFontChanged_(None)
        syntaxAttrs = syntaxAttrs = getSyntaxTextAttributes()
        self.stringsColorWell.setColor_(
            syntaxAttrs["string"][NSForegroundColorAttributeName])
        self.keywordsColorWell.setColor_(
            syntaxAttrs["keyword"][NSForegroundColorAttributeName])
        self.funcClassColorWell.setColor_(
            syntaxAttrs["identifier"][NSForegroundColorAttributeName])
        self.commentsColorWell.setColor_(
            syntaxAttrs["comment"][NSForegroundColorAttributeName])

        nc = NSNotificationCenter.defaultCenter()
        nc.addObserver_selector_name_object_(self, "textFontChanged:",
                                             "PyDETextFontChanged", None)