From: bev <fbe2@comcast.net>
To: help-gnu-emacs@gnu.org
Subject: Re: Open Outline-mode file in collapsed state
Date: Thu, 27 Mar 2008 12:27:06 -0700 (PDT) [thread overview]
Message-ID: <02bf0d38-92a9-4c06-9d64-22109d8df255@8g2000hse.googlegroups.com> (raw)
In-Reply-To: 86od90b5wy.fsf@timbral.net
On Mar 27, 7:25 am, Evans Winner <tho...@timbral.net> wrote:
> bev <f...@comcast.net> writes:
>
> I'm not sure what you mean by that. Are you saying add that to the top
> of every single outline file I have? (Hundreds). I don't want to do
> that. I need a function that will simply run (hide-trees) every time I
> open an outline file. I really can't take the time to go add a line to
> hundreds of files. Also, I've never seen that before. Is that lisp
> code?
>
> No, as I already said, this was a mistake on my part. I
> thought the question was about org-mode. I am pretty sure
> this will not work for outline mode.
>
> Maybe try putting in your .emacs something like
>
> (add-to-list 'outline-mode-hook (lambda (hide-sublevels 1)))
>
> I haven't tested it, but I think something like this would
> be the answer.
Evans,
Yep, a slight variation of your solution works. I now have in
my .emacs:
(add-hook 'outline-mode-hook '(lambda () (hide-sublevels 1)))
I've never seen that syntax before -- putting a '1' after a function
that takes no args. Does that just mean 'make it so'? I don't know why
just having hide-sublevels without the '1' won't work.
Thanks Evans.
Bev
next prev parent reply other threads:[~2008-03-27 19:27 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-03-25 3:28 Open Outline-mode file in collapsed state bev
2008-03-25 3:28 ` Evans Winner
2008-03-26 1:00 ` Xavier Maillard
[not found] ` <mailman.9419.1206495571.18990.help-gnu-emacs@gnu.org>
2008-03-27 8:33 ` bev
2008-03-27 14:25 ` Evans Winner
2008-03-27 19:15 ` bev
2008-03-27 19:27 ` bev [this message]
2008-03-27 19:48 ` Evans Winner
2008-03-27 21:01 ` bev
2008-03-29 16:12 ` Bastien
2008-03-29 15:56 ` Bastien
2008-03-29 15:55 ` Bastien
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
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=02bf0d38-92a9-4c06-9d64-22109d8df255@8g2000hse.googlegroups.com \
--to=fbe2@comcast.net \
--cc=help-gnu-emacs@gnu.org \
/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 external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.