unofficial mirror of help-gnu-emacs@gnu.org
 help / color / mirror / Atom feed
From: Baloff <washdc@wash.edu>
Subject: Re: expand/collapse{} in c++
Date: 27 Aug 2005 06:31:36 +1000	[thread overview]
Message-ID: <87fyswfniv.fsf@wash.edu> (raw)
In-Reply-To: d76ged.76.ln@acm.acm

Alan Mackenzie <acm@muc.de> writes:

> Baloff <washdc@wash.edu> wrote on 24 Aug 2005 06:00:22 +1000:
> 
> > Hello
> > I tried to find out how to do this expand/collapse the code into {...}
> > from the info docs but it is not there. could someone help please.
> 
> Oh yes it is!  Or, at least, something very like it.  The node is in the
> Emacs manual, and is called "Hideshow".  Briefly, enable it with "M-x
> hs-minor-mode" (possibly from a hook).  Then you will have commands
> available like :
> 
>   `C-c @ C-h'
>        Hide the current block (`hs-hide-block').
> 
>   `C-c @ C-s'
>        Show the current block (`hs-show-block').
> 
>   `C-c @ C-c'
>        Either hide or show the current block (`hs-toggle-hiding')
> 
> [ .... ]
> 
> > thanks
> 
> -- 
> Alan Mackenzie (Munich, Germany)
> Email: aacm@muuc.dee; to decode, wherever there is a repeated letter
> (like "aa"), remove half of them (leaving, say, "a").

I did the following but I must have done something wrong because it is
still not working.
in my .emacs I put
(add-hook 'c++-mode-hook 'hs-minor-mode t) ;for block hide/show

in a .emacs-c++ file to be loaded from inside .emacs, I have
(local-set-key [f4] "\C-c @ \C-c") ;toggles block hide/show

restart emacs, when I open .cpp file, f4 does nothing.

  reply	other threads:[~2005-08-26 20:31 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-08-23 20:00 expand/collapse{} in c++ Baloff
2005-08-23 20:31 ` Gnus threading (was: expand/collapse{} in c++) Jason Dufair
2005-08-24 17:36   ` Baloff
2005-08-24 19:22     ` Gnus threading Johan Bockgård
2005-08-23 20:47 ` expand/collapse{} in c++ Sébastien Kirche
2005-08-23 21:59 ` Alan Mackenzie
2005-08-26 20:31   ` Baloff [this message]
2005-08-26 21:56     ` Peter Lee
2005-08-26 22:00     ` Jason Dufair
2005-08-26 22:39       ` Kevin Rodgers
     [not found]       ` <mailman.5188.1125098056.20277.help-gnu-emacs@gnu.org>
2005-08-27  8:31         ` Baloff
2005-08-24  3:32 ` Eli Zaretskii

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87fyswfniv.fsf@wash.edu \
    --to=washdc@wash.edu \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).