| Store | Cart

Re: [Komodo-discuss] Feature suggestion: Word wrap and comments

From: Eric Promislow <eri...@activestate.com>
Wed, 07 Oct 2009 12:36:09 -0700
David, you can quit dreaming and get back to work... I've been working on this.
There are the various gotchas that stop me from putting it out right away, but
here are some notes on the prefs I've envisioned. Please feel free to chime in
if you have other ideas:

editAutoWrap_Global - either it's on or not
     onSpaceOnly -- vi wraps on any char, emacs only when you type a space.
                    We give a choice (favoring the vi way, where typing any
                    char past the edgeColumn will trigger an autowrap).

Normally, if wrapping is on, Komodo will wrap only the following lines:

- plain text

- HTML/XML markup (as opposed to CSS, etc.)

- any language: lines containing only comments (ignoring whitespace)

Here are further options:
     inAttributeStrings -- allow wrapping inside attr strings.

     inMultiLineStrings -- allow wrapping in triplequote strings

     inHereDocumentStrings - the "<<" things

     inPOD -- for Perl users

     inEndSections - Perl and Ruby, doc strings

     inCodeParts -- for emacs/vi compatibility, autowrap anywhere.
            I don't know who would want this though.

I've been using parts of reflow.py, but it's too limited, and doesn't know
about comments, or any other language parts, for that matter.  We don't
like to duplicate code, so I'll probably end up rewriting it along
with the autowrapper.



- Eric

On 10/7/2009 12:23 PM, David Brewer wrote:
> I often find myself typing very long block comments in Komodo (usually> in PHP).  Once I get past a couple of lines, it can be cumbersome to> manually manage the process of adding line breaks where I want them in> the comment to keep the comment within my preferred 78 character> width.>> In my dream universe, Komodo would support real word wrap where you> would be forced to follow the character width guideline established by> the "edge line" setting.  However, this would quite likely become> annoying when typing in code rather than comments, so my dream is that> you would be able to further choose whether this form of word wrap> happened throughout your file or only when typing block comments.  It> would be awesome if I could type:>> /**<enter>>> and then just blather on as if I were in a word processor, with line> breaks being managed for me automagically until I decide to type:>> <enter>*/>> to close the comment.>> A possibly easier compromise solution might be to change the 'reflow> paragraph' functionality so that it is comment aware and would, for> example, maintain the leading ' * ' when in a php block comment.>> Thoughts on this?  Is there already a way to achieve something similar> to this that I'm missing?>> David> _______________________________________________> Komodo-discuss mailing list> Komo...@listserv.ActiveState.com> To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs> Other options: http://listserv.ActiveState.com/mailman/listinfo/Komodo-discuss

Recent Messages in this Thread
David Brewer Oct 07, 2009 07:23 pm
Eric Promislow Oct 07, 2009 07:36 pm
Todd Whiteman Oct 07, 2009 07:42 pm
Eric Promislow Oct 07, 2009 07:44 pm
David Brewer Oct 07, 2009 08:29 pm
Troy Topnik Oct 07, 2009 08:59 pm
Messages in this thread