diff options
Diffstat (limited to 'Completion/User/_pdf')
-rw-r--r-- | Completion/User/_pdf | 17 |
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" |