From: Thorsten Jolitz <tjolitz@gmail.com>
To: emacs-orgmode@gnu.org
Subject: Re: Exzessive newlines in org-element item interpreter?
Date: Sun, 19 Oct 2014 09:21:04 +0200 [thread overview]
Message-ID: <87vbng7cf3.fsf@gmail.com> (raw)
In-Reply-To: 87k33w36ci.fsf@nicolasgoaziou.fr
Nicolas Goaziou <mail@nicolasgoaziou.fr> writes:
> Hello,
>
> Thorsten Jolitz <tjolitz@gmail.com> writes:
>
>> Hi List,
>>
>> evaluating this
>>
>> #+BEGIN_SRC emacs-lisp
>> (org-element-interpret-data
>> '(item (:bullet "1" :tag "hello" :checkbox "trans" :counter 2)
>> (section nil "world")))
>> #+END_SRC
>>
>> #+results:
>> : 1. [@2] hello ::
>> : world
>>
>> the content is always placed on a newline, which looks strange in my
>> eyes. Is that intended?
>
> It is. You include a `section' in an `item', which is syntactically
> wrong. Only headlines can contain sections.
I see.
So when creating an element with interpreted content (that is given as
plain string), I use
- headlines :: (section nil "foo")
- others :: (paragraph nil "foo")
or should it rather be
- headlines :: (section nil (paragraph nil "foo"))
?
>> PS
>> and checkbox is ignored, no matter if I give 'on, 'off and 'trans as
>> symbols or strings.
>
> You should not provide 'on, 'off or 'trans, and even less strings, but
> on, off or trans since your expression is already quoted.
ups ... of course.
One more question:
the :tag property of items is parsed as list (of sec. string(s)) - is it
sufficient for interpreting to give it a plain string: tag: "foo"
instead of tag: ("foo")? It seems to work ...
--
cheers,
Thorsten
next prev parent reply other threads:[~2014-10-19 7:21 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-10-18 20:57 Exzessive newlines in org-element item interpreter? Thorsten Jolitz
2014-10-19 6:45 ` Nicolas Goaziou
2014-10-19 7:21 ` Thorsten Jolitz [this message]
2014-10-19 8:04 ` Thorsten Jolitz
2014-10-19 10:01 ` Nicolas Goaziou
2014-10-19 12:40 ` Thorsten Jolitz
2014-10-19 17:10 ` Nicolas Goaziou
2014-10-19 17:39 ` Thorsten Jolitz
2014-10-20 7:55 ` Nicolas Goaziou
2014-10-20 8:30 ` Thorsten Jolitz
2014-10-20 12:31 ` Nick Dokos
2014-10-20 13:23 ` Thorsten Jolitz
2014-10-19 10:06 ` Nicolas Goaziou
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=87vbng7cf3.fsf@gmail.com \
--to=tjolitz@gmail.com \
--cc=emacs-orgmode@gnu.org \
/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).