diff lisp/w3/w3-props.el @ 138:6608ceec7cf8 r20-2b3

Import from CVS: tag r20-2b3
author cvs
date Mon, 13 Aug 2007 09:31:46 +0200
parents b980b6286996
children
line wrap: on
line diff
--- a/lisp/w3/w3-props.el	Mon Aug 13 09:31:13 2007 +0200
+++ b/lisp/w3/w3-props.el	Mon Aug 13 09:31:46 2007 +0200
@@ -1,7 +1,7 @@
 ;;; w3-props.el --- Additional text property stuff
 ;; Author: wmperry
-;; Created: 1997/04/20 19:19:14
-;; Version: 1.1
+;; Created: 1997/04/22 14:50:19
+;; Version: 1.2
 ;; Keywords: faces
 
 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
@@ -49,14 +49,13 @@
       (put-text-property start next markprop value object)
       (setq start (text-property-any next end markprop nil object)))))
 
-(if (not (fboundp 'unique))
-    (defsubst unique (list)
-      "Uniquify LIST, deleting elements using `delq'.
+(defsubst w3-props-unique (list)
+  "Uniquify LIST, deleting elements using `delq'.
 Return the list with subsequent duplicate items removed by side effects."
-      (let ((list list))
-	(while list
-	  (setq list (setcdr list (delq (car list) (cdr list))))))
-      list))
+  (let ((list list))
+    (while list
+      (setq list (setcdr list (delq (car list) (cdr list))))))
+  list)
 
 ;; A generalisation of `facemenu-add-face' for any property, but without the
 ;; removal of inactive faces via `facemenu-discard-redundant-faces' and special
@@ -72,7 +71,7 @@
 	    prev (get-text-property start prop object))
       (put-text-property
        start next prop
-       (unique (append val (if (listp prev) prev (list prev))))
+       (w3-props-unique (append val (if (listp prev) prev (list prev))))
        object)
       (setq start next))))
 
@@ -87,7 +86,7 @@
 	    prev (get-text-property start prop object))
       (put-text-property
        start next prop
-       (unique (append (if (listp prev) prev (list prev)) val))
+       (w3-props-unique (append (if (listp prev) prev (list prev)) val))
        object)
       (setq start next))))