emacs-orgmode
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Orgmode] Re: structure editing in brainstorming mode


From: Nick Dokos
Subject: Re: [Orgmode] Re: structure editing in brainstorming mode
Date: Mon, 29 Dec 2008 12:15:37 -0500

Bernt Hansen <address@hidden> wrote:

> "Rustom Mody" <address@hidden> 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 via email to

[Prev in Thread] Current Thread [Next in Thread]