Back to Devexpress

RichEditControl.ActiveViewType Property

wpf-devexpress-dot-xpf-dot-richedit-dot-richeditcontrol-bae3ca1f.md

latest5.8 KB
Original Source

RichEditControl.ActiveViewType Property

Gets or sets the type of the View , currently used by the RichEditControl to show the document. This is a dependency property.

Namespace : DevExpress.Xpf.RichEdit

Assembly : DevExpress.Xpf.RichEdit.v25.2.dll

NuGet Package : DevExpress.Wpf.RichEdit

Declaration

csharp
public RichEditViewType ActiveViewType { get; set; }
vb
Public Property ActiveViewType As RichEditViewType

Property Value

TypeDescription
RichEditViewType

A RichEditViewType enumeration value, specifying the active View type.

|

Available values:

NameDescription
Simple

Specifies that the control is in a simple mode used for simple text and web pages. This mode shows how the document looks as a website.

| | Draft |

Specifies that the control is in a draft mode.

| | PrintLayout |

Specifies that the control is in a print layout mode. In this mode, the control displays pages with all formattings applied.

|

Remarks

Use the RichEditControl.ActiveViewType property to change the View. End users can change the current view using the Document Views buttons on the View ribbon tab.

These buttons execute the following commands:

The RichEditControl.ActiveViewChanged event is raised when the active view changes.

The RichEditControl.ActiveView property provides access to the currently active view. The returned RichEditView object options allow you to customize the target view.

The following code snippets (auto-collected from DevExpress Examples) contain references to the ActiveViewType property.

Note

The algorithm used to collect these code examples remains a work in progress. Accordingly, the links and snippets below may produce inaccurate results. If you encounter an issue with code examples below, please use the feedback form on this page to report the issue.

wpf-richedit-document-api/CS/DXRichEditControlAPISample/MainWindow.xaml#L30

xml
<dx:DXTabItem Header="CS" Width="250">
    <dxre:RichEditControl x:Name="richEditControlCS" ActiveViewType="Simple" />
</dx:DXTabItem>

wpf-spreadsheet-chart-api/CS/SpreadsheetWPFChartAPISamples/MainWindow.xaml#L31

xml
<dx:DXTabItem Header="CS" Width="250">
    <dxre:RichEditControl x:Name="richEditControlCS" ActiveViewType="Simple" />
</dx:DXTabItem>

wpf-spreadsheet-pivot-table-api-examples/CS/SpreadsheetWPFPivotTableExamples/MainWindow.xaml#L31

xml
<dx:DXTabItem Header="CS" Width="250">
    <dxre:RichEditControl x:Name="richEditControlCS" ActiveViewType="Simple" />
</dx:DXTabItem>

syntax-highlighting-for-c-and-vb-code-using-devexpress-codeparser-and-syntax-highlight-tokens/CS/SyntaxHighlightSimple/MainWindow.xaml#L10

xml
<Grid>
    <dxre:RichEditControl x:Name="richEditControl1" ActiveViewType="Draft" Loaded="richEditControl1_Loaded"/>
</Grid>

wpf-richedit-bind-richeditcontrol-to-text-in-different-formats/CS/BindingConverter/MainWindow.xaml#L20

xml
<dxre:RichEditControl x:Name="richEditControl1" Height="Auto" Width="Auto"
                   BarManager="{Binding ElementName=barManager1}" ActiveViewType="Simple" />
</dxb:BarManager>

See Also

SwitchToDraftViewCommand

SwitchToSimpleViewCommand

SwitchToPrintLayoutViewCommand

ActiveViewChanged

RichEditControl Class

RichEditControl Members

DevExpress.Xpf.RichEdit Namespace