all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Stephen Berman <stephen.berman@gmx.net>
To: <tomas@tuxteam.de>
Cc: help-gnu-emacs@gnu.org
Subject: Re: Showing text in a buffer only when point is in a region
Date: Sat, 28 Jan 2017 15:45:24 +0100	[thread overview]
Message-ID: <87mvebnszf.fsf@gmx.net> (raw)
In-Reply-To: <20170128124610.GB7072@tuxteam.de> (tomas's message of "Sat, 28 Jan 2017 13:46:10 +0100")

On Sat, 28 Jan 2017 13:46:10 +0100 <tomas@tuxteam.de> wrote:

> On Sat, Jan 28, 2017 at 06:03:57PM +0530, Narendra Joshi wrote:
>> 
>> Hi,
>> 
>> I want to be able to keep some text visible in a buffer only when the
>> point is in a region. The moment the point leaves that region, I would
>> like to make the text invisible. How can I do this? I don't want to run
>> a timer which checks if the point is in the region or outside.
>
> See "Overlays" or "Text Properties" in the Emacs Lisp manual. You can set
> "point-entered" and "point-left" special properties (see "Properties with
> Special Meanings", which are hooks to be called at those events.

As of Emacs 25.1 (quoting the Info node referred to):

"These properties are obsolete; please use ‘cursor-sensor-functions’ instead."

Steve Berman



  reply	other threads:[~2017-01-28 14:45 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-01-28 12:33 Showing text in a buffer only when point is in a region Narendra Joshi
2017-01-28 12:46 ` tomas
2017-01-28 14:45   ` Stephen Berman [this message]
2017-01-28 15:26     ` tomas

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

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87mvebnszf.fsf@gmx.net \
    --to=stephen.berman@gmx.net \
    --cc=help-gnu-emacs@gnu.org \
    --cc=tomas@tuxteam.de \
    /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 external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.