From: "Ken Manheimer" <ken.manheimer@gmail.com>
Cc: rms@gnu.org, emacs-devel@gnu.org
Subject: Re: need option so line-move-to-column ignores fields, plus patch
Date: Fri, 1 Sep 2006 02:39:15 -0400 [thread overview]
Message-ID: <2cd46e7f0608312339s16a2a101p8c30840bbdeb0d22@mail.gmail.com> (raw)
In-Reply-To: <buoirk8te3g.fsf@dhapc248.dev.necel.com>
On 9/1/06, Miles Bader <miles.bader@necel.com> wrote:
> Richard Stallman <rms@gnu.org> writes:
> > the bug is that i can't use text fields this way without sacrificing
> > column retention on line moves, as far as i can tell.
> > line-move-to-column is hard-wired to respect fields when seeking the
> > prior positions column, so that moving the cursor between topics
> > usually leaves the cursor at column 0, which is almost always not what
> > the user wants.
> >
> > Creating a new variable can enable allout to get what it wants.
> > But that is a sort of a cop-out, because users might want the same
> > thing in other modes that use fields, sometimes.
>
> I'm not sure Ken's change is correct anyway -- line-move-to-column is
> what line-move _usually_ ends up using, right, to preserve the current
> column?
i don't understand what you're suggesting in that paragraph.
i can say that i noticed that line-move-finish duplicates the
line-move column positioning according to fields (mixed together with
the provision for line moves into intangibility), and the second
version of my patch addresses that.
> The current interaction between line-movement and fields is intentional,
> so that "column" preservation does not cause, for instance, the cursor
> to move into the prompt in the minibuffer when you're editing a multline
> minibuffer entry.
so the environment for that sort of editing should leave the default
value for line-move-ignore-fields, to retain the current behavior.
line-move-ignore-fields should be set when you don't want that
behavior. i don't see how that is incorrect.
> When I've noticed the sort of problem Ken's complaining about in the
> past, it's always been due to the fact that the newline character on a
> line is in a field; there is already a sort of mechanism to try and deal with
> this (used for instance, by comint), which is to put newline characters
> in a special field with the value `boundary'.
none of the newlines in the buffers where i'm having the problem have
any 'field property set. ie, the following lisp expression:
(while (and (re-search-forward "\n" nil t) (not (get-char-property
(1- (point)) 'field))))
advances from the beginning to the end of the buffers without stopping.
(out of curiousity, i tried setting the field 'boundary on the
newlines. the column was retained in the left part of the line - ie,
having characters that have the field 'boundary set. to the right of
that, with characters that lack any 'field setting, the column is not
retained - the cursor moves to the left-most non-fielded character of
the next line, just to the right of the rightmost 'boundary char.
that is in the content part of the line, and distinctly is not
desired.)
> Perhaps I misunderstand his problem though.
i want fields respected for motion within a line - specifically, when
moving from the right of the boundary towards the boundary - without
sacrificing retention of the column when moving between lines. that's
the level of control that line-move-ignore-fields provides.
i'm open to solutions using only fields as they currently are
implemented, but i haven't found any that avoid sacrificing either the
intra-line or line-motion behavior.
--
ken
ken.manheimer@gmail.com
http://myriadicity.net
next prev parent reply other threads:[~2006-09-01 6:39 UTC|newest]
Thread overview: 36+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-08-31 15:48 need option so line-move-to-column ignores fields, plus patch Ken Manheimer
2006-08-31 16:25 ` Ken Manheimer
2006-08-31 17:11 ` David Kastrup
2006-08-31 22:57 ` Richard Stallman
2006-09-01 4:17 ` Miles Bader
2006-09-01 6:39 ` Ken Manheimer [this message]
2006-09-03 15:17 ` Richard Stallman
2006-09-04 4:43 ` Ken Manheimer
2006-09-04 17:18 ` Richard Stallman
2006-09-04 19:56 ` Ken Manheimer
2006-09-06 8:49 ` Richard Stallman
2006-09-06 16:52 ` Ken Manheimer
2006-09-07 6:54 ` Richard Stallman
2006-09-07 14:47 ` Ken Manheimer
2006-09-23 23:29 ` Ken Manheimer
2006-09-24 16:28 ` Richard Stallman
2006-09-24 20:17 ` Ken Manheimer
2006-09-25 20:48 ` Richard Stallman
2006-09-24 22:04 ` Chong Yidong
2006-09-24 22:10 ` Chong Yidong
2006-09-25 1:53 ` Ken Manheimer
2006-10-11 4:13 ` Ken Manheimer
2006-10-11 18:50 ` Richard Stallman
2006-10-11 19:19 ` Ken Manheimer
2006-10-12 22:37 ` Richard Stallman
2006-09-25 1:31 ` Ken Manheimer
2006-09-25 8:36 ` Slawomir Nowaczyk
2006-09-25 20:48 ` Richard Stallman
2006-09-25 21:43 ` Chong Yidong
2006-09-27 17:18 ` Ken Manheimer
2006-09-29 16:32 ` Richard Stallman
2006-09-29 18:21 ` Chong Yidong
2006-09-07 6:54 ` Richard Stallman
2006-09-07 14:27 ` Ken Manheimer
2006-09-05 4:48 ` Miles Bader
2006-09-01 6:30 ` Ken Manheimer
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=2cd46e7f0608312339s16a2a101p8c30840bbdeb0d22@mail.gmail.com \
--to=ken.manheimer@gmail.com \
--cc=emacs-devel@gnu.org \
--cc=rms@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).