PythonWin/Scintilla aggressive folding...
Olivier Dagenais
olivierS.dagenaisP at canadaA.comM
Wed Jul 26 10:49:46 EDT 2000
"Neil Hodgson" wrote:
[about not making comments level-neutral]
> Yes, a patch like this could help for your code. I introduced the level
> neutral comments idea after developing the original strictly indentation
> based code and using it on example files. First blank lines had to become
> level neutral as lots of functions and methods have blank lines. Then I
> found lots of commented out bits so made the comment lines work like blank
> lines. Another heuristic that may be light weight would be that comment
> lines try to bind in a forwards direction but this may require some
> look-ahead.
You mean to detect the indentation of the commented-out code? That might be
hard, given you might have a comment like any of the following: "sharp",
"sharp space", "sharp sharp", "sharp sharp space". I didn't realize this
would be such an involved feature....
[about strings in code]
> I think they bulk the compiled code up a bit but I doubt whether its
> significant.
If it's pretty much harmless and all it acts as is a seperator or an "end of
definition" marker, like so:
class ztApp ( wxApp ):
def OnInit ( self, etc.. ):
print "init..."
(...)
return true
''
''
...I-can-live-with-that-ly y'rs
--
----------------------------------------------------------------------
Olivier A. Dagenais - Carleton University - Computer Science III
More information about the Python-list
mailing list