From: Peter Seibel <peter@javamonkey.com>
Subject: Re: yanking in outline mode without expanding?
Date: Mon, 22 Dec 2003 19:58:00 GMT [thread overview]
Message-ID: <m38yl47hh3.fsf@javamonkey.com> (raw)
In-Reply-To: xcv3cbcptdj.fsf@famine.OCF.Berkeley.EDU
tfb@famine.OCF.Berkeley.EDU (Thomas F. Burdick) writes:
> Peter Seibel <peter@javamonkey.com> writes:
>
> > I've been using outline mode in:
> >
> > GNU Emacs 21.3.1 (i686-pc-linux-gnu, X toolkit, Xaw3d scroll bars) of 2003-07-17 on xeon
> >
> > When I have my outline collapsed and kill a section and then yank it
> > back, it always insterts the text fully expanded. Is there some simple
> > way to change this behavior--I'd like it to stay collapsed just the
> > way it was when I killed it.
>
> It looks like outline mode uses overlays, which aren't a part of the
> text itself, so aren't copied when you kill it. You could advise the
> kill/yank functions so that in outline mode they stuff the appropriate
> overlay information into text properties on kill, and the reverse on
> yank.
Yup. I looked into the code a bit after I asked this--to do it right
you'd have to find the overlays in the region being cut, split them if
they are completely contained in the region, and then do as you
suggest. Maybe someday I'll get annoyed enough to do that. For now
I'll probably just keep recollapsing things "by hand". Thanks though.
-Peter
--
Peter Seibel peter@javamonkey.com
Lisp is the red pill. -- John Fraser, comp.lang.lisp
next prev parent reply other threads:[~2003-12-22 19:58 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2003-12-22 17:34 yanking in outline mode without expanding? Peter Seibel
2003-12-22 19:03 ` Thomas F. Burdick
2003-12-22 19:58 ` Peter Seibel [this message]
2003-12-23 6:54 ` Thomas F. Burdick
2003-12-22 19:47 ` Kevin Rodgers
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=m38yl47hh3.fsf@javamonkey.com \
--to=peter@javamonkey.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 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.