-
Notifications
You must be signed in to change notification settings - Fork 16
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
wepb image doesn't show in PDF. #70
Comments
I'm pretty sure this is an Asciidoctor PDF issue. Asciidoctor PDF does not support reading webp files. Those files have to be converted to a format that the PDF generation library (Prawn) supports, which is jpg, png, and SVG. But we certainly could look into what would need to happen to support webp. |
@mojavelinux - I agree that this is a Asciidoctor PDF issue. Could you please move this issue to that project? |
This is technically an AsciidoctorJ PDF issue. That's because Asciidoctor PDF will support webp if you have prawn-gmagick installed. But not AsciidoctorJ PDF:
prawn-gmagick does not currently work with AsciidoctorJ PDF. So AsciidoctorJ PDF would need to provide something equivalent in order to support image formats other than what Prawn itself support (PNG, JPG, and SVG). |
I tried to add the prawn-gmagick gem locally, but that doesn't seem to work.
|
I could be wrong, but I'm almost certain that prawn-gmagick isn't compatible with JRuby. However, there is an image processing library for JRuby named ruby-vips that could be used to provide an equivalent gem. It could also be done using pure Java. Here's what prawn-gmagick does: https://github.com/packetmonkey/prawn-gmagick/blob/master/lib/prawn/gmagick.rb (It just needs the decoded data from the image). |
Observed vs. expected behavior
A webp image works fine until I export to a pdf and it doesn't show up. jpg works as expected.
Steps to reproduce
Put in an image say...
.Image caption
image::LIGHTYEAR.webp["Lightyear movie 4 astronauts in a vehicle with cat and Lightyear driving", 400]
Hit the PDF button, a pdf is produced but the image doesn't show up. Even tried specifying the format... [format="webp","Lightyear.... but that didn't help.
Environment
macOS current versions of everything.
Plugin Version: 0.37.12
IntelliJ Details:IntelliJ IDEA 2021.3.3 (Ultimate Edition)
Build #IU-213.7172.25, built on March 15, 2022
Runtime version: 11.0.14.1+1-b1751.46 x86_64
VM: OpenJDK 64-Bit Server VM by JetBrains s.r.o.
macOS 12.3.1
GC: G1 Young Generation, G1 Old Generation
Memory: 2048M
Cores: 12
Registry:
debugger.watches.in.variables=false
Non-Bundled Plugins:
ski.chrzanow.foldableprojectview (1.1.2)
org.toml.lang (213.5744.224)
net.seesharpsoft.intellij.plugins.csv (2.18.2)
in.xiv.cs (0.1)
com.perl5 (2021.3.1)
com.jetbrains.plugins.ini4idea (213.5744.190)
com.jetbrains.plugins.asp (213.5744.122)
com.intellij.ideolog (203.0.27.0)
org.jetbrains.kotlin (213-1.6.10-release-961-IJ6777.52)
org.jetbrains.erlang (0.11.1129)
com.intellij.apacheConfig (213.5744.190)
com.alayouni.ansiHighlight (1.2.4)
org.asciidoctor.intellij.asciidoc (0.37.12)
mobi.hsz.idea.gitignore (4.4.0)
com.microsoft.vso.idea (1.162.0)
com.perl5.lang.mason.framework (2021.3.1)
com.perl5.lang.mason.mason2 (2021.3.1)
com.cursiveclojure.cursive (1.12.1-2021.3)
com.github.brcosta.cljstuffplugin (0.6.1)
com.intellij.plugins.html.instantEditing (213.5744.122)
com.jetbrains.php (213.7172.28)
com.jetbrains.twig (213.5744.224)
com.jetbrains.php.wordPress (213.5744.125)
com.jetbrains.php.blade (213.6461.21)
de.espend.idea.laravel (0.15.4)
Pythonid (213.7172.26)
ru.adelf.idea.dotenv (2022.1)
Kotlin: 213-1.6.10-release-961-IJ6777.52
The text was updated successfully, but these errors were encountered: