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

#include <IFrameContentUtils.h>

Inheritance diagram for IFrameContentUtils:
IPMUnknown

Public Types

enum  { kDefaultIID = IID_IFRAMECONTENTUTILS }
 

Public Member Functions

virtual bool16 DoesContainGraphicFrame (const UIDList *items, bool16 bWantEmpty) const =0
 
virtual bool16 DoesContainTextFrame (const UIDList *items, bool16 bWantEmpty) const =0
 
virtual bool16 DoesContainItem (const UIDList *items) const =0
 
virtual bool16 IsEmptyTextFrame (const IGraphicFrameData *frameData) const =0
 
virtual UID CanFitFrameToContent (const UIDRef &item) const =0
 
virtual UIDListCreateListOfFrames (const UIDList &items) const =0
 
virtual UID CanFitContentToFrame (const UIDRef &item) const =0
 
virtual UIDListCreateListOfContent (const UIDList &items) const =0
 
virtual void CalculateCurrentCropValuesForFitting (UIDRef frame, PMRect &cropAmounts)=0
 
virtual void GetContentCropParameters (ITransform *contentTransform, PMRect cropAmounts, PMRect &cropRect, PMMatrix &contentToCropMatrix, PMMatrix &cropToParentMatrix)=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

Utility interface for determining various aspects of frame contents.

Member Function Documentation

virtual void IFrameContentUtils::CalculateCurrentCropValuesForFitting (UIDRef frame,
PMRectcropAmounts 
)
pure virtual

Calculate Frame Fitting cropping values that represent the current arrangement of content in the Frame given the reference point and fitting option.

Parameters
frame[IN] the UIDRef of the frame with content
cropAmounts[OUT] the calculated crop values
virtual UID IFrameContentUtils::CanFitContentToFrame (const UIDRefitem) const
pure virtual

Determine if the item can be stretched to fit its frame.

Parameters
itemIN, UIDRef of item to examine.
Returns
UID of content, kInvalidUID if can't fit content to frame (or there is no content)
virtual UID IFrameContentUtils::CanFitFrameToContent (const UIDRefitem) const
pure virtual

Determine if the item have its frame fit to the size of the content

Parameters
itemIN UIDRef of item to check.
Returns
kInvalidUID if can't do operation, UID of item otherwise.
virtual UIDList* IFrameContentUtils::CreateListOfContent (const UIDListitems) const
pure virtual

Return the list of items from the given list that can have their content fit to their frame (non-empty frames)

Parameters
itemsIN UIDList of items to examine.
Returns
UIDList of qualifying items from "items" UIDList
virtual UIDList* IFrameContentUtils::CreateListOfFrames (const UIDListitems) const
pure virtual

Return the list of items from the given list that can have their frame fit to their content (non-empty frames)

Parameters
itemsIN UIDList of items to examine.
Returns
UIDList of qualifying items from "items" UIDList
virtual bool16 IFrameContentUtils::DoesContainGraphicFrame (const UIDListitems,
bool16 bWantEmpty 
) const
pure virtual

Determine if any item in the list is a graphic frame.

Parameters
itemsIN UIDList of items to examine.
bWantEmptyIN pass kTrue there must be an empty Graphic Frame in the list
Returns
kTrue if any item in the list is a graphic frame.
virtual bool16 IFrameContentUtils::DoesContainItem (const UIDListitems) const
pure virtual

Determine if any frame in the list is a page item.

Parameters
itemsIN UIDList of items to examine.
Returns
kTrue if any frame in the list is a page item, kFalse otherwise.
virtual bool16 IFrameContentUtils::DoesContainTextFrame (const UIDListitems,
bool16 bWantEmpty 
) const
pure virtual

Determine if item list contains one more more text frames.

Parameters
itemsIN UIDList of items to examine.
bWantEmptyIN pass kTrue if there must be an empty Text Frame in the list
Returns
kTrue if any item in the list is a text frame, kFalse otherwise.
virtual void IFrameContentUtils::GetContentCropParameters (ITransformcontentTransform,
PMRect cropAmounts,
PMRectcropRect,
PMMatrixcontentToCropMatrix,
PMMatrixcropToParentMatrix 
)
pure virtual

Calculate the crop Rectangle in a coordinate space defined by contentToCropMatrix. This is the same as the content to Parent matrix with only the rotate, skew and "flip" (sign part of the scale matrix).

Parameters
contentITransform of the content
cropAmounts4-tuple of insets from the biggest rectangle inscribed in the content but aligned with the parent.
contentToCropMatrixthe part of the content to parent matrix that contains Rotation, Skew and Flip.
cropToParentMatrixthe part of the content to parent matrix that contains the scale magnatude and translation. if you multiply the contentToCropMatrix with cropToParentMatrix you get the same thing as the content to parent matrix
virtual bool16 IFrameContentUtils::IsEmptyTextFrame (const IGraphicFrameDataframeData) const
pure virtual

Determine if the frame for this item contains an empty story.

Parameters
frameDataIN An IGraphicFrameData from the frame to check.
Returns
kTrue if the frame is a text frame which contains an empty story, kFalse otherwise.