HtmlFragment

Vue de l’ensemble

HtmlFragment est une classe dans Aspose.PDF FOSS pour Java.Déduit de: BaseParagraph.

Il représente un fragment de contenu HTML qui peut être ajouté à la collection des paragraphes d’une page PDF.

Cette classe fournit 19 méthodes pour travailler avec des objets HtmlFragment dans les programmes Java. Les méthodologies disponibles comprennent: HtMLFrage, getHorizontalAlignment , getHpdTexte ; gethyperlink; ‘getMargin : 'ghetTextState: ‘isFirstParagraphInColumn,, ' isInLineParagraf’, ‘ISInNewPage et 'IsKeptWithNext., ‘setFIRSTParagrammInColumn’ et 7 méthode supplémentaires. Tous les membres publics sont accessibles à toute application Java après l’installation de l’Aspoe.PDF FOSS pour le package Java . Propriétés : `first ParagramIncolumn‘, ‘Natal’ArticleIncole,‘Art & Art.

Propriétés

NameTypeAccessDescription
htmlTextStringReadReturns the HTML text content.
textStateTextStateReadReturns the default text state used for rendering the HTML content.
marginMarginInfoReadGets the margin information for this paragraph.
horizontalAlignmentHorizontalAlignmentReadGets the horizontal alignment of this paragraph within its container.
inLineParagraphbooleanReadReturns whether this paragraph is an inline element.
keptWithNextbooleanReadReturns whether this paragraph should be kept together with the next paragraph
on the same page during layout.
firstParagraphInColumnbooleanReadReturns whether this paragraph is the first in its column.
inNewPagebooleanReadReturns whether this paragraph should start on a new page during layout.
hyperlinkHyperlinkReadReturns the hyperlink attached to this paragraph (web, local or file
target), or {@code null} if the paragraph is not clickable.

méthodes

SignatureDescription
HtmlFragment(htmlText: String)Creates a new HtmlFragment with the given HTML content.
getHtmlText()StringReturns the HTML text content.
setHtmlText(htmlText: String)Sets the HTML text content.
getTextState()TextStateReturns the default text state used for rendering the HTML content.
setTextState(textState: TextState)Sets the default text state used for rendering the HTML content.
getMargin()MarginInfoGets the margin information for this paragraph.
setMargin(margin: MarginInfo)Sets the margin information for this paragraph.
getHorizontalAlignment()HorizontalAlignmentGets the horizontal alignment of this paragraph within its container.
setHorizontalAlignment(horizontalAlignment: HorizontalAlignment)Sets the horizontal alignment of this paragraph within its container.
isInLineParagraph()booleanReturns whether this paragraph is an inline element.
setInLineParagraph(inLineParagraph: boolean)Sets whether this paragraph should be treated as an inline element.
isKeptWithNext()booleanReturns whether this paragraph should be kept together with the next paragraph
on the same page during layout.
setKeptWithNext(keptWithNext: boolean)Sets whether this paragraph should be kept together with the next paragraph
on the same page during layout.
isFirstParagraphInColumn()booleanReturns whether this paragraph is the first in its column.
setFirstParagraphInColumn(firstParagraphInColumn: boolean)Sets whether this paragraph is the first in its column.
isInNewPage()booleanReturns whether this paragraph should start on a new page during layout.
setInNewPage(inNewPage: boolean)Sets whether this paragraph should start on a new page during layout.
getHyperlink()HyperlinkReturns the hyperlink attached to this paragraph (web, local or file
target), or {@code null} if the paragraph is not clickable.
setHyperlink(hyperlink: Hyperlink)Attaches a hyperlink to this paragraph.

Voir aussi

  • Aspose.PDF pour Java — API d’entreprise
 Français