Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Is there any way to specify the com.apple.ibooks.display-options value defined on EPUB.hs when exporting? #1684

Open
nonoesp opened this issue Oct 12, 2014 · 5 comments

Comments

@nonoesp
Copy link

nonoesp commented Oct 12, 2014

I have the need to create an .epub file setting the com.apple.ibooks.display-options as false instead of true — which seems to be the default option using the EPUB.hs Writer.

The file currently looks like this inside of the created epubs:

<?xml version="1.0" encoding="UTF-8"?>
<display_options>
  <platform name="*">
    <option name="specified-fonts">true</option>
  </platform>
</display_options>

And I would like it to look like this (the only that changes is true to false):

<?xml version="1.0" encoding="UTF-8"?>
<display_options>
  <platform name="*">
    <option name="specified-fonts">false</option>
  </platform>
</display_options>

Is there a way to specify this option without having to re-compile pandoc modifying EPUB.hs?

@jgm
Copy link
Owner

jgm commented Nov 17, 2014

No. I'm open to simply changing the default to false, unless there is some reason why it would be better for some people to make it true. I can't see one at the moment.

@nonoesp
Copy link
Author

nonoesp commented Nov 17, 2014

That would be awesome. Its a bit tedious to change it each time the book is re-generated.

I believe true enforces iBooks to show the customized stylesheet of the book, but it is usually not the desired behaviour.

@jgm
Copy link
Owner

jgm commented Mar 5, 2017

See #2693

@mb21
Copy link
Collaborator

mb21 commented Feb 2, 2019

This is still hard-coded to true in https://github.com/jgm/pandoc/blob/master/src/Text/Pandoc/Writers/EPUB.hs#L862

But apparently, it's need when you want iBooks to load custom fonts.

@jgm
Copy link
Owner

jgm commented Feb 2, 2019

So from 20103ac it looks like we have a specified-fonts field in ibook metadata.

Question: should this field be used to set the value of specified-fonts also in display-data?
It would be quite easy to change that.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants