Package: xpdf-reader
Version: 3.02-1.4
Severity: wishlist
Tags: patch

using texdoctk, sometimes vieving a pdf document fails because the
document is indexed in texdoctk database with the name
/long/path/document.pdf, while on the file system there is a
compressed version of the document, say /long/path/document.pdf.gz

i have found a solution to this problem, configuring texdoctk so that
it uses zxpdf to open pdf's, and modifying zxpdf to look for a
possibly compressed file

of course you could consider also merging /usr/bin/xpfd and
/usr/bin/zxpdf, so that a mere "xpdf /long/path/document.pdf" could do
the right thing in (almost) every circumstance

thank you
                                                        gb

here there is a diff for my changes

--- /usr/bin/zxpdf      2008-09-13 14:21:06.000000000 +0200
+++ bin/zzxpdf  2008-10-09 12:35:26.000000000 +0200
@@ -18,7 +18,12 @@
        flags="$flags $1 $2"; shift ;;
     -title) title="$2"; shift ;;
     -*) flags="$flags $1" ;;
-    *.pdf|*.PDF) file="$1"; shift; pages="$@"; cat=; break ;;
+    *.pdf|*.PDF) file="$1"
+      if [ -f $file ] ; then cat="" ; else
+          if [ -f $file.Z  ]  ; then file=$file.Z   ; cat=zcat  ; fi
+          if [ -f $file.gz  ] ; then file=$file.gz  ; cat=zcat  ; fi
+          if [ -f $file.bz2 ] ; then file=$file.bz2 ; cat=bzcat ; fi
+      fi ; shift; pages="$@"; break ;;
     *.gz|*.Z) file="$1"; shift; pages="$@"; cat=zcat; break ;;
     *.bz2) file="$1"; shift; pages="$@"; cat=bzcat; break ;;
     *) echo >&2 "ERROR: unknown suffix in file \`$1'"; exit 1 ;;


-- System Information:
Debian Release: lenny/sid
  APT prefers unstable
  APT policy: (500, 'unstable')
Architecture: i386 (i686)

Kernel: Linux 2.6.18-4-686 (SMP w/1 CPU core)
Locale: LANG=C, LC_CTYPE=C (charmap=ANSI_X3.4-1968)
Shell: /bin/sh linked to /bin/bash

Versions of packages xpdf depends on:
ii  xpdf-common                   3.02-1.4   Portable Document Format (PDF) sui
ii  xpdf-reader                   3.02-1.4   Portable Document Format (PDF) sui
ii  xpdf-utils                    3.02-1.4   Portable Document Format (PDF) sui

xpdf recommends no packages.

xpdf suggests no packages.

Versions of packages xpdf-reader depends on:
ii  gsfonts       1:8.11+urwcyr1.0.7~pre44-3 Fonts for the Ghostscript interpre
ii  lesstif2      1:0.95.0-2.1               OSF/Motif 2.1 implementation relea
ii  libc6         2.7-14                     GNU C Library: Shared libraries
ii  libfreetype6  2.3.7-2                    FreeType 2 font engine, shared lib
ii  libgcc1       1:4.3.2-1                  GCC support library
ii  libice6       2:1.0.4-1                  X11 Inter-Client Exchange library
ii  libpaper1     1.1.23+nmu1                library for handling paper charact
ii  libsm6        2:1.0.3-2                  X11 Session Management library
ii  libstdc++6    4.3.2-1                    The GNU Standard C++ Library v3
ii  libt1-5       5.1.2-3                    Type 1 font rasterizer library - r
ii  libx11-6      2:1.1.5-2                  X11 client-side library
ii  libxext6      2:1.0.4-1                  X11 miscellaneous extension librar
ii  libxp6        1:1.0.0.xsf1-2             X Printing Extension (Xprint) clie
ii  libxpm4       1:3.5.7-1                  X11 pixmap library
ii  libxt6        1:1.0.5-3                  X11 toolkit intrinsics library
ii  xpdf-common   3.02-1.4                   Portable Document Format (PDF) sui

-- no debconf information

-- 
This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.




-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Reply via email to