Adobe.com
Contents Suites Classes Class Index Member Index

AITypes.h File Reference

#include "./config/AIConfig.h"
#include <exception>
#include "AIBasicTypes.h"
#include "AIErrorCodes.h"
#include "ASTypes.h"
#include "ADMStdTypes.h"
#include "AIWinDef.h"
#include "SPFiles.h"
#include "SPPlugs.h"
#include "AIHeaderBegin.h"
#include "AIHeaderEnd.h"

Go to the source code of this file.

Classes

struct  AIRGBColor
 Opaque RGB color, access with AIColorConversionSuite. More...
struct  _t_AIEvent
 Event information structure, used by AIToolSuite, AICursorSnapSuite. More...
struct  AISize
class  ai::Error
 Exception class thrown by C++ classes. More...
class  ai::LogicError
struct  ai::CompileTimeChecker< bool >
 Provides compile-time errors that are similar to run-time assertions. More...
struct  ai::CompileTimeChecker< false >
 There is no instantiation of CompileTimeChecker for a false value. More...

Namespaces

namespace  ai
 

Usage:.


Defines

#define kPluginInterfaceVersion6001   0x06000001
#define kPluginInterfaceVersion6002   0x06000020
#define kPluginInterfaceVersion7001   0x07000001
#define kPluginInterfaceVersion6021   0x06000021
#define kPluginInterfaceVersion8001   0x08000001
#define kPluginInterfaceVersion9001   0x09000001
#define kPluginInterfaceVersion10001   0x10000001
#define kPluginInterfaceVersion11001   0x11000001
#define kPluginInterfaceVersion12001   0x12000001
#define kPluginInterfaceVersion13001   0x13000001
#define kPluginInterfaceVersion14001   0x14000001
#define kPluginInterfaceVersion15001   0x15000001
#define kPluginInterfaceVersion16001   0x16000001
#define kPluginInterfaceVersion17001   0x17000001
#define kPluginInterfaceVersion17011   0x17000011
#define kPluginInterfaceVersion18001   0x18000001
#define kPluginInterfaceVersion18011   0x18000011
#define kPluginInterfaceVersion19001   0x19000001
#define kPluginInterfaceVersion19021   0x19000021
#define kPluginInterfaceVersion20001   0x20000001
#define kPluginInterfaceVersion20011   0x20000011
#define kPluginInterfaceVersion21001   0x21000001
#define kPluginInterfaceVersion21011   0x21000011
#define kPluginInterfaceVersion22001   0x22000001
#define kPluginInterfaceVersion22011   0x22000011
#define kPluginInterfaceVersion23001   0x23000001
#define kPluginInterfaceVersion23011   0x23000011
#define kPluginInterfaceVersion24001   0x24000001
#define kPluginInterfaceVersion24011   0x24000011
#define kPluginInterfaceVersion24021   0x24000021
#define kPluginInterfaceVersion24031   0x24000031
#define kPluginInterfaceVersion25001   0x25000001
#define kPluginInterfaceVersion   kPluginInterfaceVersion25001
#define AIAPI_VERSION(x)   (x + 1000)
#define AIAPI_VERSION(x)   (x)
#define kPlatformUnloadedSuiteProc   nullptr
#define PUSH_GLOBALS
#define POP_GLOBALS
#define Macintosh   1
#define MSWindows   1
#define kCanceledErr   'STOP'
 Operation canceled by user.
#define kNoDocumentErr   'DOC?'
 No current document.
#define kSelectorClashErr   'CLSH'
 A selector was called at an inappropriate time.
#define kNameNotFoundErr   'NAM?'
 Specified name not found.
#define kNameInUseErr   'NAM2'
 Specified name not unique.
#define kInvalidNameErr   'NA*!'
 Specified name not valid.
#define kNameTooLongErr   'NAL!'
 Specified name too long.
#define kUndoRedoErr   'UND!'
 Undo/Redo Can't be done properly.
#define kAIInvalidArtBoundsErr   'IABD'
 Art bounds are invalid.
#define kAIResourcePermissionErr   '!PRM'
 Resource Permission error.
