Skip to main content

Search OfficeIMO

Enter a topic, API type, or PowerShell command.

Documentation Search all OfficeIMO/

API Reference

Class

RtfDocumentSettings

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

Document-level RTF settings that are not tied to page setup or body content.

Inheritance

  • Object
  • RtfDocumentSettings

Usage

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

Constructors

public RtfDocumentSettings() #

Methods

public RtfDocumentSettings SetCharacterSet(RtfDocumentCharacterSet characterSet, Nullable<Int32> ansiCodePage = null) #
Returns: RtfDocumentSettings

Sets the document character set declaration and optional ANSI code page.

Parameters

characterSet OfficeIMO.Rtf.RtfDocumentCharacterSet requiredposition: 0
ansiCodePage System.Nullable{System.Int32} = null optionalposition: 1
public RtfDocumentSettings SetDefaultAlternateLanguage(Int32 languageId) #
Returns: RtfDocumentSettings

Sets the default alternate document language LCID.

Parameters

languageId System.Int32 requiredposition: 0
public RtfDocumentSettings SetDefaultFarEastLanguage(Int32 languageId) #
Returns: RtfDocumentSettings

Sets the default Far East document language LCID.

Parameters

languageId System.Int32 requiredposition: 0
public RtfDocumentSettings SetDefaultFont(Int32 fontId) #
Returns: RtfDocumentSettings

Sets the default font id from the document font table.

Parameters

fontId System.Int32 requiredposition: 0
public RtfDocumentSettings SetDefaultLanguage(Int32 languageId) #
Returns: RtfDocumentSettings

Sets the default document language LCID.

Parameters

languageId System.Int32 requiredposition: 0
public RtfDocumentSettings SetDefaultTabWidth(Int32 twips) #
Returns: RtfDocumentSettings

Sets the default tab width in twips.

Parameters

twips System.Int32 requiredposition: 0
public RtfDocumentSettings SetDirection(Nullable<RtfTextDirection> direction) #
Returns: RtfDocumentSettings

Sets the document default text direction.

Parameters

direction System.Nullable{OfficeIMO.Rtf.RtfTextDirection} requiredposition: 0
public RtfDocumentSettings SetDrawingGrid(Nullable<Int32> horizontalSpacingTwips = null, Nullable<Int32> verticalSpacingTwips = null, Nullable<Int32> horizontalOriginTwips = null, Nullable<Int32> verticalOriginTwips = null, Nullable<Int32> horizontalShow = null, Nullable<Int32> verticalShow = null, Nullable<Boolean> snapToGrid = null, Nullable<Boolean> useMargins = null) #
Returns: RtfDocumentSettings

Sets document-level drawing grid controls.

Parameters

horizontalSpacingTwips System.Nullable{System.Int32} = null optionalposition: 0
verticalSpacingTwips System.Nullable{System.Int32} = null optionalposition: 1
horizontalOriginTwips System.Nullable{System.Int32} = null optionalposition: 2
verticalOriginTwips System.Nullable{System.Int32} = null optionalposition: 3
horizontalShow System.Nullable{System.Int32} = null optionalposition: 4
verticalShow System.Nullable{System.Int32} = null optionalposition: 5
snapToGrid System.Nullable{System.Boolean} = null optionalposition: 6
useMargins System.Nullable{System.Boolean} = null optionalposition: 7
public RtfDocumentSettings SetHyphenation(Nullable<Boolean> automatic = null, Nullable<Boolean> caps = null, Nullable<Int32> consecutiveLimit = null, Nullable<Int32> zoneTwips = null) #
Returns: RtfDocumentSettings

Sets document-level automatic hyphenation controls.

Parameters

automatic System.Nullable{System.Boolean} = null optionalposition: 0
caps System.Nullable{System.Boolean} = null optionalposition: 1
consecutiveLimit System.Nullable{System.Int32} = null optionalposition: 2
zoneTwips System.Nullable{System.Int32} = null optionalposition: 3
public RtfDocumentSettings SetProtection(Nullable<Boolean> forms = null, Nullable<Boolean> revisions = null, Nullable<Boolean> annotations = null, Nullable<Boolean> readOnly = null) #
Returns: RtfDocumentSettings

