Skip to main content

Search OfficeIMO

Enter a topic, API type, or PowerShell command.

Documentation Search all OfficeIMO/

API Reference

Class

RtfStyle

Namespace OfficeIMO.Rtf
Assembly OfficeIMO.Rtf
Implements
IRtfCloneable
Modifiers sealed

Minimal semantic representation of an RTF stylesheet entry.

Inheritance

  • Object
  • RtfStyle

Usage

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

Constructors

public RtfStyle(Int32 id, String name, RtfStyleKind kind = Paragraph) #

Creates a stylesheet entry.

Parameters

id System.Int32 requiredposition: 0
name System.String requiredposition: 1
kind OfficeIMO.Rtf.RtfStyleKind = Paragraph optionalposition: 2

Methods

public RtfTabStop AddTabStop(Int32 positionTwips, RtfTabAlignment alignment = Left, RtfTabLeader leader = None) #
Returns: RtfTabStop

Adds a paragraph tab stop to this stylesheet entry.

Parameters

positionTwips System.Int32 requiredposition: 0
alignment OfficeIMO.Rtf.RtfTabAlignment = Left optionalposition: 1
leader OfficeIMO.Rtf.RtfTabLeader = None optionalposition: 2
public RtfStyle SetBorder(RtfParagraphBorderSide side, RtfParagraphBorderStyle style, Nullable<Int32> width = null, Nullable<Int32> colorIndex = null) #
Returns: RtfStyle

Sets paragraph border formatting for one stylesheet side.

Parameters

side OfficeIMO.Rtf.RtfParagraphBorderSide requiredposition: 0
style OfficeIMO.Rtf.RtfParagraphBorderStyle requiredposition: 1
width System.Nullable{System.Int32} = null optionalposition: 2
colorIndex System.Nullable{System.Int32} = null optionalposition: 3
public RtfStyle SetFrame(Action<RtfParagraphFrame> configure) #
Returns: RtfStyle

Configures absolute positioning frame metadata for this stylesheet entry.

Parameters

configure System.Action{OfficeIMO.Rtf.RtfParagraphFrame} requiredposition: 0
public RtfStyle SetLegacyNumbering(Action<RtfLegacyNumbering> configure) #
Returns: RtfStyle

Configures Word 6/95 legacy paragraph numbering metadata for this style.

Parameters

configure System.Action{OfficeIMO.Rtf.RtfLegacyNumbering} requiredposition: 0

Properties

public Int32 Id { get; set; } #

RTF style id.

public String Name { get; set; } #

Human-readable style name.

public RtfStyleKind Kind { get; set; } #

Style kind.

public Nullable<Int32> BasedOnStyleId { get; set; } #

Optional base style id.

public Nullable<Int32> NextStyleId { get; set; } #

Optional next paragraph style id.

public Nullable<Int32> LinkedStyleId { get; set; } #

Optional linked style id.

public Nullable<Int32> ListId { get; set; } #

Optional list-instance reference inherited by paragraphs using this style.

public Nullable<Int32> ListLevel { get; set; } #

Optional zero-based list level inherited by paragraphs using this style.

public RtfStyleKeyCode KeyCode { get; set; } #

Optional shortcut key metadata from the stylesheet {\*\keycode ...} group.

public Boolean Additive { get; set; } #

Whether the style is marked as additive.

public Boolean AutoUpdate { get; set; } #

Whether this style automatically updates from document content.

public Boolean Hidden { get; set; } #

Whether this style is hidden from style lists.

public Boolean Locked { get; set; } #

Whether this style is locked against modification.

public Boolean Personal { get; set; } #

Whether this style is marked as a personal e-mail style.

public Boolean Compose { get; set; } #

Whether this style is marked as an e-mail compose style.

public Boolean Reply { get; set; } #

Whether this style is marked as an e-mail reply style.

public Boolean SemiHidden { get; set; } #

Whether this style is semi-hidden.

public Boolean UnhideWhenUsed { get; set; } #

Whether this style is unhidden after use.

public Boolean QuickFormat { get; set; } #

Whether this style appears in quick style galleries.

public Nullable<Int32> Priority { get; set; } #

Optional style priority.

public Nullable<Int32> RevisionSaveId { get; set; } #

Optional style revision save id.

public Nullable<Boolean> Bold { get; set; } #

Optional direct bold setting carried by the stylesheet entry.

public Nullable<Boolean> Italic { get; set; } #

Optional direct italic setting carried by the stylesheet entry.

public Nullable<Boolean> TextHidden { get; set; } #

Optional hidden-text formatting represented by \v. This is separate from style-list visibility.

public Nullable<RtfUnderlineStyle> UnderlineStyle { get; set; } #

Optional direct underline setting carried by the stylesheet entry.

public Nullable<Double> FontSize { get; set; } #