#define kImageTooBigError   '!I2B'
#define AI_THREAD_SAFE_API
#define AI_MAIN_THREAD_API
#define AIAPI   AI_MAIN_THREAD_API
#define AINOEXCEPT
#define AINOTHROW
 This macro is used to decorate C++ functions and methods that are guaranteed not to throw.
#define AI_STATIC_CHECK(expr, msg)
 Use to instantiate a CompileTimeChecker object for an expression.

Typedefs

typedef struct ArtObject * AIArtHandle
 Opaque reference to an art object.
typedef struct ArtObject * ConstAIArtHandle
typedef struct _t_AISafeArtOpaque * AISafeArtHandle
 Opaque reference to an Safe Art Handle.
typedef struct _t_AILayerOpaque * AILayerHandle
 Opaque reference to a layer.
typedef struct _t_AIDocument * AIDocumentHandle
 Opaque reference to a document.
typedef ASFixed AIFixed
 Fixed number (obsolete) See AIFixedMathSuite.
typedef ASFract AIFract
 A fractional number greater than -2 and less than 2.
typedef ai::uint32 AIUFract
 An unsigned fractional number greater than 0 and less than 4.
typedef AIReal * AIRealPtr
typedef struct _t_AIStreamOpaque * AIStream
 Data stream.
typedef ASFixedRect AIFixedRect
 Rectangle specified with AIFixed coordinates.
typedef ASFixedPoint AIFixedPoint
 Point specified with AIFixed coordinates.
typedef ASFixedMatrix AIFixedMatrix
 Transformation matrix specified with AIFixed values.
typedef ASRealMatrix AIFloatMatrix
typedef ASRealPoint AIFloatPoint
typedef ASByte AIBool8
 Transformation matrix specified with AIReal values.
typedef struct
_t_AIPlatformViewOpaque * 
AIPlatformViewRef
 Opaque reference to a Platform View, NSView* on Mac and HWND on Windows .
typedef struct MacPort_t * AIPortRef
 Port reference, Mac OS only, same as Mac OS CGrafPtr.
typedef struct MacWindow_t * AIWindowRef
 Window reference, Mac OS only, same as Mac OS WindowPtr.
typedef struct MacDialog_t * AIDialogRef
 Dialog reference, Mac OS only, same as Mac OS DialogPtr.
typedef struct _t_AIEvent AIEvent
 Event information structure, used by AIToolSuite, AICursorSnapSuite.
typedef ASErr AIErr
 Opaque error, returned by most suite functions.
typedef ACEProfile * AIColorProfile
 Opaque color profile.
typedef ai::uint32 AICommandID
 An Illustrator menu command identifier.
typedef struct ZREFStruct * ZRef
 A ZString (localizable string) reference.
typedef enum ai::Quadrant ai::Quadrant

Enumerations

enum  AIPaintOrder {
  kPlaceDefault = 0, kPlaceAbove = 1, kPlaceBelow, kPlaceInsideOnTop,
  kPlaceInsideOnBottom, kPlaceAboveAll, kPlaceBelowAll
}
 

The position of an art object, which determines how it is drawn relative to another, overlapping art object, known as the prep (prepositional) object, and also whether a path is inside a compound path or group.

More...
enum  AIPaintUsage { kAINotUsed = 0x0000, kAIUsedOnFill = 0x0001, kAIUsedOnStroke = 0x0002, kAIUsedOnBoth = 0x0003 }
 

How paint is applied--to fills, strokes, or both.

More...
enum  ai::Quadrant { ai::kFirstQuadrant = 1, ai::kSecondQuadrant, ai::kThirdQuadrant, ai::kFourthQuadrant }
enum  ai::IconType { ai::kInvalid = 0, ai::kSVG, ai::kPNG }
 

Icon Types to be given by clients.

More...
enum  AIVersion {
  kAIVersion1 = 1, kAIVersion88, kAIVersion3, kAIVersion4,
  kAIVersion5, kAIVersion6, kAIVersion7, kAIVersion8,
  kAIVersion9, kAIVersion10, kAIVersion11, kAIVersion12,
  kAIVersion13, kAIVersion14, kAIVersion15, kAIVersion16,
  kAIVersion17, kAIVersion18, kAIVersion19, kAIVersion20,
  kAIVersion21, kAIVersion22, kAIVersion23, kAIVersion24,
  kAIVersion25, kAIVersionLatest = kAIVersion25
}
 

