TX Text Control .NET for Windows Forms

Bounds Property

Property|Introduced in 23.0
Namespace
TXTextControl.Drawing
Package
TXTextControl.TextControl.WinForms.SDK as TXDrawing.dll from the private NuGet feed or Text Control Offline Packages

Description

Gets or sets the bounding rectangle of the shape. The values are given in twips with an origin at the upper left corner of the TX Drawing Control. The default value correspond to the shape's default Location and Size values.

Syntax

public Rectangle Bounds { get; set; }

Examples

The following example uses Shape.Bounds to configure bounds as part of the shape workflow. The configured value is checked before the workflow continues.

shape.Bounds = new System.Drawing.Rectangle(20, 20, 600, 400);
Console.WriteLine($"Bounds used by Shape: {shape.Bounds}");