InDesign SDK  20.5
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
Facade::IAppearanceItemFacade Class Referenceabstract
Inheritance diagram for Facade::IAppearanceItemFacade:
IPMUnknown

Public Types

enum  { kDefaultIID = IID_IAPPEARANCEITEMFACADE }
 
enum  CopyItemsFlag { kCopyItems = kTrue, kDoNotCopyItems = kFalse }
 
enum  { kInvalidIndex = -1 }
 

Public Member Functions

virtual ErrorCode CreateAppearanceItem (const UIDList &inItems, const ClassID &inAppearanceItemClass, UIDList *outAppearanceItems=nil) const =0
 
virtual ErrorCode CreateNewState (const UIDList &inItems, Form::AppearanceState inState, int32 inPosition=IAppearanceList::kLastInOrder, CopyItemsFlag inCopyItems=kCopyItems, INewStateCmdData::NamePolicy inNamePolicy=INewStateCmdData::kUseDefaultName, const PMString *inNameString=nil) const =0
 
virtual ErrorCode MoveState (const UIDList &inAppearanceItems, Form::AppearanceState inState, int32 inPosition) const =0
 
virtual ErrorCode DeleteState (const UIDList &inAppearanceItems, Form::AppearanceState inState) const =0
 
virtual ErrorCode DeleteAppearance (const UIDList &inAppearanceItems, Form::AppearanceState inState) const =0
 
virtual ErrorCode SetActiveState (const UIDList &inAppearanceItems, Form::AppearanceState inState) const =0
 
virtual ErrorCode AddItemsToAppearance (const UIDRef &inAppearanceItem, const UIDList &inItemsToAdd, Form::AppearanceState inState) const =0
 
virtual ErrorCode AddItemsAsState (const UIDRef &inAppearanceItem, const UIDList &inItemsToAdd, Form::AppearanceState inState) const =0
 
virtual ErrorCode AddItemsAsStates (const UIDRef &inAppearanceItem, const UIDList &inItemsToAdd) const =0
 
virtual ErrorCode ReleaseAppearanceAsObject (const UIDList &inAppearanceItems, Form::AppearanceState inState) const =0
 
virtual ErrorCode ReleaseAllAppearancesAsObjects (const UIDList &inAppearanceItems) const =0
 
virtual Form::AppearanceState GetActiveState (const UIDRef &inAppearanceItem) const =0
 
virtual Form::AppearanceState GetNthState (const UIDRef &inAppearanceItem, int32 inStateIndex) const =0
 
virtual Form::AppearanceState GetNextAvailableState (const UIDRef &inAppearanceItem) const =0
 
virtual ErrorCode SetStateName (const UIDRef &inAppearanceItem, Form::AppearanceState inState, const PMString &inName) const =0
 
virtual PMString GetStateName (const UIDRef &inAppearanceItem, Form::AppearanceState inState) const =0
 
virtual int32 GetNumStates (const UIDRef &inAppearanceItem) const =0
 
virtual int32 GetStatePosition (const UIDRef &inAppearanceItem, Form::AppearanceState inState) const =0
 
virtual bool16 HasState (const UIDRef &inAppearanceItem, Form::AppearanceState inState) const =0
 
virtual bool16 CanAddState (const UIDRef &inAppearanceItem, Form::AppearanceState inState) const =0
 
virtual ErrorCode PasteIntoState (const UIDRef &inAppearanceItem, Form::AppearanceState inState, UIDList *outPastedItems=nil) const =0
 
virtual bool16 GetIsInitiallyHidden (const UIDRef &inItem) const =0
 
virtual ErrorCode SetIsInitiallyHidden (const UIDRef &inItem, bool16 inHidden) const =0
 
- Public Member Functions inherited from IPMUnknown
virtual IPMUnknownQueryInterface (PMIID interfaceID) const =0
 
virtual void AddRef () const =0
 
virtual void Release () const =0
 

Member Function Documentation

virtual ErrorCode Facade::IAppearanceItemFacade::AddItemsAsState (const UIDRefinAppearanceItem,
const UIDListinItemsToAdd,
Form::AppearanceState inState 
) const
pure virtual

Create a new state on an appearance item, and add page items to that state's appearance.

Parameters
inAppearanceItemthe appearance item to which a state is being added
inItemsToAddthe page items to add to the state's appearance
inStatethe new state to be created
Returns
ErrorCode
virtual ErrorCode Facade::IAppearanceItemFacade::AddItemsAsStates (const UIDRefinAppearanceItem,
const UIDListinItemsToAdd 
) const
pure virtual

