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

Keep logos and headers/footers from template (ODT) #3242

Open
jcpsantiago opened this issue Nov 18, 2016 · 2 comments
Open

Keep logos and headers/footers from template (ODT) #3242

jcpsantiago opened this issue Nov 18, 2016 · 2 comments

Comments

@jcpsantiago
Copy link

jcpsantiago commented Nov 18, 2016

So earlier this was working for me. I updated my template with a new version and now I'm only getting a file with the main body text -- no logos/headers.

The template in question is from the Frontiers journals:
http://www.frontiersin.org/Design/zip/Frontiers_Word_Templates.zip

I opened it in Word and saved it as ODT. Before I was getting an ODT file converted from MD with the logos and the messages in header and footer, but not anymore.

I need this, because my collaborators still use Word and we need to use this template.

My xml template file is very simple and doesn't match perfectly the Frontiers template. If anyone else this templatem would you be so kind and share your xml?

Any ideas? I'm attaching my docx (github doesn't allow odt)
frontiers.docx

Note: converting with the attached docx as reference will (almost) give me the result I want, but it doesn't support different left/right headers/footer which are present in the original docx template and the whole YAML stuff (authors, etc)

@jcpsantiago
Copy link
Author

jcpsantiago commented Nov 19, 2016

I started from the beginning and now I'm getting almost the same result as before, using the frontiers template as my --reference-docx. When I open the converted docx file in Word though, it complains and asks to repair the file. It seems my three tables have errors somewhere. Word says it's the first rows. One of the tables is not a square i.e. the rows below the header are narrower.

The footer has a text box in the original template that I'm not getting in the converted document. This used to work.

If I convert my MD to docx without any --reference-docx, the tables are perfect and Word doesn't say anything about an error. Using any --reference-docx and word complains.

I'm using pipe tables produces by this site:
http://www.tablesgenerator.com/markdown_tables

@agusmba
Copy link
Contributor

agusmba commented Sep 16, 2017

Note: converting with the attached docx as reference will (almost) give me the result I want, but it doesn't support different left/right headers/footer which are present in the original docx template and the whole YAML stuff (authors, etc)

Using docx does support different left/right/headers/footer although there is a small caveat in that the resulting docx doesn't have the "different odd/even pages" activated, but you can activate it manually and the result will be as expected.

See #3901

I'm also not having problems with the yaml stuff (appart from the fact that I cannot modify where they are placed since there is no "template" for docx).

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

3 participants