emacs-diffs
[Top][All Lists]
Advanced

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

[Emacs-diffs] Changes to emacs/lisp/whitespace.el,v


From: Vinicius Jose Latorre
Subject: [Emacs-diffs] Changes to emacs/lisp/whitespace.el,v
Date: Sun, 27 Apr 2008 11:50:48 +0000

CVSROOT:        /sources/emacs
Module name:    emacs
Changes by:     Vinicius Jose Latorre <viniciusjl>      08/04/27 11:50:47

Index: whitespace.el
===================================================================
RCS file: /sources/emacs/emacs/lisp/whitespace.el,v
retrieving revision 1.76
retrieving revision 1.77
diff -u -b -r1.76 -r1.77
--- whitespace.el       26 Apr 2008 12:38:54 -0000      1.76
+++ whitespace.el       27 Apr 2008 11:50:47 -0000      1.77
@@ -6,7 +6,7 @@
 ;; Author: Vinicius Jose Latorre <address@hidden>
 ;; Maintainer: Vinicius Jose Latorre <address@hidden>
 ;; Keywords: data, wp
-;; Version: 11.0
+;; Version: 11.1
 ;; X-URL: http://www.emacswiki.org/cgi-bin/wiki/ViniciusJoseLatorre
 
 ;; This file is part of GNU Emacs.
@@ -744,7 +744,7 @@
 
 
 (defcustom whitespace-trailing-regexp
-  "\t\\| \\|\xA0\\|\x8A0\\|\x920\\|\xE20\\|\xF20"
+  "\\(\\(\t\\| \\|\xA0\\|\x8A0\\|\x920\\|\xE20\\|\xF20\\)+\\)$"
   "*Specify trailing characters regexp.
 
 If you're using `mule' package, there may be other characters besides:
@@ -754,9 +754,8 @@
 
 that should be considered blank.
 
-NOTE: DO NOT enclose by \\\\( and \\\\) the elements to highlight.
-      `whitespace-mode' surrounds this regexp by \"\\\\(\\\\(\" and
-      \"\\\\)+\\\\)$\".
+NOTE: Enclose always by \"\\\\(\\\\(\" and \"\\\\)+\\\\)$\" the elements to 
highlight.
+      Use exactly one pair of enclosing elements above.
 
 Used when `whitespace-style' includes `trailing'."
   :type '(regexp :tag "Trailing Chars")
@@ -1476,7 +1475,7 @@
        (when (memq 'trailing whitespace-style)
          (whitespace-replace-action
           'delete-region rstart rend
-          (whitespace-trailing-regexp) 1))
+          whitespace-trailing-regexp 1))
        ;; PROBLEM 4: 8 or more SPACEs after TAB
        (cond
         ;; ACTION: replace 8 or more SPACEs by TABs, if
@@ -1535,11 +1534,6 @@
 ;;;; User command - report
 
 
-(defun whitespace-trailing-regexp ()
-  "Make the `whitespace-trailing-regexp' regexp."
-  (concat "\\(\\(" whitespace-trailing-regexp "\\)+\\)$"))
-
-
 (defun whitespace-regexp (regexp &optional kind)
   "Return REGEXP depending on `whitespace-indent-tabs-mode'."
   (cond
@@ -1565,7 +1559,7 @@
   (list
    (cons 'empty                   whitespace-empty-at-bob-regexp)
    (cons 'empty                   whitespace-empty-at-eob-regexp)
-   (cons 'trailing                (whitespace-trailing-regexp))
+   (cons 'trailing                whitespace-trailing-regexp)
    (cons 'indentation             nil)
    (cons 'indentation::tab        nil)
    (cons 'indentation::space      nil)
@@ -2093,7 +2087,7 @@
        nil
        (list
        ;; Show trailing blanks
-       (list (whitespace-trailing-regexp) 1 whitespace-trailing t))
+       (list whitespace-trailing-regexp 1 whitespace-trailing t))
        t))
     (when (or (memq 'lines      whitespace-active-style)
              (memq 'lines-tail whitespace-active-style))




reply via email to

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