emacs-devel
[Top][All Lists]
Advanced

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

Re: Text property searching


From: Lars Ingebrigtsen
Subject: Re: Text property searching
Date: Mon, 16 Apr 2018 18:09:55 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux)

João Távora <address@hidden> writes:

> 1. What should happen if search starts in the region where the
> property is already set?

I think it should give you a match starting at point and ending where
the property ends.  

> 2. Can we generalize this to work for searches for regions where the
> property is set to some constant value and also for regions where the
> property is just present. What about "not-present"?

Well, that's what the two arguments do -- the match and the predicate,
so those are covered...

> Or do you envision this to be handled by the second and third
> arguments? Perhaps, in addition to the other type of value, both could
> also be passed a function: the second one a function of one arg, the
> buffer position, producing a value, and the third one a function of
> two values returning a boolean (this is vaguely CL's :key and :test,
> obviously).

Hm...  I don't quite see the need for the single-value function (i.e.,
the :key function) because the predicate can do whatever it wants.

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no



reply via email to

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