Skip to main content

Search OfficeIMO

Enter a topic, API type, or PowerShell command.

Documentation Search all OfficeIMO/
Class

PdfParagraphStyle

OfficeIMO.Pdf

Namespace
OfficeIMO.Pdf
Assembly
OfficeIMO.Pdf
Source revision
be6c300e4ab1 with working tree changes

Describes layout options for rich paragraph rendering.

Inheritance

  • object
  • PdfParagraphStyle

Usage

Explore 6 API references to this type

This type appears in these public API surfaces even when no hand-authored example is attached directly to the page.

Accepted by parameters 3

Constructors

public PdfParagraphStyle() #

Methods

public PdfTabStop AddTabStop(OfficeLength position, PdfTabAlignment alignment = Left, PdfTabLeaderStyle leader = None) #

Adds an explicit paragraph tab stop.

Parameters

position OfficeIMO.OfficeLength required
Physical tab stop position relative to the paragraph text frame.
alignment OfficeIMO.Pdf.PdfTabAlignment = Left optional
Text alignment anchored at this tab stop.
leader OfficeIMO.Pdf.PdfTabLeaderStyle = None optional
Leader fill rendered before the following text.

Returns

PdfTabStop
public void ClearTabStops() #

Removes all explicit paragraph tab stops.

public PdfParagraphStyle Clone() #

Creates a copy of this paragraph style.

Properties

public OfficeLength? FontSize { get; set; } #

Physical fallback font size and empty-line font size. When null the writer uses the current default font size.

public PdfLineSpacing? LineSpacing { get; set; } #

Explicit line spacing. When set, this overrides PdfParagraphStyle.LineHeight.

public double? LineHeight { get; set; } #

Line advance multiplier relative to the paragraph font size. Used when PdfParagraphStyle.LineSpacing is null. When null the writer uses the default line height.

public OfficeLength LeftIndent { get; set; } #

Physical offset from the left edge of the paragraph frame. Negative values extend text into the left margin.

public OfficeLength RightIndent { get; set; } #

Physical offset from the right edge of the paragraph frame. Negative values extend text into the right margin.

public OfficeLength FirstLineIndent { get; set; } #

Physical additional indent for the first line. Negative values create a hanging indent relative to PdfParagraphStyle.LeftIndent.

public OfficeLength SpacingBefore { get; set; } #

Physical space before the paragraph.

public OfficeLength? SpacingAfter { get; set; } #

Physical space after the paragraph. When null the writer uses the default paragraph spacing.

public OfficeLength? DefaultTabStopWidth { get; set; } #

Physical default paragraph tab-stop width. When null the writer uses the Word-compatible half-inch default.

public IList<PdfTabStop> TabStops { get; } #

Explicit physical paragraph tab stops relative to the paragraph text frame.

public PdfTextWhitespaceMode? TextWhitespaceMode { get; set; } #

Overrides document whitespace handling for this paragraph. Null uses the document setting.

public PdfJustificationMode JustificationMode { get; set; } #

Expandable boundaries when the paragraph uses OfficeAlignment.Justify. The default expands word separators.

public bool JustifyExplicitLineBreaks { get; set; } #

When true, a justified paragraph also expands lines ending with an explicit line break. The default retains natural spacing on those lines.

public bool JustifyLastLine { get; set; } #

When true, a justified paragraph also expands its final line. The default retains natural spacing on that line.

public bool KeepTogether { get; set; } #

When true, the paragraph starts on a new page instead of splitting across pages.

public bool KeepWithNext { get; set; } #

When true, the paragraph moves to the next page when it would otherwise be separated from the following paragraph.

public bool WidowControl { get; set; } #

When true, paragraph page splits avoid single-line widows and orphans where the page frame allows it.

public int MinimumOrphanLines { get; set; } #

Minimum number of paragraph lines kept at the bottom of a page when the paragraph splits. Zero uses the two-line default when PdfParagraphStyle.WidowControl is enabled, or disables this constraint otherwise.

public int MinimumWidowLines { get; set; } #

Minimum number of paragraph lines carried to the top of the following page when the paragraph splits. Zero uses the two-line default when PdfParagraphStyle.WidowControl is enabled, or disables this constraint otherwise.