Examples of BorderProps


Examples of org.apache.fop.traits.BorderProps

    }

    private static BorderProps getBorderProps(CommonBorderPaddingBackground bordProps, int side) {
        int width = bordProps.getBorderWidth(side, false);
        if (width != 0) {
            BorderProps bps;
            bps = new BorderProps(bordProps.getBorderStyle(side),
                                  width,
                                  bordProps.getBorderColor(side),
                                  BorderProps.SEPARATE);
            return bps;
        } else {
View Full Code Here

Examples of org.apache.fop.traits.BorderProps

    private static BorderProps getCollapsingBorderProps(BorderInfo borderInfo, boolean outer) {
        assert borderInfo != null;
        int width = borderInfo.getRetainedWidth();
        if (width != 0) {
            return new BorderProps(borderInfo.getStyle(), width, borderInfo.getColor(),
                    (outer ? BorderProps.COLLAPSE_OUTER : BorderProps.COLLAPSE_INNER));
        } else {
            return null;
        }
    }
View Full Code Here

Examples of org.apache.fop.traits.BorderProps

            float width, float height,
            BorderProps bpsBefore, BorderProps bpsAfter,
            BorderProps bpsStart, BorderProps bpsEnd, int level) {
        Rectangle rect = toMillipointRectangle(startx, starty, width, height);
        try {
            BorderProps bpsTop = bpsBefore;
            BorderProps bpsBottom = bpsAfter;
            BorderProps bpsLeft;
            BorderProps bpsRight;
            if ( ( level == -1 ) || ( ( level & 1 ) == 0 ) ) {
                bpsLeft = bpsStart;
                bpsRight = bpsEnd;
            } else {
                bpsLeft = bpsEnd;
View Full Code Here

Examples of org.apache.fop.traits.BorderProps

        if (blocks[i][j] == null) {
            blocks[i][j] = new Block();
            blocks[i][j].addTrait(Trait.IS_REFERENCE_AREA, Boolean.TRUE);
            blocks[i][j].setPositioning(Block.ABSOLUTE);
        }
        blocks[i][j].addTrait(side, new BorderProps(border.getStyle(),
                border.getRetainedWidth(), border.getColor(),
                outer ? BorderProps.COLLAPSE_OUTER : BorderProps.COLLAPSE_INNER));
    }
View Full Code Here

Examples of org.apache.fop.traits.BorderProps

     * @param width the width of the area
     * @param height the height of the area
     */
    protected void drawBackAndBorders(Area area, float startx, float starty,
            float width, float height) {
        BorderProps bpsBefore = (BorderProps) area.getTrait(Trait.BORDER_BEFORE);
        BorderProps bpsAfter = (BorderProps) area.getTrait(Trait.BORDER_AFTER);
        BorderProps bpsStart = (BorderProps) area.getTrait(Trait.BORDER_START);
        BorderProps bpsEnd = (BorderProps) area.getTrait(Trait.BORDER_END);
   
        // draw background
        Trait.Background back;
        back = (Trait.Background) area.getTrait(Trait.BACKGROUND);
        if (back != null) {
View Full Code Here

Examples of org.apache.fop.traits.BorderProps

    protected void drawBackAndBorders(Area area,
                    float startx, float starty,
                    float width, float height) {
        // draw background then border

        BorderProps bpsBefore = (BorderProps)area.getTrait(Trait.BORDER_BEFORE);
        BorderProps bpsAfter = (BorderProps)area.getTrait(Trait.BORDER_AFTER);
        BorderProps bpsStart = (BorderProps)area.getTrait(Trait.BORDER_START);
        BorderProps bpsEnd = (BorderProps)area.getTrait(Trait.BORDER_END);

        Trait.Background back;
        back = (Trait.Background)area.getTrait(Trait.BACKGROUND);
        if (back != null) {
            endTextObject();
View Full Code Here

Examples of org.apache.fop.traits.BorderProps

     *
     * @return width in millipoints
     */
    public int getBorderAndPaddingWidthBefore() {
        int margin = 0;
        BorderProps bps = (BorderProps) getTrait(Trait.BORDER_BEFORE);
        if (bps != null) {
            margin = bps.width;
        }
       
        Integer padWidth = (Integer) getTrait(Trait.PADDING_BEFORE);
View Full Code Here

Examples of org.apache.fop.traits.BorderProps

     * @return width in millipoints
     */
    public int getBorderAndPaddingWidthAfter() {
        int margin = 0;
       
        BorderProps bps = (BorderProps) getTrait(Trait.BORDER_AFTER);
        if (bps != null) {
            margin = bps.width;
        }
       
        Integer padWidth = (Integer) getTrait(Trait.PADDING_AFTER);
View Full Code Here

Examples of org.apache.fop.traits.BorderProps

     *
     * @return width in millipoints
     */
    public int getBorderAndPaddingWidthStart() {
        int margin = 0;
        BorderProps bps = (BorderProps) getTrait(Trait.BORDER_START);
        if (bps != null) {
            margin = bps.width;
        }
       
        Integer padWidth = (Integer) getTrait(Trait.PADDING_START);
View Full Code Here

Examples of org.apache.fop.traits.BorderProps

     *
     * @return width in millipoints
     */
    public int getBorderAndPaddingWidthEnd() {
        int margin = 0;
        BorderProps bps = (BorderProps) getTrait(Trait.BORDER_END);
        if (bps != null) {
            margin = bps.width;
        }
       
        Integer padWidth = (Integer) getTrait(Trait.PADDING_END);
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.