[Expand]General Information
[Collapse]WinForms Controls
  Prerequisites
 [Expand]What's Installed
 [Expand]Build an Application
 [Collapse]Controls and Libraries
  [Expand]Forms and User Controls
  [Expand]Messages, Notifications and Dialogs
  [Expand]Editors and Simple Controls
  [Expand]Ribbon, Bars and Menu
  [Expand]Application UI Manager
  [Expand]Docking Library
  [Expand]Data Grid
  [Expand]Vertical Grid
  [Expand]Property Grid
  [Expand]Pivot Grid
  [Expand]Tree List
  [Expand]Chart Control
  [Expand]Diagrams
  [Expand]Gauges
  [Expand]Map Control
  [Expand]Scheduler
  [Expand]Spreadsheet
  [Collapse]Rich Text Editor
   [Expand]Product Information
    Product Class Structure
    Supported Formats
   [Expand]Getting Started
   [Expand]RichEditControl Document
   [Expand]Fields
    Text Formatting
    Import and Export
   [Expand]Page Layout
    Printing
    Spell Checking
    AutoCorrect
    Mail Merge
    Restrictions and Protection
    Syntax Highlighting
   [Expand]Visual Elements
    Services
    Events
    Commands
    Keyboard Shortcuts
    HTML Tag Support
   [Collapse]Examples
    [Expand]Files
    [Expand]Text
    [Expand]Formatting
    [Expand]Styles
    [Expand]Lists
    [Expand]Pictures
    [Expand]Text Boxes
    [Expand]Tables
    [Expand]Document Elements
    [Expand]Layout
    [Expand]Automation
    [Expand]Search and Replace
    [Expand]Mail Merge
    [Expand]Spell Check
    [Expand]Export-Import
    [Expand]Printing
    [Expand]Protection
    [Collapse]User Interface Customization
      How to: Hide or Show ScrollBars and Rulers
      How to: Customize the Search Form
      How to: Customize the Hyperlink Form
      How to: Add Custom Menu Items (Spelling Suggestions) to the Context Menu
      How to: Customize and Hide the Popup Menu
    [Expand]Commands
  [Expand]Spell Checker
  [Expand]Form Layout Managers
  [Expand]Navigation Controls
  [Expand]Printing-Exporting
  [Expand]PDF Viewer
   Reporting
  [Expand]Snap
  [Expand]TreeMap Control
  [Expand]Sunburst Control
 [Expand]Common Features
  Get More Help
 [Expand]API Reference
[Expand]ASP.NET Controls and MVC Extensions
[Expand]ASP.NET Bootstrap Controls
[Expand]ASP.NET Core Bootstrap Controls
[Expand]WPF Controls
[Expand]Xamarin Controls
[Expand]Windows 10 App Controls
[Expand]Office File API
[Expand]Reporting
[Expand]Report and Dashboard Server
[Expand]Dashboard
[Expand]eXpressApp Framework
[Expand]eXpress Persistent Objects
[Expand]CodeRush
[Expand]CodeRush Classic
[Expand]Cross-Platform Core Libraries
[Expand]Tools and Utilities
 End-User Documentation
View this topic on docs.devexpress.com (Learn more)

How to: Hide or Show ScrollBars and Rulers

By default, the PrintLayoutView displays a complete set of scrollbars and rulers - a pair of rulers (horizontal and vertical) and a pair of scrollbars (horizontal and vertical). Scrollbars are shown when needed, i.e. if a page does not fit into the control's display area. Default layout of the DraftView provides only the top, horizontal ruler and a pair of scrollbars. The SimpleView comes without rulers.

The following picture illustrates the PrintLayout view of the RichEdit control with scroll bars and rulers. Ruler ticks reflect the current measurement unit that is set for the document. In this example the Document.Unit value is DocumentUnit.Inch.

To change the visibility of scrollbars and rulers, use the RichEditControl.Options property. It provides access to various characteristics of the control, among them: the RichEditControlOptionsBase.HorizontalRuler, RichEditControlOptionsBase.VerticalRuler, RichEditControlOptions.HorizontalScrollbar, RichEditControlOptions.VerticalScrollbar.

To change the visibility of ruler and scrollbar elements, adjust the corresponding Visibility property values as required. E.g. to hide the top ruler use the code below:

Expanded See Also

Is this topic helpful?​​​​​​​