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

#include <IXRefFormat.h>

Inheritance diagram for IXRefFormat:
IPMUnknown

Public Types

enum  { kDefaultIID = IID_IXREFFORMAT }
 

Public Member Functions

virtual void CopyData (const IXRefFormat *other)=0
 
virtual void SetName (const PMString &formatName)=0
 
virtual PMString GetName () const =0
 
virtual void SetCharacterStyle (UID charStyle)=0
 
virtual UID GetCharacterStyle () const =0
 
virtual void SetBuildingBlocks (const K2Vector< XRefBuildingBlock > &buildingBlocks)=0
 
virtual void GetBuildingBlocks (K2Vector< XRefBuildingBlock > &buildingBlocks) const =0
 
virtual int32 GetBuildingBlockCount () const =0
 
virtual bool16 GetNthBuildingBlock (int32 index, XRefBuildingBlock &buildingBlock) const =0
 
virtual bool16 HasParagraphBlock () const =0
 
virtual PMString GenerateBlocksString () const =0
 
virtual PMString GenerateSourceString (const IOwnedItem *destMarker, bool16 isParagraphDest, K2Vector< CharStyleRange > &charStyleRanges, K2Vector< uint32 > &pageNumLocations, K2Vector< uint32 > &chapterNumLocations, std::map< TextIndex, WideString > *variableLocations, std::map< TextIndex, TextIndex > *inlineLocations) const =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

Abstract interface to cross reference format. Cross reference format is referenced by cross reference source object. The format is used by the source to generate proper content string in the document.

See Also
kXRefBuildingBlockBoss

Member Function Documentation

virtual PMString IXRefFormat::GenerateBlocksString () const
pure virtual

Get the string representation of the building blocks in the format. The string is used in the UI for editing building blocks.

Returns
PMString - The string value of the building blocks
virtual PMString IXRefFormat::GenerateSourceString (const IOwnedItemdestMarker,
bool16 isParagraphDest,
K2Vector< CharStyleRange > & charStyleRanges,
K2Vector< uint32 > & pageNumLocations,
K2Vector< uint32 > & chapterNumLocations,
std::map< TextIndex, WideString > * variableLocations,
std::map< TextIndex, TextIndex > * inlineLocations 
) const
pure virtual

Get the source string of the format for the specified destination marker

Parameters
destMarker- destination marker owned item
isParagraphDest- kTrue if the destination is a paragraph destination
charStyleRanges- contains ranges where to apply character styles
pageNumLocations- offset of page numbers in the source string
chapterNumLocations- offset of chapter numbers in the source string
variableLoations- [OUT] text variables and their index offset in the source content
inlineLocations- [OUT] inline objects index offset in the source content and corresponding index in destination story.
Returns
PMString - The source string generated for the destination
virtual int32 IXRefFormat::GetBuildingBlockCount () const
pure virtual

Get the building blocks count.

Returns
int32 - total count of building blocks
virtual void IXRefFormat::GetBuildingBlocks (K2Vector< XRefBuildingBlock > & buildingBlocks) const
pure virtual

Get the building blocks list of the format

Parameters
K2Vector<XRefBuildingblock>*- [OUT]list of building blocks.
virtual PMString IXRefFormat::GetName () const
pure virtual

Get the name of the format (This name will be marked as translated)

Returns
PMString - The name of the format
virtual bool16 IXRefFormat::GetNthBuildingBlock (int32 index,
XRefBuildingBlockbuildingBlock 
) const
pure virtual

Get the n'th building block of the format.

Parameters
index- index of the building block
buildingBlock- [OUT] building block returned
Returns
bool16 - kTrue if we successfully retrieve the building block, kFalse otherwise.
virtual bool16 IXRefFormat::HasParagraphBlock () const
pure virtual

Checks if the format contains full paragraph or paragraph text building block.

Returns
bool16 - kTrue if format contains paragraph text or full paragraph building block. kFalse otherwise.
virtual void IXRefFormat::SetBuildingBlocks (const K2Vector< XRefBuildingBlock > & buildingBlocks)
pure virtual

Set the building blocks list to the format

Parameters
buildingBlocks- building blocks list used to initialize the internal structure private to the object.
virtual void IXRefFormat::SetCharacterStyle (UID charStyle)
pure virtual

Set/Get character style for the entire format

virtual void IXRefFormat::SetName (const PMStringformatName)
pure virtual

Set the name of the format

Parameters
formatName- The new name to use