special editor support for indentation needed.

Eric S. Johansson esj at harvee.org
Fri Nov 14 21:01:43 EST 2008


drobinow at gmail.com wrote:

>  I don't understand. If you don't want to terminate the "if", why do
> you hit backspace? What is it that you would like to have happen?

the goal is to make some aspects of indentation behave the same without context
dependency.  this goal exists for many features of programming assistance
because it's a prerequisite for lowering the vocal load for this aspect of
programming by voice

I want three indentation adjustment tools.  Indent to where a class should be,
indent to where a method should be, and outdent n levels (close block
(once|twice|thrice)).  This is probably best shown by example although, I'm not
guaranteeing my example will make it any clearer.  :-)


the current outdent capability conflates multiple outdent events.  The outdent
events are, at a minimum,:

Close block
close method
close class

Another way to look at these events are start method, start class and close
block.  Now using these events, let's compare a use case against the outdent
mechanism.

starting with an example of a previous message,

class pet (object):
    """
    """
    def cat(self):
        """
        """
        if food in bowl:
            self.empty = True

    def dog(self):

to start the dog method, after ending the Method, I would need to say something
like:

newline tab key Close block close block delta echo foxtrot dog left paren self
close paren colon...

But if the method ended like:

    ...

    def cat(self):
        """
        """
        self.empty = True

    def dog(self):

I would only want to use a single "close block" to outdent.  unfortunately, this
 context dependent behavior is frustratingly wrong when it comes to creating
speech driven macros to enter templates.  it requires user intervention to tell
you how may times to outdent and that's counterproductive at best and physically
damaging at worst for a disabled user.


any clearer?






More information about the Python-list mailing list