Add page items to new states on an appearance item. Each page item in inItemsToAdd will be placed into its own new state on inAppearanceItem.

Parameters
inAppearanceItemthe appearance item to which a states are being added
inItemsToAddthe page items to add as states
Returns
ErrorCode
virtual ErrorCode Facade::IAppearanceItemFacade::AddItemsToAppearance (const UIDRefinAppearanceItem,
const UIDListinItemsToAdd,
Form::AppearanceState inState 
) const
pure virtual

Move a state to a new position in the state ordering on its parent page item. Can be used on multiple page items, simultaneously.

Parameters
inAppearanceItemsthe page items whose states to move
inStatethe state to move
inPositionthe new position for the state
Returns
ErrorCode
virtual bool16 Facade::IAppearanceItemFacade::CanAddState (const UIDRefinAppearanceItem,
Form::AppearanceState inState 
) const
pure virtual

Determines if a state is both supported and not already created.

Parameters
inAppearanceItemthe appearance item in question
inStatethe state in question
Returns
whether inState can be added to inAppearanceItem
virtual ErrorCode Facade::IAppearanceItemFacade::CreateAppearanceItem (const UIDListinItems,
const ClassIDinAppearanceItemClass,
UIDListoutAppearanceItems = nil 
) const
pure virtual

Creates a new appearance item of the specified class. Appearance items are created from already-existing page items. The page items that are passed into this method are used to define the how states of the appearance item look. If inAppearanceItemClass is kPushButtonItemBoss, then each of the items created will be individual buttons; if kMultiStateObjectItemBoss, then each of the items will be used to create individual states of a single Multi-State Object.

Parameters
inItemsthe page items to use to create the appearance item(s)
inAppearanceItemClassthe class of the desired page item: either kMultiStateObjectItemBoss or kPushButtonItemBoss.
outAppearanceItema UIDList of the items that were created
Returns
ErrorCode
virtual ErrorCode Facade::IAppearanceItemFacade::CreateNewState (const UIDListinItems,
Form::AppearanceState inState,
int32 inPosition = IAppearanceList::kLastInOrder,
CopyItemsFlag inCopyItems = kCopyItems,
INewStateCmdData::NamePolicy inNamePolicy = INewStateCmdData::kUseDefaultName,
const PMStringinNameString = nil 
) const
pure virtual

Creates a new state on a page item that supports states.

Parameters
inItemsthe item(s) to create the new state on
inStatethe AppearanceState to create on the items
inPositionthe position in the ordering of states to create the state at
inCopyItemswhether to page items into the new state. for buttons, these come from the normal state. for multi-state objects, these come from the active state
inNamePolicythe policy to use for assigning a name to the state
inNameStringif inNamePolicy is set to kBaseNameOnString, then this parameter is used as the string to base the name on
Returns
ErrorCode
virtual ErrorCode Facade::IAppearanceItemFacade::DeleteAppearance (const UIDListinAppearanceItems,
Form::AppearanceState inState 
) const
pure virtual

Deletes a contents of a state on one or more page items.

Parameters
inAppearanceItemsthe page items whose states to delete
inStatethe state to delete on the items
Returns
ErrorCode
virtual ErrorCode Facade::IAppearanceItemFacade::DeleteState (const UIDListinAppearanceItems,
Form::AppearanceState inState 
) const
pure virtual

Deletes a state on one or more page items.

Parameters
inAppearanceItemsthe page items whose states to delete
inStatethe state to delete on the items
Returns
ErrorCode
virtual Form::AppearanceState Facade::IAppearanceItemFacade::GetActiveState (const UIDRefinAppearanceItem) const
pure virtual

Gets the currently active state of the appearance item.

Parameters
inAppearanceItemthe appearance item in question
Returns
the active state of inAppearanceItem
virtual bool16 Facade::IAppearanceItemFacade::GetIsInitiallyHidden (const UIDRefinItem) const
pure virtual

Gets whether a appearance item is hidden when exported to SWF/PDF.

Parameters
inItemthe appearance item
Returns
whether this item is hidden when exported to SWF
virtual Form::AppearanceState Facade::IAppearanceItemFacade::GetNextAvailableState (const UIDRefinAppearanceItem) const
pure virtual

Gets next valid state that can be added to the page item.

