Class PdfDiv

    • Field Detail

      • content

        private java.util.ArrayList<Element> content
      • left

        private java.lang.Float left
      • top

        private java.lang.Float top
      • right

        private java.lang.Float right
      • bottom

        private java.lang.Float bottom
      • width

        private java.lang.Float width
      • height

        private java.lang.Float height
      • percentageHeight

        private java.lang.Float percentageHeight
      • percentageWidth

        private java.lang.Float percentageWidth
      • contentWidth

        private float contentWidth
      • contentHeight

        private float contentHeight
      • textAlignment

        private int textAlignment
      • paddingLeft

        private float paddingLeft
      • paddingRight

        private float paddingRight
      • paddingTop

        private float paddingTop
      • paddingBottom

        private float paddingBottom
      • yLine

        private float yLine
      • runDirection

        protected int runDirection
      • keepTogether

        private boolean keepTogether
        Defines if the div should be kept on one page if possible
      • accessibleAttributes

        protected java.util.HashMap<PdfName,​PdfObject> accessibleAttributes
      • backgroundColor

        private BaseColor backgroundColor
      • backgroundImage

        private Image backgroundImage
      • backgroundImageWidth

        private java.lang.Float backgroundImageWidth
      • backgroundImageHeight

        private java.lang.Float backgroundImageHeight
      • spacingBefore

        protected float spacingBefore
        The spacing before the table.
      • spacingAfter

        protected float spacingAfter
        The spacing after the table.
    • Constructor Detail

      • PdfDiv

        public PdfDiv()
    • Method Detail

      • getContentWidth

        public float getContentWidth()
      • setContentWidth

        public void setContentWidth​(float contentWidth)
      • getContentHeight

        public float getContentHeight()
      • setContentHeight

        public void setContentHeight​(float contentHeight)
      • getPercentageHeight

        public java.lang.Float getPercentageHeight()
      • setPercentageHeight

        public void setPercentageHeight​(java.lang.Float percentageHeight)
      • getPercentageWidth

        public java.lang.Float getPercentageWidth()
      • setPercentageWidth

        public void setPercentageWidth​(java.lang.Float percentageWidth)
      • getBackgroundColor

        public BaseColor getBackgroundColor()
      • setBackgroundColor

        public void setBackgroundColor​(BaseColor backgroundColor)
      • setBackgroundImage

        public void setBackgroundImage​(Image image)
        Image will be scaled to fit in the div occupied area.
      • setBackgroundImage

        public void setBackgroundImage​(Image image,
                                       float width,
                                       float height)
        Image will be scaled to fit in the div occupied area.
      • getYLine

        public float getYLine()
      • getRunDirection

        public int getRunDirection()
      • setRunDirection

        public void setRunDirection​(int runDirection)
      • getKeepTogether

        public boolean getKeepTogether()
      • setKeepTogether

        public void setKeepTogether​(boolean keepTogether)
      • getChunks

        public java.util.List<Chunk> getChunks()
        Gets all the chunks in this element.
        Specified by:
        getChunks in interface Element
        Returns:
        an ArrayList
      • type

        public int type()
        Gets the type of the text element.
        Specified by:
        type in interface Element
        Returns:
        a type
      • isContent

        public boolean isContent()
        Description copied from interface: Element
        Checks if this element is a content object. If not, it's a metadata object.
        Specified by:
        isContent in interface Element
        Returns:
        true if this is a 'content' element; false if this is a 'metadata' element
        Since:
        iText 2.0.8
        See Also:
        Element.isContent()
      • isNestable

        public boolean isNestable()
        Description copied from interface: Element
        Checks if this element is nestable.
        Specified by:
        isNestable in interface Element
        Returns:
        true if this element can be nested inside other elements.
        Since:
        iText 2.0.8
        See Also:
        Element.isNestable()
      • process

        public boolean process​(ElementListener listener)
        Processes the element by adding it (or the different parts) to an ElementListener.
        Specified by:
        process in interface Element
        Parameters:
        listener - an ElementListener
        Returns:
        true if the element was processed successfully
      • setSpacingBefore

        public void setSpacingBefore​(float spacing)
        Sets the spacing before this table.
        Specified by:
        setSpacingBefore in interface Spaceable
        Parameters:
        spacing - the new spacing
      • setSpacingAfter

        public void setSpacingAfter​(float spacing)
        Sets the spacing after this table.
        Specified by:
        setSpacingAfter in interface Spaceable
        Parameters:
        spacing - the new spacing
      • getSpacingBefore

        public float getSpacingBefore()
        Gets the spacing before this table.
        Specified by:
        getSpacingBefore in interface Spaceable
        Returns:
        the spacing
      • getSpacingAfter

        public float getSpacingAfter()
        Gets the spacing after this table.
        Specified by:
        getSpacingAfter in interface Spaceable
        Returns:
        the spacing
      • getTextAlignment

        public int getTextAlignment()
        Gets the alignment of this paragraph.
        Returns:
        textAlignment
      • setTextAlignment

        public void setTextAlignment​(int textAlignment)
        Sets the alignment of this paragraph.
        Parameters:
        textAlignment - the new alignment
      • addElement

        public void addElement​(Element element)
      • getLeft

        public java.lang.Float getLeft()
      • setLeft

        public void setLeft​(java.lang.Float left)
      • getRight

        public java.lang.Float getRight()
      • setRight

        public void setRight​(java.lang.Float right)
      • getTop

        public java.lang.Float getTop()
      • setTop

        public void setTop​(java.lang.Float top)
      • getBottom

        public java.lang.Float getBottom()
      • setBottom

        public void setBottom​(java.lang.Float bottom)
      • getWidth

        public java.lang.Float getWidth()
      • setWidth

        public void setWidth​(java.lang.Float width)
      • getHeight

        public java.lang.Float getHeight()
      • setHeight

        public void setHeight​(java.lang.Float height)
      • getPaddingLeft

        public float getPaddingLeft()
      • setPaddingLeft

        public void setPaddingLeft​(float paddingLeft)
      • getPaddingRight

        public float getPaddingRight()
      • setPaddingRight

        public void setPaddingRight​(float paddingRight)
      • setPaddingTop

        public void setPaddingTop​(float paddingTop)
        Specified by:
        setPaddingTop in interface Spaceable
      • getPaddingBottom

        public float getPaddingBottom()
      • setPaddingBottom

        public void setPaddingBottom​(float paddingBottom)
      • getContent

        public java.util.ArrayList<Element> getContent()
      • setContent

        public void setContent​(java.util.ArrayList<Element> content)
      • setRole

        public void setRole​(PdfName role)
        Description copied from interface: IAccessibleElement
        Sets the role of the accessiblee element. Set role to null if you don't want to tag this element. Note that all child elements won't also be tagged.
        Specified by:
        setRole in interface IAccessibleElement