summary refs log tree commit diff
path: root/Completion/User/_pdf
diff options
context:
space:
mode:
authorSven Wischnowsky <wischnow@users.sourceforge.net>2000-08-23 08:27:01 +0000
committerSven Wischnowsky <wischnow@users.sourceforge.net>2000-08-23 08:27:01 +0000
commit989faba5887f1961b31a2e16b42261ee48355042 (patch)
tree77d6a7f1a71405b2bf84911d7067b6ce56530d69 /Completion/User/_pdf
parent0992bff14c9274d26a30b1ace878ccface48d006 (diff)
downloadzsh-989faba5887f1961b31a2e16b42261ee48355042.tar.gz
zsh-989faba5887f1961b31a2e16b42261ee48355042.tar.xz
zsh-989faba5887f1961b31a2e16b42261ee48355042.zip
complete compressed files for gv; improve results from _pspdf (12692)
Diffstat (limited to 'Completion/User/_pdf')
-rw-r--r--Completion/User/_pdf17
1 files changed, 15 insertions, 2 deletions
diff --git a/Completion/User/_pdf b/Completion/User/_pdf
index 7d7756c3e..de373a355 100644
--- a/Completion/User/_pdf
+++ b/Completion/User/_pdf
@@ -1,3 +1,16 @@
-function acroread
+#compdef acroread pdf2dsc pdf2ps pdfimages pdfinfo pdftopbm pdftops pdftotext xpdf
 
-_files -g '*.(pdf|PDF)'
+local expl ext=''
+
+# ghostscript:
+#  pdf2dsc pdf2ps
+# xpdf:
+#  pdfimages pdfinfo pdftopbm pdftops pdftotext xpdf
+
+if [[ "$1" == '-z' ]]; then
+  ext='(|.gz|.Z)'
+  shift
+fi
+
+_description files expl 'PDF file'
+_files "$@" "$expl[@]" -g "*.(#i)pdf$ext"