-
Notifications
You must be signed in to change notification settings - Fork 199
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
Pdf generation fix #142
Merged
Merged
Pdf generation fix #142
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
I didn't have time to sort out these issues: Sound chapter: uses approximately equal sign within inline code, which breaks lstinline Math: Similar issues as sound, but more of them. Also, it has latex code within the chapter. Not clear whether that is problematic. Memory: uses svg images which latex can't handle by default
…o pdf-generation-fix
…o pdf-generation-fix
…o pdf-generation-fix
…o pdf-generation-fix
…ge-extension pandoc option
Looks good to me. |
Thanks for taking a look |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Now that the pdf-generation-fix branch is working, I'd like to merge it into master. The bulk of what was holding up the pdf pipeline was formatting (replacing typographic quotes and fixing inconsistent markdown, image locations & line breaking), but the one worth bringing attention to is @arturoc's memory chapter.
@arturoc is using SVGs, which work for web, but break the PDF book because vanilla latex doesn't support SVGs. PDF images work nicely for the PDF book, but don't play as nicely with the web book (because they use the
<embed>
tag which breaks the web book script).The solution I used was to convert the SVGs to PDFs (
convertSVGToPDF.py
) using inkscape. The file extensions can be left out of the memory chapter, and then the pandoc option of--default-image-extension
can be used to pick SVG vs PDF for the separate pipelines. This seems like a better option than adding inkscape as a dependency for ofBook (compared to converting images on-the-fly).(This PR will not create a conflict with open mergeable PRs - specifically #126.)