Canvas.Left attached property
Gets or sets the distance between the left side of an object and the left side of its parent Canvas.
<object Canvas.Left="offset"/>
XAML Values
- offset
-
The horizontal offset between the left edge of the parent Canvas, and where the target element should be placed. You typically specify positive integer numbers. Non-integer Double values are allowed but can potentially cause subpixel rendering issues; see UseLayoutRounding.
Remarks
Canvas.Left is an attached property, which supports a XAML usage. When setting this property in code, use SetLeft instead. When getting this property in code, use GetLeft instead. In code usages, the target parameter is the object where the attached property value is set. Another way to get or set the value in code is to use the dependency property system, calling either GetValue or SetValue and passing LeftProperty as the dependency property identifier.
A Canvas.Left value is interpreted by the most immediate parent Canvas element from where the value is set. The value is used along with Canvas.Top to specify the layout characteristics of each child element of a Canvas.
Requirements (Windows 10 device family)
|
API contract | |
|---|---|
|
Namespace |
Windows.UI.Xaml.Controls |
|
Metadata |
Requirements (Windows 8.x and Windows Phone 8.x)
|
Minimum supported client |
Windows 8 |
|---|---|
|
Minimum supported server |
Windows Server 2012 |
|
Minimum supported phone |
Windows Phone 8.1 [Windows Runtime apps only] |
|
Namespace |
Windows.UI.Xaml.Controls |
|
Metadata |
|
See also