ACO (.aco)

Background & Context

    • Adobe Photoshop color swatch format.
    • Used for storing color palettes.
    • Native format of the Adobe Photoshop image-editing application.
    • ACO is an acronym derived from Adobe Color.
    • Binary file format.
    • Stores color specifications and, in Version 2 of the format, color names.
    • Represents color values using 16 bits per color channel.
    • Supports a variety of color spaces.

Import & Export

  • Import["file.aco"] imports an ACO file as a list of color primitives.
  • Export["file.aco",expr] exports a list of colors or color rules to ACO.
  • Import["file.aco"] reads an ACO file and returns a list of color primitives, using exact numbers to represent color coordinates.
  • Export["file.aco",{col1,col2,}] exports a list of color primitives to ACO, using Version 1 of the format.
  • Export["file.aco",{"name"1->col1,}] creates an ACO Version 2 file from color rules.
  • Import["file.aco",elem] imports the specified element from an ACO file.
  • Import["file.aco",{elem,sub,}] imports a subelement.
  • Import["file.aco",{{elem1,elem2,}}] imports multiple elements.
  • The import format can be specified with Import["file","ACO"] or Import["file",{"ACO",elem,}].
  • Export["file.aco",expr, elem] creates an ACO file by treating expr as specifying element elem.
  • Export["file.aco",{expr1,expr2,},{{elem1,elem2,}}] treats each expri as specifying the corresponding elemi.
  • Export["file.aco",expr,opt1->val1,] exports expr with the specified option elements taken to have the specified values.
  • Export["file.aco",{elem1->expr1,elem2->expr2,},"Rules"] uses rules to specify the elements to be exported.
  • See the following reference pages for full general information:
  • Import, Exportimport from or export to a file
    CloudImport, CloudExportimport from or export to a cloud object
    ImportString, ExportStringimport from or export to a string
    ImportByteArray, ExportByteArrayimport from or export to a byte array

Import Elements

  • General Import elements:
  • "Elements" list of elements and options available in this file
    "Summary"summary of the file
    "Rules"list of rules for all available elements
  • Data representation elements:
  • "ColorList"list of color primitives
    "ColorRules"rules for named colors
    "ColorSetters"list of ColorSetter objects
  • Import by default uses the "ColorList" element.

Examples

Basic Examples  (2)

Read an ACO file that contains a palette of the 206 web-safe colors, and show the first few:

Import the same file as a list of ColorSetter objects:

Show all ColorSetter objects arranged in a grid: