<doc>
  <legacy_id></legacy_id>
  <name>imageCacheLimit</name>
  <type>property</type>
  <syntax>
    <example>set the imageCacheLimit to <i>theCacheLimit</i></example>
    <example>get the imageCacheLimit</example>
  </syntax>
  <library></library>
  <objects>
    <global/>
  </objects>
  <synonyms>
  </synonyms>
  <classification>
  </classification>
  <references>
    <property tag="alwaysBuffer">alwaysBuffer Property</property>
    <property tag="imageCacheUsage">imageCacheUsage Property</property>
    <command tag="prepare image">prepare image Command</command>
  </references>
  <history>
    <introduced version="6.0.0">Added.</introduced>
  </history>
  <platforms>
    <mac/>
    <windows/>
    <linux/>
    <ios/>
    <android/>
  </platforms>
  <classes>
    <desktop/>
    <server/>
    <web/>
    <mobile/>
  </classes>
  <security>
  </security>
  <summary>Sets the size of memory that is used to cache all decompressed image data.</summary>
  <examples>
    <example>set the imageCacheLimit to 33554432</example>
    <example>get the imageCacheLimit</example>
  </examples>
  <description>
    <p>Use the <b>imageCacheLimit</b> to specify how much memory should be used to cache all decompressed image data. The default limit for mobile devices is 67108864 byte (64 MB) and 268435456 byte (256 MB) for all other platforms.</p><p/><p>In the event of running out or memory, the image cache operates a least-recently-used policy. This means that if an image needs to be decompressed and there is not sufficient cache space, then the images that have not been used for the longest time are discarded until there is sufficient space to add the new image.</p><p/><p>If an image has the <property tag="alwaysBuffer">alwaysBuffer</property> property set to true, then it is decompressed into the cache on card open. Images are processed from lowest layer to highest. If the number of images with the <property tag="alwaysBuffer">alwaysBuffer</property> property set to true exceed the cache size, then images on lower layers are removed from the cache before images higher up the layers.</p><p/><p>An image can be forced to be cached by using the <command tag="prepare image">prepare image</command> command.</p><p/><p>The image cache is keyed on the absolute filename of image thus it is highly efficient to use image objects referencing the same filename, rather than buttons referencing icons. In particular, there is only one decompressed set of image data for a given (absolute) filename in the cache at any one time.</p><p/><p><b>Note:</b> The transformed image data of rotated and scaled images is cached, but images do not share this transformed data.</p><p/>
  </description>
</doc>



