44#include "MagickWand/studio.h"
45#include "MagickWand/MagickWand.h"
46#include "MagickWand/mogrify-private.h"
47#include "MagickCore/display-private.h"
48#include "MagickCore/string-private.h"
94static MagickBooleanType DisplayUsage(
void)
98 " 1 press to map or unmap the Command widget\n"
99 " 2 press and drag to magnify a region of an image\n"
100 " 3 press to load an image from a visual image directory",
102 " -debug events display copious debugging information\n"
103 " -help print program options\n"
104 " -list type print a list of supported option arguments\n"
105 " -log format format of debugging information\n"
106 " -version print version information",
108 " -auto-level automagically adjust color levels of image\n"
109 " -auto-orient automagically orient image\n"
110 " -border geometry surround image with a border of color\n"
111 " -clip clip along the first path from the 8BIM profile\n"
112 " -clip-path id clip along a named path from the 8BIM profile\n"
113 " -colors value preferred number of colors in the image\n"
114 " -contrast enhance or reduce the image contrast\n"
115 " -crop geometry preferred size and location of the cropped image\n"
116 " -decipher filename convert cipher pixels to plain pixels\n"
117 " -deskew threshold straighten an image\n"
118 " -despeckle reduce the speckles within an image\n"
119 " -edge factor apply a filter to detect edges in the image\n"
120 " -enhance apply a digital filter to enhance a noisy image\n"
121 " -equalize perform histogram equalization to an image\n"
122 " -extent geometry set the image size\n"
123 " -extract geometry extract area from image\n"
124 " -flip flip image in the vertical direction\n"
125 " -flop flop image in the horizontal direction\n"
126 " -frame geometry surround image with an ornamental border\n"
127 " -fuzz distance colors within this distance are considered equal\n"
128 " -gamma value level of gamma correction\n"
129 " -monochrome transform image to black and white\n"
130 " -negate replace every pixel with its complementary color\n"
131 " -normalize transform image to span the full range of colors\n"
132 " -raise value lighten/darken image edges to create a 3-D effect\n"
133 " -resample geometry change the resolution of an image\n"
134 " -resize geometry resize the image\n"
135 " -roll geometry roll an image vertically or horizontally\n"
136 " -rotate degrees apply Paeth rotation to the image\n"
137 " -sample geometry scale image with pixel sampling\n"
138 " -segment value segment an image\n"
139 " -sharpen geometry sharpen the image\n"
140 " -strip strip image of all profiles and comments\n"
141 " -threshold value threshold the image\n"
142 " -thumbnail geometry create a thumbnail of the image\n"
143 " -trim trim image edges",
145 " -alpha option on, activate, off, deactivate, set, opaque, copy\n"
146 " transparent, extract, background, or shape\n"
147 " -antialias remove pixel-aliasing\n"
148 " -authenticate password\n"
149 " decipher image with this password\n"
150 " -backdrop display image centered on a backdrop\n"
151 " -channel type apply option to select image channels\n"
152 " -colormap type Shared or Private\n"
153 " -colorspace type alternate image colorspace\n"
154 " -comment string annotate image with comment\n"
155 " -compress type type of pixel compression when writing the image\n"
156 " -define format:option\n"
157 " define one or more image format options\n"
158 " -delay value display the next image after pausing\n"
159 " -density geometry horizontal and vertical density of the image\n"
160 " -depth value image depth\n"
161 " -display server display image to this X server\n"
162 " -dispose method layer disposal method\n"
163 " -dither method apply error diffusion to image\n"
164 " -endian type endianness (MSB or LSB) of the image\n"
165 " -filter type use this filter when resizing an image\n"
166 " -format string output formatted image characteristics\n"
167 " -geometry geometry preferred size and location of the Image window\n"
168 " -gravity type horizontal and vertical backdrop placement\n"
169 " -identify identify the format and characteristics of the image\n"
170 " -immutable displayed image cannot be modified\n"
171 " -interlace type type of image interlacing scheme\n"
172 " -interpolate method pixel color interpolation method\n"
173 " -label string assign a label to an image\n"
174 " -limit type value pixel cache resource limit\n"
175 " -loop iterations loop images then exit\n"
176 " -map type display image using this Standard Colormap\n"
177 " -matte store matte channel if the image has one\n"
178 " -monitor monitor progress\n"
179 " -nostdin do not try to open stdin\n"
180 " -page geometry size and location of an image canvas\n"
181 " -profile filename add, delete, or apply an image profile\n"
182 " -quality value JPEG/MIFF/PNG compression level\n"
183 " -quantize colorspace reduce colors in this colorspace\n"
184 " -quiet suppress all warning messages\n"
185 " -regard-warnings pay attention to warning messages\n"
186 " -remote command execute a command in an remote display process\n"
187 " -repage geometry size and location of an image canvas (operator)\n"
188 " -respect-parentheses settings remain in effect until parenthesis boundary\n"
189 " -sampling-factor geometry\n"
190 " horizontal and vertical sampling factor\n"
191 " -scenes range image scene range\n"
192 " -seed value seed a new sequence of pseudo-random numbers\n"
193 " -set property value set an image property\n"
194 " -size geometry width and height of image\n"
195 " -support factor resize support: > 1.0 is blurry, < 1.0 is sharp\n"
196 " -texture filename name of texture to tile onto the image background\n"
197 " -transparent-color color\n"
198 " transparent color\n"
199 " -treedepth value color tree depth\n"
200 " -update seconds detect when image file is modified and redisplay\n"
201 " -verbose print detailed information about the image\n"
202 " -visual type display image using this visual type\n"
203 " -virtual-pixel method\n"
204 " virtual pixel access method\n"
205 " -window id display image to background of this window\n"
206 " -window-group id exit program when this window id is destroyed\n"
207 " -write filename write image to a file",
208 sequence_operators[] =
209 " -coalesce merge a sequence of images\n"
210 " -flatten flatten a sequence of images";
212 ListMagickVersion(stdout);
213 (void) printf(
"Usage: %s [options ...] file [ [options ...] file ...]\n",
215 (void) printf(
"\nImage Settings:\n");
216 (void) puts(settings);
217 (void) printf(
"\nImage Operators:\n");
218 (void) puts(operators);
219 (void) printf(
"\nImage Sequence Operators:\n");
220 (void) puts(sequence_operators);
221 (void) printf(
"\nMiscellaneous Options:\n");
222 (void) puts(miscellaneous);
224 "\nIn addition to those listed above, you can specify these standard X\n");
226 "resources as command line options: -background, -bordercolor,\n");
228 " -mattecolor, -borderwidth, -font, -foreground, -iconGeometry,\n");
229 (void) printf(
"-iconic, -name, -shared-memory, -usePixmap, or -title.\n");
231 "\nBy default, the image format of 'file' is determined by its magic\n");
233 "number. To specify a particular image format, precede the filename\n");
235 "with an image format name and a colon (i.e. ps:image) or specify the\n");
237 "image type as the filename suffix (i.e. image.ps). Specify 'file' as\n");
238 (void) printf(
"'-' for standard input or output.\n");
239 (void) printf(
"\nButtons: \n");
240 (void) puts(buttons);
244#if defined(MAGICKCORE_X11_DELEGATE)
245WandExport MagickBooleanType DisplayImageCommand(ImageInfo *image_info,
246 int argc,
char **argv,
char **wand_unused(metadata),ExceptionInfo *exception)
248#define DestroyDisplay() \
250 if ((state & ExitState) == 0) \
251 DestroyXResources(); \
252 if (display != (Display *) NULL) \
254 XCloseDisplay(display); \
255 display=(Display *) NULL; \
257 XDestroyResourceInfo(&resource_info); \
258 DestroyImageStack(); \
259 if (image_marker != (size_t *) NULL) \
260 image_marker=(size_t *) RelinquishMagickMemory(image_marker); \
261 for (i=0; i < (ssize_t) argc; i++) \
262 argv[i]=DestroyString(argv[i]); \
263 argv=(char **) RelinquishMagickMemory(argv); \
265#define ThrowDisplayException(asperity,tag,option) \
267 (void) ThrowMagickException(exception,GetMagickModule(),asperity,tag,"`%s'", \
270 return(MagickFalse); \
272#define ThrowDisplayInvalidArgumentException(option,argument) \
274 (void) ThrowMagickException(exception,GetMagickModule(),OptionError, \
275 "InvalidArgument","'%s': %s",option,argument); \
277 return(MagickFalse); \
294 image_stack[MaxImageStackDepth+1];
333 assert(image_info != (ImageInfo *) NULL);
334 assert(image_info->signature == MagickCoreSignature);
335 assert(exception != (ExceptionInfo *) NULL);
336 wand_unreferenced(metadata);
337 if (IsEventLogging() != MagickFalse)
338 (void) LogMagickEvent(TraceEvent,GetMagickModule(),
"...");
342 if ((LocaleCompare(
"version",option+1) == 0) ||
343 (LocaleCompare(
"-version",option+1) == 0))
345 ListMagickVersion(stdout);
350 display=(Display *) NULL;
353 image_marker=(
size_t *) NULL;
357 option=(
char *) NULL;
359 respect_parentheses=MagickFalse;
361 resource_database=(XrmDatabase) NULL;
362 (void) memset(&resource_info,0,
sizeof(resource_info));
363 server_name=(
char *) NULL;
366 ReadCommandlLine(argc,&argv);
367 status=ExpandFilenames(&argc,&argv);
368 if (status == MagickFalse)
369 ThrowDisplayException(ResourceLimitError,
"MemoryAllocationFailed",
370 GetExceptionMessage(errno));
371 image_marker=(
size_t *) AcquireQuantumMemory((
size_t) argc+1UL,
372 sizeof(*image_marker));
373 if (image_marker == (
size_t *) NULL)
374 ThrowDisplayException(ResourceLimitError,
"MemoryAllocationFailed",
375 GetExceptionMessage(errno));
376 for (i=0; i <= (ssize_t) argc; i++)
377 image_marker[i]=(
size_t) argc;
381 for (i=1; i < (ssize_t) argc; i++)
387 if (IsCommandOption(option) == MagickFalse)
389 if (LocaleCompare(
"display",option+1) == 0)
395 if (i == (ssize_t) argc)
396 ThrowDisplayException(OptionError,
"MissingArgument",option);
399 if (LocaleCompare(
"nostdin",option+1) == 0)
401 if ((LocaleCompare(
"help",option+1) == 0) ||
402 (LocaleCompare(
"-help",option+1) == 0))
405 return(DisplayUsage());
411 display=XOpenDisplay(server_name);
412 if (display == (Display *) NULL)
413 ThrowDisplayException(XServerError,
"UnableToOpenXServer",
414 XDisplayName(server_name));
415 (void) XSetErrorHandler(XError);
416 resource_database=XGetResourceDatabase(display,GetClientName());
417 XGetResourceInfo(image_info,resource_database,GetClientName(),
419 quantize_info=resource_info.quantize_info;
420 image_info->density=XGetResourceInstance(resource_database,GetClientName(),
421 "density",(
char *) NULL);
422 if (image_info->density == (
char *) NULL)
423 image_info->density=XGetScreenDensity(display);
424 resource_value=XGetResourceInstance(resource_database,GetClientName(),
426 image_info->interlace=(InterlaceType)
427 ParseCommandOption(MagickInterlaceOptions,MagickFalse,resource_value);
428 image_info->page=XGetResourceInstance(resource_database,GetClientName(),
429 "pageGeometry",(
char *) NULL);
430 resource_value=XGetResourceInstance(resource_database,GetClientName(),
432 image_info->quality=StringToUnsignedLong(resource_value);
433 resource_value=XGetResourceInstance(resource_database,GetClientName(),
435 image_info->verbose=IsStringTrue(resource_value);
436 resource_value=XGetResourceInstance(resource_database,GetClientName(),
438 quantize_info->dither_method=IsStringTrue(resource_value) != MagickFalse ?
439 RiemersmaDitherMethod : NoDitherMethod;
444 for (i=1; ((i <= (ssize_t) argc) && ((state & ExitState) == 0)); i++)
446 if (i < (ssize_t) argc)
449 if (image != (Image *) NULL)
452 if (isatty(STDIN_FILENO) != MagickFalse || (nostdin != MagickFalse))
456 if (LocaleCompare(option,
"(") == 0)
458 FireImageStack(MagickFalse,MagickTrue,pend);
459 if (k == MaxImageStackDepth)
460 ThrowDisplayException(OptionError,
"ParenthesisNestedTooDeeply",
465 if (LocaleCompare(option,
")") == 0)
467 FireImageStack(MagickFalse,MagickTrue,MagickTrue);
469 ThrowDisplayException(OptionError,
"UnableToParseExpression",option);
473 if (IsCommandOption(option) == MagickFalse)
486 FireImageStack(MagickFalse,MagickFalse,pend);
488 if ((LocaleCompare(filename,
"--") == 0) && (i < (ssize_t) (argc-1)))
493 (void) CopyMagickString(image_info->filename,filename,MagickPathExtent);
494 images=ReadImage(image_info,exception);
495 CatchException(exception);
496 status&=(MagickStatusType) (images != (Image *) NULL) &&
497 (exception->severity < ErrorException);
498 if (images == (Image *) NULL)
500 AppendImageStack(images);
501 FinalizeImageSettings(image_info,image,MagickFalse);
502 iterations=image->iterations;
503 image_list=CloneImageList(image,exception);
504 if (image_list == (Image *) NULL)
505 ThrowDisplayException(ResourceLimitError,
"MemoryAllocationFailed",
506 GetExceptionMessage(errno));
507 display_image=image_list;
513 resource_info.quantum=1;
514 if (resource_info.window_id != (
char *) NULL)
519 status=XDisplayBackgroundImage(display,&resource_info,
520 display_image,exception);
521 if (status != MagickFalse)
523 state|=RetainColorsState;
526 if (GetNextImageInList(display_image) == (Image *) NULL)
538 if (resource_info.delay != 1)
539 display_image->delay=resource_info.delay;
540 nexus=XDisplayImage(display,&resource_info,argv,argc,
541 &display_image,&state,exception);
542 if (nexus == (Image *) NULL)
544 while ((nexus != (Image *) NULL) && ((state & ExitState) == 0))
549 if (nexus->montage != (
char *) NULL)
557 next=XDisplayImage(display,&resource_info,argv,argc,&nexus,
559 if ((next == (Image *) NULL) &&
560 (GetNextImageInList(nexus) != (Image *) NULL))
562 display_image=GetNextImageInList(nexus);
563 nexus=NewImageList();
567 if (nexus != display_image)
568 nexus=DestroyImageList(nexus);
572 }
while ((state & ExitState) == 0);
573 if (resource_info.write_filename != (
char *) NULL)
578 (void) CopyMagickString(display_image->filename,
579 resource_info.write_filename,MagickPathExtent);
580 (void) SetImageInfo(image_info,1,exception);
581 status&=(MagickStatusType) WriteImage(image_info,display_image,
587 if ((state & FormerImageState) != 0)
588 for (l=0; l < (ssize_t) resource_info.quantum; l++)
590 if (GetPreviousImageInList(display_image) == (Image *) NULL)
592 display_image=GetPreviousImageInList(display_image);
595 for (l=0; l < (ssize_t) resource_info.quantum; l++)
597 if (GetNextImageInList(display_image) == (Image *) NULL)
599 display_image=GetNextImageInList(display_image);
601 if (l < (ssize_t) resource_info.quantum)
603 }
while ((display_image != (Image *) NULL) && ((state & ExitState) == 0));
607 display_image=DestroyImageList(display_image);
608 if ((state & FormerImageState) == 0)
610 last_image=(size_t) image_number;
611 image_marker[i]=(size_t) image_number++;
618 for (i--; i > 0; i--)
619 if (image_marker[i] == (
size_t) (image_number-2))
623 if ((i == (ssize_t) argc) && ((state & ExitState) == 0))
625 if ((state & ExitState) != 0)
630 if (image_number < 0)
632 if ((state & FormerImageState) != 0)
635 for (i=1; i < (ssize_t) (argc-2); i++)
636 if (last_image == image_marker[i])
638 image_number=(ssize_t) image_marker[i]+1;
642 if (resource_info.window_id != (
char *) NULL)
646 if (++iteration == (ssize_t) iterations)
650 if (LocaleCompare(filename,
"-") == 0)
652 RemoveAllImageStack();
655 pend=image != (Image *) NULL ? MagickTrue : MagickFalse;
660 if (LocaleCompare(
"alpha",option+1) == 0)
668 if (i == (ssize_t) argc)
669 ThrowDisplayException(OptionError,
"MissingArgument",option);
670 type=ParseCommandOption(MagickAlphaChannelOptions,MagickFalse,
673 ThrowDisplayException(OptionError,
674 "UnrecognizedAlphaChannelOption",argv[i]);
677 if (LocaleCompare(
"antialias",option+1) == 0)
679 if (LocaleCompare(
"authenticate",option+1) == 0)
684 if (i == (ssize_t) argc)
685 ThrowDisplayException(OptionError,
"MissingArgument",option);
688 if (LocaleCompare(
"auto-level",option+1) == 0)
690 if (LocaleCompare(
"auto-orient",option+1) == 0)
692 ThrowDisplayException(OptionError,
"UnrecognizedOption",option);
696 if (LocaleCompare(
"backdrop",option+1) == 0)
698 resource_info.backdrop=(*option ==
'-') ? MagickTrue : MagickFalse;
701 if (LocaleCompare(
"background",option+1) == 0)
706 if (i == (ssize_t) argc)
707 ThrowDisplayException(OptionError,
"MissingArgument",option);
708 resource_info.background_color=argv[i];
711 if (LocaleCompare(
"border",option+1) == 0)
716 if (i == (ssize_t) argc)
717 ThrowDisplayException(OptionError,
"MissingArgument",option);
718 if (IsGeometry(argv[i]) == MagickFalse)
719 ThrowDisplayInvalidArgumentException(option,argv[i]);
722 if (LocaleCompare(
"bordercolor",option+1) == 0)
727 if (i == (ssize_t) argc)
728 ThrowDisplayException(OptionError,
"MissingArgument",option);
729 resource_info.border_color=argv[i];
732 if (LocaleCompare(
"borderwidth",option+1) == 0)
734 resource_info.border_width=0;
738 if (i == (ssize_t) argc)
739 ThrowDisplayException(OptionError,
"MissingArgument",option);
740 if (IsGeometry(argv[i]) == MagickFalse)
741 ThrowDisplayInvalidArgumentException(option,argv[i]);
742 resource_info.border_width=(
unsigned int)
743 StringToUnsignedLong(argv[i]);
746 ThrowDisplayException(OptionError,
"UnrecognizedOption",option);
750 if (LocaleCompare(
"cache",option+1) == 0)
755 if (i == (ssize_t) argc)
756 ThrowDisplayException(OptionError,
"MissingArgument",option);
757 if (IsGeometry(argv[i]) == MagickFalse)
758 ThrowDisplayInvalidArgumentException(option,argv[i]);
761 if (LocaleCompare(
"channel",option+1) == 0)
769 if (i == (ssize_t) argc)
770 ThrowDisplayException(OptionError,
"MissingArgument",option);
771 channel=ParseChannelOption(argv[i]);
773 ThrowDisplayException(OptionError,
"UnrecognizedChannelType",
777 if (LocaleCompare(
"clip",option+1) == 0)
779 if (LocaleCompare(
"clip-path",option+1) == 0)
782 if (i == (ssize_t) argc)
783 ThrowDisplayException(OptionError,
"MissingArgument",option);
786 if (LocaleCompare(
"coalesce",option+1) == 0)
788 if (LocaleCompare(
"colormap",option+1) == 0)
790 resource_info.colormap=PrivateColormap;
794 if (i == (ssize_t) argc)
795 ThrowDisplayException(OptionError,
"MissingArgument",option);
796 resource_info.colormap=UndefinedColormap;
797 if (LocaleCompare(
"private",argv[i]) == 0)
798 resource_info.colormap=PrivateColormap;
799 if (LocaleCompare(
"shared",argv[i]) == 0)
800 resource_info.colormap=SharedColormap;
801 if (resource_info.colormap == UndefinedColormap)
802 ThrowDisplayException(OptionError,
"UnrecognizedColormapType",
806 if (LocaleCompare(
"colors",option+1) == 0)
808 quantize_info->number_colors=0;
812 if (i == (ssize_t) argc)
813 ThrowDisplayException(OptionError,
"MissingArgument",option);
814 if (IsGeometry(argv[i]) == MagickFalse)
815 ThrowDisplayInvalidArgumentException(option,argv[i]);
816 quantize_info->number_colors=StringToUnsignedLong(argv[i]);
819 if (LocaleCompare(
"colorspace",option+1) == 0)
827 if (i == (ssize_t) argc)
828 ThrowDisplayException(OptionError,
"MissingArgument",option);
829 colorspace=ParseCommandOption(MagickColorspaceOptions,
830 MagickFalse,argv[i]);
832 ThrowDisplayException(OptionError,
"UnrecognizedColorspace",
836 if (LocaleCompare(
"comment",option+1) == 0)
841 if (i == (ssize_t) argc)
842 ThrowDisplayException(OptionError,
"MissingArgument",option);
845 if (LocaleCompare(
"compress",option+1) == 0)
853 if (i == (ssize_t) argc)
854 ThrowDisplayException(OptionError,
"MissingArgument",option);
855 compress=ParseCommandOption(MagickCompressOptions,MagickFalse,
858 ThrowDisplayException(OptionError,
"UnrecognizedImageCompression",
862 if (LocaleCompare(
"concurrent",option+1) == 0)
864 if (LocaleCompare(
"contrast",option+1) == 0)
866 if (LocaleCompare(
"crop",option+1) == 0)
871 if (i == (ssize_t) argc)
872 ThrowDisplayException(OptionError,
"MissingArgument",option);
873 if (IsGeometry(argv[i]) == MagickFalse)
874 ThrowDisplayInvalidArgumentException(option,argv[i]);
877 ThrowDisplayException(OptionError,
"UnrecognizedOption",option);
881 if (LocaleCompare(
"debug",option+1) == 0)
889 if (i == (ssize_t) argc)
890 ThrowDisplayException(OptionError,
"MissingArgument",option);
891 event=ParseCommandOption(MagickLogEventOptions,MagickFalse,argv[i]);
893 ThrowDisplayException(OptionError,
"UnrecognizedEventType",
895 (void) SetLogEventMask(argv[i]);
898 if (LocaleCompare(
"decipher",option+1) == 0)
903 if (i == (ssize_t) argc)
904 ThrowDisplayException(OptionError,
"MissingArgument",option);
907 if (LocaleCompare(
"define",option+1) == 0)
910 if (i == (ssize_t) argc)
911 ThrowDisplayException(OptionError,
"MissingArgument",option);
917 define=GetImageOption(image_info,argv[i]);
918 if (define == (
const char *) NULL)
919 ThrowDisplayException(OptionError,
"NoSuchOption",argv[i]);
924 if (LocaleCompare(
"delay",option+1) == 0)
929 if (i == (ssize_t) argc)
930 ThrowDisplayException(OptionError,
"MissingArgument",option);
931 if (IsGeometry(argv[i]) == MagickFalse)
932 ThrowDisplayInvalidArgumentException(option,argv[i]);
935 if (LocaleCompare(
"density",option+1) == 0)
940 if (i == (ssize_t) argc)
941 ThrowDisplayException(OptionError,
"MissingArgument",option);
942 if (IsGeometry(argv[i]) == MagickFalse)
943 ThrowDisplayInvalidArgumentException(option,argv[i]);
946 if (LocaleCompare(
"depth",option+1) == 0)
951 if (i == (ssize_t) argc)
952 ThrowDisplayException(OptionError,
"MissingArgument",option);
953 if (IsGeometry(argv[i]) == MagickFalse)
954 ThrowDisplayInvalidArgumentException(option,argv[i]);
957 if (LocaleCompare(
"deskew",option+1) == 0)
962 if (i == (ssize_t) argc)
963 ThrowDisplayException(OptionError,
"MissingArgument",option);
964 if (IsGeometry(argv[i]) == MagickFalse)
965 ThrowDisplayInvalidArgumentException(option,argv[i]);
968 if (LocaleCompare(
"despeckle",option+1) == 0)
970 if (LocaleCompare(
"display",option+1) == 0)
975 if (i == (ssize_t) argc)
976 ThrowDisplayException(OptionError,
"MissingArgument",option);
979 if (LocaleCompare(
"dispose",option+1) == 0)
987 if (i == (ssize_t) argc)
988 ThrowDisplayException(OptionError,
"MissingArgument",option);
989 dispose=ParseCommandOption(MagickDisposeOptions,MagickFalse,argv[i]);
991 ThrowDisplayException(OptionError,
"UnrecognizedDisposeMethod",
995 if (LocaleCompare(
"dither",option+1) == 0)
1000 quantize_info->dither_method=NoDitherMethod;
1004 if (i == (ssize_t) argc)
1005 ThrowDisplayException(OptionError,
"MissingArgument",option);
1006 method=ParseCommandOption(MagickDitherOptions,MagickFalse,argv[i]);
1008 ThrowDisplayException(OptionError,
"UnrecognizedDitherMethod",
1010 quantize_info->dither_method=(DitherMethod) method;
1013 if (LocaleCompare(
"duration",option+1) == 0)
1018 if (i == (ssize_t) argc)
1019 ThrowDisplayException(OptionError,
"MissingArgument",option);
1020 if (IsGeometry(argv[i]) == MagickFalse)
1021 ThrowDisplayInvalidArgumentException(option,argv[i]);
1024 ThrowDisplayException(OptionError,
"UnrecognizedOption",option);
1028 if (LocaleCompare(
"edge",option+1) == 0)
1033 if (i == (ssize_t) argc)
1034 ThrowDisplayException(OptionError,
"MissingArgument",option);
1035 if (IsGeometry(argv[i]) == MagickFalse)
1036 ThrowDisplayInvalidArgumentException(option,argv[i]);
1039 if (LocaleCompare(
"endian",option+1) == 0)
1047 if (i == (ssize_t) argc)
1048 ThrowDisplayException(OptionError,
"MissingArgument",option);
1049 endian=ParseCommandOption(MagickEndianOptions,MagickFalse,
1052 ThrowDisplayException(OptionError,
"UnrecognizedEndianType",
1056 if (LocaleCompare(
"enhance",option+1) == 0)
1058 if (LocaleCompare(
"equalize",option+1) == 0)
1060 if (LocaleCompare(
"extent",option+1) == 0)
1065 if (i == (ssize_t) argc)
1066 ThrowDisplayException(OptionError,
"MissingArgument",option);
1067 if (IsGeometry(argv[i]) == MagickFalse)
1068 ThrowDisplayInvalidArgumentException(option,argv[i]);
1071 if (LocaleCompare(
"extract",option+1) == 0)
1076 if (i == (ssize_t) argc)
1077 ThrowDisplayException(OptionError,
"MissingArgument",option);
1078 if (IsGeometry(argv[i]) == MagickFalse)
1079 ThrowDisplayInvalidArgumentException(option,argv[i]);
1082 ThrowDisplayException(OptionError,
"UnrecognizedOption",option);
1086 if (LocaleCompare(
"filter",option+1) == 0)
1094 if (i == (ssize_t) argc)
1095 ThrowDisplayException(OptionError,
"MissingArgument",option);
1096 filter=ParseCommandOption(MagickFilterOptions,MagickFalse,argv[i]);
1098 ThrowDisplayException(OptionError,
"UnrecognizedImageFilter",
1102 if (LocaleCompare(
"flatten",option+1) == 0)
1104 if (LocaleCompare(
"flip",option+1) == 0)
1106 if (LocaleCompare(
"flop",option+1) == 0)
1108 if (LocaleCompare(
"font",option+1) == 0)
1113 if (i == (ssize_t) argc)
1114 ThrowDisplayException(OptionError,
"MissingArgument",option);
1115 resource_info.font=XGetResourceClass(resource_database,
1116 GetClientName(),
"font",argv[i]);
1119 if (LocaleCompare(
"foreground",option+1) == 0)
1124 if (i == (ssize_t) argc)
1125 ThrowDisplayException(OptionError,
"MissingArgument",option);
1126 resource_info.foreground_color=argv[i];
1129 if (LocaleCompare(
"format",option+1) == 0)
1134 if (i == (ssize_t) argc)
1135 ThrowDisplayException(OptionError,
"MissingArgument",option);
1138 if (LocaleCompare(
"frame",option+1) == 0)
1143 if (i == (ssize_t) argc)
1144 ThrowDisplayException(OptionError,
"MissingArgument",option);
1145 if (IsGeometry(argv[i]) == MagickFalse)
1146 ThrowDisplayInvalidArgumentException(option,argv[i]);
1149 if (LocaleCompare(
"fuzz",option+1) == 0)
1154 if (i == (ssize_t) argc)
1155 ThrowDisplayException(OptionError,
"MissingArgument",option);
1156 if (IsGeometry(argv[i]) == MagickFalse)
1157 ThrowDisplayInvalidArgumentException(option,argv[i]);
1160 ThrowDisplayException(OptionError,
"UnrecognizedOption",option);
1164 if (LocaleCompare(
"gamma",option+1) == 0)
1167 if (i == (ssize_t) argc)
1168 ThrowDisplayException(OptionError,
"MissingArgument",option);
1169 if (IsGeometry(argv[i]) == MagickFalse)
1170 ThrowDisplayInvalidArgumentException(option,argv[i]);
1173 if (LocaleCompare(
"geometry",option+1) == 0)
1175 resource_info.image_geometry=(
char *) NULL;
1178 (void) CopyMagickString(argv[i]+1,
"sans",MagickPathExtent);
1180 if (i == (ssize_t) argc)
1181 ThrowDisplayException(OptionError,
"MissingArgument",option);
1182 if (IsGeometry(argv[i]) == MagickFalse)
1183 ThrowDisplayInvalidArgumentException(option,argv[i]);
1184 resource_info.image_geometry=ConstantString(argv[i]);
1187 if (LocaleCompare(
"gravity",option+1) == 0)
1195 if (i == (ssize_t) argc)
1196 ThrowDisplayException(OptionError,
"MissingArgument",option);
1197 gravity=ParseCommandOption(MagickGravityOptions,MagickFalse,
1200 ThrowDisplayException(OptionError,
"UnrecognizedGravityType",
1204 ThrowDisplayException(OptionError,
"UnrecognizedOption",option);
1208 if ((LocaleCompare(
"help",option+1) == 0) ||
1209 (LocaleCompare(
"-help",option+1) == 0))
1211 ThrowDisplayException(OptionError,
"UnrecognizedOption",option);
1215 if (LocaleCompare(
"identify",option+1) == 0)
1217 if (LocaleCompare(
"iconGeometry",option+1) == 0)
1219 resource_info.icon_geometry=(
char *) NULL;
1223 if (i == (ssize_t) argc)
1224 ThrowDisplayException(OptionError,
"MissingArgument",option);
1225 if (IsGeometry(argv[i]) == MagickFalse)
1226 ThrowDisplayInvalidArgumentException(option,argv[i]);
1227 resource_info.icon_geometry=argv[i];
1230 if (LocaleCompare(
"iconic",option+1) == 0)
1232 resource_info.iconic=(*option ==
'-') ? MagickTrue : MagickFalse;
1235 if (LocaleCompare(
"immutable",option+1) == 0)
1237 resource_info.immutable=(*option ==
'-') ? MagickTrue : MagickFalse;
1240 if (LocaleCompare(
"interlace",option+1) == 0)
1248 if (i == (ssize_t) argc)
1249 ThrowDisplayException(OptionError,
"MissingArgument",option);
1250 interlace=ParseCommandOption(MagickInterlaceOptions,MagickFalse,
1253 ThrowDisplayException(OptionError,
"UnrecognizedInterlaceType",
1257 if (LocaleCompare(
"interpolate",option+1) == 0)
1265 if (i == (ssize_t) argc)
1266 ThrowDisplayException(OptionError,
"MissingArgument",option);
1267 interpolate=ParseCommandOption(MagickInterpolateOptions,MagickFalse,
1269 if (interpolate < 0)
1270 ThrowDisplayException(OptionError,
"UnrecognizedInterpolateMethod",
1274 ThrowDisplayException(OptionError,
"UnrecognizedOption",option);
1278 if (LocaleCompare(
"label",option+1) == 0)
1283 if (i == (ssize_t) argc)
1284 ThrowDisplayException(OptionError,
"MissingArgument",option);
1287 if (LocaleCompare(
"limit",option+1) == 0)
1301 if (i == (ssize_t) argc)
1302 ThrowDisplayException(OptionError,
"MissingArgument",option);
1303 resource=ParseCommandOption(MagickResourceOptions,MagickFalse,
1306 ThrowDisplayException(OptionError,
"UnrecognizedResourceType",
1309 if (i == (ssize_t) argc)
1310 ThrowDisplayException(OptionError,
"MissingArgument",option);
1311 value=StringToDouble(argv[i],&p);
1313 if ((p == argv[i]) && (LocaleCompare(
"unlimited",argv[i]) != 0))
1314 ThrowDisplayInvalidArgumentException(option,argv[i]);
1317 if (LocaleCompare(
"list",option+1) == 0)
1325 if (i == (ssize_t) argc)
1326 ThrowDisplayException(OptionError,
"MissingArgument",option);
1327 list=ParseCommandOption(MagickListOptions,MagickFalse,argv[i]);
1329 ThrowDisplayException(OptionError,
"UnrecognizedListType",argv[i]);
1330 status=MogrifyImageInfo(image_info,(
int) (i-j+1),(
const char **)
1333 return(status == 0 ? MagickFalse : MagickTrue);
1335 if (LocaleCompare(
"log",option+1) == 0)
1340 if ((i == (ssize_t) argc) ||
1341 (strchr(argv[i],
'%') == (
char *) NULL))
1342 ThrowDisplayException(OptionError,
"MissingArgument",option);
1345 if (LocaleCompare(
"loop",option+1) == 0)
1350 if (i == (ssize_t) argc)
1351 ThrowDisplayException(OptionError,
"MissingArgument",option);
1352 if (IsGeometry(argv[i]) == MagickFalse)
1353 ThrowDisplayInvalidArgumentException(option,argv[i]);
1354 iterations=StringToUnsignedLong(argv[i]);
1357 ThrowDisplayException(OptionError,
"UnrecognizedOption",option);
1361 if (LocaleCompare(
"magnify",option+1) == 0)
1363 resource_info.magnify=2;
1367 if (i == (ssize_t) argc)
1368 ThrowDisplayException(OptionError,
"MissingArgument",option);
1369 if (IsGeometry(argv[i]) == MagickFalse)
1370 ThrowDisplayInvalidArgumentException(option,argv[i]);
1371 resource_info.magnify=(
unsigned int) StringToUnsignedLong(argv[i]);
1374 if (LocaleCompare(
"map",option+1) == 0)
1376 resource_info.map_type=(
char *) NULL;
1379 (void) CopyMagickString(argv[i]+1,
"...",strlen(argv[i]+1)+1);
1381 if (i == (ssize_t) argc)
1382 ThrowDisplayException(OptionError,
"MissingArgument",option);
1383 resource_info.map_type=argv[i];
1386 if (LocaleCompare(
"matte",option+1) == 0)
1388 if (LocaleCompare(
"mattecolor",option+1) == 0)
1393 if (i == (ssize_t) argc)
1394 ThrowDisplayException(OptionError,
"MissingArgument",option);
1395 resource_info.matte_color=argv[i];
1398 if (LocaleCompare(
"monitor",option+1) == 0)
1400 if (LocaleCompare(
"monochrome",option+1) == 0)
1404 quantize_info->number_colors=2;
1405 quantize_info->colorspace=GRAYColorspace;
1408 ThrowDisplayException(OptionError,
"UnrecognizedOption",option);
1412 if (LocaleCompare(
"name",option+1) == 0)
1414 resource_info.name=(
char *) NULL;
1418 if (i == (ssize_t) argc)
1419 ThrowDisplayException(OptionError,
"MissingArgument",option);
1420 resource_info.name=ConstantString(argv[i]);
1423 if (LocaleCompare(
"negate",option+1) == 0)
1425 if (LocaleCompare(
"noop",option+1) == 0)
1427 if (LocaleCompare(
"normalize",option+1) == 0)
1429 if (LocaleCompare(
"nostdin",option+1) == 0)
1431 ThrowDisplayException(OptionError,
"UnrecognizedOption",option);
1435 if (LocaleCompare(
"page",option+1) == 0)
1437 resource_info.image_geometry=(
char *) NULL;
1441 if (i == (ssize_t) argc)
1442 ThrowDisplayException(OptionError,
"MissingArgument",option);
1443 resource_info.image_geometry=ConstantString(argv[i]);
1446 if (LocaleCompare(
"profile",option+1) == 0)
1449 if (i == (ssize_t) argc)
1450 ThrowDisplayException(OptionError,
"MissingArgument",option);
1453 ThrowDisplayException(OptionError,
"UnrecognizedOption",option);
1457 if (LocaleCompare(
"quality",option+1) == 0)
1462 if (i == (ssize_t) argc)
1463 ThrowDisplayException(OptionError,
"MissingArgument",option);
1464 if (IsGeometry(argv[i]) == MagickFalse)
1465 ThrowDisplayInvalidArgumentException(option,argv[i]);
1468 if (LocaleCompare(
"quantize",option+1) == 0)
1476 if (i == (ssize_t) argc)
1477 ThrowDisplayException(OptionError,
"MissingArgument",option);
1478 colorspace=ParseCommandOption(MagickColorspaceOptions,
1479 MagickFalse,argv[i]);
1481 ThrowDisplayException(OptionError,
"UnrecognizedColorspace",
1485 if (LocaleCompare(
"quiet",option+1) == 0)
1487 ThrowDisplayException(OptionError,
"UnrecognizedOption",option);
1491 if (LocaleCompare(
"raise",option+1) == 0)
1494 if (i == (ssize_t) argc)
1495 ThrowDisplayException(OptionError,
"MissingArgument",option);
1496 if (IsGeometry(argv[i]) == MagickFalse)
1497 ThrowDisplayInvalidArgumentException(option,argv[i]);
1500 if (LocaleCompare(
"regard-warnings",option+1) == 0)
1502 if (LocaleCompare(
"remote",option+1) == 0)
1505 if (i == (ssize_t) argc)
1506 ThrowDisplayException(OptionError,
"MissingArgument",option);
1507 if (XRemoteCommand(display,resource_info.window_id,argv[i]) != 0)
1510 return(MagickFalse);
1515 if (LocaleCompare(
"repage",option+1) == 0)
1520 if (i == (ssize_t) argc)
1521 ThrowDisplayException(OptionError,
"MissingArgument",option);
1522 if (IsGeometry(argv[i]) == MagickFalse)
1523 ThrowDisplayInvalidArgumentException(option,argv[i]);
1526 if (LocaleCompare(
"resample",option+1) == 0)
1531 if (i == (ssize_t) argc)
1532 ThrowDisplayException(OptionError,
"MissingArgument",option);
1533 if (IsGeometry(argv[i]) == MagickFalse)
1534 ThrowDisplayInvalidArgumentException(option,argv[i]);
1537 if (LocaleCompare(
"resize",option+1) == 0)
1542 if (i == (ssize_t) argc)
1543 ThrowDisplayException(OptionError,
"MissingArgument",option);
1544 if (IsGeometry(argv[i]) == MagickFalse)
1545 ThrowDisplayInvalidArgumentException(option,argv[i]);
1548 if (LocaleNCompare(
"respect-parentheses",option+1,17) == 0)
1550 respect_parentheses=(*option ==
'-') ? MagickTrue : MagickFalse;
1553 if (LocaleCompare(
"roll",option+1) == 0)
1558 if (i == (ssize_t) argc)
1559 ThrowDisplayException(OptionError,
"MissingArgument",option);
1560 if (IsGeometry(argv[i]) == MagickFalse)
1561 ThrowDisplayInvalidArgumentException(option,argv[i]);
1564 if (LocaleCompare(
"rotate",option+1) == 0)
1567 if (i == (ssize_t) argc)
1568 ThrowDisplayException(OptionError,
"MissingArgument",option);
1569 if (IsGeometry(argv[i]) == MagickFalse)
1570 ThrowDisplayInvalidArgumentException(option,argv[i]);
1573 ThrowDisplayException(OptionError,
"UnrecognizedOption",option);
1577 if (LocaleCompare(
"sample",option+1) == 0)
1582 if (i == (ssize_t) argc)
1583 ThrowDisplayException(OptionError,
"MissingArgument",option);
1584 if (IsGeometry(argv[i]) == MagickFalse)
1585 ThrowDisplayInvalidArgumentException(option,argv[i]);
1588 if (LocaleCompare(
"sampling-factor",option+1) == 0)
1593 if (i == (ssize_t) argc)
1594 ThrowDisplayException(OptionError,
"MissingArgument",option);
1595 if (IsGeometry(argv[i]) == MagickFalse)
1596 ThrowDisplayInvalidArgumentException(option,argv[i]);
1599 if (LocaleCompare(
"scenes",option+1) == 0)
1604 if (i == (ssize_t) argc)
1605 ThrowDisplayException(OptionError,
"MissingArgument",option);
1606 if (IsSceneGeometry(argv[i],MagickFalse) == MagickFalse)
1607 ThrowDisplayInvalidArgumentException(option,argv[i]);
1610 if (LocaleCompare(
"seed",option+1) == 0)
1615 if (i == (ssize_t) argc)
1616 ThrowDisplayException(OptionError,
"MissingArgument",option);
1617 if (IsGeometry(argv[i]) == MagickFalse)
1618 ThrowDisplayInvalidArgumentException(option,argv[i]);
1621 if (LocaleCompare(
"segment",option+1) == 0)
1626 if (i == (ssize_t) argc)
1627 ThrowDisplayException(OptionError,
"MissingArgument",option);
1628 if (IsGeometry(argv[i]) == MagickFalse)
1629 ThrowDisplayInvalidArgumentException(option,argv[i]);
1632 if (LocaleCompare(
"set",option+1) == 0)
1635 if (i == (ssize_t) argc)
1636 ThrowDisplayException(OptionError,
"MissingArgument",option);
1640 if (i == (ssize_t) argc)
1641 ThrowDisplayException(OptionError,
"MissingArgument",option);
1644 if (LocaleCompare(
"sharpen",option+1) == 0)
1649 if (i == (ssize_t) argc)
1650 ThrowDisplayException(OptionError,
"MissingArgument",option);
1651 if (IsGeometry(argv[i]) == MagickFalse)
1652 ThrowDisplayInvalidArgumentException(option,argv[i]);
1655 if (LocaleCompare(
"shared-memory",option+1) == 0)
1657 resource_info.use_shared_memory= (*option ==
'-') ? MagickTrue :
1661 if (LocaleCompare(
"size",option+1) == 0)
1666 if (i == (ssize_t) argc)
1667 ThrowDisplayException(OptionError,
"MissingArgument",option);
1668 if (IsGeometry(argv[i]) == MagickFalse)
1669 ThrowDisplayInvalidArgumentException(option,argv[i]);
1672 if (LocaleCompare(
"strip",option+1) == 0)
1674 if (LocaleCompare(
"support",option+1) == 0)
1679 ThrowDisplayException(OptionError,
"UnrecognizedOption",option);
1683 if (LocaleCompare(
"text-font",option+1) == 0)
1685 resource_info.text_font=(
char *) NULL;
1689 if (i == (ssize_t) argc)
1690 ThrowDisplayException(OptionError,
"MissingArgument",option);
1691 resource_info.text_font=XGetResourceClass(resource_database,
1692 GetClientName(),
"font",argv[i]);
1695 if (LocaleCompare(
"texture",option+1) == 0)
1700 if (i == (ssize_t) argc)
1701 ThrowDisplayException(OptionError,
"MissingArgument",option);
1704 if (LocaleCompare(
"threshold",option+1) == 0)
1709 if (i == (ssize_t) argc)
1710 ThrowDisplayException(OptionError,
"MissingArgument",option);
1711 if (IsGeometry(argv[i]) == MagickFalse)
1712 ThrowDisplayInvalidArgumentException(option,argv[i]);
1715 if (LocaleCompare(
"thumbnail",option+1) == 0)
1720 if (i == (ssize_t) argc)
1721 ThrowDisplayException(OptionError,
"MissingArgument",option);
1722 if (IsGeometry(argv[i]) == MagickFalse)
1723 ThrowDisplayInvalidArgumentException(option,argv[i]);
1726 if (LocaleCompare(
"title",option+1) == 0)
1728 resource_info.title=(
char *) NULL;
1732 if (i == (ssize_t) argc)
1733 ThrowDisplayException(OptionError,
"MissingArgument",option);
1734 resource_info.title=argv[i];
1737 if (LocaleCompare(
"transparent-color",option+1) == 0)
1742 if (i == (ssize_t) argc)
1743 ThrowDisplayException(OptionError,
"MissingArgument",option);
1746 if (LocaleCompare(
"treedepth",option+1) == 0)
1748 quantize_info->tree_depth=0;
1752 if (i == (ssize_t) argc)
1753 ThrowDisplayException(OptionError,
"MissingArgument",option);
1754 if (IsGeometry(argv[i]) == MagickFalse)
1755 ThrowDisplayInvalidArgumentException(option,argv[i]);
1756 quantize_info->tree_depth=StringToUnsignedLong(argv[i]);
1759 if (LocaleCompare(
"trim",option+1) == 0)
1761 ThrowDisplayException(OptionError,
"UnrecognizedOption",option);
1765 if (LocaleCompare(
"update",option+1) == 0)
1767 resource_info.update=(
unsigned int) (*option ==
'-');
1771 if (i == (ssize_t) argc)
1772 ThrowDisplayException(OptionError,
"MissingArgument",option);
1773 if (IsGeometry(argv[i]) == MagickFalse)
1774 ThrowDisplayInvalidArgumentException(option,argv[i]);
1775 resource_info.update=(
unsigned int) StringToUnsignedLong(argv[i]);
1778 if (LocaleCompare(
"use-pixmap",option+1) == 0)
1780 resource_info.use_pixmap=(*option ==
'-') ? MagickTrue :
1784 ThrowDisplayException(OptionError,
"UnrecognizedOption",option);
1788 if (LocaleCompare(
"verbose",option+1) == 0)
1790 if ((LocaleCompare(
"version",option+1) == 0) ||
1791 (LocaleCompare(
"-version",option+1) == 0))
1793 ListMagickVersion(stdout);
1796 if (LocaleCompare(
"visual",option+1) == 0)
1798 resource_info.visual_type=(
char *) NULL;
1802 if (i == (ssize_t) argc)
1803 ThrowDisplayException(OptionError,
"MissingArgument",option);
1804 resource_info.visual_type=argv[i];
1807 if (LocaleCompare(
"virtual-pixel",option+1) == 0)
1815 if (i == (ssize_t) argc)
1816 ThrowDisplayException(OptionError,
"MissingArgument",option);
1817 method=ParseCommandOption(MagickVirtualPixelOptions,MagickFalse,
1820 ThrowDisplayException(OptionError,
1821 "UnrecognizedVirtualPixelMethod",argv[i]);
1824 ThrowDisplayException(OptionError,
"UnrecognizedOption",option);
1828 if (LocaleCompare(
"window",option+1) == 0)
1830 resource_info.window_id=(
char *) NULL;
1834 if (i == (ssize_t) argc)
1835 ThrowDisplayException(OptionError,
"MissingArgument",option);
1836 resource_info.window_id=argv[i];
1839 if (LocaleCompare(
"window-group",option+1) == 0)
1841 resource_info.window_group=(
char *) NULL;
1845 if (i == (ssize_t) argc)
1846 ThrowDisplayException(OptionError,
"MissingArgument",option);
1847 if (StringToDouble(argv[i],(
char **) NULL) != 0)
1848 resource_info.window_group=argv[i];
1851 if (LocaleCompare(
"write",option+1) == 0)
1853 resource_info.write_filename=(
char *) NULL;
1857 if (i == (ssize_t) argc)
1858 ThrowDisplayException(OptionError,
"MissingArgument",option);
1859 resource_info.write_filename=argv[i];
1860 if (IsPathAccessible(resource_info.write_filename) != MagickFalse)
1866 (void) FormatLocaleFile(stderr,
"Overwrite %s? ",
1867 resource_info.write_filename);
1868 p=fgets(answer,(
int)
sizeof(answer),stdin);
1870 if (((*answer !=
'y') && (*answer !=
'Y')))
1873 return(MagickFalse);
1878 ThrowDisplayException(OptionError,
"UnrecognizedOption",option);
1883 ThrowDisplayException(OptionError,
"UnrecognizedOption",option);
1885 fire=(GetCommandOptionFlags(MagickCommandOptions,MagickFalse,option) &
1886 FireOptionFlag) == 0 ? MagickFalse : MagickTrue;
1887 if (fire != MagickFalse)
1888 FireImageStack(MagickFalse,MagickTrue,MagickTrue);
1891 ThrowDisplayException(OptionError,
"UnbalancedParenthesis",argv[i]);
1892 if (state & RetainColorsState)
1894 XRetainWindowColors(display,XRootWindow(display,XDefaultScreen(display)));
1895 (void) XSync(display,MagickFalse);
1898 return(status != 0 ? MagickTrue : MagickFalse);
1900WandExport MagickBooleanType DisplayImageCommand(ImageInfo *image_info,
1901 int wand_unused(argc),
char **wand_unused(argv),
1902 char **wand_unused(metadata),ExceptionInfo *exception)
1904 wand_unreferenced(argc);
1905 wand_unreferenced(argv);
1906 wand_unreferenced(metadata);
1907 (void) ThrowMagickException(exception,GetMagickModule(),MissingDelegateError,
1908 "DelegateLibrarySupportNotBuiltIn",
"'%s' (X11)",image_info->filename);
1909 return(DisplayUsage());