bug-gnu-emacs
[Top][All Lists]
Advanced

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

bug#15600: 24.3; ruby-mode lacks a menu


From: John Anthony
Subject: bug#15600: 24.3; ruby-mode lacks a menu
Date: Sat, 12 Oct 2013 19:07:53 +0100
User-agent: Mutt/1.5.20 (2009-06-14)

Here's a menu that just covers the basic commands from
lisp/progmodes/ruby.el

diff --git a/lisp/progmodes/ruby-mode.el b/lisp/progmodes/ruby-mode.el
index 2f92216..07ca58b 100644
--- a/lisp/progmodes/ruby-mode.el
+++ b/lisp/progmodes/ruby-mode.el
@@ -158,6 +158,22 @@ This should only be called after matching against 
`ruby-here-doc-beg-re'."
     map)
   "Keymap used in Ruby mode.")
 
+(easy-menu-define
+  ruby-mode-menu
+  ruby-mode-map
+  "Ruby Mode Menu"
+  '("Ruby"
+    ["Beginning Of Block" ruby-beginning-of-block t]
+    ["End Of Block" ruby-end-of-block t]
+    ["Toggle Block" ruby-toggle-block t]
+    "--"
+    ["Backward Sexp" ruby-backward-sexp
+     :active (not ruby-use-smie)]
+    ["Forward Sexp" ruby-forward-sexp
+     :active (not ruby-use-smie)]
+    ["Indent Sexp" ruby-indent-sexp
+     :active (not ruby-use-smie)]))
+
 (defvar ruby-mode-syntax-table
   (let ((table (make-syntax-table)))
     (modify-syntax-entry ?\' "\"" table)

-- 
John Anthony





reply via email to

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