I had found editra myself during my searching but had already decided to try
dabo by the time I found it. If I end up going back to writing
directly with wxPython It will probably be more helpfull. I have been trying to
look at the editra code to try to undstand what to do.
Well I took another stab at it but i'm still not able to get affect changes to
the text. Part way through I started keeping my attempts seperated. I'm
wondering if the evt parameter of the onEditorStyleNeeded(self, evt) is the
right version of event? The examples I can find use
evt.GetPosition() to find the end posistion to format but that method doesn't
exist in the evt parameter being passed. Again thanks for all the help.
-- AaronS
def afterInit(self):
self.Language = "container"
def onEditorStyleNeeded(self, evt):
self.StyleSetItalic(4, True)
start = self.GetEndStyled() # this is the first character that needs styling
end = self.GetPosition() # this is the last character that needs
styling
self.StartStyling(start, 31) # in this example, only style the text style
bits
for pos in range(start, end): # in this example, simply loop over it..
self.SetStyling(1, 4)
#----------------
# Error: TypeError: range() integer end argument expected, got Point.
# self.StyleSetItalic(4, True)
# start = self.GetEndStyled() # this is the first character that needs
styling
# end = self.GetPosition() # this is the last character that needs
styling #this is probably the point of the stc control
# self.StartStyling(start, 31) # in this example, only style the text style
bits
# for pos in range(start, end): # in this example, simply loop over it..
# self.SetStyling(1, 4)
#----------------
#Error: AttributeError: dabo.dEvents.EditorStyleNeeded Object has no attribute
GetPosition.
# start = self.GetEndStyled() # this is the first character that needs
styling
# end = evt.GetPosition() # this is the last character that needs
styling
# self.StartStyling(start, 31) # in this example, only style the text style
bits
# for pos in range(start, end): # in this example, simply loop over it..
# self.SetStyling(1, NUMBER)
#-------------------
# StyleSetBackground(4,"RED")
# stc.StartStyling(0, 31)
# stc.SetStyling(1, 4)
#end = evt.GetPosition()
#start = stc.GetEndStyled()
#stc.StartStyling(start, 0x1f)
#for i in range(start, end + 1):
#stc.SetStyling(1, 4)
--- StripMime Report -- processed MIME parts ---
multipart/alternative
text/plain (text body -- kept)
text/html
---
_______________________________________________
Post Messages to: [email protected]
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message:
http://leafe.com/archives/byMID/[email protected]