emacs-devel
[Top][All Lists]
Advanced

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

Change in fill-nobreak-predicate


From: Chong Yidong
Subject: Change in fill-nobreak-predicate
Date: Fri, 4 Feb 2005 19:43:55 -0500 (EST)
User-agent: SquirrelMail/1.4.3a

In 21.3, the variable fill-nobreak-predicate stored a function symbol.
This was changed in CVS, long ago, into a hook:

2001-10-30  Stefan Monnier  <address@hidden>

        * textmodes/fill.el (sentence-end-double-space)
        (sentence-end-without-period): Move to paragraphs.el.
        (fill-indent-according-to-mode): Change default to t.
        (fill-context-prefix): Simplify control-flow and use a more
        sophisticated merge that unifies both previous checks.
        (fill-single-word-nobreak-p, fill-french-nobreak-p): New funs.
        (fill-nobreak-predicate): Make it into a defcustom'd hook.

This breaks third-party code that relies on fill-nobreak-predicate (such
as longlines.el), but never mind; the problem is that the NEWS entry does
not give any indication of this:

** You can now customize fill-nobreak-predicate to control where
filling can break lines.  We provide two sample predicates,
fill-single-word-nobreak-p and fill-french-nobreak-p.

+++

This makes it sound like the only change was to make it customizable, when
in fact its data type has changed.

The entry in lispref/text.texi should also be corrected:

@defvar fill-nobreak-predicate
This variable gives major modes a way to specify not to break a line at
certain places.  Its value should be a function.  This function is
called during filling, with no arguments and with point located at the
place where a break is being considered.  If the function returns
address@hidden, then the line won't be broken there.
@end defvar





reply via email to

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