TX Text Control .NET for Windows Forms

Colors Class

Class|Introduced in 15.1
Namespace
TXTextControl
Package
TXTextControl.TextControl.WinForms.SDK from the private NuGet feed or Text Control Offline Packages
Assembly
TXTextControl.Windows.Forms.dll
Install
dotnet add package TXTextControl.TextControl.WinForms.SDK .NET 8 and later. For .NET Framework, reference TXTextControl.Windows.Forms.dll from the setup.
Inherits
  1. ColorBase
  2. TextControl.Colors

Description

The TextControl.Colors class gets, sets or resets the display colors of a Windows Forms TextControl control. By default the display colors depend on sytem colors or a default value. With this class all colors can be individually designed.

Syntax

public sealed class TextControl.Colors : ColorBase

Examples

The following example creates a Colors instance and configures its desktop color setting for a document workflow.

TextControl.Colors colors = new();
colors.DesktopColor = System.Drawing.Color.LightSteelBlue;

Members

Constructors

ConstructorDescription
ColorsInitializes a new instance of the TextControl.Colors class. After creating the object with this constuctor, individual colors can be set. If the Colors object is assigned to the TextControl.DisplayColors property, non-set colors are reset to their default values.

Properties

PropertyDescription
ActiveFormFieldColorGets or sets the highlight color of a form field containing the current text input position. To suppress highlighting the active FormField the property value can be set to Color.Transparent.
DarkShadowColorGets or sets the display color for the shadow at the right and the bottom edge of the pages.
DesktopColorGets or sets the display color for the area around the pages.
FormFieldColorGets or sets the highlight color of a form field. This color can be overwritten with the TextField.HighlightColor property. To suppress highlighting a FormField the property value can be set to Color.Transparent.
HeaderFooterLabelColorGets or sets the display color for the label showing which header or footer is activated.
HeaderFooterLineColorGets or sets the display color for the dividing line between headers and footers and the main text.
LightShadowColorGets or sets the display color for the shadow at the left and the top edge of the pages.

Methods

MethodDescription
ResetActiveFormFieldColorResets the text control's ActiveFormFieldColor to its default value.
ResetDarkShadowColorResets the text control's DarkShadowColor to its system dependent default value.
ResetDesktopColorResets the text control's DesktopColor to its system dependent default value.
ResetFormFieldColorResets the text control's FormFieldColor to its default value.
ResetHeaderFooterLabelColorResets the text control's HeaderFooterLabelColor to its system dependent default value.
ResetHeaderFooterLineColorResets the text control's HeaderFooterLineColor to its system dependent default value.
ResetLightShadowColorResets the text control's LightShadowColor to its system dependent default value.