aspose.pdf
Class Paragraph

java.lang.Object
  extended by aspose.pdf.Paragraph
Direct Known Subclasses:
Attachment, Canvas, DocumentAttachment, FloatingBox, FormField, Graph, Image, RadioButton, Table, Text

public abstract class Paragraph
extends java.lang.Object

Represents a paragraph object.


Nested Class Summary
 class Paragraph.VerticalPositionInfo
          for Text MarginInfo
 
Field Summary
protected  int _realPageNumber
          Real PageNumber of the paragraph.
static int INNER_INDENT
           
 boolean isNeedAddToPage
          Indicates whether the paragraph need add to page or not.
 boolean isPositionProcessed
          Indicates whether the paragraph'position has been processed.
 Paragraph.VerticalPositionInfo VerticalPosInfo
          Indicates the paragraph's vertical position information.
 
Constructor Summary
Paragraph()
          Initializes a new instance of the Paragraph class.
 
Method Summary
abstract  java.lang.Object completeClone()
           
 void copyTo(Paragraph par)
           
 float getHeight()
          Gets a float value that indicates the Height of the paragraph
 java.lang.String getID()
          Gets a String that indicates the ID of the paragraph.
 boolean getIsNeedAddToPage()
          Gets a boolean value that indicates whether the paragraph need add to page or not.
 boolean getIsPositionGot()
          Gets a boolean value that indicates whether the paragraph is Position Got
 boolean getIsPositionProcessed()
          Gets a boolean value that indicates whether the paragraph'position has been processed.
 float getLeft()
          Gets a float value that indicates the left position of the paragraph.
 MarginInfo getMargin()
          Get MarginInfo object that indicates the margin info of the paragraph.
 boolean getMayNeedReprocess()
          Gets a boolean value that indicates whether the paragraph may need be reprocessed or not.
 boolean getNeedReprocess()
          Gets a boolean value that indicates the paragraph need processing or not.
 Paragraph getNextParagraphInHeading()
          Gets a Paragraph object that indicates the next paragraph in heading link.
 int getPageNumber()
          Gets a int value that indicates the PageNumber of the paragraph.
 Cell getParentCell()
          get Cell object that indicates the parent cell of the paragraph.
 PositioningType getPositioningType()
          Get the positioning type for custom positioning.
 float getPosX()
          Gets a float value that indicates the x-coordinate of the paragraph beginning position.
 float getPosY()
          Gets a float value that indicates the y-coordinate of the paragraph beginning position.
 int getRealPageNumber()
          Gets a int value that indicates real PageNumber of the paragraph.
 java.lang.String getReferenceParagraphID()
          Gets a String that indicates the reference paragraph when using paragraph relative customer positioning.
 Paragraph getRefPara()
          Gets a Paragraph object that indicates the ref paragraph.
 Section getSection()
          get Section object that indicates the parent section of the paragraph.
 float getTop()
          Gets a float value that indicates the top position of the paragraph.
 Paragraph.VerticalPositionInfo getVerticalPosInfo()
          Gets a VerticalPositionInfo object that indicates the paragraph's vertical position information.
 float getWidth()
          Gets a float value that indicates the width of the paragraph
 boolean isDisabled()
          Gets a boolean value that indicates whether this paragraph is disabled.
 boolean isEndNote()
          get a boolean value that indicates if the current Text is endnote.
 boolean isFirstParagraph()
          Gets a boolean value that indicates whether the paragraph is the first paragraph of a page.
 boolean isFirstParagraphInColumn()
          Gets a boolean value that indicates whether the paragraph be the first paragraph of a column.
 boolean isFootNote()
          get a boolean value that indicates this paragraph is footnote or not.
 boolean isFootNoteProcessed()
          get a boolean value that indicates the processing of the footnote.
 boolean isInHeaderFooter()
          Gets a boolean value that indicates whether the paragraph is in Header/Footer
 boolean isInList()
          Get a boolean value that indicates whether this paragraph is used as a list item.
 boolean isKeptTogether()
          Gets a boolean value that indicates whether all lines in the paragraph are to remain on the same page.
 boolean isKeptWithNext()
          Gets a boolean value that indicates whether current paragraph remains in the same page along with next paragraph.
 boolean isOnOddPage()
          Gets a boolean value that indicates whether this paragraph be shown in odd page only.
 void setEndNote(boolean isEndNote)
          set a boolean value that indicates if the current Text is endnote.
 void setFootNoteProcessed(boolean footNoteProcessed)
          set a boolean value that indicates the processing of the footnote.
 void setHeight(float paraHeight)
          Sets a float value that indicates the Height of the paragraph
 void setID(java.lang.String paraID)
          Sets a String that indicates the ID of the paragraph.
 void setIsDisabled(boolean isDisabled)
          Sets a boolean value that indicates whether this paragraph is disabled.
 void setIsFirstParagraph(boolean isFirstParagraph)
          Sets a boolean value that indicates whether the paragraph is the first paragraph of a page.
 void setIsFirstParagraphInColumn(boolean isFirstInColumn)
          Sets a boolean value that indicates whether the paragraph be the first paragraph of a column.
 void setIsFootNote(boolean isFootNote)
          set a boolean value that indicates this paragraph is footnote or not.
 void setIsInHeaderFooter(boolean isInHeaderFooter)
          Sets a boolean value that indicates whether the paragraph is in Header/Footer
 void setIsInList(boolean isInList)
          Set a boolean value that indicates whether this paragraph is used as a list item.
 void setIsKeptTogether(boolean isKeptTogether)
          Sets a boolean value that indicates whether all lines in the paragraph are to remain on the same page.
 void setIsKeptWithNext(boolean isKeptWithNext)
          Sets a boolean value that indicates whether current paragraph remains in the same page along with next paragraph.
 void setIsNeedAddToPage(boolean isNeedAddToPage)
          Sets a boolean value that indicates whether the paragraph need add to page or not.
 void setIsOnOddPage(boolean isOnOddPage)
          Sets a boolean value that indicates whether this paragraph be shown in odd page only.
 void setIsPositionGot(boolean isPositionGot)
          Sets a boolean value that indicates whether the paragraph is Position Got
 void setIsPositionProcessed(boolean isPositionProcessed)
          Sets a boolean value that indicates whether the paragraph'position has been processed.
 void setLeft(float leftPos)
          Sets a float value that indicates the left position of the paragraph.
 void setMargin(MarginInfo paragraphMargin)
          sets MarginInfo object that indicates the margin info of the paragraph.
 void setMayNeedReprocess(boolean mayNeedReprocess)
          Sets a boolean value that indicates whether the paragraph may need be reprocessed or not.
 void setNeedReprocess(boolean isNeedReprocess)
          Sets a boolean value that indicates the paragraph need processing or not.
 void setNextParagraphInHeading(Paragraph nextParaInHeading)
          Sets a Paragraph object that indicates the next paragraph in heading link.
 void setPageNumber(int paragraphPageNumber)
          Sets a int value that indicates the PageNumber of the paragraph.
 void setParentCell(Cell parCell)
          set a boolean value that indicates the parent cell of the paragraph.
 void setParentIsTable(boolean parentIsTable)
          set a boolean value that indicates the parent of this paragraph is table.
 void setPositioningType(PositioningType posType)
          Set the positioning type for custom positioning.
 void setPosX(float posX)
          sets a float value that indicates the x-coordinate of the paragraph beginning position.
 void setPosY(float posY)
          Sets a float value that indicates the y-coordinate of the paragraph beginning position.
 void setRealPageNumber(int realPageNumber)
          Sets a int value that indicates real PageNumber of the paragraph.
 void setReferenceParagraphID(java.lang.String refParaID)
          Sets a String that indicates the reference paragraph when using paragraph relative customer positioning.
 void setRefPara(Paragraph refPara)
          Sets a Paragraph object that indicates the ref paragraph.
 void setSection(Section parentSection)
          set a boolean value that indicates the parent section of the paragraph.
 void setTop(float topPos)
          Sets a float value that indicates the top position of the paragraph.
 void setVerticalPosInfo(Paragraph.VerticalPositionInfo VerticalPosInfo)
          Sets a VerticalPositionInfo value that indicates the paragraph's vertical position information.
 void setWidth(float paraWidth)
          Sets a float value that indicates the width of the paragraph
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

