From: Puneeth Chaganti <punchagan@gmail.com>
To: Petro Khoroshyy <khoroshyy@gmail.com>
Cc: emacs-orgmode@gnu.org
Subject: Re: source code folding
Date: Mon, 28 May 2012 21:16:11 +0530 [thread overview]
Message-ID: <CALnw1fTMxRba5DCNwhpMjsOhV=wwoHGUaJ2NnOE9puGvdZTQoQ@mail.gmail.com> (raw)
In-Reply-To: <87ehq4figm.fsf@cica.cica>
On Mon, May 28, 2012 at 8:42 PM, Petro Khoroshyy <khoroshyy@gmail.com> wrote:
> Hi all.
> I can fold source code block using TAB key on begin_src block. Is there
> a shortcut to do it within source code block, without navigation to
> begin_src line?
I'm not sure there's such a short cut, but you can define one for yourself.
A simple function (without any sort of error checking) like the one
below can be bound to a key-binding of your choice.
------------------------------------------------------------------------
(defun my/collapse-src-block ()
"Collapses a source block when called from inside a block."
(interactive)
(org-babel-goto-src-block-head)
(org-cycle))
------------------------------------------------------------------------
Hope that helps,
Puneeth
next prev parent reply other threads:[~2012-05-28 15:46 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-05-28 15:12 source code folding Petro Khoroshyy
2012-05-28 15:46 ` Puneeth Chaganti [this message]
2012-05-28 16:25 ` Memnon Anon
2012-05-29 8:46 ` Petro Khoroshyy
2012-05-28 16:38 ` Eric Schulte
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.orgmode.org/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to='CALnw1fTMxRba5DCNwhpMjsOhV=wwoHGUaJ2NnOE9puGvdZTQoQ@mail.gmail.com' \
--to=punchagan@gmail.com \
--cc=emacs-orgmode@gnu.org \
--cc=khoroshyy@gmail.com \
/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.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
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).