Sets protection-related flags.

Parameters

forms System.Nullable{System.Boolean} = null optionalposition: 0
revisions System.Nullable{System.Boolean} = null optionalposition: 1
annotations System.Nullable{System.Boolean} = null optionalposition: 2
readOnly System.Nullable{System.Boolean} = null optionalposition: 3
public RtfDocumentSettings SetRevisionTracking(Nullable<Boolean> enabled = null, Nullable<Int32> displayStyle = null, Nullable<Int32> barPlacement = null) #
Returns: RtfDocumentSettings

Sets revision-marking display controls.

Parameters

enabled System.Nullable{System.Boolean} = null optionalposition: 0
displayStyle System.Nullable{System.Int32} = null optionalposition: 1
barPlacement System.Nullable{System.Int32} = null optionalposition: 2
public RtfDocumentSettings SetUnicodeSkipCount(Int32 count) #
Returns: RtfDocumentSettings

Sets the document default alternate character count after Unicode escapes.

Parameters

count System.Int32 requiredposition: 0
public RtfDocumentSettings SetView(Nullable<Int32> kind = null, Nullable<Int32> scale = null, Nullable<Int32> zoomKind = null, Nullable<Int32> backspaceBehavior = null) #
Returns: RtfDocumentSettings

Sets the document view controls.

Parameters

kind System.Nullable{System.Int32} = null optionalposition: 0
scale System.Nullable{System.Int32} = null optionalposition: 1
zoomKind System.Nullable{System.Int32} = null optionalposition: 2
backspaceBehavior System.Nullable{System.Int32} = null optionalposition: 3

Properties

public Nullable<RtfDocumentCharacterSet> CharacterSet { get; set; } #

Document character set declaration represented by \ansi, \mac, \pc, or \pca.

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

ANSI code page represented by \ansicpg.

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

Default alternate character count after Unicode escapes, represented by \uc.

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

Default font id represented by \deff.

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

Default tab width in twips, represented by \deftab.

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

Default document language LCID represented by \deflang.

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

Default Far East language LCID represented by \deflangfe.

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

Default alternate language LCID represented by \adeflang.

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

View kind value represented by \viewkind.

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

View scale percentage represented by \viewscale.

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

Zoom kind value represented by \viewzk.

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

View backspace behavior represented by \viewbksp.

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

Whether widow/orphan control is explicitly enabled or disabled.

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

Whether automatic hyphenation is explicitly enabled or disabled.

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

Whether words in all caps may be hyphenated, represented by \hyphcaps.

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

Maximum number of consecutive hyphenated lines represented by \hyphconsec.

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

Hyphenation hot zone in twips represented by \hyphhotz.

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

Whether facing pages are explicitly enabled or disabled.

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

Whether mirrored margins are explicitly enabled or disabled.

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

Whether form protection is explicitly enabled or disabled.

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

Whether revision protection is explicitly enabled or disabled.

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

Whether annotation protection is explicitly enabled or disabled.

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

Whether read-only protection is explicitly enabled or disabled.

public Boolean HasEditingProtection { get; } #

Whether any RTF editing-protection flag is enabled.

public Boolean IsContentEncrypted { get; } #

Whether this model represents encrypted RTF content.

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

Whether revision marking is enabled, represented by \revisions.

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

Revision text display style represented by \revprop.

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

Revision bar placement represented by \revbar.

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

Drawing grid horizontal spacing represented by \dghspace.

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

Drawing grid vertical spacing represented by \dgvspace.

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

Drawing grid horizontal origin represented by \dghorigin.

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

Drawing grid vertical origin represented by \dgvorigin.

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

Drawing grid horizontal display frequency represented by \dghshow.

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

Drawing grid vertical display frequency represented by \dgvshow.

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

Whether drawing objects snap to the document grid, represented by \dgsnap.

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

Whether drawing grid origin uses page margins, represented by \dgmargin.

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

Document default text direction represented by \ltrdoc or \rtldoc.