Optional direct font size in points carried by the stylesheet entry.

public Nullable<Int32> FontId { get; set; } #

Optional direct font id carried by the stylesheet entry.

public Nullable<Int32> ForegroundColorIndex { get; set; } #

Optional direct foreground color table index carried by the stylesheet entry.

public Nullable<Int32> HighlightColorIndex { get; set; } #

Optional direct highlight color table index carried by the stylesheet entry.

public IReadOnlyList<RtfTabStop> TabStops { get; } #

Paragraph tab stops carried by the stylesheet entry.

public Nullable<RtfTextAlignment> ParagraphAlignment { get; set; } #

Optional direct paragraph alignment carried by the stylesheet entry.

public Nullable<RtfTextDirection> ParagraphDirection { get; set; } #

Optional direct paragraph text direction carried by the stylesheet entry.

public Nullable<Int32> LeftIndentTwips { get; set; } #

Optional left paragraph indentation in twips carried by the stylesheet entry.

public Nullable<Int32> RightIndentTwips { get; set; } #

Optional right paragraph indentation in twips carried by the stylesheet entry.

public Nullable<Int32> FirstLineIndentTwips { get; set; } #

Optional first-line paragraph indentation in twips carried by the stylesheet entry.

public Nullable<Int32> SpaceBeforeTwips { get; set; } #

Optional space before paragraph in twips carried by the stylesheet entry.

public Nullable<Int32> SpaceAfterTwips { get; set; } #

Optional space after paragraph in twips carried by the stylesheet entry.

public Nullable<Boolean> SpaceBeforeAuto { get; set; } #

Optional automatic space-before setting carried by the stylesheet entry.

public Nullable<Boolean> SpaceAfterAuto { get; set; } #

Optional automatic space-after setting carried by the stylesheet entry.

public Nullable<Int32> LineSpacingTwips { get; set; } #

Optional raw RTF line spacing value carried by the stylesheet entry.

public Nullable<Boolean> LineSpacingMultiple { get; set; } #

Optional line spacing multiplier flag carried by the stylesheet entry.

public Nullable<Int32> BackgroundColorIndex { get; set; } #

Optional paragraph background color table index carried by the stylesheet entry.

public Nullable<Int32> ShadingForegroundColorIndex { get; set; } #

Optional paragraph pattern foreground color table index carried by the stylesheet entry.

public Nullable<Int32> ShadingPatternPercent { get; set; } #

Optional raw paragraph shading percentage carried by the stylesheet entry.

public RtfShadingPattern ShadingPattern { get; set; } #

Optional paragraph shading pattern carried by the stylesheet entry.

public RtfParagraphBorder TopBorder { get; set; } #

Top paragraph border carried by the stylesheet entry.

public RtfParagraphBorder LeftBorder { get; set; } #

Left paragraph border carried by the stylesheet entry.

public RtfParagraphBorder BottomBorder { get; set; } #

Bottom paragraph border carried by the stylesheet entry.

public RtfParagraphBorder RightBorder { get; set; } #

Right paragraph border carried by the stylesheet entry.

public Nullable<Boolean> PageBreakBefore { get; set; } #

Optional page-break-before setting carried by the stylesheet entry.

public Nullable<Boolean> KeepWithNext { get; set; } #

Optional keep-with-next setting carried by the stylesheet entry.

public Nullable<Boolean> KeepLinesTogether { get; set; } #

Optional keep-lines-together setting carried by the stylesheet entry.

public Nullable<Boolean> SuppressLineNumbers { get; set; } #

Optional line-number suppression setting carried by the stylesheet entry.

public Nullable<Boolean> AutoHyphenation { get; set; } #

Optional paragraph automatic hyphenation setting carried by the stylesheet entry.

public Nullable<Boolean> ContextualSpacing { get; set; } #

Optional contextual spacing setting carried by the stylesheet entry.

public Nullable<Boolean> AdjustRightIndent { get; set; } #

Optional automatic right-indent adjustment setting carried by the stylesheet entry.

public Nullable<Boolean> SnapToLineGrid { get; set; } #

Optional snap-to-line-grid setting carried by the stylesheet entry.

public Nullable<Boolean> WidowControl { get; set; } #

Optional widow/orphan control setting carried by the stylesheet entry.

public Nullable<Int32> OutlineLevel { get; set; } #

Optional paragraph outline level carried by the stylesheet entry.

public RtfLegacyNumbering LegacyNumbering { get; set; } #

Word 6/95 legacy paragraph numbering metadata carried by this stylesheet entry.

public RtfParagraphFrame Frame { get; set; } #

Absolute positioning, text wrapping, and drop-cap metadata carried by the stylesheet entry.

public RtfTableRow TableRowFormat { get; set; } #

Table row and cell formatting carried by a table stylesheet entry.