[Top][All Lists]

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

Re: [O] About commit named "Allow multi-line properties to be specified

From: Nicolas Goaziou
Subject: Re: [O] About commit named "Allow multi-line properties to be specified in property blocks"
Date: Mon, 31 Oct 2011 21:49:18 +0100

Eric Schulte <address@hidden> writes:

> The only problem with a single #+PROPERTY: line is that this line could
> become unreadably long.  By allowing such an entry to span multiple
> lines it becomes feasible to chain together many variables into a single
> property.  Another approach which is easily implementable would be to
> use syntax like the following...
>   #+PROPERTY:  var foo=1,
>   #+PROPERTY+:     bar=2,
>   #+PROPERTY+:     baz=3,
>   #+PROPERTY+:     qux=4

Well, what about:

#+begin_src org
#+property: :var foo=1
#+property: :var bar=2
#+property: :var baz=3
#+property: :var qux=4

Sure, we repeat ":var" more times, but at least, it's consistent with
the rest of Org.

> Although I originally switched from the above to the implemented
> because I thought that using a block would be more consistent with
> Org-mode syntax.

No, as I said, no block has ever controlled Org internals. That's a job
for keywords and property drawers.

> Also, the above is undesirable in its requires the PROPERTY+ lines to
> care about their position in the Org-mode file, which isn't normally
> the case.

Yes, "#+property+:" would be atypical in that situation.

> I think of #+FOO: lines as containers for anything that fits on
> a single line, and as blocks as containers for anything that requires
> a line break, e.g., #+HTML and #+BEGIN_HTML/#+END_HTML.

That comparison with "#+html" and "#+begin_html" doesn't hold as most
"#+keyword:" syntax don't have an equivalent block "#+begin_keyword",
and the other way. Look again at every block type in Org, and see if
there's any equivalent use of the "#+begin_property" you're introducing.
I don't think so.

Moreover, some keywords can be repeated on multiple lines. Think about
"#+text:" before first headline, or "#+header:" before a src block. So,
clearly, "#+keyword:" isn't just about things that must fit on a single

Also, you don't really need a line break here, since you will eventually
parse the values line by line anyway, and not as a block or a paragraph.

You want to add syntactic sugar. There's nothing wrong with it though,
but not everyone appreciate aspartame ;)

> I didn't realize that there was an extra semantics of blocks as
> formatting, and I'm not sure if such an association is desirable or
> intentional.

It is desirable to have a logic behind syntax, and to always refer to
it. Thus, is is desirable to separate syntax used for contents from
syntax used for Org control. It's very different from "things on
a single line vs things on multiple lines".


Nicolas Goaziou

reply via email to

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