diff options
Diffstat (limited to 'Completion/Unix')
-rw-r--r-- | Completion/Unix/Command/_imagemagick | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/Completion/Unix/Command/_imagemagick b/Completion/Unix/Command/_imagemagick index 115cb01e4..1fc6089c8 100644 --- a/Completion/Unix/Command/_imagemagick +++ b/Completion/Unix/Command/_imagemagick @@ -1,6 +1,7 @@ #compdef animate composite combine convert display identify import mogrify montage xtp -local state line expl formats curcontext="$curcontext" +local state line expl curcontext="$curcontext" +local -a formats typeset -A opt_args # Things that could be improved: @@ -11,10 +12,10 @@ typeset -A opt_args # # and certainly many other things... -formats=jpg:jpeg:jp2:j2k:jpc:jpx:jpf:tiff:miff:ras:bmp:cgm:dcx:ps:eps:fig:fits:fpx:gif:mpeg:pbm:pgm:ppm:pcd:pcl:pdf:pcx:png:rad:rgb:rgba:rle:sgi:html:shtml:tga:ttf:uil:xcf:xwd:xbm:xpm:yuv +formats=(jpg jpeg jp2 j2k jpc jpx jpf tiff miff ras bmp cgm dcx ps eps fig fits fpx gif mpeg pbm pgm ppm pcd pcl pdf pcx png rad rgb rgba rle sgi html shtml tga ttf uil xcf xwd xbm xpm yuv) if (( $# )); then - _files "$@" -g "*.(#i)(${~formats//:/|})(-.)" + _files "$@" -g "*.(#i)(${(j:|:)formats})(-.)" return fi @@ -444,7 +445,7 @@ case "$service" in '*-filter:filter type for resizing:(Point Box Triangle Hermite Hanning Hamming Blackman Gaussian Quadratic Cubic Catrom Mitchell Lanczos Bessel Sinc)' \ '*-flip[vertical mirror image]' \ '*-flop[horizontal mirror image]' \ - "*-format:output file format:(${formats//:/ })" \ + "*-format:output file format:($formats)" \ '*-font:annotation font:_x_font' \ '*-frame:border dimensions (<width>x<height>+<out>+<in>)' \ '*-fuzz:maximum distance for equal colors' \ |