asciidoctor / asciidoctorj-pdf

AsciidoctorJ PDF bundles the Asciidoctor PDF RubyGem (asciidoctor-pdf) so it can be loaded into the JVM using JRuby.
Apache License 2.0
35 stars 17 forks source link

broken rendering of source blocks under certain condition #61

Closed wklaebe closed 2 years ago

wklaebe commented 3 years ago

With a pdf theme specifying Courier as font-family for code blocks, code blocks with line numbers and wrapped lines get annoying  characters. Minimal example: test.adoc.txt test-theme.yml.txt test.pdf

I found that one small change in gems/prawn-2.4.0/lib/prawn/text/formatted/box.rb inside asciidoctorj-pdf.jar (1.5.3, 1.5.4, 1.6.0) corrects this, but I am not sure whether the prawn project would accept this: fix.diff.txt

Ideas?

robertpanzer commented 3 years ago

As asciidoctorj-pdf is just a repackaging of asciidoctor-pdf I'd recommend opening a ticket for asciidoctor/asciidoctor-pdf, maybe there's a way to circumvent the issue that you are facing. Or maybe also open a ticket for prawn.

What I'd really like to avoid is to patch libraries so that asciidoctorj-pdf behaves differently than asciidoctor-pdf.

wklaebe commented 2 years ago

Problem solved in https://github.com/asciidoctor/asciidoctor-pdf/issues/1934