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

Postscript (.ps) format support #8258

Open
multimeric opened this issue Aug 30, 2022 · 7 comments
Open

Postscript (.ps) format support #8258

multimeric opened this issue Aug 30, 2022 · 7 comments

Comments

@multimeric
Copy link

I recently encountered a journal that would accept PostScript (.ps) files, but not LaTeX files. Considering that pandoc supports .tex and .pdf, it would be helpful for pandoc to support the .ps intermediate, because it seems that it might be useful to have access to this for the reason above.

Describe your proposed improvement and the problem it solves.

Support .ps as an output format.

Describe alternatives you've considered.

Exporting to .tex and then manually running e.g. latex and then dvips on it would work, but ideally pandoc would provide a shortcut to make the conversion smoother.

@jgm
Copy link
Owner

jgm commented Aug 30, 2022

This would require implementing all of the layout that TeX does.
It's out of scope. Ps is not a format for structured text; it's a layout format.

@jgm jgm closed this as completed Aug 30, 2022
@multimeric
Copy link
Author

Right, but I'm not suggesting it as a markup format that we can convert from, I'm suggesting it as an output format like PDF. If PDF is in scope why not PostScript?

@jgm
Copy link
Owner

jgm commented Aug 30, 2022

Oh, I see. You mean, pandoc could shell out to latex instead of pdflatex, producing a dvi then using dvips to create a ps? (or perhaps using .ms and then groff?)

I don't know. It adds complexity and I'm not sure it's worth it. Most people who need to deal with ps will know how to produce it themselves from the latex or roff output pandoc can produce.

But we can reopen this for further consideration.

@jgm jgm reopened this Aug 30, 2022
@multimeric
Copy link
Author

Yes, exactly. The reason why it would be helpful in pandoc specifically, rather than doing this manually, is because pandoc underlies a number of higher level publishing tools (manubot, and I think quarto?) which can't easily export to .ps until pandoc can.

@jgm
Copy link
Owner

jgm commented Aug 30, 2022

"can't easily" - I don't know. These tools could add a couple lines in a scripting language if they wanted to allow PS output. For example, you could take the PDF pandoc produces and pass it through

https://www.xpdfreader.com/pdftops-man.html

@tarleb
Copy link
Collaborator

tarleb commented Aug 30, 2022

A custom writer could be another option. I believe pandoc Lua has all the necessary tools to do this in a portable way, which could also benefit the publishing tools mentioned above.

@jgm
Copy link
Owner

jgm commented Oct 5, 2022

I think we do use some PDF-specific commands, both in latex and in ms, so that might cause problems for generating ps. Of course you can just pipe the pdf through pdftops!

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