unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
* bug#53354: 29.0.50; doc-view not handle odf->pdf->png using pdf->png coverter
@ 2022-01-19  0:59 Shuguang Sun via Bug reports for GNU Emacs, the Swiss army knife of text editors
  2022-01-21 10:25 ` Lars Ingebrigtsen
  0 siblings, 1 reply; 2+ messages in thread
From: Shuguang Sun via Bug reports for GNU Emacs, the Swiss army knife of text editors @ 2022-01-19  0:59 UTC (permalink / raw)
  To: 53354

[-- Attachment #1: Type: text/plain, Size: 300 bytes --]

Hi All,

When I'm using doc-view to open a docx or pptx file, it convert the office file to pdf as expected, however, when it tries to convert the derived pdf to png, it calls the function `doc-view-ps->png-converter-ghostscript` and not the one specified by `doc-view-pdf->png-converter-function`.


[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: specify odf to use doc-view-pdf->png-converter-function --]
[-- Type: text/x-patch, Size: 523 bytes --]

diff --git a/lisp/doc-view.el b/lisp/doc-view.el
index 5b462b24f5..5e160f5dff 100644
--- a/lisp/doc-view.el
+++ b/lisp/doc-view.el
@@ -1189,7 +1189,7 @@ is named like ODF with the extension turned to pdf."
   "Convert PDF-PS to PNG asynchronously."
   (funcall
    (pcase doc-view-doc-type
-     ('pdf doc-view-pdf->png-converter-function)
+     ((or 'pdf 'odf) doc-view-pdf->png-converter-function)
      ('djvu #'doc-view-djvu->tiff-converter-ddjvu)
      (_ #'doc-view-ps->png-converter-ghostscript))
    pdf-ps png nil

[-- Attachment #3: Type: text/plain, Size: 1254 bytes --]



Best Regards,
Shuguang Sun



In GNU Emacs 29.0.50 (build 1, x86_64-pc-linux-gnu, GTK+ Version 3.24.31, cairo version 1.17.4)
 of 2022-01-17 built on lilydjwg
Repository revision: 714e11d53534416b6519396a9df5d62054731810
Repository branch: master
System Description: Manjaro Linux

Configured using:
 'configure --prefix=/usr --sysconfdir=/etc --libexecdir=/usr/lib
 --localstatedir=/var --mandir=/usr/share/man --with-gameuser=:games
 --with-sound=alsa --with-modules --without-libotf --without-m17n-flt
 --without-gconf --without-gsettings --with-native-compilation
 --with-xinput2 --with-pgtk --without-xaw3d --with-sound=no
 --with-xwidgets --without-gpm --without-compress-install
 '--program-transform-name=s/\([ec]tags\)/\1.emacs/'
 'CFLAGS=-march=x86-64 -mtune=generic -O2 -pipe -fno-plt'
 CPPFLAGS=-D_FORTIFY_SOURCE=2
 LDFLAGS=-Wl,-O1,--sort-common,--as-needed,-z,relro,-z,now'

Configured features:
ACL CAIRO DBUS FREETYPE GIF GLIB GMP GNUTLS HARFBUZZ JPEG JSON LCMS2
LIBSYSTEMD LIBXML2 MODULES NATIVE_COMP NOTIFY INOTIFY PDUMPER PGTK PNG
RSVG SECCOMP SQLITE3 THREADS TIFF TOOLKIT_SCROLL_BARS WEBP XIM XWIDGETS
GTK3 ZLIB

Important settings:
  value of $LANG: en_US.UTF-8
  value of $XMODIFIERS: @im=fcitx
  locale-coding-system: utf-8-unix


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* bug#53354: 29.0.50; doc-view not handle odf->pdf->png using pdf->png coverter
  2022-01-19  0:59 bug#53354: 29.0.50; doc-view not handle odf->pdf->png using pdf->png coverter Shuguang Sun via Bug reports for GNU Emacs, the Swiss army knife of text editors
@ 2022-01-21 10:25 ` Lars Ingebrigtsen
  0 siblings, 0 replies; 2+ messages in thread
From: Lars Ingebrigtsen @ 2022-01-21 10:25 UTC (permalink / raw)
  To: Shuguang Sun; +Cc: 53354

Shuguang Sun <shuguang79@qq.com> writes:

> When I'm using doc-view to open a docx or pptx file, it convert the
> office file to pdf as expected, however, when it tries to convert the
> derived pdf to png, it calls the function
> `doc-view-ps->png-converter-ghostscript` and not the one specified by
> `doc-view-pdf->png-converter-function`.

Thanks; applied to Emacs 29.

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no





^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2022-01-21 10:25 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-01-19  0:59 bug#53354: 29.0.50; doc-view not handle odf->pdf->png using pdf->png coverter Shuguang Sun via Bug reports for GNU Emacs, the Swiss army knife of text editors
2022-01-21 10:25 ` Lars Ingebrigtsen

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).