unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
From: Lute Kamstra <Lute.Kamstra@cwi.nl>
Cc: emacs-devel@gnu.org
Subject: Re: Suggestion for hl-line.el
Date: Fri, 09 May 2003 13:59:14 +0200	[thread overview]
Message-ID: <sgdfznoib59.fsf@occarina.pna.cwi.nl> (raw)
In-Reply-To: <200305081448.h48EmnZd019230@rum.cs.yale.edu> (Stefan Monnier's message of "Thu, 08 May 2003 10:48:49 -0400")

"Stefan Monnier" <monnier+gnu/emacs@rum.cs.yale.edu> writes:

>> Do you want that changing hl-line-sticky takes effect immediately,
>> or the next time the mode is turned on?  The first case would
>> require an unhighlight function on pre-command-hook whenever
>> hl-line-mode is turned on.  Just in case sticky is set to t.  The
>> second case can, in case hl-line-sticky is t, do without an
>> unhighlight function on pre-command-hook, which should be faster.
>
> It's up to you.  If I were you I'd ask the user to re-exec
> hl-line-mode for a new value of hl-line-sticky to take effect.
>
>>> Better yet: make the buffer-local mode sticky, but the global mode
>>> non-sticky.
>>
>> Do you like to have this behavior instead of a hl-line-sticky
>> variable (easier), or in addition to such a variable (more
>> difficult)?
>
> Probably "instead".  But here again it's up to you.
>
>> The global mode is currently defined in terms of the local mode
>> (courtesy of easy-mmode-define-global-mode).  I don't easily see how a
>> non-sticky global mode can piggyback on a sticky local mode like that,
>> so it probably needs to be implemented directly.
>
> I think the global mode should be implemented directly, using the
> global part of post/pre-command-hook.  But guess what.... it's up to
> you ;-)

Well, if it's up to me...  I like the idea of one local mode that is
governed by a hl-line-sticky-flag variable and one non-sticky global
mode that is implemented directly.  I guess nobody will want to use a
sticky global mode.

Is it OK if I boldly go ahead and commit such a change?

Lute.

  reply	other threads:[~2003-05-09 11:59 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-05-07 12:33 Suggestion for hl-line.el Lute Kamstra
2003-05-07 14:46 ` Stefan Monnier
2003-05-08  7:00   ` Lute Kamstra
2003-05-08 14:48     ` Stefan Monnier
2003-05-09 11:59       ` Lute Kamstra [this message]
2003-05-15 13:32         ` Lute Kamstra
2003-05-15 15:50           ` Stefan Monnier
2003-05-16 10:07             ` Lute Kamstra

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=sgdfznoib59.fsf@occarina.pna.cwi.nl \
    --to=lute.kamstra@cwi.nl \
    --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).