Parameters
inAppearanceItemthe appearance item in question
Returns
if one the appearance item has valid states available, then the next valid state; otherwise kStateInvalid
virtual Form::AppearanceState Facade::IAppearanceItemFacade::GetNthState (const UIDRefinAppearanceItem,
int32 inStateIndex 
) const
pure virtual

Gets the nth state of the appearance item.

Parameters
inAppearanceItemthe appearance item in question
inStateIndexthe index of the state to be retrieved
Returns
the nth state of inAppearanceItem
virtual int32 Facade::IAppearanceItemFacade::GetNumStates (const UIDRefinAppearanceItem) const
pure virtual

Gets the number of states that an appearance item has.

Parameters
inAppearanceItemthe appearance item in question
Returns
the number of states that inAppearanceItem has
virtual PMString Facade::IAppearanceItemFacade::GetStateName (const UIDRefinAppearanceItem,
Form::AppearanceState inState 
) const
pure virtual

Gets the name of a state on an appearance item.

Parameters
inAppearanceItemthe appearance item that owns the state
inStatethe state whose name to get
Returns
the name of the state, if it exists; otherwise an empty string
virtual int32 Facade::IAppearanceItemFacade::GetStatePosition (const UIDRefinAppearanceItem,
Form::AppearanceState inState 
) const
pure virtual

Gets the the position of a state in an appearance item's state ordering.

Parameters
inAppearanceItemthe appearance item in question
inStatethe state whose position to get
Returns
the index of the state in the state ordering, or kInvalidIndex
virtual bool16 Facade::IAppearanceItemFacade::HasState (const UIDRefinAppearanceItem,
Form::AppearanceState inState 
) const
pure virtual

Determines if an appearance item has a specific state defined.

Parameters
inAppearanceItemthe appearance item in question
inStatethe state in question
Returns
whether inAppearanceItem has a state identified by inState
virtual ErrorCode Facade::IAppearanceItemFacade::MoveState (const UIDListinAppearanceItems,
Form::AppearanceState inState,
int32 inPosition 
) const
pure virtual

Move a state to a new position in the state ordering on its parent page item. Can be used on multiple page items, simultaneously.

Parameters
inAppearanceItemsthe page items whose states to move
inStatethe state to move
inPositionthe new position for the state
Returns
ErrorCode
virtual ErrorCode Facade::IAppearanceItemFacade::PasteIntoState (const UIDRefinAppearanceItem,
Form::AppearanceState inState,
UIDListoutPastedItems = nil 
) const
pure virtual

Paste the currently copied item(s) into the specified state of the specified appearance item

Parameters
inAppearanceItemthe appearance item to paste into
inStatethe state to paste into
outPastedItemsan optional list to fill with the UIDs of the newly pasted items
Returns
ErrorCode
virtual ErrorCode Facade::IAppearanceItemFacade::ReleaseAllAppearancesAsObjects (const UIDListinAppearanceItems) const
pure virtual

Deletes the appearance item and places all of the objects that made up the appearances of that item's states onto the spread.

Parameters
inAppearanceItemthe appearance item whose state is to be released
inStatethe state to release to the spread
Returns
ErrorCode
virtual ErrorCode Facade::IAppearanceItemFacade::ReleaseAppearanceAsObject (const UIDListinAppearanceItems,
Form::AppearanceState inState 
) const
pure virtual

Deletes a state and places the objects that made up that state's appearance onto the spread.

Parameters
inAppearanceItemthe appearance item whose state is to be released
inStatethe state to release to the spread
Returns
ErrorCode
virtual ErrorCode Facade::IAppearanceItemFacade::SetActiveState (const UIDListinAppearanceItems,
Form::AppearanceState inState 
) const
pure virtual

Changes the active state of one or more appearance items.

Parameters
inAppearanceItemsthe appearance items to change
inStatethe new state to set as active
Returns
ErrorCode
virtual ErrorCode Facade::IAppearanceItemFacade::SetIsInitiallyHidden (const UIDRefinItem,
bool16 inHidden 
) const
pure virtual

Sets whether an appearance item is hidden when exported to SWF/PDF.

Parameters
inItemthe appearance item
inHiddenwhether or not this object should be hidden
Returns
ErrrorCode
virtual ErrorCode Facade::IAppearanceItemFacade::SetStateName (const UIDRefinAppearanceItem,
Form::AppearanceState inState,
const PMStringinName 
) const
pure virtual

Sets the name of a state on an appearance item.

Parameters
inAppearanceItemthe appearance item that owns the state
inStatethe state whose name to modify
inNamethe new name for the state
Returns
ErrorCode