InDesign SDK  20.5
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
IPageItemScrapData Class Referenceabstract

#include <IPageItemScrapData.h>

Inheritance diagram for IPageItemScrapData:
IPMUnknown

Public Types

enum  { kScrapType = 'PMLY' }
 
enum  { kDefaultIID = IID_IPAGEITEMSCRAPDATA }
 

Public Member Functions

virtual void Replace (const UIDList &newList)=0
 
virtual void Append (UID newItem)=0
 
virtual void Append (const UIDList &newList)=0
 
virtual void Clear ()=0
 
virtual bool16 IsEmpty () const =0
 
virtual UIDListCreateUIDList () const =0
 
virtual UIDRef GetRootNode () const =0
 
virtual void SetRootNode (const UIDRef &newRoot)=0
 
virtual bool16 GetIsGuide () const =0
 
virtual void SetIsGuide (bool16 isGuide)=0
 
virtual bool16 GetCenterItemOnPaste () const =0
 
virtual void SetCenterItemOnPaste (bool16 centerItem)=0
 
virtual PMPoint GetPasteInsideOffset (void) const =0
 
virtual void SetPasteInsideOffset (const PMPoint &offset)=0
 
virtual PMMatrix GetPasteInsideRelativeTransform (void) const =0
 
virtual void SetPasteInsideRelativeTransform (const PMMatrix &transform)=0
 
- Public Member Functions inherited from IPMUnknown
virtual IPMUnknownQueryInterface (PMIID interfaceID) const =0
 
virtual void AddRef () const =0
 
virtual void Release () const =0
 

Detailed Description

IPageItemScrapData interface, is used to represent pageitems in a scrap database by the data exchange framework. This interface can be found on the PageItemScrapHandler boss as well as several other handler bosses that also store page item data. The class PageItemScrapData provides the necessary implementation.

Note that the pageitems are not required to live in the same database as this interface does. The pageitems can either exist in the scrap database (as is the case for the clipboard) in another document (typical when dragging from ne document to another), etc.

Member Function Documentation

virtual void IPageItemScrapData::Append (UID newItem)
pure virtual

Append an item to the scrap data

Parameters
newItemINOUT DESCRIPTION
Precondition
you MUST call Replace first to establish which database the items exist in.
virtual void IPageItemScrapData::Append (const UIDListnewList)
pure virtual

Append a list of items to the scrap data

Parameters
newListIN items to add to the list (should be in the same database as those items already there)
Precondition
you MUST call Replace first to establish which database the items exist in.
virtual void IPageItemScrapData::Clear ()
pure virtual

Remove all of the page items (release references or delete actual page items)

virtual UIDList* IPageItemScrapData::CreateUIDList () const
pure virtual

Get a copy of the list of items on the scrap.

Returns
list of pageitems
Postcondition
Caller is responsible for deleting the list.
virtual bool16 IPageItemScrapData::GetCenterItemOnPaste () const
pure virtual

When pasting, should the pageitems be centered on the page

virtual bool16 IPageItemScrapData::GetIsGuide () const
pure virtual

Does the scrap contain guides rather than pageitems?

virtual PMPoint IPageItemScrapData::GetPasteInsideOffset (void ) const
pure virtual

For Paste Inside: Get the offset, saved at copy time of the item within it's parent.

virtual PMMatrix IPageItemScrapData::GetPasteInsideRelativeTransform (void ) const
pure virtual

For Paste Inside: Get the transform set at copy time of the item(s) parent.

virtual UIDRef IPageItemScrapData::GetRootNode () const
pure virtual

Get the parent to be used when adding items to the scrap

virtual bool16 IPageItemScrapData::IsEmpty () const
pure virtual

Are there any pageitems in the scrap data

virtual void IPageItemScrapData::Replace (const UIDListnewList)
pure virtual

Specify the pageitems to be remembered. Note that you MUST call Replace first to establish which database the items exist in. You can then optionally call Append to add other items.

Parameters
newListIN list of pageitems
Postcondition
this establishes which database the items exist in.
virtual void IPageItemScrapData::SetCenterItemOnPaste (bool16 centerItem)
pure virtual

Set whether the should the pageitems be centered on the page, when pasting.

virtual void IPageItemScrapData::SetIsGuide (bool16 isGuide)
pure virtual

Set the flag that records whether the items in the scrap are guides rather than pageitems.

virtual void IPageItemScrapData::SetPasteInsideOffset (const PMPointoffset)
pure virtual

For Paste Inside: Set the offset at copy time of the top left of the item we are copying to the top left of its parent. The Offset calculation should be done in the coordinate space of the parent. At PasteInside time, this Offset will be transformed into PasteBoard coordinates using the transform of the frame we are pasting into in order to calculate an offset in PasteBoard coordinates which can be used to move the pasted item such that it maintains the same offset with respect to its new frame as when originally copied.

Parameters
offsetIN the offset
virtual void IPageItemScrapData::SetPasteInsideRelativeTransform (const PMMatrixtransform)
pure virtual

For Paste Inside: Set the transform at copy time of the item(s) parent.

virtual void IPageItemScrapData::SetRootNode (const UIDRefnewRoot)
pure virtual

Set the parent to be used when adding page items to the scrap. Used when copying or otherwise creating pageitems that reside in the scrap database.

Parameters
newRootIN the root node
Precondition
it is necessary for the root node to live in the same database as the handler boss containing the IPageItemScrapData