Class DocumentEditorSettingsModel
Interface for a class DocumentEditorSettings.
Inheritance
Namespace: Syncfusion.Blazor.DocumentEditor
Assembly: Syncfusion.Blazor.DocumentEditor.dll
Syntax
public class DocumentEditorSettingsModel : Object
Constructors
DocumentEditorSettingsModel()
Declaration
public DocumentEditorSettingsModel()
Properties
AllowDragAndDrop
Gets or sets a value indicating whether to allow dragging and dropping the selected content within Document editor.
Declaration
public bool AllowDragAndDrop { get; set; }
Property Value
Type | Description |
---|---|
System.Boolean | The value |
ColorPickerSettings
Gets or sets the color picker settings to customize the color picker used in Document Editor.
Declaration
public SfColorPicker ColorPickerSettings { get; set; }
Property Value
Type |
---|
SfColorPicker |
Remarks
You can customize the color picker default appearance or palette mode, or to show a mode switcher between the picker and palette in the Document Editor.
Examples
The following code example demonstrates how to customize the color picker's default appearance as a palette in the SfDocumentEditorContainer.
// Set appearance as palette in SfDocumentEditorContainer component.
sfDocumentEditorContainer.DocumentEditorSettings.ColorPickerSettings.Mode = ColorPickerMode.Palette;
The following code example demonstrates how to customize the color picker's default appearance as a palette in the SfDocumentEditor.
// Set appearance as palette in SfDocumentEditorContainer component.
sfDocumentEditor.DocumentEditorSettings.ColorPickerSettings.Mode = ColorPickerMode.Palette;
EnableOptimizedTextMeasuring
Gets or sets a value indicating whether to use optimized text measuring approach to match Microsoft Word pagination.
Declaration
public bool EnableOptimizedTextMeasuring { get; set; }
Property Value
Type | Description |
---|---|
System.Boolean | true use optimized text measuring approach to match Microsoft Word pagination; otherwise, false |
FontFamilies
Specifies the user preferred font family of Document Editor.
Declaration
public string[] FontFamilies { get; set; }
Property Value
Type |
---|
System.String[] |
FormFieldSettings
Form field settings.
Declaration
public FormFieldSettingsModel FormFieldSettings { get; set; }
Property Value
Type |
---|
FormFieldSettingsModel |
HighlightEditableRanges
Gets or sets a value indicating whether to highlight the editable ranges in the document where the current user can edit. The default value is true.
Declaration
public bool HighlightEditableRanges { get; set; }
Property Value
Type | Description |
---|---|
System.Boolean | 'True' if editable ranges in the document is highlighted. Otherwise 'False'. |
Examples
The following code example demonstrates how to remove the highlighting of the editable ranges in Syncfusion Word Processor (Document editor) component.
//Disables the highlighting of the editable ranges in Syncfusion Word Processor (Document editor)
sfDocumentEditorContainer.DocumentEditorSettings.HighlightEditableRanges = false;
MaximumColumns
Gets or sets a maximum number of columns allowed while inserting a table. The default value is 63.
Declaration
public int MaximumColumns { get; set; }
Property Value
Type | Description |
---|---|
System.Int32 | Returns the value to maximum number of columns allowed while inserting a table. |
Remarks
The value `20` means the maximum number of columns while inserting a table is 20. If the value entered is greater than 20, Provided alert message will display.
Examples
The following code example demonstrates how to set an limitation for maximum number of columns allowed while inserting a table in Syncfusion Word Processor (Document editor) component.
//Displays the alert when an value provide is beyond the maximum number of columns in Document editor component.
sfDocumentEditorContainer.DocumentEditorSettings.MaximumColumns = 63;
MaximumRows
Gets or sets a maximum number of rows allowed while inserting a table. The default value is 32767.
Declaration
public int MaximumRows { get; set; }
Property Value
Type | Description |
---|---|
System.Int32 | Returns the value to maximum number of rows allowed while inserting a table. |
Remarks
The value `20` means the maximum number of rows while inserting a table is 20. If the value entered is greater than 20, Provided alert message will display.
Examples
The following code example demonstrates how to set an limitation for maximum number of rows allowed while inserting a table in Syncfusion Word Processor (Document editor) component.
//Displays the alert when an value provide is beyond the maximum number of rows in Document editor component.
sfDocumentEditorContainer.DocumentEditorSettings.MaximumRows = 32767;
OptimizeSfdt
Gets or sets a value indicating whether to reduce the resultant SFDT file size by minifying the file content. The default value is true.
Declaration
public bool OptimizeSfdt { get; set; }
Property Value
Type | Description |
---|---|
System.Boolean | 'True' if the resultant SFDT file size is reduced by minifying the file content. Otherwise 'False'. |
Remarks
The value `false` means the sfdt content are not optimized. The value `true` means generate the optimized sfdt.
Examples
The following code example demonstrates how to generate the Sfdt without optimization in Syncfusion Word Processor (Document editor) component.
WordDocument document = WordDocument.Load(stream, GetFormatType(type.ToLower()));
//Disables the optimized sfdt.
document.OptimizeSfdt = false;
document.Dispose();
PrintDevicePixelRatio
Specifies the device pixel ratio for the image generated for printing. Remarks: Increasing the device pixel ratio will increase the image file size, due to high resolution of image.
Declaration
public int PrintDevicePixelRatio { get; set; }
Property Value
Type |
---|
System.Int32 |
SearchHighlightColor
Specifies the user preferred Search Highlight Color of Document Editor.
Declaration
public string SearchHighlightColor { get; set; }
Property Value
Type |
---|
System.String |
ShowBookmarks
Gets or sets a value indicating whether to display square brackets at the beginning and end of each bookmark. The default value is false.
Declaration
public bool ShowBookmarks { get; set; }
Property Value
Type | Description |
---|---|
System.Boolean | True if square brackets are displayed at the beginning and end of each bookmark. |
Remarks
True if square brackets are displayed at the beginning and end of each bookmark. Otherwise false
Examples
The following code example demonstrates how to display square brackets at the beginning and end of each bookmark in Syncfusion Word Processor (Document editor) component.
//Displays the square brackets at the beginning and end of each bookmark in Document editor component.
sfDocumentEditorContainer.DocumentEditorSettings.ShowBookmarks = true;
ShowHiddenMarks
Gets or sets a value indicating whether to show the hidden characters like spaces, tab, paragraph marks, and breaks. The default value is false.
Declaration
public bool ShowHiddenMarks { get; set; }
Property Value
Type | Description |
---|---|
System.Boolean | Returns the value to show/hide hidden characters like spaces, tab, paragraph marks, and breaks. |
Remarks
The value `false` means hide the hidden characters like spaces, tab, paragraph marks, and breaks. The value `true` means show the hidden characters.
Examples
The following code example demonstrates how to show the hidden characters like spaces, tab, paragraph marks, and breaks in Syncfusion Word Processor (Document editor) component.
//Displays the hidden characters in Document editor component.
sfDocumentEditorContainer.DocumentEditorSettings.ShowHiddenMarks = true;
ShowNavigationPane
Gets or sets a value indicating whether to display the navigation pane in the Document Editor.
Declaration
public bool ShowNavigationPane { get; set; }
Property Value
Type | Description |
---|---|
System.Boolean |
|
Remarks
You can show or hide the navigation pane option through this property in the Document Editor.
Examples
The following code example demonstrates how to show the navigation pane in the SfDocumentEditorContainer.
// Displays the navigation pane in SfDocumentEditorContainer component.
sfDocumentEditorContainer.DocumentEditorSettings.ShowNavigationPane = true;
The following code example demonstrates how to show the navigation pane in the SfDocumentEditor.
// Displays the navigation pane in SfDocumentEditor component.
sfDocumentEditor.DocumentEditorSettings.ShowNavigationPane = true;
ShowRuler
Gets or sets a value indicating whether to display the ruler in the Document Editor.
Declaration
public bool ShowRuler { get; set; }
Property Value
Type | Description |
---|---|
System.Boolean |
|
Remarks
You can show or hide the ruler option through this property in the Document Editor.
Examples
The following code example demonstrates how to show the ruler in the SfDocumentEditorContainer.
// Displays the ruler in the SfDocumentEditorContainer component.
sfDocumentEditorContainer.DocumentEditorSettings.ShowRuler = true;
The following code example demonstrates how to show the ruler in the SfDocumentEditor.
// Displays the ruler in the SfDocumentEditor component.
sfDocumentEditor.DocumentEditorSettings.ShowRuler = true;
Methods
Dispose()
Dispose unmanaged resources used in DocumentEditorSettingsModel.
Declaration
public void Dispose()
Equals(DocumentEditorSettingsModel)
Indicates whether the current object is equal to another object of the same type.
Declaration
public bool Equals(DocumentEditorSettingsModel documentEditorSettingsModel)
Parameters
Type | Name | Description |
---|---|---|
DocumentEditorSettingsModel | documentEditorSettingsModel | An DocumentEditorSettingsModel to compare. |
Returns
Type | Description |
---|---|
System.Boolean | true if the current object is equal to the other parameter; otherwise, false. |