Generic FunctionPackage: cgToCDocOverviewCGDocRelNotesFAQIndexPermutedIndex
Allegro CL version 9.0
Unrevised from 8.2 to 9.0.
8.2 version

rich-edit-range

Arguments: text-edit-pane &key (format :rich-text) (start 0) (end most-positive-fixnum) (return-crlf t)

This function returns a string for window (identified by text-edit-pane) from character position start to end. If start and end are not supplied, the entire contents are returned. If format is :rich-text (the default), then a rich-text string is returned. If it is :text, then a plain-text string is returned.

If end is not greater than start, then an empty string is returned. If format is :rich-text, this empty string is a special two-character string consisting of an open curly brace followed by a close curly brace. Otherwise it is the usual zero-length null string. The special empty string for rich text is the value of *empty-rtf-string*, and is used because it works as a valid rich text string with the rich-edit-control, while the standard lisp null string does not.

The return-crlf argument no longer has any effect, and is kept for backward compatibility only. It was used on the Windows platform by an earlier version of the RichEdit control.

The setf function sets the text in window from start to end to be string. If start and end are not specified, the entire contents of window are replaced. If format is :rich-text (the default), then string should be a rich-text string, which will be inserted using its own formatting. If it is :text, then string should be a plain-text string, which will be inserted using the formatting at the current position of the text-edit-pane.

When format is :rich-text, string may be the value of *empty-rtf-string* to indicate a rich text string with no contents.

See also rich-edit-selected-range and its setf.

See cg-rich-text.htm for information about rich text editing in Common Graphics.

GTK note

Formated editable text is not yet implemented on the GTK platform. It appears feasible to implement functions such as set-character-format and set-paragraph-format that modify the text formatting of an edit control, but not to implement functions such as rich-text and rich-edit-range that handle actual rich text strings.

Attempting to create a rich-edit widget or a rich-edit-pane window currently will error on GTK.


Copyright (c) 1998-2019, Franz Inc. Oakland, CA., USA. All rights reserved.
This page was not revised from the 8.2 page.
Created 2012.5.30.

ToCDocOverviewCGDocRelNotesFAQIndexPermutedIndex
Allegro CL version 9.0
Unrevised from 8.2 to 9.0.
8.2 version