BackColor Property
- Namespace
TXTextControl.WPF. Drawing
- Package
TXTextControl.asTextControl. WPF. SDK TXDrawing.from the private NuGet feed or Text Control Offline PackagesWPF. dll
Description
Gets or sets the TX Drawing Control's back color. The default value is the color System.Windows.Media.Colors.Transparent. If the property is set to null the current System.Windows.SystemColors.WindowColor is used.
Syntax
public Color? BackColor { get; set; }Public Property BackColor As Color?Examples
The following example uses TXDrawingControl.BackColor to set the txdrawing control's background color. The configured value is checked before the workflow continues.
tXDrawingControl.BackColor = System.Windows.Media.Colors.CornflowerBlue;
if (tXDrawingControl.BackColor != null)
{
Console.WriteLine("TXDrawing Control: Back Color is available.");
}tXDrawingControl.BackColor = System.Windows.Media.Colors.CornflowerBlue
If tXDrawingControl.BackColor IsNot Nothing Then
Console.WriteLine("TXDrawing Control: Back Color is available.")
End IfLimitations
A control's back color that differs to the default back color is only drawn if the control's IsCanvasVisible property return true. Otherwise the default value is used.