diff lisp/textmodes/fill.el @ 90133:4da4a09e8b1b

Revision: miles@gnu.org--gnu-2005/emacs--unicode--0--patch-31 Merge from emacs--cvs-trunk--0 Patches applied: * emacs--cvs-trunk--0 (patch 206-222) - Update from CVS - Merge from gnus--rel--5.10 * gnus--rel--5.10 (patch 45-52) - Update from CVS - Update from CVS: texi Makefile.in CVS keyw cruft - Update from CVS: ChangeLog tweaks
author Miles Bader <miles@gnu.org>
date Thu, 31 Mar 2005 09:58:14 +0000
parents 8395880305fe 801f886872c5
children f042e7c0fe20
line wrap: on
line diff
--- a/lisp/textmodes/fill.el	Tue Mar 29 00:48:14 2005 +0000
+++ b/lisp/textmodes/fill.el	Thu Mar 31 09:58:14 2005 +0000
@@ -539,6 +539,17 @@
 	    ;; Make sure we take SOMETHING after the fill prefix if any.
 	    (fill-find-break-point linebeg)))))
 
+;; Like text-properties-at but don't include `composition' property.
+(defun fill-text-properties-at (pos)
+  (let ((l (text-properties-at pos))
+	prop-list)
+    (while l
+      (unless (eq (car l) 'composition)
+	(setq prop-list
+	      (cons (car l) (cons (cadr l) prop-list))))
+      (setq l (cddr l)))
+    prop-list))
+
 (defun fill-newline ()
   ;; Replace whitespace here with one newline, then
   ;; indent to left margin.
@@ -546,7 +557,7 @@
   (insert ?\n)
   ;; Give newline the properties of the space(s) it replaces
   (set-text-properties (1- (point)) (point)
-		       (text-properties-at (point)))
+		       (fill-text-properties-at (point)))
   (and (looking-at "\\( [ \t]*\\)\\(\\c|\\)?")
        (or (aref (char-category-set (or (char-before (1- (point))) ?\000)) ?|)
 	   (match-end 2))