emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Nick Dokos <nicholas.dokos@hp.com>
To: Bernt Hansen <bernt@norang.ca>
Cc: Rustom Mody <rustompmody@gmail.com>, emacs-orgmode@gnu.org
Subject: Re: Re: structure editing in brainstorming mode
Date: Mon, 29 Dec 2008 12:15:37 -0500	[thread overview]
Message-ID: <5474.1230570937@gamaville.dokosmarshall.org> (raw)
In-Reply-To: Message from Bernt Hansen <bernt@norang.ca> of "Mon, 29 Dec 2008 11:36:26 EST." <871vvrym45.fsf@gollum.intra.norang.ca>

Bernt Hansen <bernt@norang.ca> wrote:

> "Rustom Mody" <rustompmody@gmail.com> writes:
> 
> > 1. Multiple heading demotion
> >
> > Lets say I start writing down some points maybe with/without some
> > additional text
> > * Cat
> > * Dog
> >
> > And now I decide to put all these into a superheading 'My Pets'
> > The only way I know is to enter
> > * My Pets
> > before Cat and then demote each subtree -- if there were not two but
> > ten I'd have to do that 10 times
> 
> This sounds like a great use for a keyboard macro
> 
> Hit S-Tab until you get Contents view which shows headlines only (the
> rest of the content is folded) and position the cursor on the first
> headline to be demoted
> 
> C-x (
> M-S-right
> M-x org-forward-same-level
> C-x )
> 
> Then just C-x e to repeat the macro and demote the current headline and
> move forward to the next one.  If you're demoting consecutive entries
> then you can do C-x e for the first and just 'e' for each successive one
> to repeat the macro. (eg. C-x e e e e demotes this headline and the 
> following it)
> 

... or use a numeric prefix.

Alternatively, I think you can do this with the kill/copy/yank commands
(although I had to specify a numeric prefix for the yank level: when I yanked
without it, it didn't "fit in nicely at the yank position." But I may be
misunderstanding the way it's supposed to work):

`C-c C-x C-w'
     Kill subtree, i.e. remove it from buffer but save in kill ring.
     With a numeric prefix argument N, kill N sequential subtrees.  

`C-c C-x M-w'
     Copy subtree to kill ring.  With a numeric prefix argument N, copy
     the N sequential subtrees.  

`C-c C-x C-y'
     Yank subtree from kill ring.  This does modify the level of the
     subtree to make sure the tree fits in nicely at the yank position.
     The yank level can also be specified with a numeric prefix
     argument, or by yanking after a headline marker like `****'.  

`C-y'
     Depending on the variables `org-yank-adjusted-subtrees' and
     `org-yank-folded-subtrees', Org's internal `yank' command will
     paste subtrees folded and in a clever way, using the same command
     as `C-c C-x C-y'.  With the default settings, level adjustment
     will take place and yanked trees will be folded unless doing so
     would swallow text previously visible.  Any prefix argument to
     this command will force a normal `yank' to be executed, with the
     prefix passed along.  A good way to force a normal yank is `C-u
     C-y'.  If you use `yank-pop' after a yank, it will yank previous
     kill items plainly, without adjustment and folding.  


> >
> > 2. Converting heading type
> >
> > Sometimes one assumes that the points are 'small' and so are entered
> > as + points. Thus
> > * Pets
> >   + Cat
> >   + Dog
> > and then at some point it emerges that the +es had better be changed
> > to headings that is (the requisite number of) *s.  Any easy way of
> > doing that?
> 
> You can just use query replace for this
> 
> Highlight the entries to convert and then
> 
> C-M-%
> 
> and change 
> '^  \+'
> to
> '**'  (or '***' if you are using odd levels only)
> 

I tend to forget occasionally that org-mode is *just text*: none of the
binary/proprietary/hidden/convoluted/confused/confusing/obfuscated crap
that most other programs force you into.  Thanks for the reminder,
Bernt!

Regards,
Nick

  reply	other threads:[~2008-12-29 17:15 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-12-29  5:58 structure editing in brainstorming mode Rustom Mody
2008-12-29 12:51 ` Matthew Lundin
2008-12-30 23:55   ` Carsten Dominik
2008-12-31  6:04     ` Rustom Mody
2008-12-31  8:07       ` Carsten Dominik
2008-12-31 11:36         ` Daniel Clemente
2008-12-31 13:28           ` Carsten Dominik
2008-12-31 13:33             ` Daniel Martins
2009-01-01  6:42             ` Rustom Mody
2009-01-01  8:58               ` Carsten Dominik
2009-01-01 22:53         ` Matthew Lundin
2008-12-29 16:36 ` Bernt Hansen
2008-12-29 17:15   ` Nick Dokos [this message]
2008-12-30  0:50 ` Olaf Dietsche
2008-12-30 14:11   ` Rustom Mody
2008-12-31  0:23     ` Carsten Dominik

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=5474.1230570937@gamaville.dokosmarshall.org \
    --to=nicholas.dokos@hp.com \
    --cc=bernt@norang.ca \
    --cc=emacs-orgmode@gnu.org \
    --cc=rustompmody@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).