INNER_INDENT

public static final int INNER_INDENT
See Also:
Constant Field Values

_realPageNumber

protected int _realPageNumber
Real PageNumber of the paragraph.


isNeedAddToPage

public boolean isNeedAddToPage
Indicates whether the paragraph need add to page or not.


isPositionProcessed

public boolean isPositionProcessed
Indicates whether the paragraph'position has been processed.


VerticalPosInfo

public Paragraph.VerticalPositionInfo VerticalPosInfo
Indicates the paragraph's vertical position information.

Constructor Detail

Paragraph

public Paragraph()
Initializes a new instance of the Paragraph class.

Method Detail

completeClone

public abstract java.lang.Object completeClone()

setParentIsTable

public void setParentIsTable(boolean parentIsTable)
set a boolean value that indicates the parent of this paragraph is table.

Parameters:
parentIsTable -

isFootNoteProcessed

public boolean isFootNoteProcessed()
get a boolean value that indicates the processing of the footnote.


setFootNoteProcessed

public void setFootNoteProcessed(boolean footNoteProcessed)
set a boolean value that indicates the processing of the footnote.

Parameters:
footNoteProcessed -

isFootNote

public boolean isFootNote()
get a boolean value that indicates this paragraph is footnote or not.


setIsFootNote

public void setIsFootNote(boolean isFootNote)
set a boolean value that indicates this paragraph is footnote or not.

