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

#include <IDynDocsPublicUtils.h>

Inheritance diagram for IDynDocsPublicUtils:
IPMUnknown

Public Types

enum  { kDefaultIID = IID_IDYNDOCSPUBLICUTILS }
 

Public Member Functions

virtual bool BeginHyperlink (IGraphicsPort *port, UIDRef const &item)=0
 
virtual bool BeginHyperlink (IGraphicsPort *port, UIDRef const &item, PMRect const &bounds, PMMatrix const &matrix)=0
 
virtual void EndHyperlink (IGraphicsPort *port)=0
 
virtual bool CanAddHyperlink (IGraphicsPort const *port, UIDRef const &item)=0
 
virtual void CalculateSelectedBounds (UIDList const &items, PMReal &width, PMReal &height) const =0
 
virtual void CalculateTotalBounds (UIDList const &items, bool readersSpreads, PMReal &width, PMReal &height) const =0
 
virtual void CalculateWidthAndHeightForExport (PMReal const &sourceWidth, PMReal const &sourceHeight, flash_export::SizeAndFitSettings const &settings, uint32 &destWidth, uint32 &destHeight) const =0
 
virtual bool IterateDocForExport (ICommand *pCmdExport, const UIDList &items, IDocument *pDoc, UIFlags uiFlags, bool *bValidationFailure=nil) const =0
 
virtual AString GetResourceDirectoryNameFromDDExportFile (const IDFile &ddExportFile) const =0
 
virtual bool ShouldIgnoreTextXPAdornment (IShape *iShape, IXPAttributeSuite::AttributeTarget target)=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

This utility interface is on the kUtilsBoss. It is used for installing a stack based object to process hyperlink information when export InDesign document to SWF.

Member Function Documentation

virtual bool IDynDocsPublicUtils::BeginHyperlink (IGraphicsPortport,
UIDRef const & item 
)
pure virtual

This method is called at the constructor of DynDocsHyperlinkHelper to start pushing the hyperlink information to port.

Parameters
port[IN]: graphics port that we push the information to.
item[IN]: item that has hyperlink information.
bounds[IN]: optional bounding box for the hyperlink. May be omitted if bounds can be deduced from hyperlink.
Returns
bool: Return true if we did push the hyperlink information; otherwise return false.
virtual bool IDynDocsPublicUtils::BeginHyperlink (IGraphicsPortport,
UIDRef const & item,
PMRect const & bounds,
PMMatrix const & matrix 
)
pure virtual

This method is called at the constructor of DynDocsHyperlinkHelper to start pushing the hyperlink information to port.

Parameters
port[IN]: graphics port that we push the information to.
item[IN]: item that has hyperlink information.
bounds[IN]: bounding box for the hyperlink. May be omitted if bounds can be deduced from hyperlink.
matrix[IN]: Matrix for transforming bounds to spread coordinates
Returns
bool: Return true if we did push the hyperlink information; otherwise return false.
virtual void IDynDocsPublicUtils::CalculateSelectedBounds (UIDList const & items,
PMRealwidth,
PMRealheight 
) const
pure virtual

This method is to calculate the bounds of the given page items.

Parameters
items[IN]: the selected page items
width[OUT]: the width of the items
height[OUT]: the height of the items
virtual void IDynDocsPublicUtils::CalculateTotalBounds (UIDList const & items,
bool readersSpreads,
PMRealwidth,
PMRealheight 
) const
pure virtual

This method is to calculate the total bounds of the given items. If readersSpreads is true, then it is the bounds of spread; otherwise it is the bounds of page.

Parameters
items[IN]: the given items
readersSpreads[IN]: flag indicate checking spread bounds or page bounds.
width[OUT]: the width of the items
height[OUT]: the height of the items
virtual void IDynDocsPublicUtils::CalculateWidthAndHeightForExport (PMReal const & sourceWidth,
PMReal const & sourceHeight,
flash_export::SizeAndFitSettings const & settings,
uint32 & destWidth,
uint32 & destHeight 
) const
pure virtual

Calculates the effective width and height for an export to either SWF or XFL given source dimensions and a structure defining the type of scaling to be applied.

Note: The calculated width and height are implicitly converted to unsigned integers by determining their mathematical ceiling.

Parameters
sourceWidth[in]: The width of the source document, as determined by CalculateTotalBounds
sourceHeight[in]: The height of the source document, as determined by CalculateTotalBounds
settings[in]: The settings to be used to determine the scaled dimensions
destWidth[out]: The calculated width
destHeight[out]: The calculated height
virtual bool IDynDocsPublicUtils::CanAddHyperlink (IGraphicsPort const * port,
UIDRef const & item 
)
pure virtual

This method is to check if we should push (see TableShape.cpp).

Parameters
port[IN]: graphics port that we push the information to.
item[IN]: item could be page item or text source hyperlink.
Returns
bool: Return true when we can push hyperlink info to port; otherwise false.
virtual void IDynDocsPublicUtils::EndHyperlink (IGraphicsPortport)
pure virtual

This method is called at the destructor of DynDocsHyperlinkHelper to end pushing the hyperlink information to port.

Parameters
port[IN]: graphics port that we push the information to.
virtual AString IDynDocsPublicUtils::GetResourceDirectoryNameFromDDExportFile (const IDFileddExportFile) const
pure virtual

Determine the expected name of a resource directory associated with an exported file.

Parameters
ddExportFile[in]: The exported file for which to find the resource directory.
Returns
AString: The expected name of the resource directory associated with ddExportFile.
virtual bool IDynDocsPublicUtils::IterateDocForExport (ICommandpCmdExport,
const UIDListitems,
IDocumentpDoc,
UIFlags uiFlags,
bool * bValidationFailure = nil 
) const
pure virtual

Iterate the document before export to look for problems and, if showing UI, warn the user about issues. If the user cancels in response to a problem, IterateDocForExport will return false.

Parameters
pCmdExport[in]: The dynamic documents export command to be used.
items[in]: The list of items to be exported: spreads, pages or selected page items.
pDoc[in]: The document to be exported.
uiFlags[in]: A flag indicating whether or not UI is permitted.
bValidationFailure[out]: Optional argument that denotes whether the items to be exported include missing or out-of-date links, legacy media, or flattening is turned on and the items have transparency.
Returns
bool: Return true if the user did not cancel in response to any problems; otherwise return false.
virtual bool IDynDocsPublicUtils::ShouldIgnoreTextXPAdornment (IShapeiShape,
IXPAttributeSuite::AttributeTarget target 
)
pure virtual

Determine whether we should ignore the transparency effects applied on text when export to FLA.

Parameters
iShape[in]: The shape that has effects applied to it.
target[in]: The applied transparency effect target(object, fill, stroke and content).
Returns
bool: return true if we should ignore; otherwise return false.