Applies to
Declaration
property ParagraphsForeground[i: Integer]: TColor;
property ParagraphsBackground[i: Integer]: TColor;
Description
These array properties permit setting the background and foreground (text color) for individual paragraphs from your application. The index corresponds to the paragraph number.
Setting the background or foreground color of a paragraph to -1 represents a no color change, relative to the default value (TPlusMemo.Color for the background, TPlusMemo.Font.Color for the text color). Setting them to another value will make this color take precedence over the default ones, except for parts of text marked by the fsHighlight style, either from static or dynamic formatting (see PlusMemo Overview topic for a discussion of static and dynamic formatting).
If a bitmap is used as a background for the text area (see property BackgroundBmp), the background used for paragraphs whose background color is set to -1 is that of the bitmap picture. For paragraphs having property ParagraphsBackground set to something other than -1, the corresponding color will override the background bitmap or the default color, whichever applies.
By default or after loading some text from a stream or file, all paragraphs have -1 for both the foreground and background colors.
These properties are available at runtime only, with read and write access.
See Also
ParagraphsWrapable property
Lines and Paragraphs properties
ParagraphCount property