Parameters:
isFootNote -

isEndNote

public boolean isEndNote()
get a boolean value that indicates if the current Text is endnote.


setEndNote

public void setEndNote(boolean isEndNote)
set a boolean value that indicates if the current Text is endnote.

Parameters:
isEndNote -

getSection

public Section getSection()
get Section object that indicates the parent section of the paragraph.


setSection

public void setSection(Section parentSection)
set a boolean value that indicates the parent section of the paragraph.

Parameters:
parentSection -

getParentCell

public Cell getParentCell()
get Cell object that indicates the parent cell of the paragraph.


setParentCell

public void setParentCell(Cell parCell)
set a boolean value that indicates the parent cell of the paragraph.

Parameters:
parCell -

getMargin

public MarginInfo getMargin()
Get MarginInfo object that indicates the margin info of the paragraph.


setMargin

public void setMargin(MarginInfo paragraphMargin)
sets MarginInfo object that indicates the margin info of the paragraph.

Parameters:
paragraphMargin -

getPosX

public float getPosX()
Gets a float value that indicates the x-coordinate of the paragraph beginning position.


setPosX

public void setPosX(float posX)
sets a float value that indicates the x-coordinate of the paragraph beginning position.

Parameters:
posX -

getPosY

public float getPosY()
Gets a float value that indicates the y-coordinate of the paragraph beginning position.


setPosY

public void setPosY(float posY)
Sets a float value that indicates the y-coordinate of the paragraph beginning position.

Parameters:
posY -

getWidth

public float getWidth()
Gets a float value that indicates the width of the paragraph


setWidth

public void setWidth(float paraWidth)
Sets a float value that indicates the width of the paragraph

Parameters:
paraWidth -

getHeight

public float getHeight()
Gets a float value that indicates the Height of the paragraph


setHeight

public void setHeight(float paraHeight)
Sets a float value that indicates the Height of the paragraph

Parameters:
paraHeight -

getPageNumber

public int getPageNumber()
Gets a int value that indicates the PageNumber of the paragraph.


setPageNumber

public void setPageNumber(int paragraphPageNumber)
Sets a int value that indicates the PageNumber of the paragraph.

Parameters:
paragraphPageNumber -

getRealPageNumber

public int getRealPageNumber()
Gets a int value that indicates real PageNumber of the paragraph.


setRealPageNumber

public void setRealPageNumber(int realPageNumber)
Sets a int value that indicates real PageNumber of the paragraph.

Parameters:
realPageNumber -