These constants identify the various shipping versions of Illustrator.

More...
enum  AIUnits {
  kAINoUnits = 0, kAIPointUnits = 1, kAIInchUnits = 2, kAIMillimeterUnits = 3,
  kAICentimeterUnits = 4, kAIPicaUnits = 5, kAIPercentUnits = 6, kAIDegreeUnits = 7,
  kAIQUnits = 8, kAIBase16Units = 9, kAIPixelUnits = 10, kAITimeUnits = 11,
  kAIFeetUnits = 12, kAIHaUnits = 13, kAIFeetInchUnits = 14, kAIMeterUnits = 15,
  kAIYardUnits = 16, kAIMinNormalUnits = kAIPointUnits, kAIMaxNormalUnits = kAIYardUnits, kAIAppUnits1 = 101,
  kAIAppUnits2 = 102, kAIAppUnits3 = 103, kAIAppUnits4 = 104, kAIAppUnits5 = 105,
  kAIAppUnits6 = 106, kAIAppUnits7 = 107, kAIAppUnits8 = 108, kAIAppUnits9 = 109,
  kAIAppUnits10 = 110, kAIMaxAppUnits = kAIAppUnits10, kAIDummyUnits = 0xFFFFFFFF
}
 

These constants identify the various units used in Illustrator.

More...

Functions

ZRef ZREF (const char *str)
bool operator== (const AIPoint &l, const AIPoint &r)
bool operator!= (const AIPoint &l, const AIPoint &r)
bool operator== (const AIRect &l, const AIRect &r)
bool operator!= (const AIRect &l, const AIRect &r)
void ai::check_ai_error (AIErr err)
 Validate an AIErr error code.
template<typename T >
void ai::check_precondition (T condition, AIErr err=kBadParameterErr)
 Validate that condition is met.
template<class T >
void ai::NOTUSED (const T &result)
 Inline method to suppress unused variable warning/error.

Detailed Description


Define Documentation

