I agree that $actualLineStart is cryptic. I was using the implementation of
$selectLongWords as a model but I'm sure there's a better way to do it, if
even just a better name.

Then, there's a question about how closely we want to emulate emacs. I
thought about this in connection with the kill-line fix. That fix does not
behave like emacs either in the case of soft-wrapped lines. It only kills
to the end of the line as displayed.

I'd be happy to implement the stricter emulation but I would want to
include a configuration option, because frankly I prefer it the way I
implemented it. Emacs has curved arrows in the right margin to alert you
that the line is wrapped, and ace doesn't have that.

So according to the "principle of least surprise," what will be more
surprising? Expecting to kill the line you're looking at and killing the
whole paragraph? Or expecting emacs behaviour and not killing the whole
paragraph?

What do you think?

thanks

chester

On Tue, Jan 29, 2013 at 11:10 AM, Harutyun Amirjanyan <
notifications@github.com> wrote:

> In lib/ace/selection.js:
>
> > @@ -517,7 +517,7 @@ var Selection = function(session) {
> >          );
> >
> >          var leadingSpace = beforeCursor.match(/^\s*/);
> > -        if (leadingSpace[0].length == column) {
> > +        if (leadingSpace[0].length == column || this.session.$actualLineStart) {
>
> this is different from emacs behavior on, wrapped lines, also
> $actualLineStart is too unclear, maybe it's better to add a new command
> for this?
>
> —
> Reply to this email directly or view it on GitHub<https://github.com/ajaxorg/ace/pull/1223/files#r2812741>.
>
>