getNextParagraphInHeading

public Paragraph getNextParagraphInHeading()
Gets a Paragraph object that indicates the next paragraph in heading link.


setNextParagraphInHeading

public void setNextParagraphInHeading(Paragraph nextParaInHeading)
Sets a Paragraph object that indicates the next paragraph in heading link.

Parameters:
nextParaInHeading -

getID

public java.lang.String getID()
Gets a String that indicates the ID of the paragraph.


setID

public void setID(java.lang.String paraID)
Sets a String that indicates the ID of the paragraph.

Parameters:
paraID -

isFirstParagraph

public boolean isFirstParagraph()
Gets a boolean value that indicates whether the paragraph is the first paragraph of a page. If this property is set to true,Aspose.Pdf will start a new page for this paragraph.


setIsFirstParagraph

public void setIsFirstParagraph(boolean isFirstParagraph)
Sets a boolean value that indicates whether the paragraph is the first paragraph of a page. If this property is set to true,Aspose.Pdf will start a new page for this paragraph.

Parameters:
isFirstParagraph -

isFirstParagraphInColumn

public boolean isFirstParagraphInColumn()
Gets a boolean value that indicates whether the paragraph be the first paragraph of a column.


setIsFirstParagraphInColumn

public void setIsFirstParagraphInColumn(boolean isFirstInColumn)
Sets a boolean value that indicates whether the paragraph be the first paragraph of a column.

Parameters:
isFirstInColumn -

isKeptTogether

public boolean isKeptTogether()
Gets a boolean value that indicates whether all lines in the paragraph are to remain on the same page. Default is false. This property only affects paragraphs in section (but not in table).


setIsKeptTogether

public void setIsKeptTogether(boolean isKeptTogether)
Sets a boolean value that indicates whether all lines in the paragraph are to remain on the same page. Default is false. This property only affects paragraphs in section (but not in table).

Parameters:
isKeptTogether -

isKeptWithNext

public boolean isKeptWithNext()
Gets a boolean value that indicates whether current paragraph remains in the same page along with next paragraph. Default is false. This property only affects paragraphs in section (but ont in table) except FloatingBox, which position is set by manual.


setIsKeptWithNext

public void setIsKeptWithNext(boolean isKeptWithNext)
Sets a boolean value that indicates whether current paragraph remains in the same page along with next paragraph. Default is false. This property only affects paragraphs in section (but ont in table) except FloatingBox, which position is set by manual.

Parameters:
isKeptWithNext -

isDisabled

public boolean isDisabled()
Gets a boolean value that indicates whether this paragraph is disabled. The default value is false. If this property is set to true, this paragraph will not be rendered.


setIsDisabled

public void setIsDisabled(boolean isDisabled)
Sets a boolean value that indicates whether this paragraph is disabled. The default value is false. If this property is set to true, this paragraph will not be rendered.

Parameters:
isDisabled -

isInList

public boolean isInList()
Get a boolean value that indicates whether this paragraph is used as a list item. The default value is false. If this property is set to true, this paragraph will appear in the list when the list is constructed.


setIsInList

public void setIsInList(boolean isInList)
Set a boolean value that indicates whether this paragraph is used as a list item. The default value is false. If this property is set to true, this paragraph will appear in the list when the list is constructed.

Parameters:
isInList -

isOnOddPage

public boolean isOnOddPage()
Gets a boolean value that indicates whether this paragraph be shown in odd page only. This property used for duplex Printing. If you want to print a paragraph in a new odd page in duplex Printing,you can set "IsFirstParagraph = true" and "IsOnOddPage = true".


setIsOnOddPage

public void setIsOnOddPage(boolean isOnOddPage)
Sets a boolean value that indicates whether this paragraph be shown in odd page only. This property used for duplex Printing. If you want to print a paragraph in a new odd page in duplex Printing,you can set "IsFirstParagraph = true" and "IsOnOddPage = true".

Parameters:
isOnOddPage -

getLeft

public float getLeft()
Gets a float value that indicates the left position of the paragraph. The unit is point.

Remarks: The property is used for custom positioning. You need not use this property if you want the paragraph be auto aligned.


