Skip to main content

DevExpress v24.2 Update — Your Feedback Matters

Our What's New in v24.2 webpage includes product-specific surveys. Your response to our survey questions will help us measure product satisfaction for features released in this major update and help us refine our plans for our next major release.

Take the survey Not interested

Document.Hyphenation Property

Gets or sets whether to enable hyphenation in a document.

Namespace: DevExpress.XtraRichEdit.API.Native

Assembly: DevExpress.RichEdit.v24.2.Core.dll

NuGet Package: DevExpress.RichEdit.Core

#Declaration

bool Hyphenation { get; set; }

#Property Value

Type Description
Boolean

true, to enable hyphenation; otherwise, false.

#Remarks

Set the Hyphenation property to true to hyphenate all text in the document. Use the Document.HyphenateCaps property to determine whether to hyphenate words in CAPS.

Provide the hyphenation dictionary to automatically hyphenate words in a document. Otherwise, the Hyphenation property has no effect.

The following properties provide access to the component’s collection of hyphenation dictionaries:

Use an OpenOfficeHyphenationDictionary class object to add an OpenOffice hyphenation dictionary to the component. The CustomHyphenationDictionary class represents hyphenation pattern files containing words divided into syllables, (e.g., hy-phen-ation).

The code sample below shows how to add an OpenOffice dictionary to the component and enable hyphenation:

OpenOfficeHyphenationDictionary hyphenationDictionary = new OpenOfficeHyphenationDictionary("hyph_sl_SI.dic", new System.Globalization.CultureInfo("sl-SL"));
server.HyphenationDictionaries.Add(hyphenationDictionary);

server.Document.Hyphenation = true;

The following code snippets (auto-collected from DevExpress Examples) contain references to the Hyphenation 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.

See Also