Adobe.com
Contents Suites Classes Class Index Member Index

AIFileFormat.h File Reference

#include "AITypes.h"
#include "AIPlugin.h"
#include "AIArt.h"
#include "AIPlaced.h"
#include "AIEntry.h"
#include "IAIFilePath.hpp"
#include "AIArtboardRange.h"
#include "AIActionManager.h"
#include "AIHeaderBegin.h"
#include "AIHeaderEnd.h"

Go to the source code of this file.

Classes

struct  PlatformAddFileFormatData4
 Legacy structure for kAIFileFormatVersion4. More...
struct  PlatformAddFileFormatData
 Information needed to add a file format. More...
struct  PlatformAddFileFormatExData
 Information needed to add a file format. More...
struct  AICreatorTypePair
 A Mac OS file creator/type pair. More...
union  FileFormatExtUnion
 Union of extended file format datatypes. More...
struct  FileFormatExtData
 Extended file format message data. More...
struct  AIFileFormatMessage
 Message data sent by the file format selectors. More...
struct  AIUpdateFileFormatMessage
 Obsolete - linked raster art is now implemented as placed art. More...
struct  AILinkUpdateNotifyData
 Notification data sent with the kAIFileFormatLinkUpdateNotifier. More...
struct  AIFileFormatSuite
 This suite provides functions for creating and managing file-format plug-ins, which extend the number of file formats that Illustrator can read and write. More...
struct  AIMacFileFormatSuite

Defines

#define kAIFileFormatSuite   "AI File Format Suite"
#define kAIFileFormatSuiteVersion14   AIAPI_VERSION(14)
#define kAIFileFormatSuiteVersion   kAIFileFormatSuiteVersion14
#define kAIFileFormatVersion   kAIFileFormatSuiteVersion
#define kAIMacFileFormatSuite   "AI Mac File Format Suite"
#define kAIMacFileFormatSuiteVersion   AIAPI_VERSION(4)
#define kAIMacFileFormatVersion   kAIMacFileFormatSuiteVersion
#define kCallerAIFileFormat   "AI File Format"
 The file format caller.
#define kSelectorAIGetFileFormatParameters   "AI Get Parameters"
 Sent to file format plug-ins to allow the plug-in to show any dialogs necessary to gather parameters.
#define kSelectorAISetFileFormatParameters   "AI Set Parameters"
 Sent to file format plug-ins to allow the plug-in to customize import/export based on client provided options.
#define kSelectorAIGoFileFormat   "AI Go"
 Sent to file format plug-ins to execute the read or write operation.
#define kSelectorAICheckFileFormat   "AI Check"
 Sent to file format plug-ins after the user has selected a file, to allow a reader to open the file and check for header information in order to verify that it can be opened.
#define kSelectorAIUpdateFileFormat   "AI Update AI140"
 Obsolete.
#define kAIFileFormatDocumentOpenedNotifier   "AI File Format Document Opened Notifier"
 If a notifier plug-in requests this type of notification, it receives this selector when any open-file action has been completed.
#define kAIFileFormatLinkUpdateNotifier   "AI File Format Link Update Notifier"
 If a notifier plug-in requests this type of notification, it receives this selector when Illustrator cannot find a linked file for the current document.
#define kFileFormatWritePalettesOnly   (kFileFormatWriteSwatchLibrary|kFileFormatWriteBrushLibrary|kFileFormatWriteStyleLibrary|kFileFormatWriteSymbolLibrary)
 Used internally to test for matches to any of the options indicating that only specific palettes should be written.
#define kFileFormatExtensionStrMaxLength   31
 Maximum length of the extension string in PlatformAddFileFormatData.
#define kFileFormatExtMaxLength   5
 Maximum length for each extension within the extension string in PlatformAddFileFormatData.
#define kUnknownFormatErr   'FMT?'
 Plug-in file format does not recognize the file type.
#define kInvalidFormatErr   'FMTi'
 Plug-in file format recognizes the file type but explicitly disallows processing it with the options specified.
#define kBadResolutionErr   'RES!'
 Plug-in file format could not complete the operation at current resolution, either because the resolution is invalid or its too high.

Typedefs

