BuildingBlock
QuickLinks
Hierarchy
Properties
Property | Type | Access | Description |
---|---|---|---|
appliedCharacterStyle | CharacterStyle | r/w | Character style to be applied to the building block. |
appliedDelimiter | string | r/w | Delimiter character for paragraph text and full paragraph building blocks. It is ignored for other types of building blocks. |
blockType | BuildingBlockTypes: BuildingBlockTypes.CUSTOM_STRING_BUILDING_BLOCK BuildingBlockTypes.FILE_NAME_BUILDING_BLOCK BuildingBlockTypes.CHAPTER_NUMBER_BUILDING_BLOCK BuildingBlockTypes.PAGE_NUMBER_BUILDING_BLOCK BuildingBlockTypes.FULL_PARAGRAPH_BUILDING_BLOCK BuildingBlockTypes.PARAGRAPH_NUMBER_BUILDING_BLOCK BuildingBlockTypes.PARAGRAPH_TEXT_BUILDING_BLOCK BuildingBlockTypes.BOOKMARK_NAME_BUILDING_BLOCK |
r/w | Type of the building block. |
customText | string | r/w | Building block custom text. Currently this is only useful in custom string building block. It is ignored for other types of building blocks. |
eventListeners | EventListeners EventListener | readonly | A collection of event listeners. |
events | Events Event | readonly | A collection of events. |
includeDelimiter | bool | r/w | If true, the source generated for the building block includes the delimiter. It is ignored if no delimiter is specified on the building block. |
index | number | readonly | The index of the BuildingBlock within its containing object. |
isValid | bool | readonly | Returns true if the object specifier resolves to valid objects. |
parent | CrossReferenceFormat | readonly | The parent of the BuildingBlock (a CrossReferenceFormat). |
properties | Object | r/w | A property that allows setting of several properties at the same time. |
Methods
Instances
EventListener addEventListener (eventType:
string, handler:
varies[, captures:
bool=false])
Adds an event listener.
Parameter | Type | Description |
---|---|---|
eventType | string | The event type. |
handler | File JavaScript Function | The event handler. Can accept: File or JavaScript Function. |
captures | bool | This parameter is obsolete. (Optional) (default: false) |
Array
of BuildingBlock getElements ()
Resolves the object specifier, creating an array of object references.
void remove ()
Deletes the BuildingBlock.
bool removeEventListener (eventType:
string, handler:
varies[, captures:
bool=false])
Removes the event listener.
Parameter | Type | Description |
---|---|---|
eventType | string | The registered event type. |
handler | File JavaScript Function | The registered event handler. Can accept: File or JavaScript Function. |
captures | bool | This parameter is obsolete. (Optional) (default: false) |
string toSource ()
Generates a string which, if executed, will return the BuildingBlock.
Used in:
BuildingBlock BuildingBlocks.nextItem (obj: BuildingBlock)
BuildingBlock BuildingBlocks.previousItem (obj: BuildingBlock)
Return
Array of BuildingBlock BuildingBlock.getElements ()
BuildingBlock BuildingBlocks.[] (index: number)
BuildingBlock BuildingBlocks.add (blockType: BuildingBlockTypes[, appliedCharacterStyle: CharacterStyle][, customText: string][, withProperties: Object])
BuildingBlock BuildingBlocks.anyItem ()
Array of BuildingBlock BuildingBlocks.everyItem ()
BuildingBlock BuildingBlocks.firstItem ()
BuildingBlock BuildingBlocks.item (index: varies)
Array of BuildingBlock BuildingBlocks.itemByRange (from: varies, to: varies)
BuildingBlock BuildingBlocks.lastItem ()
BuildingBlock BuildingBlocks.middleItem ()
BuildingBlock BuildingBlocks.nextItem (obj: BuildingBlock)
BuildingBlock BuildingBlocks.previousItem (obj: BuildingBlock)
Jongware, 29-Apr-2012 v3.0.3i | Contents :: Index |