[Orgmode] Re: shortcut keys for mark ups

2009-01-07 Thread Patrick Drechsler
Bernt Hansen schrieb: [snipped nice code] How can I extend this function to wrap the current selection into a #+BEGIN_SRC ...code... #+END_SRC string while also interactively asking the user for a language string? - ;;

[Orgmode] Re: shortcut keys for mark ups

2009-01-07 Thread Bernt Hansen
Patrick Drechsler patr...@pdrechsler.de writes: Bernt Hansen schrieb: [snipped nice code] How can I extend this function to wrap the current selection into a #+BEGIN_SRC ...code... #+END_SRC string while also interactively asking the user for a language string?

[Orgmode] Re: shortcut keys for mark ups

2009-01-07 Thread Patrick Drechsler
Bernt Hansen schrieb: Patrick Drechsler patr...@pdrechsler.de writes: Bernt Hansen schrieb: [snipped nice code] How can I extend this function to wrap the current selection into a #+BEGIN_SRC ...code... #+END_SRC string while also interactively asking the user for a language string?

[Orgmode] Re: shortcut keys for mark ups

2009-01-06 Thread Bernt Hansen
Xin Shi x...@cornell.edu writes: In org mode, are there any shortcut keys for typing the following mark-ups? #+BEGIN_EXAMPLE #+END_EXAMPLE Not that I'm aware of. You can use a function like the following to achieve this - or maybe you can use yasnippets (I've never tried that yet)

[Orgmode] Re: shortcut keys for mark ups

2009-01-06 Thread Xin Shi
Hi Bernt, Thanks for your reply! That's what I was trying to do. But I think Carsten's suggestion of using the org-structure-template-alist is more appealing to general user. Xin Bernt Hansen wrote: Xin Shi x...@cornell.edu writes: In org mode, are there any shortcut keys for typing

Re: [Orgmode] Re: shortcut keys for mark ups

2009-01-06 Thread Carsten Dominik
On Jan 6, 2009, at 7:50 PM, Xin Shi wrote: Hi Bernt, Thanks for your reply! That's what I was trying to do. But I think Carsten's suggestion of using the org-structure-template-alist is more appealing to general user. I do like thought that Bernt puts his template around the current

Re: [Orgmode] Re: shortcut keys for mark ups

2009-01-06 Thread Richard Riley
Or use the org-mode map rather than global key (define-key org-mode-map (kbd C-f9) '(lambda()(interactive)(insert #+BEGIN_EXAMPLE\n\n#+END_EXAMPLE)(previous-line))) Xin Shi x...@cornell.edu writes: Hi Bernt, Thanks for your reply! That's what I was trying to do. But I think Carsten's