typedef struct
_t_AIFileFormatOpaque * 
AIFileFormatHandle
 Opaque reference to a file format.

Enumerations

enum  AIFileFormatOptions {
  kFileFormatRead = (1<<0), kFileFormatExport = (1<<1), kFileFormatWrite = (1<<9), kFileFormatImportArt = (1<<2),
  kFileFormatPlaceArt = (1<<3), kFileFormatConvertTemplate = (1<<7), kFileFormatLinkArt = (1<<8), kFileFormatImportStyles = (1<<4),
  kFileFormatSuppliesPrintRecordOption = (1<<5), kFileFormatIsDefaultOption = (1<<6), kFileFormatNoAutoCheckFormat = (1<<10), kFileFormatCreateTemplateLayer = (1<<11),
  kFileFormatHasExtendedData = (1<<12), kFileFormatSkipStartupObjectsOption = (1<<13), kFileFormatNoWarningOption = (1<<14), kFileFormatSaveCopyOption = (1<<15),
  kFileFormatExportSelection = (1 << 16), kFileFormatBatchExport = (1 << 17), kFileFormatSuppressPluginFileNameUniquify = (1 << 18), kFileFormatSuppressUI = (1<<21),
  kFileFormatWriteAs = (1<<22), kFileFormatCheckAlways = (1<<23), kFileFormatContainsPartialParameters = (1<<24), kFileFormatImportCompositeFonts = (1<<25),
  kFileFormatOpenUntitledCopy = (1<<26), kFileFormatWriteSwatchLibrary = (1<<27), kFileFormatWriteBrushLibrary = (1<<28), kFileFormatWriteStyleLibrary = (1<<29),
  kFileFormatWriteSymbolLibrary = (1<<30), kFileFormatWriteInTouch = (1<<31)
}
 

These options specify the capabilities of a file format plug-in.

More...
enum  AIFileFormatPriority { kAIFileFormatPriorityNative = 10000, kAIFileFormatPriorityNormal = 0, kAIFileFormatPriorityLowest = -10000 }
 

File format priorities, which determine the order in which Illustrator searches through formats in deciding which one to use to open a file.

More...
enum  eFFExtType { kFFExtNone, kFFExtPlaceRequest, kFFExtAdditionalOptions }
 

Selector for extended file format datatype.

More...
enum  AIFFExtendedOptions { kNoExtendedOptions = (0), kSaveMultiArtboards = (1<<0), kDoNotExitTextEditingModeOption = ( 1 << 1), kFileFormatPlaceInTouch = (1<<2) }
 

Extended options of various file formats.

More...
enum  eFFOperationOptions { kSaveMultiArtboardsSelected = (1<<0) }
 

The flags passed by the application to the plugins in the AIFileFormatMessage.

More...
enum  eLinkUpdateType { kNormalUpdate, kLinkReplaced, kMissingLinkIgnored }
 

The type of link update that triggered the kAIFileFormatLinkUpdateNotifier.

More...
enum  AIDocumentStartupProfile {
  kAIStartupProfileUnknown = 0, kAIStartupProfilePrint = 1, kAIStartupProfileWeb, kAIStartupProfileVideo,
  kAIStartupProfileCMYK, kAIStartupProfileRGB, kAIStartupProfileMobile
}
 

Document startup profile types, returned by AIDocumentSuite::GetDocumentStartupProfile() and AIFileFormatSuite::GetFileStartupProfileType().

More...

Detailed Description


Define Documentation

#define kAIFileFormatSuite   "AI File Format Suite"
#define kAIFileFormatSuiteVersion   kAIFileFormatSuiteVersion14
#define kAIFileFormatSuiteVersion14   AIAPI_VERSION(14)
#define kAIFileFormatVersion   kAIFileFormatSuiteVersion
#define kAIMacFileFormatSuite   "AI Mac File Format Suite"
#define kAIMacFileFormatSuiteVersion   AIAPI_VERSION(4)
#define kAIMacFileFormatVersion   kAIMacFileFormatSuiteVersion
#define kFileFormatExtensionStrMaxLength   31

Maximum length of the extension string in PlatformAddFileFormatData.

#define kFileFormatExtMaxLength   5

