public class BoxBuilder extends Object
Element to an
InlineBox or a BlockBox (or some subclass of
BlockBox), but the tree is reorganized according to the CSS rules.
This includes inserting anonymous block and inline boxes, anonymous table
content, and :before and :after content. White
space is also normalized at this point. Table columns and table column groups
are added to the table which owns them, but are not created as regular boxes.
Floated and absolutely positioned content is always treated as inline
content for purposes of inserting anonymous block boxes and calculating
the kind of content contained in a given block box.| Modifier and Type | Class and Description |
|---|---|
static class |
BoxBuilder.ChildBoxInfo |
| Modifier and Type | Field and Description |
|---|---|
static int |
MARGIN_BOX_HORIZONTAL |
static int |
MARGIN_BOX_VERTICAL |
| Constructor and Description |
|---|
BoxBuilder() |
| Modifier and Type | Method and Description |
|---|---|
static void |
createChildren(LayoutContext c,
BlockBox parent) |
static TableBox |
createMarginTable(LayoutContext c,
PageInfo pageInfo,
MarginBoxName[] names,
int height,
int direction) |
static BlockBox |
createRootBox(LayoutContext c,
Document document) |
static BlockBox |
getRunningBlock(LayoutContext c,
PropertyValue value) |
static void |
insertGeneratedContent(LayoutContext c,
Element element,
CalculatedStyle parentStyle,
String peName,
List<Styleable> children,
BoxBuilder.ChildBoxInfo info) |
static boolean |
isAttrFunction(FSFunction function) |
static boolean |
isElementFunction(FSFunction function) |
static CounterFunction |
makeCounterFunction(FSFunction function,
LayoutContext c,
CalculatedStyle style) |
public static final int MARGIN_BOX_VERTICAL
public static final int MARGIN_BOX_HORIZONTAL
public static BlockBox createRootBox(LayoutContext c, Document document)
public static void createChildren(LayoutContext c, BlockBox parent)
public static TableBox createMarginTable(LayoutContext c, PageInfo pageInfo, MarginBoxName[] names, int height, int direction)
public static boolean isAttrFunction(FSFunction function)
public static boolean isElementFunction(FSFunction function)
public static CounterFunction makeCounterFunction(FSFunction function, LayoutContext c, CalculatedStyle style)
public static BlockBox getRunningBlock(LayoutContext c, PropertyValue value)
public static void insertGeneratedContent(LayoutContext c, Element element, CalculatedStyle parentStyle, String peName, List<Styleable> children, BoxBuilder.ChildBoxInfo info)
Copyright © 2004–2025. All rights reserved.