[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: How to programmatically highlight region?

From: David Abrahams
Subject: Re: How to programmatically highlight region?
Date: Wed, 15 Nov 2006 17:48:12 -0500
User-agent: Gnus/5.110006 (No Gnus v0.6) Emacs/23.0.0 (gnu/linux)

Perry Smith <address@hidden> writes:

> On Nov 15, 2006, at 2:10 PM, David Abrahams wrote:
>     Hi,
>     Could someone tell me how to get the effect of an "activated mark" in
>     transient mark mode from within elisp?  In other words, I'd like to be
>     able to set up the point and mark, and when my elisp completes, see
>     the region highlighted.  Seems like it should be simple, but nothing I
>     do seems to work.
> You might be asking how transient mark mode works.  

I don't think that's what I'm asking.

> It seems to be just a variable that commands look at.  But this
> works for me:
> (defun dog-test ()
>  (interactive)
>  (transient-mark-mode 1)
>  (set-mark (point))
>  (forward-char 20))
> execute dog-test from the minibuffer and the current point plus 20
> characters are highlighted

Not for me. :(

Thanks for responding.

Dave Abrahams
Boost Consulting

reply via email to

[Prev in Thread] Current Thread [Next in Thread]