]> granicus.if.org Git - imagemagick/commitdiff
...
authorCristy <urban-warrior@imagemagick.org>
Sat, 12 Nov 2016 00:46:11 +0000 (19:46 -0500)
committerCristy <urban-warrior@imagemagick.org>
Sat, 12 Nov 2016 00:46:11 +0000 (19:46 -0500)
MagickCore/property.c

index 39fcb8ce7a7080a4dbc04ef84530d41e454ca24d..39350d8127924caaee05bf8a441a644977dab381 100644 (file)
@@ -2792,6 +2792,13 @@ MagickExport const char *GetMagickProperty(ImageInfo *image_info,
             (void) ConcatenateMagickString(value,"a",MagickPathExtent);
           break;
         }
+      if (LocaleCompare("colors",property) == 0)
+        {
+          WarnNoImageReturn("\"%%[%s]\"",property);
+          (void) FormatLocaleString(value,MagickPathExtent,"%.20g",(double)
+            GetNumberColors(image,(FILE *) NULL,exception));
+          break;
+        }
       if (LocaleCompare("colorspace",property) == 0)
         {
           WarnNoImageReturn("\"%%[%s]\"",property);
@@ -2807,6 +2814,13 @@ MagickExport const char *GetMagickProperty(ImageInfo *image_info,
             image->compose);
           break;
         }
+      if (LocaleCompare("compression",property) == 0)
+        {
+          WarnNoImageReturn("\"%%[%s]\"",property);
+          string=CommandOptionToMnemonic(MagickCompressOptions,(ssize_t)
+            image->compression);
+          break;
+        }
       if (LocaleCompare("copyright",property) == 0)
         {
           (void) CopyMagickString(value,GetMagickCopyright(),MagickPathExtent);
@@ -2886,6 +2900,13 @@ MagickExport const char *GetMagickProperty(ImageInfo *image_info,
           string=image->filename;
           break;
         }
+      if (LocaleCompare("interlace",property) == 0)
+        {
+          WarnNoImageReturn("\"%%[%s]\"",property);
+          string=CommandOptionToMnemonic(MagickInterlaceOptions,(ssize_t)
+            image->interlace);
+          break;
+        }
       break;
     }
     case 'k':
@@ -3031,8 +3052,26 @@ MagickExport const char *GetMagickProperty(ImageInfo *image_info,
         }
       break;
     }
+    case 'q':
+    {
+      if (LocaleCompare("quality",property) == 0)
+        {
+          WarnNoImageReturn("\"%%[%s]\"",property);
+          (void) FormatLocaleString(value,MagickPathExtent,"%.*g",
+            GetMagickPrecision(),(double) image->quality);
+          break;
+        }
+      break;
+    }
     case 'r':
     {
+      if (LocaleCompare("rendering-intent",property) == 0)
+        {
+          WarnNoImageReturn("\"%%[%s]\"",property);
+          string=CommandOptionToMnemonic(MagickIntentOptions,(ssize_t)
+            image->rendering_intent);
+          break;
+        }
       if (LocaleCompare("resolution.x",property) == 0)
         {
           WarnNoImageReturn("\"%%[%s]\"",property);