[Idle-dev] CVS: idle ColorDelegator.py,1.3,1.4
Stephen M. Gava
elguavas@users.sourceforge.net
Fri, 02 Nov 2001 21:04:57 -0800
Update of /cvsroot/idlefork/idle
In directory usw-pr-cvs1:/tmp/cvs-serv29906
Modified Files:
ColorDelegator.py
Log Message:
more work to support new config system
Index: ColorDelegator.py
===================================================================
RCS file: /cvsroot/idlefork/idle/ColorDelegator.py,v
retrieving revision 1.3
retrieving revision 1.4
diff -C2 -r1.3 -r1.4
*** ColorDelegator.py 2001/07/13 00:04:24 1.3
--- ColorDelegator.py 2001/11/03 05:04:55 1.4
***************
*** 5,9 ****
from Tkinter import *
from Delegator import Delegator
! from IdleConf import idleconf
#$ event <<toggle-auto-coloring>>
--- 5,9 ----
from Tkinter import *
from Delegator import Delegator
! from configHandler import idleConf
#$ event <<toggle-auto-coloring>>
***************
*** 54,70 ****
self.tag_raise('sel')
! cconf = idleconf.getsection('Colors')
tagdefs = {
! "COMMENT": cconf.getcolor("comment"),
! "KEYWORD": cconf.getcolor("keyword"),
! "STRING": cconf.getcolor("string"),
! "DEFINITION": cconf.getcolor("definition"),
! "SYNC": cconf.getcolor("sync"),
! "TODO": cconf.getcolor("todo"),
! "BREAK": cconf.getcolor("break"),
# The following is used by ReplaceDialog:
! "hit": cconf.getcolor("hit"),
}
def insert(self, index, chars, tags=None):
--- 54,72 ----
self.tag_raise('sel')
! theme = idleConf.GetOption('main','Theme','name')
tagdefs = {
! "COMMENT": idleConf.GetHighlight(theme, "comment"),
! "KEYWORD": idleConf.GetHighlight(theme, "keyword"),
! "STRING": idleConf.GetHighlight(theme, "string"),
! "DEFINITION": idleConf.GetHighlight(theme, "definition"),
! "SYNC": idleConf.GetHighlight(theme, "sync"),
! "TODO": idleConf.GetHighlight(theme, "todo"),
! "BREAK": idleConf.GetHighlight(theme, "break"),
# The following is used by ReplaceDialog:
! "hit": idleConf.GetHighlight(theme, "hit"),
}
+
+ print tagdefs
def insert(self, index, chars, tags=None):