help-octave
[Top][All Lists]
Advanced

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

Re: Commenting out lines


From: Christoph Dalitz
Subject: Re: Commenting out lines
Date: Wed, 4 Aug 2004 09:50:33 +0200

On Tue, 03 Aug 2004 19:25:47 +0100
Geraint Paul Bevan <address@hidden> wrote:

> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
> 
> Jonathan Stickel wrote:
> 
> | Is there something I can add to ~/.emacs to have "comment-region" and
> | "uncomment-region" in my menu bar?  For c++-mode, these are in the c++
> | pull down menu.  I'd like them in the octave pull-down menu when I am in
> | octave-mode.
> |
> | Thanks,
> | Jonathan
> |
> 
> 
> I think that you just need to add a couple of lines to octave-mod.el:
> 
Adding it to ~/.emacs has the advantage that your changes are immune against
an upgrade of octave or emacs.

Adding menu entries is described in
http://www.gnu.org/software/emacs/elisp-manual/html_chapter/elisp_22.html#SEC346

If you only want it in a specific mode (eg. octave-mode), bracket this code
inside

(add-hook 'octave-mode-hook '(lambda ()
   ;; your code for adding menus
))

Christoph



-------------------------------------------------------------
Octave is freely available under the terms of the GNU GPL.

Octave's home on the web:  http://www.octave.org
How to fund new projects:  http://www.octave.org/funding.html
Subscription information:  http://www.octave.org/archive.html
-------------------------------------------------------------



reply via email to

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