Re: [O] Use org-element to figure out if I am in a drawer.

2013-11-26 Thread Nicolas Goaziou
Hello, Carsten Dominik writes: > Hmmm, > > what is the magic incantation to use org-element to figure out if > point is currently inside a drawer? Something like: (let ((element (org-element-at-point))) (while (and element (not (memq (org-element-type element) '(drawer p

Re: [O] Use org-element to figure out if I am in a drawer.

2013-11-26 Thread Rasmus
Carsten Dominik writes: > Hmmm, > > what is the magic incantation to use org-element to figure out if > point is currently inside a drawer? What about org-element-at-point? E.g. like here: * This is a headline Still outside the drawer :DRAWERNAME: This is inside the drawer. :END:

Re: [O] Use org-element to figure out if I am in a drawer.

2013-11-26 Thread Nick Dokos
Carsten Dominik writes: > what is the magic incantation to use org-element to figure out if > point is currently inside a drawer? > (eq 'drawer (org-element-type (org-element-at-point))) is my (untested) guess, but I don't think you can be at an arbitrary place inside: you'll need to be on the

[O] Use org-element to figure out if I am in a drawer.

2013-11-26 Thread Carsten Dominik
Hmmm, what is the magic incantation to use org-element to figure out if point is currently inside a drawer? Thanks - Carsten