[Top][All Lists]

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


From: Alan Mackenzie
Subject: narrowedp?
Date: Thu, 1 Oct 2009 10:17:06 +0000
User-agent: Mutt/1.5.9i

Hi, Emacs!

There doesn't seem to be a function `narrowedp'.  This is, perhaps, an
unfortunate lack.

It's easy enough to test the lower bound:

    (eq (point-min) 1)

, but the upper bound is a touch tedious:

      (let ((reg-end (point-max)))
        (eq reg-end (point-max))))

.  Actually, I really just want to test the lower bound (to know whether
to need to test for point-min being inside a literal).  But testing
point-min against "1" seems a bit unemacsy and unfutureproof.  When
Emacs gets good multi-major-mode facilities, the "beginning of buffer"
will not be 1, rather the beginning of the particular buffer part.  Or
something like that.

Alan Mackenzie (Nuremberg, Germany).

reply via email to

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