all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: "L.C. Karssen" <lennart@karssen.org>
To: Christian Moe <mail@christianmoe.com>
Cc: emacs-orgmode@gnu.org
Subject: Re: [BUG][ODT] ODT_STYLES_FILE not read as a list
Date: Tue, 6 Nov 2018 17:15:42 +0100	[thread overview]
Message-ID: <2fbfc24e-c356-831b-0e41-cca5a79de9c3@karssen.org> (raw)
In-Reply-To: <87r2fyxlpl.fsf@christianmoe.com>


[-- Attachment #1.1: Type: text/plain, Size: 3158 bytes --]


On 06-11-18 16:35, Christian Moe wrote:
> 
> I believe the need to use quotation marks around the style file name was
> removed at some point

I didn't know that. I had a quick look at the changes to ox-odt.el for
the last few months, but it doesn't seem to be mentioned in any of the
commit messages. Or was this a more global change?

Does this also count for the regular #+INCLUDE: statement? I just tested
it and for #+INCLUDE: it seems to work both with and without quotes
(although the manual uses quotes).


Best,

Lennart.

> , and the manual is out of date. Instead of
> 
>  #+ODT_STYLES_FILE: "template.ott"
> 
> the manual ought now to read:
> 
>  #+ODT_STYLES_FILE: template.ott
> 
> Yours,
> Christian
> 
> L.C. Karssen writes:
> 
>> Hi list,
>>
>> Not sure if this is related (or fixed with the aforementioned patch)
>> because I'm not using a list for the ODT style file.
>>
>> Today, after upgrading from Org 9.1.13 (actually installed from melpa on
>> 20180625) to melpa version 20181105 exporting to ODT stopped working. In
>> my org file the style file name was enclosed in double quotes (as
>> specified in the manual [1]):
>>
>> #+ODT_STYLES_FILE: "template.ott"
>>
>> The error message is:
>>
>> OpenDocument export failed: Invalid specification of styles.xml file:
>> "\"template.ott\""
>>
>> Removing the quotes fixes the export to ODT.
>>
>>
>> Best regards,
>>
>> Lennart.
>>
>> [1] https://orgmode.org/org.html#Applying-custom-styles
>>
>>
>> On 05-11-18 09:49, Christian Moe wrote:
>>>
>>> Thanks, Nicolas!
>>>
>>> I'll test on my end when it shows up in ELPA.
>>>
>>> Yours,
>>> Christian
>>>
>>> Nicolas Goaziou writes:
>>>
>>>> Hello,
>>>>
>>>> Christian Moe <mail@christianmoe.com> writes:
>>>>
>>>>> It seems the ODT exporter currently fails to read the ODT_STYLES_FILE
>>>>> option as a list, as in this example from the manual
>>>>> ([[info:org#Applying custom styles]]):
>>>>>
>>>>>   #+ODT_STYLES_FILE: ("/path/to/file.ott" ("styles.xml" "image/hdr.png"))
>>>>>
>>>>> This is needed if you want a complex style with e.g. an image in the
>>>>> header.
>>>>>
>>>>> Exporting this causes an "Invalid specification of styles.xml file"
>>>>> error on my recent ELPA version. The problem seems to be that the option
>>>>> is treated as a string and never tested to see if it contains a list.
>>>>>
>>>>> To reproduce the problem, place the attached documents
>>>>> odt-styles-test.org and odt-test-styles.odt in the same directory, then
>>>>> export odt-styles-test.org to ODT. The result should have a unicorn in
>>>>> the letterhead.
>>>>>
>>>>> The below quick-and-dirty patch seems to fix it, but I'm sure there's a
>>>>> better approach.
>>>>
>>>> Thank you. I applied your patch with an additional check: the value should
>>>> be enclosed within round brackets.
>>>>
>>>> Regards,
>>>
>>>

-- 
*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*
L.C. Karssen
's-Hertogenbosch
The Netherlands

lennart@karssen.org
http://blog.karssen.org
GPG key ID: A88F554A
-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-


[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 228 bytes --]

  reply	other threads:[~2018-11-06 16:15 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-10-30 20:47 [BUG][ODT] ODT_STYLES_FILE not read as a list Christian Moe
2018-10-30 20:49 ` Christian Moe
2018-11-04 22:05 ` Nicolas Goaziou
2018-11-05  8:49   ` Christian Moe
2018-11-06 15:18     ` L.C. Karssen
2018-11-06 15:35       ` Christian Moe
2018-11-06 16:15         ` L.C. Karssen [this message]
2018-11-07  8:28           ` Christian Moe
2018-11-07 15:32             ` L.C. Karssen
2018-11-10  8:16               ` Nicolas Goaziou
2018-11-19 17:21                 ` L.C. Karssen
2018-11-19 22:58                   ` 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

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=2fbfc24e-c356-831b-0e41-cca5a79de9c3@karssen.org \
    --to=lennart@karssen.org \
    --cc=emacs-orgmode@gnu.org \
    --cc=mail@christianmoe.com \
    /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 external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.