Maximum length for each extension within the extension string in PlatformAddFileFormatData.

#define kFileFormatWritePalettesOnly   (kFileFormatWriteSwatchLibrary|kFileFormatWriteBrushLibrary|kFileFormatWriteStyleLibrary|kFileFormatWriteSymbolLibrary)

Used internally to test for matches to any of the options indicating that only specific palettes should be written.


Typedef Documentation

typedef struct _t_AIFileFormatOpaque* AIFileFormatHandle

Opaque reference to a file format.

Never dereferenced. Use the functions in AIFileFormatSuite to access it.


Enumeration Type Documentation

Document startup profile types, returned by AIDocumentSuite::GetDocumentStartupProfile() and AIFileFormatSuite::GetFileStartupProfileType().

Enumerator:
kAIStartupProfileUnknown 
kAIStartupProfilePrint 
kAIStartupProfileWeb 
kAIStartupProfileVideo 
kAIStartupProfileCMYK 
kAIStartupProfileRGB 
kAIStartupProfileMobile 

Extended options of various file formats.

Enumerator:
kNoExtendedOptions 
kSaveMultiArtboards 
kDoNotExitTextEditingModeOption 

Used internally to request app not to exit "Text Editing Mode" before calling this File format plugin for save/export.

kFileFormatPlaceInTouch 

Read the file and embed artwork to the current document.

Use when adding a format, this option should be added if this format can be placed in touch workspace.

These options specify the capabilities of a file format plug-in.

A subset of options are used with AIFileFormatSuite::AddFileFormat() to specify which operations are supported, and are also sent in the AIFileFormatMessage to indicate the requested action. Additional options can be set in the Go selector message to provide more information about the requested operation.

Note:
The read, embed (import/place), and link operations are very similar in execution. In all cases, Illustrator creates an empty artwork and send the plug-in a message to read the file into the artwork. Special handling is required only if the plug-in needs to do different things depending on the type of operation; for example the Photoshop file format plug-in has options for preserving Photoshop's layers if it is not linking.
Enumerator:
kFileFormatRead 

Read the file, creating artwork in a new document.

The format is included in the File > Open file types. Use when adding a format.

kFileFormatExport 

Write the documents contents to a file in a non-Illustrator format.

The format is included in the File > Export file types. Use when adding a format.

kFileFormatWrite 

Write the documents contents to a file in a format from which is can be read back into Illustrator without loss of data.

The format is included in the File > Save As file types. Use when adding a format.

kFileFormatImportArt 

Read the file and embed artwork to the current document.

The format is included in the File > Import file types. Use when adding a format.

kFileFormatPlaceArt 

Read the file and embed artwork to the current document.

This is the same as kFileFormatImportArt. Use when adding a format.

kFileFormatConvertTemplate 

Allows "Template" to be checked in the Place dialog when linking or embedding a file of this type, so the art is placed in a template layer.

Use when adding a format.

kFileFormatLinkArt 

Make a link from the contents of a file to an Illustrator document.

Use when adding a format.

kFileFormatImportStyles 

Not used.

kFileFormatSuppliesPrintRecordOption 

When reading, the plug-in sets the print record.

See AIDocumentSuite::SetDocumentPrintRecord(). Use when adding a format.

kFileFormatIsDefaultOption 

Makes this the default format for all documents.

If specified by more than one plug-in, the last one becomes the default. Use when adding a format.

kFileFormatNoAutoCheckFormat 

The plug-in will not respond to the kSelectorAICheckFileFormat selector.

(For example, the PhotoShop adapter plug-in always returns kNoErr.) Use when adding a format.

kFileFormatCreateTemplateLayer 

Read the file, creating artwork in a new template layer in the current document.

Not used for adding a format.

kFileFormatHasExtendedData 

Handle the extended data passed in a Go message for a placement request or in the Set Parameters message for additional options.

Use when adding a format.

kFileFormatSkipStartupObjectsOption 

This file format supplies its own startup objects (colors, patterns, and so on), Illustrator does not copy the startup file Use when adding a format.

kFileFormatNoWarningOption 

Disable warning dialogs upon read and write.

Not used for adding a format.

