| java.lang.Object org.netbeans.modules.visualweb.css2.CssBox org.netbeans.modules.visualweb.css2.TextBox
TextBox | final public class TextBox extends CssBox (Code) | | TextBox represents a box of text characters placed within
a LineBox.
See http://www.w3.org/TR/REC-CSS2/visuren.html
author: Tor Norbye |
Constructor Summary | |
public | TextBox(WebForm webform, Element styleElement, Text node, char[] contentChars, String xhtml, String jspx, int beginOffset, int endOffset, Color fg, Color bg, int decoration, FontMetrics metrics, boolean hidden) Create an TextBox representing the text run from
position [beginNode,beginOffset] to position
[endNode,endOffset], formatted using the given style.
Parameters: contentChars - The string to draw text from, as an arrayof chars. Parameters: beginOffset - The offset into the contentChars array where the textfor this inline box begins. Parameters: endOffset - The offset into the contentChars array where the textfor this inline box ends. Parameters: fg - The color to draw the text with Parameters: decoration - A bit mask indicating whether underline, overline,strikethrough etc. |
OVERLINE | final public static int OVERLINE(Code) | | |
STRIKE | final public static int STRIKE(Code) | | |
UNDERLINE | final public static int UNDERLINE(Code) | | |
TextBox | public TextBox(WebForm webform, Element styleElement, Text node, char[] contentChars, String xhtml, String jspx, int beginOffset, int endOffset, Color fg, Color bg, int decoration, FontMetrics metrics, boolean hidden)(Code) | | Create an TextBox representing the text run from
position [beginNode,beginOffset] to position
[endNode,endOffset], formatted using the given style.
Parameters: contentChars - The string to draw text from, as an arrayof chars. Parameters: beginOffset - The offset into the contentChars array where the textfor this inline box begins. Parameters: endOffset - The offset into the contentChars array where the textfor this inline box ends. Parameters: fg - The color to draw the text with Parameters: decoration - A bit mask indicating whether underline, overline,strikethrough etc. should be drawn according to the UNDERLINE,STRIKE etc. constant fields of the class. Parameters: metrics - The font metrics (& font, via metrics.getFont()) touse to render this text. |
computePosition | public DomPosition computePosition(int px)(Code) | | TODO: rename to computePosition
|
getBaseline | public int getBaseline()(Code) | | |
getBoundingBox | public Rectangle getBoundingBox(DomPosition pos)(Code) | | Return the bounding box of the character at the given position
|
getDomEndOffset | public int getDomEndOffset()(Code) | | Return the ending offset within the text node that this box represents
|
getDomStartOffset | public int getDomStartOffset()(Code) | | Return the beginning offset within the text node that this box represents
|
getFirstPosition | public DomPosition getFirstPosition()(Code) | | Return the first position in the document of this text node
|
getIntrinsicHeight | public int getIntrinsicHeight()(Code) | | |
getIntrinsicWidth | public int getIntrinsicWidth()(Code) | | |
getLastPosition | public DomPosition getLastPosition()(Code) | | Return the last position in the document of this text node
|
getNext | public DomPosition getNext(DomPosition pos)(Code) | | Given the position, return the next position within this textbox if available
or Position.NONE if not.
|
getNode | public Text getNode()(Code) | | Return the node this text box is associated with
|
getPrev | public DomPosition getPrev(DomPosition pos)(Code) | | Given the position, return the previous position within this textbox if available
or Position.NONE if not.
|
initialize | protected void initialize()(Code) | | |
initializeDesignBean | protected void initializeDesignBean()(Code) | | |
initializeHorizontalWidths | protected void initializeHorizontalWidths(FormatContext context)(Code) | | Can't set widths on text boxes themselves
|
initializeInvariants | protected void initializeInvariants()(Code) | | |
isOverline | public boolean isOverline()(Code) | | |
isStrikeThrough | public boolean isStrikeThrough()(Code) | | |
isUnderline | public boolean isUnderline()(Code) | | |
paintBackground | protected void paintBackground(Graphics g, int px, int py)(Code) | | |
Methods inherited from org.netbeans.modules.visualweb.css2.CssBox | protected void clearBottom(FormatContext context, CssValue cssSide)(Code)(Java Doc) protected void clearTop(FormatContext context, CssValue cssSide)(Code)(Java Doc) protected Rectangle computeBounds(Element componentRootElement, Rectangle bounds)(Code)(Java Doc) protected void computeHorizNonInlineNormalFlow(FormatContext context, int parentWidth)(Code)(Java Doc) void computeHorizontalLengths(FormatContext context)(Code)(Java Doc) protected void computeRectangles(Element componentRootElement, List<Rectangle> list)(Code)(Java Doc) final public Rectangle computeRegionBounds(Element regionElement, Rectangle bounds)(Code)(Java Doc) void computeVerticalLengths(FormatContext context)(Code)(Java Doc) protected CssValue computeWidthCssValue()(Code)(Java Doc) protected void considerDesignBorder()(Code)(Java Doc) protected CssBox findCssBox(int x, int y, int px, int py, int depth)(Code)(Java Doc) protected CssBox findCssBoxForComponentRootElement(Element componentRootElement)(Code)(Java Doc) public int getAbsoluteX()(Code)(Java Doc) public int getAbsoluteY()(Code)(Java Doc) protected int getBaseline()(Code)(Java Doc) public Color getBg()(Code)(Java Doc) public int getBlockHeight()(Code)(Java Doc) public int getBlockWidth()(Code)(Java Doc) public Rectangle getBorderWidthRectangle()(Code)(Java Doc) public CssBox getBox(int index)(Code)(Java Doc) public int getBoxCount()(Code)(Java Doc) public BoxType getBoxType()(Code)(Java Doc) public String getBoxTypeName()(Code)(Java Doc) public Rectangle getCBRectangle()(Code)(Java Doc) public Box[] getChildren()(Code)(Java Doc) protected int getCollapsedBottomMargin()(Code)(Java Doc) protected int getCollapsedTopMargin()(Code)(Java Doc) public Element getComponentRootElement()(Code)(Java Doc) public static Element getComponentRootElementForCssBox(CssBox cssBox)(Code)(Java Doc) public String getComputedStyles()(Code)(Java Doc) protected int getContentHeight()(Code)(Java Doc) public Dimension getContentSize()(Code)(Java Doc) protected int getContentWidth()(Code)(Java Doc) protected int getContentX()(Code)(Java Doc) protected int getContentY()(Code)(Java Doc) protected int getContributingBaseline()(Code)(Java Doc) public Insets getCssSizeInsets()(Code)(Java Doc) public Decoration getDecoration()(Code)(Java Doc) protected int getEffectiveBottomMargin()(Code)(Java Doc) public int getEffectiveTopMargin()(Code)(Java Doc) final public Element getElement()(Code)(Java Doc) public static Element getElementForComponentRootCssBox(CssBox cssBox)(Code)(Java Doc) protected int getExtentX()(Code)(Java Doc) protected int getExtentX2()(Code)(Java Doc) protected int getExtentY()(Code)(Java Doc) protected int getExtentY2()(Code)(Java Doc) public Rectangle getExtentsRectangle()(Code)(Java Doc) CssBox getFirstNormalBox()(Code)(Java Doc) public int getHeight()(Code)(Java Doc) public int getInternalResizeDirection(int x, int y)(Code)(Java Doc) public Interaction getInternalResizer(int x, int y)(Code)(Java Doc) protected int getIntrinsicHeight()(Code)(Java Doc) protected int getIntrinsicWidth()(Code)(Java Doc) public int getLeftMargin()(Code)(Java Doc) public Rectangle getMarginRectangle()(Code)(Java Doc) protected CssBox getNextNormalBlockBox()(Code)(Java Doc) protected CssBox getNextNormalBox()(Code)(Java Doc) public Rectangle getPaddingRectangle()(Code)(Java Doc) public boolean getPaintPositions()(Code)(Java Doc) public boolean getPaintSpaces()(Code)(Java Doc) public boolean getPaintText()(Code)(Java Doc) final public ContainerBox getParent()(Code)(Java Doc) protected int getParentIndex()(Code)(Java Doc) public Point getPosition()(Code)(Java Doc) public Rectangle getPositionRect()(Code)(Java Doc) public CssBox getPositionedBy()(Code)(Java Doc) protected int getPrefMinWidth()(Code)(Java Doc) protected int getPrefWidth()(Code)(Java Doc) protected CssBox getPrevNormalBlockBox()(Code)(Java Doc) protected CssBox getPrevNormalBox()(Code)(Java Doc) public Point getRelPosition()(Code)(Java Doc) public int getRightMargin()(Code)(Java Doc) public String getRules()(Code)(Java Doc) public Dimension getSize()(Code)(Java Doc) final public Element getSourceElement()(Code)(Java Doc) public String getStyles()(Code)(Java Doc) public HtmlTag getTag()(Code)(Java Doc) public WebForm getWebForm()(Code)(Java Doc) public int getWidth()(Code)(Java Doc) public int getX()(Code)(Java Doc) public int getY()(Code)(Java Doc) public int getZ()(Code)(Java Doc) final protected boolean hasInitialFocus()(Code)(Java Doc) protected boolean hasNormalBlockLevelChildren()(Code)(Java Doc) protected void initialize()(Code)(Java Doc) protected void initializeBackground()(Code)(Java Doc) protected void initializeBackgroundColor()(Code)(Java Doc) protected void initializeBackgroundImage()(Code)(Java Doc) protected void initializeBorder()(Code)(Java Doc) protected void initializeContentSize()(Code)(Java Doc) protected void initializeDesignBean()(Code)(Java Doc) protected void initializeHorizontalWidths(FormatContext context)(Code)(Java Doc) protected void initializeInvariants()(Code)(Java Doc) protected void initializeMargins()(Code)(Java Doc) protected void initializePadding()(Code)(Java Doc) protected void initializeZOrder()(Code)(Java Doc) public boolean isAbsolutelyPositioned()(Code)(Java Doc) public boolean isBlockLevel()(Code)(Java Doc) protected boolean isBorderSizeIncluded()(Code)(Java Doc) public boolean isClearBox()(Code)(Java Doc) public boolean isGrid()(Code)(Java Doc) public boolean isInlineBox()(Code)(Java Doc) protected boolean isPlaceHolder()(Code)(Java Doc) public boolean isPositioned()(Code)(Java Doc) public boolean isReplacedBox()(Code)(Java Doc) public void list(PrintStream out, int indent)(Code)(Java Doc) public void list(PrintWriter out, int indent)(Code)(Java Doc) public void paint(Graphics g, int px, int py)(Code)(Java Doc) protected void paintBackground(Graphics g, int x, int y)(Code)(Java Doc) protected void paintBox(Graphics g, int x, int y, int w, int h)(Code)(Java Doc) protected void paintDebugPositioning(Graphics g)(Code)(Java Doc) protected void paintDecoration(Graphics g, int x, int y)(Code)(Java Doc) final protected void paintFocusWaterMark(Graphics g, int x, int y)(Code)(Java Doc) protected String paramString()(Code)(Java Doc) void putBoxReference(Element element, CssBox box)(Code)(Java Doc) protected void relayout(FormatContext context)(Code)(Java Doc) protected void setContainingBlock(int x, int y, int width, int height)(Code)(Java Doc) final public void setLocation(int x, int y)(Code)(Java Doc) public void setMargins(int leftMargin, int effectiveTopMargin)(Code)(Java Doc) public void setPaintPositions(boolean paintPositioning)(Code)(Java Doc) public void setPaintSpaces(boolean paintSpaces)(Code)(Java Doc) public void setPaintText(boolean paintText)(Code)(Java Doc) final void setParent(ContainerBox parent)(Code)(Java Doc) void setParentIndex(int idx)(Code)(Java Doc) void setPositionedBy(CssBox positionedBy)(Code)(Java Doc) void setX(int x)(Code)(Java Doc) void setY(int y)(Code)(Java Doc) protected int shrinkToFit(int availableWidth, FormatContext context)(Code)(Java Doc) final public String toString()(Code)(Java Doc) protected void uncomputeWidthCssValue()(Code)(Java Doc) protected void updateAutoContentSize()(Code)(Java Doc) protected void updateExtents(int px, int py, int depth)(Code)(Java Doc)
|
|
|