From: Eli Zaretskii <eliz@gnu.org>
To: David Reitter <david.reitter@gmail.com>
Cc: emacs-devel@gnu.org
Subject: Re: Hl-line and visual-line
Date: Sun, 23 May 2010 23:33:02 +0300 [thread overview]
Message-ID: <83ljbanytd.fsf@gnu.org> (raw)
In-Reply-To: <47101594-5A7C-4FF1-8C58-C77AF33F35F2@gmail.com>
> From: David Reitter <david.reitter@gmail.com>
> Date: Sun, 23 May 2010 15:13:42 -0400
> Cc: tassilo@member.fsf.org,
> emacs-devel@gnu.org
>
> The first use case would be to jump to beginning and end of a visual line. That means, if point is at any of {abcde JIHGF}, beginning would be at "a" and the end at " " (between "E " and "F").
> If point is at any of {ABCDE xyz}, then beginning would be at "E" and end would be after "z".
This already works today, so no change seems to be needed to cover
this.
> C-k (kill-visual-line) would probably need to be rewritten anyway.
Why? it seems to work already, killing the visual line. Am I missing
something?
> The second use case would be to actually capture a whole line. I have functions that kill the whole line (from left to right). They would use `kill-region' from X to Y. The same goes for hl-line-mode, where ONE overlay is drawn.
> So, these functions would need a new function such as "regions-within-visual-line" or so, returning a list of (from . to) regions, or some other means of identifying the region.
Sorry, I don't get this part. Can you give an example that uses
kill-region and another one with one overlay for hl-line-mode, and
explain how the list of the form you mention would help?
> Are we going to have discontinuous regions? When I set the Mark at "c" in your example, and point at "G", what is highlighted (transient-mark-mode), and what is killed?
Both the region and kill commands work in logical order. So after
C-w, you will see
ab JIHG xyz
I don't think we should have discontinuous regions. Their semantics
is not clear (there's more than one way of interpreting them), and no
bidi-aware application I've seen supports them.
Users expect logical-order regions. Logical-order regions may surprise
the first time you see it, but are easy to get used to, since that's
the order you read the text you mark.
> (NB You're throwing some of the most basic assumptions away. This could get interesting.)
Yes, I'm in this "interesting" stuff for several months now.
next prev parent reply other threads:[~2010-05-23 20:33 UTC|newest]
Thread overview: 28+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-05-20 20:30 Hl-line and visual-line David Reitter
2010-05-20 21:02 ` Eli Zaretskii
2010-05-21 2:35 ` David Reitter
2010-05-21 6:34 ` Tassilo Horn
2010-05-21 8:17 ` Eli Zaretskii
2010-05-21 10:16 ` Tassilo Horn
2010-05-21 14:22 ` David Reitter
2010-05-21 14:57 ` Eli Zaretskii
2010-05-23 17:26 ` Eli Zaretskii
2010-05-23 19:13 ` David Reitter
2010-05-23 20:33 ` Eli Zaretskii [this message]
2010-05-23 23:04 ` David Reitter
2010-05-24 18:16 ` Eli Zaretskii
2010-05-24 18:46 ` Stefan Monnier
2010-05-24 19:06 ` Lennart Borgman
2010-05-24 22:24 ` Eli Zaretskii
2010-05-24 22:37 ` Lennart Borgman
2010-05-24 22:47 ` David Reitter
2010-05-24 23:03 ` Lennart Borgman
2010-05-21 16:54 ` Lennart Borgman
2010-05-21 17:39 ` Eli Zaretskii
2010-05-21 20:24 ` Stefan Monnier
2010-05-21 22:31 ` Lennart Borgman
2010-05-22 0:18 ` Stefan Monnier
2010-05-22 2:35 ` Lennart Borgman
2010-05-22 13:10 ` Lennart Borgman
2010-05-22 17:04 ` Lennart Borgman
2010-05-21 6:36 ` Eli Zaretskii
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=83ljbanytd.fsf@gnu.org \
--to=eliz@gnu.org \
--cc=david.reitter@gmail.com \
--cc=emacs-devel@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).