kFileFormatSaveCopyOption 

Write the current document to a copy of the file it was loaded from.

Not used for adding a format.

kFileFormatExportSelection 

Write the contents of selected artwork in a document to a file in a non-Illustrator format.

The format is included in the File > Export Selection file types. Use when adding a format.

kFileFormatBatchExport 

Enables Batch Export mode which prevents certain actions like: 1.

Prevent individual file format plugins from showing File Replace Dialog. 2. Prevent individual file format plugins to add exported files to Recent File Menu Items. Not used when adding a format.

kFileFormatSuppressPluginFileNameUniquify 

Prevent a file format plugin from uniquifying file name.

Not used when adding a format.

kFileFormatSuppressUI 

Prevents this file format from appearing in the file selection menu of the Open, Place, Save and Export dialogs.

Use when adding a format.

kFileFormatWriteAs 

Set in combination with kFileFormatWrite for a Save As operation, to distinguish it from Save.

Not used for adding a format.

kFileFormatCheckAlways 

Always receive the Check message, even for operations this plug-in does not support.

Allows an opportunity to explicitly reject operations on files matching this plug-in's type. Use when adding a format.

kFileFormatContainsPartialParameters 

Handle additional parameters passed in AIFileFormatMessage::actionParm.

These supplement the usual parameters of the file format, and may not be complete. Can be used, for instance, for scripting or optimizing.

If set in the Go message for a plug-in that does not handle the option, you can ignore it. Not used for adding a format.

kFileFormatImportCompositeFonts 

Import only the SLO composite fonts.

Do not import artwork or other global objects, and do not perform font fauxing. Not used for adding a format.

kFileFormatOpenUntitledCopy 

Treat the file as stationary--that is, open a copy with an Untitled name.

Use only in conjunction with kFileFormatRead Not used for adding a format.

kFileFormatWriteSwatchLibrary 

An option for the native (PGF) AI File Format Writer, telling it to write out only the indicated palettes and the global objects, directly or indirectly.

Not used for adding a format.

kFileFormatWriteBrushLibrary 

An option for the native (PGF) AI File Format Writer, telling it to write out only the indicated palettes and the global objects, directly or indirectly.

Not used for adding a format.

kFileFormatWriteStyleLibrary 

An option for the native (PGF) AI File Format Writer, telling it to write out only the indicated palettes and the global objects, directly or indirectly.

Not used for adding a format.

kFileFormatWriteSymbolLibrary 

An option for the native (PGF) AI File Format Writer, telling it to write out only the indicated palettes and the global objects, directly or indirectly.

Not used for adding a format.

kFileFormatWriteInTouch 

Write the documents contents to a file in a format from which it can be read back into Illustrator without loss of data.

The format should be added if this format can be saved in touch workspace. Use when adding a format.

File format priorities, which determine the order in which Illustrator searches through formats in deciding which one to use to open a file.

The first format found that handles a file type is used to open the file.

See also:
AIFileFormatSuite::SetFileFormatPriority()
Enumerator:
kAIFileFormatPriorityNative 

Highest priority.

kAIFileFormatPriorityNormal 

Normal priority.

This is the value assigned when a file format is added.

kAIFileFormatPriorityLowest 

Lowest priority.

enum eFFExtType

Selector for extended file format datatype.

Enumerator:
kFFExtNone 
kFFExtPlaceRequest 
kFFExtAdditionalOptions 

The flags passed by the application to the plugins in the AIFileFormatMessage.

Enumerator:
kSaveMultiArtboardsSelected 

The type of link update that triggered the kAIFileFormatLinkUpdateNotifier.

Enumerator:
kNormalUpdate 

Perform a normal update.

Sent when illustrator detects that a linked file inside an artboard has been updated by an external program.

kLinkReplaced 

The link that pointed to a missing file was changed to point to a new file.

kMissingLinkIgnored 

A link points to a missing file, and has not been changed.



Contents Suites Classes Class Index Member Index
Adobe Solutions Network
 
Copyright © 2016 Adobe Systems Incorporated. All rights reserved.
Terms of Use Online Privacy Policy Adobe and accessibility Avoid software piracy Permissions and Trademarks