public class LineArea extends Area
bidiLevel, bpd, CLASS_ABSOLUTE, CLASS_BEFORE_FLOAT, CLASS_FIXED, CLASS_FOOTNOTE, CLASS_MAX, CLASS_NORMAL, CLASS_SIDE_FLOAT, effectiveIPD, ipd, log, ORIENT_0, ORIENT_180, ORIENT_270, ORIENT_90, traits
extensionAttachments, foreignAttributes
Constructor and Description |
---|
LineArea()
default constructor:
nothing to do
|
LineArea(int alignment,
int diff,
int stretch,
int shrink)
constructor with extra parameters:
a new LineAdjustingInfo object is created
|
Modifier and Type | Method and Description |
---|---|
void |
addChildArea(Area childArea)
Add a child area to this line area.
|
void |
addInlineArea(InlineArea area)
Add an inline child area to this line area.
|
void |
finish()
apply the variation factor to all descendant areas
and destroy the AdjustingInfo object if there are
no UnresolvedAreas left
|
int |
getEffectiveIPD() |
int |
getEndIndent()
Get the end indent of this line area.
|
List |
getInlineAreas()
Get the inline child areas of this line area.
|
int |
getStartIndent()
Get the start indent of this line area.
|
void |
handleIPDVariation(int ipdVariation)
receive notification about the ipd variation of a descendant area
and perform the needed adjustment, according to the alignment;
in particular:
left-aligned text needs no adjustement;
right-aligned text and centered text are handled locally,
adjusting the indent of this LineArea;
justified text requires a more complex adjustment, as the
variation factor computed on the basis of the total
stretch and shrink of the line must be applied in every
descendant leaf areas (text areas and leader areas).
|
void |
setInlineAreas(List inlineAreas)
Set (en masse) the inline child areas of this line area.
|
void |
updateExtentsFromChildren()
Updates the extents of the line area from its children.
|
activateEffectiveIPD, addTrait, clone, getAllocBPD, getAllocIPD, getAreaClass, getBidiLevel, getBorderAndPaddingWidthAfter, getBorderAndPaddingWidthBefore, getBorderAndPaddingWidthEnd, getBorderAndPaddingWidthStart, getBPD, getChangeBarList, getEffectiveAllocIPD, getIPD, getSpaceAfter, getSpaceBefore, getSpaceEnd, getSpaceStart, getTrait, getTraitAsBoolean, getTraitAsInteger, getTraits, hasTrait, hasTraits, resetBidiLevel, setAreaClass, setBidiLevel, setBPD, setChangeBarList, setIPD, setTraits, setWritingModeTraits, toString
addExtensionAttachment, getExtensionAttachments, getForeignAttributes, getForeignAttributeValue, hasExtensionAttachments, setExtensionAttachments, setForeignAttribute, setForeignAttributes
public LineArea()
public LineArea(int alignment, int diff, int stretch, int shrink)
alignment
- alignment of this linediff
- difference between content width and line widthstretch
- the available stretch for any adjustmentsshrink
- the available shrink for any adjustmentspublic void addChildArea(Area childArea)
addChildArea
in class Area
childArea
- the inline child area to addpublic void addInlineArea(InlineArea area)
area
- the inline child area to addpublic void setInlineAreas(List inlineAreas)
Set (en masse) the inline child areas of this line area.
Used by bidirectional processing after line area consituent reordering.
inlineAreas
- the list of inline areaspublic List getInlineAreas()
public int getStartIndent()
public int getEndIndent()
public void updateExtentsFromChildren()
public void handleIPDVariation(int ipdVariation)
ipdVariation
- the difference between old and new ipdpublic void finish()
public int getEffectiveIPD()
getEffectiveIPD
in class Area
Copyright © 2022 Apache Software Foundation. All rights reserved.