Rich Text Editor – Improved WYSIWYG Support (v18.1)

As we all know, accurate document rendering is an important feature for any word processing tool. In our forthcoming release, we’ve invested significant resources to improve the manner in which our DevExpress Rich Edit control for WinForms, WPF Word Processor, and our Word Processing File API renders documents.

Before I describe what we expect to ship in v18.1, let me take a moment to detail the issues we sought to address in this release.

When we began work on our Rich Edit control over a decade ago, we decided to use a 96DPI display resolution to calculate its layout. Because high-resolution devices did not exist, our choice was a logical one. We used 300DPI for printing. Thus, the Rich Edit control calculated its display and print layouts using different units. This caused a problem with layout consistency in the Rich Edit control. A document would not accurately print content: paragraphs could slide apart, text lines could shift to the next page, etc. Here is an example:

Rich Text Editor - Print and Display Layouts in v17.2

To address this issue, your only option was to change display units. Unfortunately, this move could lead to layout corruption.

With the start of the high DPI era, we encountered new but similar issues. Pixel size is no longer absolute and is based on system settings. As a result, a document may not display properly on devices with non-standard DPI settings.

The bottom-line is simple: the need to modify our Rich Text Editors is no longer an option...we had to act.

With this release, we’ve modified layout calculation algorithms for both our RichEditControl (WinForms and WPF) and our Word Processing File API.

These modifications help to:

  1. Increase the accuracy of document layouts.
  2. Eliminate the need for any customization. Documents maintain the same appearance when displayed within the viewer, printed or exported to PDF.

And as you’ve probably guessed by now, DPI settings are also no longer an issue. Simply said, the changes we’ll introduce in v18.1 help ensure that “what you see is what you get.”

Rich Text Editor - Print and Display Layouts in v18.1

Unfortunately, there is a downside to these changes. Since we’ve updated the layout engine in v18.1, your documents may look different than in previous releases.

For those who want to retain previous document layouts, we’ve kept the previous behavior for backward compatibility. To activate it, enable RichEditControlCompatibility.EnableLegacyLayoutEngine option at the application start.

We are working hard to extend document layout accuracy and hope to incorporate additional enhancements in future release cycles. Please let us know what you think about this change. We’d love to hear your feedback.

Free DevExpress Products - Get Your Copy Today

The following free DevExpress product offers remain available. Should you have any questions about the free offers below, please submit a ticket via the DevExpress Support Center at your convenience. We'll be happy to follow-up.
No Comments

Please login or register to post comments.