InDesign SDK  20.5
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
LineDescription Class Reference

#include <LineDescription.h>

Public Types

enum  LineType {
  textWithLineNumber = 0, textWithoutLineNumber, pageDivider, columnDivider,
  frameDivider, oversetDivider, storyBar, paraDivider,
  tableRowDivider, tableColumnDivider
}
 
enum  LineAttributes { none = 0x0, oversetSplitLineStart = 0x1, oversetSplitLineEnd = 0x2 }
 
typedef object_type data_type
 

Public Member Functions

 LineDescription ()
 
 LineDescription (const LineDescription &other)
 
void ReadWrite (IPMStream *s, StoryDescription *storyDesc)
 

Public Attributes

TextIndex lineStartOffset
 
TextIndex lineEndOffset
 
TextIndex tableThreadStartOffset
 
TextIndex tableThreadEndOffset
 
TextIndex displayStartOffset
 
TextIndex displayEndOffset
 
PMReal xPosition
 
PMReal lineWidth
 
int32 lineID
 
int32 lineNumber
 
LineType typeLine
 
bool16 hyphenAtEnd
 
bool16 paraEndCharacter
 
bool16 overlapsWithNext
 
int32 psuedoLineID
 
uint32 attributes
 
K2Vector< RunDescription > * fTextRuns
 
LineDescriptionME * fMEData
 

Static Public Attributes

static const int32 kMaxViewSpace
 

Detailed Description

The LineDescription interface is a storage cache for the drawing of galley and story view text. The line data is filled out during text composition. It is related closely to the IWaxLines in layout view in the case of galley view with line endings. For story view most of the same data will be maintained, lineNumbers and lineID's have no meaning in story view.

Member Typedef Documentation

Member Enumeration Documentation

LineAttributes - Currently not used possible use for alternate implementation of overset divider.

LineType - Enum defines different possible line types for a LineDescription.
Enumerator
textWithLineNumber 

textWithLineNumber - text that has an associated line number in the info column. Only for galley view ignored in story view.

textWithoutLineNumber 

textWithLineNumber - text that has no associated line number in the info column (paragraph style name column).

pageDivider 

pageDivider - a line that indicates a page transition (galley view only).

columnDivider 

columnDivider - a line that indicates a column transition (galley view only).

frameDivider 

frameDivider - a line that indicates a frame transition (galley view only).

oversetDivider 

frameDivider - a line that indicates a transition to overset text (galley view only).

storyBar 

storyBar - InCopy only the first line of the story is a bar that shows the story name and a widget to collapse or expand the story.

paraDivider 

paraDivider - not used

tableRowDivider 

tableRowDivider - a divider line that indicates a transition to a new row (story and galley views).

tableColumnDivider 

tableColumnDivider - a divider line that indicates a transition to a new column (story and galley views).

Constructor & Destructor Documentation

LineDescription::LineDescription ()

Constructor for LineDescription

Returns
none

Member Function Documentation

void LineDescription::ReadWrite (IPMStreams,
StoryDescriptionstoryDesc 
)

internal use only undo/redo support.

Member Data Documentation

uint32 LineDescription::attributes

attributes - used as a compact storage mechanism for various line settings (internal use only).

TextIndex LineDescription::displayEndOffset

displayEndOffset - End position of the text line (display model offsets). Not alway up to date have to call ITextLine::UpdateLine() to update the value if not already correct. Can be a time penality calling UpdateLine() if it actually needs to update. See ITextLines.

TextIndex LineDescription::displayStartOffset

displayStartOffset - Start position of the text line (display model offsets). Not alway up to date have to call ITextLine::UpdateLine() to update the value if not already correct. Can be a time penality calling UpdateLine() if it actually needs to update. See ITextLines.

K2Vector<RunDescription>* LineDescription::fTextRuns

fTextRuns - Pointer to a vector of runs. See comments for RunDescription.

bool16 LineDescription::hyphenAtEnd

typeLine - Line ends in a hyphenated word (galley view only story view doesn't hyphenate)

TextIndex LineDescription::lineEndOffset

lineEndOffset

int32 LineDescription::lineID

lineID - matches unique id stored in ILayoutViewLineData for mapping between galley and layout line data (used in galley view only).

int32 LineDescription::lineNumber

lineNumber - the line number that corresponds to the layout view line number. Not necessarily the same as the lineindex+1 (galley view only)

TextIndex LineDescription::lineStartOffset

lineStartOffset - Start position of the text line (text model offsets). These are not always up to date use ITextLines::GetLineStartOffsetAtLine() to get updated value for sure may be a time penality to calculate if not updated.

PMReal LineDescription::lineWidth

lineWidth - The width of the line in pixels.

bool16 LineDescription::overlapsWithNext

overlapsWithNext - Line contains a run which overlaps with the next line (inline notes for example) requires extra invaling.

bool16 LineDescription::paraEndCharacter

paraEndCharacter - Line ends in a paragraph return or other character that starts a new paragraph.

int32 LineDescription::psuedoLineID

psuedoLineID - used to mark line as being psuedo composed and needing background composition.

TextIndex LineDescription::tableThreadEndOffset

tableThreadEndOffset

TextIndex LineDescription::tableThreadStartOffset
tableThreadStartOffset - Start position of the text line (text model offsets) in terms of the table cell. These are not always 

filled up. Only to be populated in case the line corresponds to a table cell in the text model.

LineType LineDescription::typeLine

typeLine - Describes how this line draws and behaves see comments for enum LineType

PMReal LineDescription::xPosition

xPosition - Where to draw the line in local view coordinates from left side of the view. Note, there is no yPosition the yPosition is calculated dynamically. See ITextLines::GetYPosition()