]> git.eshelyaron.com Git - emacs.git/commitdiff
Add a menu bar menu for CSS mode
authorSimen Heggestøyl <simenheg@gmail.com>
Sun, 26 May 2019 19:37:05 +0000 (21:37 +0200)
committerSimen Heggestøyl <simenheg@gmail.com>
Sun, 26 May 2019 19:53:05 +0000 (21:53 +0200)
* lisp/textmodes/css-mode.el (css-mode-map): Add menu bar menu.

lisp/textmodes/css-mode.el

index 11a77b5bb7850d3f30e265b44a505fb37398ee99..ae7b8eacd17286018f999b095e9d9a1422af80eb 100644 (file)
@@ -845,6 +845,18 @@ cannot be completed sensibly: `custom-ident',
   (let ((map (make-sparse-keymap)))
     (define-key map [remap info-lookup-symbol] 'css-lookup-symbol)
     (define-key map "\C-c\C-f" 'css-cycle-color-format)
+    (easy-menu-define css-menu map "CSS mode menu"
+      '("CSS"
+        :help "CSS-specific features"
+        ["Reformat block" fill-paragraph
+         :help "Reformat declaration block or fill comment at point"]
+        ["Cycle color format" css-cycle-color-format
+         :help "Cycle color at point between different formats"]
+        "-"
+        ["Describe symbol" css-lookup-symbol
+         :help "Display documentation for a CSS symbol"]
+        ["Complete symbol" complete-symbol
+         :help "Complete symbol before point"]))
     map)
   "Keymap used in `css-mode'.")