]> code.delx.au - gnu-emacs-elpa/blobdiff - packages/company/company-css.el
* company/*.el: Fix case misunderstanding. Use checkdoc.
[gnu-emacs-elpa] / packages / company / company-css.el
index d1b3e028c837ea038591e502a93f767cfaa286fa..5642c363cbe7880c2307ec6b2fe1783b5e0f1732 100644 (file)
@@ -1,6 +1,6 @@
-;;; company-css.el --- a company-mode completion back-end for css-mode
+;;; company-css.el --- A company-mode completion back-end for css-mode
 
-;; Copyright (C) 2009 Free Software Foundation, Inc.
+;; Copyright (C) 2009, 2011  Free Software Foundation, Inc.
 
 ;; Author: Nikolaj Schumacher
 
@@ -19,6 +19,8 @@
 ;; You should have received a copy of the GNU General Public License
 ;; along with GNU Emacs.  If not, see <http://www.gnu.org/licenses/>.
 
+;;; Commentary:
+
 ;;; Code:
 
 (require 'company)
           "\\)*"
           "\\(\\(?:#\\|\\_<[[:alpha:]]\\)\\(?:[[:alnum:]-#]*\\_>\\)?\\_>\\|\\)"
           "\\=")
-  "A regular expression matching CSS tags")
+  "A regular expression matching CSS tags.")
 
 ;;; pseudo id
 (defconst company-css-pseudo-regexp
           "\\)*"
           "\\(?:\\(?:\\#\\|\\_<[[:alpha:]]\\)[[:alnum:]-#]*\\):"
           "\\([[:alpha:]-]+\\_>\\|\\)\\_>\\=")
-  "A regular expression matching CSS pseudo classes")
+  "A regular expression matching CSS pseudo classes.")
 
 ;;; properties
 
@@ -272,20 +274,20 @@ Returns \"\" if no property found, but feasible at this position."
 ;;; values
 (defconst company-css-property-value-regexp
   "\\_<\\([[:alpha:]-]+\\):\\(?:[^};]*[[:space:]]+\\)?\\([^};]*\\_>\\|\\)\\="
-  "A regular expression matching CSS tags")
+  "A regular expression matching CSS tags.")
 
 ;;;###autoload
 (defun company-css (command &optional arg &rest ignored)
   "A `company-mode' completion back-end for `css-mode'."
   (interactive (list 'interactive))
   (case command
-    ('interactive (company-begin-backend 'company-css))
-    ('prefix (and (derived-mode-p 'css-mode)
+    (interactive (company-begin-backend 'company-css))
+    (prefix (and (derived-mode-p 'css-mode)
                   (or (company-grab company-css-tag-regexp 1)
                       (company-grab company-css-pseudo-regexp 1)
                       (company-grab company-css-property-value-regexp 2)
                       (company-css-grab-property))))
-    ('candidates
+    (candidates
      (cond
       ((company-grab company-css-tag-regexp 1)
        (all-completions arg company-css-html-tags))
@@ -297,7 +299,7 @@ Returns \"\" if no property found, but feasible at this position."
                          (company-grab company-css-property-value-regexp 1))))
       ((company-css-grab-property)
        (all-completions arg company-css-property-alist))))
-    ('sorted t)))
+    (sorted t)))
 
 (provide 'company-css)
 ;;; company-css.el ends here