emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Nick Dokos <nicholas.dokos@hp.com>
To: "Filippo A. Salustri" <salustri@ryerson.ca>
Cc: Juan Pechiar <juan@pechiar.com>,
	emacs-orgmode@gnu.org, nicholas.dokos@hp.com
Subject: Re: hide #+ lines?
Date: Sat, 19 Mar 2011 21:42:12 -0400	[thread overview]
Message-ID: <10904.1300585332@alphaville.dokosmarshall.org> (raw)
In-Reply-To: Message from "Filippo A. Salustri" <salustri@ryerson.ca> of "Sat, 19 Mar 2011 18:38:37 EDT." <AANLkTimHqW5vtYOUS_tSeT_GHX+4L_D5Jd=WuvhRpfEf@mail.gmail.com>

Filippo A. Salustri <salustri@ryerson.ca> wrote:

> 
> On 19 March 2011 18:26, Nick Dokos <nicholas.dokos@hp.com> wrote:
> ...
> > Another similar solution (cribbed from this list, but I don't remember
> > who suggested it) is to define a drawer and put all that stuff in it -

That was Carsten: see http://thread.gmane.org/gmane.emacs.orgmode/2722/focus=2732
and there is another bit of setup needed to keep the drawer closed to begin
with. Carsten suggested

(add-hook 'org-mode-hook
       (lambda () (org-cycle-hide-drawers 'all)))

> 
> Juan & Nick,
> I like your ideas, but my case is a little different.  I only want to
> hide the BEGIN/END statements, not what comes between them.
> That is, I'm using a trick Ido Magal suggested
> (http://permalink.gmane.org/gmane.emacs.orgmode/39226).
> It works fine, except I see all the distracting block directives.
> 

The first line in the posting you point to is not org-mode related at
all: it asks emacs to eval the form when the file is visited. Since
emacs requires that to be the *first* line you cannot do anything about
that. However, there is another way to specify local variables: in a
"Local variables" section at the end of the file. That *can* be put into a
drawer:

:SETUP:
# Local variables:
# eval: (org-update-all-dblocks)
# End:
:END:

but it becomes the "personal property" of the last headline, so if that
is folded, the drawer is completely invisible and if it's deep in the
tree it becomes difficult to find. I would put it under its own
headline, perhaps "* COMMENT setup".

The #+BEGIN: ... / #+END surrounding the output of the dblock cannot be
hidden afaik, but are they really distracting? I find them helpful in
focusing my eyes on the output.

Nick

  reply	other threads:[~2011-03-20  1:42 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-03-19 21:27 hide #+ lines? Filippo A. Salustri
2011-03-19 22:06 ` Juan Pechiar
2011-03-19 22:26   ` Nick Dokos
2011-03-19 22:38     ` Filippo A. Salustri
2011-03-20  1:42       ` Nick Dokos [this message]
2011-03-20  1:58         ` Filippo A. Salustri
2011-03-20  2:19           ` Nick Dokos
2011-03-20 14:46             ` Filippo A. Salustri

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=10904.1300585332@alphaville.dokosmarshall.org \
    --to=nicholas.dokos@hp.com \
    --cc=emacs-orgmode@gnu.org \
    --cc=juan@pechiar.com \
    --cc=salustri@ryerson.ca \
    /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).