Subject: bug#25373: 25.1.91; emacs align.el patch for CSS alignment

From: John Wiegley <[email-masked]>
Date: Thu, 05 Jan 2017 23:23:52 -0800 (PST)

From: Le Wang <[email-masked]>

The regexp for CSS currently fails for the following CSS:

div.indented{
 margin-left: 2.0em;
 background: #ccccff;
 border:     1px solid red;}

because of the dash in "margin-left"

Here is a patch

--- c:/emacs/emacs-23.3/lisp/align.el   2011-01-08 12:45:14.000000000 +0800
+++ c:/Users/Le/cygwin_home/tmp/align.el        2011-08-28
00:28:28.966461600 +0800
@@ -578,7 +578,7 @@
                    (eq '- current-prefix-arg)))))

    (css-declaration
-     (regexp . "^\\s-*\\w+:\\(\\s-*\\).*;")
+     (regexp . "^\\s-*\\(?:\\w\\|\\s_\\)+:\\(\\s-*\\).*;")
     (group . (1))
     (modes . '(css-mode html-mode))))
  "A list describing all of the available alignment rules.

-- 
John Wiegley                  GPG fingerprint = 4710 CF98 AF9B 327B B80F
http://newartisans.com                          60E1 46C4 BD1A 7AC1 4BA2