#define AI_MAIN_THREAD_API
#define AI_STATIC_CHECK ( expr,
msg   ) 
Value:
{\
        class ERROR_##msg {};\
        (void)sizeof(ai::CompileTimeChecker<(expr) != 0>((new ERROR_##msg())));\
}

Use to instantiate a CompileTimeChecker object for an expression.

Parameters:
expr An expression that compiles to the Boolean constant true. If the expression compiles to a false value, the checker cannot be instantiated, and a compile-time error occurs.
msg The compile-time error message that is displayed when the condition is met. Must be a legal C++ identifier (that is, contains no spaces, cannot begin with a digit, and so on).

Referenced by ai::WCHARStr::as_ASUnicode(), ai::UnicodeString::as_WCHARStr(), and ai::WCHARStr::WCHARStr().

#define AI_THREAD_SAFE_API
#define AIAPI   AI_MAIN_THREAD_API
#define AIAPI_VERSION (  )     (x)
#define AIAPI_VERSION (  )     (x + 1000)
#define AINOEXCEPT

Referenced by ai::ArtSet::ArtSet().

#define AINOTHROW

This macro is used to decorate C++ functions and methods that are guaranteed not to throw.

Due to the current state of compiler support for throw specifications, it is defined to be empty.

#define kImageTooBigError   '!I2B'
#define kPlatformUnloadedSuiteProc   nullptr
#define kPluginInterfaceVersion   kPluginInterfaceVersion25001
#define kPluginInterfaceVersion10001   0x10000001
#define kPluginInterfaceVersion11001   0x11000001
#define kPluginInterfaceVersion12001   0x12000001
#define kPluginInterfaceVersion13001   0x13000001
#define kPluginInterfaceVersion14001   0x14000001
#define kPluginInterfaceVersion15001   0x15000001
#define kPluginInterfaceVersion16001   0x16000001
#define kPluginInterfaceVersion17001   0x17000001
#define kPluginInterfaceVersion17011   0x17000011
#define kPluginInterfaceVersion18001   0x18000001
#define kPluginInterfaceVersion18011   0x18000011
#define kPluginInterfaceVersion19001   0x19000001
#define kPluginInterfaceVersion19021   0x19000021
#define kPluginInterfaceVersion20001   0x20000001
#define kPluginInterfaceVersion20011   0x20000011
#define kPluginInterfaceVersion21001   0x21000001
#define kPluginInterfaceVersion21011   0x21000011
#define kPluginInterfaceVersion22001   0x22000001
#define kPluginInterfaceVersion22011   0x22000011
#define kPluginInterfaceVersion23001   0x23000001
#define kPluginInterfaceVersion23011   0x23000011
#define kPluginInterfaceVersion24001   0x24000001
#define kPluginInterfaceVersion24011   0x24000011
#define kPluginInterfaceVersion24021   0x24000021
#define kPluginInterfaceVersion24031   0x24000031
#define kPluginInterfaceVersion25001   0x25000001
#define kPluginInterfaceVersion6001   0x06000001
#define kPluginInterfaceVersion6002   0x06000020
#define kPluginInterfaceVersion6021   0x06000021
#define kPluginInterfaceVersion7001   0x07000001
#define kPluginInterfaceVersion8001   0x08000001
#define kPluginInterfaceVersion9001   0x09000001
#define Macintosh   1
#define MSWindows   1
#define POP_GLOBALS
#define PUSH_GLOBALS

Typedef Documentation

typedef struct ArtObject* AIArtHandle

Opaque reference to an art object.

Access using AIArtSuite.

typedef ASByte AIBool8

Transformation matrix specified with AIReal values.

1-byte boolean value, true (1) or false (0)

typedef ACEProfile* AIColorProfile

Opaque color profile.

See AIColorConversionSuite.

typedef ai::uint32 AICommandID

An Illustrator menu command identifier.

See AICommandManagerSuite.

typedef HWND AIDialogRef

Dialog reference, Mac OS only, same as Mac OS DialogPtr.

Dialog reference, Windows only, same as Windows HWND.

typedef struct _t_AIDocument* AIDocumentHandle

Opaque reference to a document.

Access using AIDocumentSuite.

typedef ASErr AIErr

Opaque error, returned by most suite functions.

See Error Return Codes

typedef struct _t_AIEvent AIEvent

Event information structure, used by AIToolSuite, AICursorSnapSuite.

AIEvent is the same as Macintosh EventRecord on Macintosh and Windows. Event record.

typedef ASFixed AIFixed

Fixed number (obsolete) See AIFixedMathSuite.

Transformation matrix specified with AIFixed values.

Obsolete, use AIRealMatrix.

Point specified with AIFixed coordinates.

Obsolete, use AIRealPoint.

Rectangle specified with AIFixed coordinates.

Obsolete, use AIRealRect.

typedef ASFract AIFract

A fractional number greater than -2 and less than 2.

Obsolete, use AIReal.

typedef struct _t_AILayerOpaque* AILayerHandle

Opaque reference to a layer.

Access using AILayerSuite.

typedef struct _t_AIPlatformViewOpaque* AIPlatformViewRef

Opaque reference to a Platform View, NSView* on Mac and HWND on Windows .

typedef HDC AIPortRef

Port reference, Mac OS only, same as Mac OS CGrafPtr.

Port reference, Windows only, same as Windows HDC.

typedef AIReal* AIRealPtr
typedef struct _t_AISafeArtOpaque* AISafeArtHandle

Opaque reference to an Safe Art Handle.

Access using AIArtSuite

typedef struct _t_AIStreamOpaque* AIStream

Data stream.

typedef ai::uint32 AIUFract

An unsigned fractional number greater than 0 and less than 4.

Obsolete, use AIReal.

typedef HWND AIWindowRef

Window reference, Mac OS only, same as Mac OS WindowPtr.

Window reference, Windows only, same as Windows HWND.

typedef struct ArtObject* ConstAIArtHandle
typedef struct ZREFStruct* ZRef

A ZString (localizable string) reference.

Enforces the passing of ZStrings. A ZStrings is a char* with a conventional format, so it is easy to pass a non-ZString by accident. When this type is specified, the function expects a ZString. You can cast it back to a char* if you need to look inside it.


Enumeration Type Documentation

The position of an art object, which determines how it is drawn relative to another, overlapping art object, known as the prep (prepositional) object, and also whether a path is inside a compound path or group.

  • If the paint order is kPlaceAbove or kPlaceBelow, the object is drawn above or below the prep object when the boundaries overlap.
  • If the paint order is kPlaceInsideOnTop or kPlaceInsideOnBottom,the object is inside the prep object, which must be a container.
  • If the paint order is kPlaceAboveAll or kPlaceBelowAll, the prep object is ignored and the object is placed on top of or at the bottom of the entire document (that is, inside-on-top the topmost group or inside-on-bottom the bottommost group).

The paint order is the back-to-front ordering of art objects, also called the occlusion order or Z-order. It determines which objects obscure others when their bounds overlap. If objects do not overlap, the paint order is irrelevant to rendering.

Paint order values are used, for example, when creating art objects with AIArtSuite::NewArt(), copying or moving art objects, or specifying insertion points for art.

Enumerator:
kPlaceDefault 

Default value.

kPlaceAbove 

Place above the prepositional object.

kPlaceBelow 

Place below the prepositional object.

kPlaceInsideOnTop 

Place within and at the top of the prepositional container.

kPlaceInsideOnBottom 

Place within and at the bottom of the prepositional container.

kPlaceAboveAll 

Place at the top of the paint order, ignoring prepositional object.

kPlaceBelowAll 

Place at the bottom of the paint order, ignoring prepositional object.

How paint is applied--to fills, strokes, or both.

Enumerator:
kAINotUsed 
kAIUsedOnFill 

Paint is applied to fills.

kAIUsedOnStroke 

Paint is applied to strokes.

kAIUsedOnBoth 

Paint is applied to both fills and strokes.

enum AIUnits

These constants identify the various units used in Illustrator.

Enumerator:
kAINoUnits 

None.

kAIPointUnits 

Points.

kAIInchUnits 

Inches.

kAIMillimeterUnits 

Millimeters.

kAICentimeterUnits 

Centimeters.

kAIPicaUnits 

Picas.

kAIPercentUnits 

Percentage.

kAIDegreeUnits 

Degrees.

kAIQUnits 

Q units.

kAIBase16Units 

Hexadecimal units.

kAIPixelUnits 

Pixels.

kAITimeUnits 

Time.

kAIFeetUnits 

Feets units.

kAIHaUnits 

Ha.

kAIFeetInchUnits 

Feet Inch.

kAIMeterUnits 

Meter.

kAIYardUnits 

Yards.

kAIMinNormalUnits 

Minimum default.

kAIMaxNormalUnits 

Maximum default.

kAIAppUnits1 

App constant.

kAIAppUnits2 

App constant.

kAIAppUnits3 

App constant.

kAIAppUnits4 

App constant.

kAIAppUnits5 

App constant.

kAIAppUnits6 

App constant.

kAIAppUnits7 

App constant.

kAIAppUnits8 

App constant.

kAIAppUnits9 

App constant.

kAIAppUnits10 

App constant.

kAIMaxAppUnits 

App constant.

kAIDummyUnits 

internal use

enum AIVersion

These constants identify the various shipping versions of Illustrator.

Enumerator:
kAIVersion1 
kAIVersion88 
kAIVersion3 
kAIVersion4 
kAIVersion5 
kAIVersion6 
kAIVersion7 
kAIVersion8 
kAIVersion9 
kAIVersion10 
kAIVersion11 
kAIVersion12 
kAIVersion13 
kAIVersion14 
kAIVersion15 
kAIVersion16 
kAIVersion17 
kAIVersion18 
kAIVersion19 
kAIVersion20 
kAIVersion21 
kAIVersion22 
kAIVersion23 
kAIVersion24 
kAIVersion25 
kAIVersionLatest 

Function Documentation

bool operator!= ( const AIRect l,
const AIRect r 
) [inline]
bool operator!= ( const AIPoint l,
const AIPoint r 
) [inline]
bool operator== ( const AIRect l,
const AIRect r 
) [inline]
bool operator== ( const AIPoint l,
const AIPoint r 
) [inline]

References _t_AIPoint::h, and _t_AIPoint::v.

ZRef ZREF ( const char *  str  )  [inline]


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