setLeft

public void setLeft(float leftPos)
Sets a float value that indicates the left position of the paragraph. The unit is point.

Parameters:
leftPos -

getTop

public float getTop()
Gets a float value that indicates the top position of the paragraph. The unit is point.

Remarks: The property is used for custom positioning. You need not use this property if you want the paragraph be auto aligned.


setTop

public void setTop(float topPos)
Sets a float value that indicates the top position of the paragraph. The unit is point.

Remarks: The property is used for custom positioning. You need not use this property if you want the paragraph be auto aligned.

Parameters:
topPos -

getPositioningType

public PositioningType getPositioningType()
Get the positioning type for custom positioning. Default value is Auto (don not use custom positioning).


setPositioningType

public void setPositioningType(PositioningType posType)
Set the positioning type for custom positioning.

Parameters:
posType -

getReferenceParagraphID

public java.lang.String getReferenceParagraphID()
Gets a String that indicates the reference paragraph when using paragraph relative customer positioning.

Remarks: The reference paragraph must be ahead of the current paragraph in the document object model.


setReferenceParagraphID

public void setReferenceParagraphID(java.lang.String refParaID)
Sets a String that indicates the reference paragraph when using paragraph relative customer positioning.

Remarks: The reference paragraph must be ahead of the current paragraph in the document object model.

Parameters:
refParaID -

getRefPara

public Paragraph getRefPara()
Gets a Paragraph object that indicates the ref paragraph.


setRefPara

public void setRefPara(Paragraph refPara)
Sets a Paragraph object that indicates the ref paragraph.

Parameters:
refPara -

getNeedReprocess

public boolean getNeedReprocess()
Gets a boolean value that indicates the paragraph need processing or not.


setNeedReprocess

public void setNeedReprocess(boolean isNeedReprocess)
Sets a boolean value that indicates the paragraph need processing or not.

Parameters:
isNeedReprocess -

isInHeaderFooter

public boolean isInHeaderFooter()
Gets a boolean value that indicates whether the paragraph is in Header/Footer


setIsInHeaderFooter

public void setIsInHeaderFooter(boolean isInHeaderFooter)
Sets a boolean value that indicates whether the paragraph is in Header/Footer

Parameters:
isInHeaderFooter -

getIsPositionGot

public boolean getIsPositionGot()
Gets a boolean value that indicates whether the paragraph is Position Got


setIsPositionGot

public void setIsPositionGot(boolean isPositionGot)
Sets a boolean value that indicates whether the paragraph is Position Got

Parameters:
isPositionGot -

getIsNeedAddToPage

public boolean getIsNeedAddToPage()
Gets a boolean value that indicates whether the paragraph need add to page or not.


setIsNeedAddToPage

public void setIsNeedAddToPage(boolean isNeedAddToPage)
Sets a boolean value that indicates whether the paragraph need add to page or not.

Parameters:
isNeedAddToPage -

getIsPositionProcessed

public boolean getIsPositionProcessed()
Gets a boolean value that indicates whether the paragraph'position has been processed.


setIsPositionProcessed

public void setIsPositionProcessed(boolean isPositionProcessed)
Sets a boolean value that indicates whether the paragraph'position has been processed.

Parameters:
isPositionProcessed -

getMayNeedReprocess

public boolean getMayNeedReprocess()
Gets a boolean value that indicates whether the paragraph may need be reprocessed or not.


setMayNeedReprocess

public void setMayNeedReprocess(boolean mayNeedReprocess)
Sets a boolean value that indicates whether the paragraph may need be reprocessed or not.

Parameters:
mayNeedReprocess -

getVerticalPosInfo

public Paragraph.VerticalPositionInfo getVerticalPosInfo()
Gets a VerticalPositionInfo object that indicates the paragraph's vertical position information.


setVerticalPosInfo

public void setVerticalPosInfo(Paragraph.VerticalPositionInfo VerticalPosInfo)
Sets a VerticalPositionInfo value that indicates the paragraph's vertical position information.

Parameters:
VerticalPosInfo -

copyTo

public void copyTo(Paragraph par)