using Avalonia.Layout; using Avalonia.Threading; namespace Avalonia.Controls { public partial class RelativePanel { static RelativePanel() { ClipToBoundsProperty.OverrideDefaultValue(true); AffectsParentArrange( AlignLeftWithPanelProperty, AlignLeftWithProperty, LeftOfProperty, AlignRightWithPanelProperty, AlignRightWithProperty, RightOfProperty, AlignTopWithPanelProperty, AlignTopWithProperty, AboveProperty, AlignBottomWithPanelProperty, AlignBottomWithProperty, BelowProperty, AlignHorizontalCenterWithPanelProperty, AlignHorizontalCenterWithProperty, AlignVerticalCenterWithPanelProperty, AlignVerticalCenterWithProperty); AffectsParentMeasure( AlignLeftWithPanelProperty, AlignLeftWithProperty, LeftOfProperty, AlignRightWithPanelProperty, AlignRightWithProperty, RightOfProperty, AlignTopWithPanelProperty, AlignTopWithProperty, AboveProperty, AlignBottomWithPanelProperty, AlignBottomWithProperty, BelowProperty, AlignHorizontalCenterWithPanelProperty, AlignHorizontalCenterWithProperty, AlignVerticalCenterWithPanelProperty, AlignVerticalCenterWithProperty); } /// /// Gets the value of the RelativePanel.Above XAML attached property for the target element. /// /// The object from which the property value is read. /// /// The RelativePanel.Above XAML attached property value of the specified object. /// (The element to position this element above.) /// [ResolveByName] public static object GetAbove(AvaloniaObject obj) { return (object)obj.GetValue(AboveProperty); } /// /// Sets the value of the RelativePanel.Above XAML attached property for a target element. /// /// The object to which the property value is written. /// The value to set. (The element to position this element above.) [ResolveByName] public static void SetAbove(AvaloniaObject obj, object value) { obj.SetValue(AboveProperty, value); } /// /// Identifies the XAML attached property. /// public static readonly AttachedProperty AboveProperty = AvaloniaProperty.RegisterAttached("Above", typeof(RelativePanel)); /// /// Gets the value of the RelativePanel.AlignBottomWithPanel XAML attached property for the target element. /// /// The object from which the property value is read. /// /// The RelativePanel.AlignBottomWithPanel XAML attached property value of the specified /// object. (true to align this element's bottom edge with the panel's bottom edge; /// otherwise, false.) /// public static bool GetAlignBottomWithPanel(AvaloniaObject obj) { return (bool)obj.GetValue(AlignBottomWithPanelProperty); } /// /// Sets the value of the RelativePanel.Above XAML attached property for a target element. /// /// The object to which the property value is written. /// /// The value to set. (true to align this element's bottom edge with the panel's /// bottom edge; otherwise, false.) /// public static void SetAlignBottomWithPanel(AvaloniaObject obj, bool value) { obj.SetValue(AlignBottomWithPanelProperty, value); } /// /// Identifies the XAML attached property. /// public static readonly AttachedProperty AlignBottomWithPanelProperty = AvaloniaProperty.RegisterAttached("AlignBottomWithPanel", typeof(RelativePanel)); /// /// Gets the value of the RelativePanel.AlignBottomWith XAML attached property for the target element. /// /// The object from which the property value is read. /// /// The RelativePanel.AlignBottomWith XAML attached property value of the specified object. /// (The element to align this element's bottom edge with.) /// [ResolveByName] public static object GetAlignBottomWith(AvaloniaObject obj) { return (object)obj.GetValue(AlignBottomWithProperty); } /// /// Sets the value of the RelativePanel.Above XAML attached property for a target element. /// /// The object to which the property value is written. /// The value to set. (The element to align this element's bottom edge with.) [ResolveByName] public static void SetAlignBottomWith(AvaloniaObject obj, object value) { obj.SetValue(AlignBottomWithProperty, value); } /// /// Identifies the XAML attached property. /// public static readonly AttachedProperty AlignBottomWithProperty = AvaloniaProperty.RegisterAttached("AlignBottomWith", typeof(RelativePanel)); /// /// Gets the value of the RelativePanel.AlignHorizontalCenterWithPanel XAML attached property for the target element. /// /// The object from which the property value is read. /// /// The RelativePanel.AlignHorizontalCenterWithPanel XAML attached property value /// of the specified object. (true to horizontally center this element in the panel; /// otherwise, false.) /// public static bool GetAlignHorizontalCenterWithPanel(AvaloniaObject obj) { return (bool)obj.GetValue(AlignHorizontalCenterWithPanelProperty); } /// /// Sets the value of the RelativePanel.Above XAML attached property for a target element. /// /// The object to which the property value is written. /// /// The value to set. (true to horizontally center this element in the panel; otherwise, /// false.) /// public static void SetAlignHorizontalCenterWithPanel(AvaloniaObject obj, bool value) { obj.SetValue(AlignHorizontalCenterWithPanelProperty, value); } /// /// Identifies the XAML attached property. /// public static readonly AttachedProperty AlignHorizontalCenterWithPanelProperty = AvaloniaProperty.RegisterAttached("AlignHorizontalCenterWithPanel", typeof(RelativePanel), false); /// /// Gets the value of the RelativePanel.AlignHorizontalCenterWith XAML attached property for the target element. /// /// The object from which the property value is read. /// /// The RelativePanel.AlignHorizontalCenterWith XAML attached property value of the /// specified object. (The element to align this element's horizontal center with.) /// [ResolveByName] public static object GetAlignHorizontalCenterWith(AvaloniaObject obj) { return (object)obj.GetValue(AlignHorizontalCenterWithProperty); } /// /// Sets the value of the RelativePanel.Above XAML attached property for a target element. /// /// The object to which the property value is written. /// The value to set. (The element to align this element's horizontal center with.) [ResolveByName] public static void SetAlignHorizontalCenterWith(AvaloniaObject obj, object value) { obj.SetValue(AlignHorizontalCenterWithProperty, value); } /// /// Identifies the XAML attached property. /// public static readonly AttachedProperty AlignHorizontalCenterWithProperty = AvaloniaProperty.RegisterAttached("AlignHorizontalCenterWith", typeof(object), typeof(RelativePanel)); /// /// Gets the value of the RelativePanel.AlignLeftWithPanel XAML attached property for the target element. /// /// The object from which the property value is read. /// /// The RelativePanel.AlignLeftWithPanel XAML attached property value of the specified /// object. (true to align this element's left edge with the panel's left edge; otherwise, /// false.) /// public static bool GetAlignLeftWithPanel(AvaloniaObject obj) { return (bool)obj.GetValue(AlignLeftWithPanelProperty); } /// /// Sets the value of the RelativePanel.Above XAML attached property for a target element. /// /// The object to which the property value is written. /// /// The value to set. (true to align this element's left edge with the panel's left /// edge; otherwise, false.) /// public static void SetAlignLeftWithPanel(AvaloniaObject obj, bool value) { obj.SetValue(AlignLeftWithPanelProperty, value); } /// /// Identifies the XAML attached property. /// public static readonly AttachedProperty AlignLeftWithPanelProperty = AvaloniaProperty.RegisterAttached("AlignLeftWithPanel", typeof(RelativePanel), false); /// /// Gets the value of the RelativePanel.AlignLeftWith XAML attached property for the target element. /// /// The object from which the property value is read. /// /// The RelativePanel.AlignLeftWith XAML attached property value of the specified /// object. (The element to align this element's left edge with.) /// [ResolveByName] public static object GetAlignLeftWith(AvaloniaObject obj) { return (object)obj.GetValue(AlignLeftWithProperty); } /// /// Sets the value of the RelativePanel.Above XAML attached property for a target element. /// /// The object to which the property value is written. /// The value to set. (The element to align this element's left edge with.) [ResolveByName] public static void SetAlignLeftWith(AvaloniaObject obj, object value) { obj.SetValue(AlignLeftWithProperty, value); } /// /// Identifies the XAML attached property. /// public static readonly AttachedProperty AlignLeftWithProperty = AvaloniaProperty.RegisterAttached("AlignLeftWith"); /// /// Gets the value of the RelativePanel.AlignRightWithPanel XAML attached property for the target element. /// /// The object from which the property value is read. /// /// The RelativePanel.AlignRightWithPanel XAML attached property value of the specified /// object. (true to align this element's right edge with the panel's right edge; /// otherwise, false.) /// public static bool GetAlignRightWithPanel(AvaloniaObject obj) { return (bool)obj.GetValue(AlignRightWithPanelProperty); } /// /// Sets the value of the RelativePanel.Above XAML attached property for a target element. /// /// The object to which the property value is written. /// /// The value to set. (true to align this element's right edge with the panel's right /// edge; otherwise, false.) /// public static void SetAlignRightWithPanel(AvaloniaObject obj, bool value) { obj.SetValue(AlignRightWithPanelProperty, value); } /// /// Identifies the XAML attached property. /// public static readonly AttachedProperty AlignRightWithPanelProperty = AvaloniaProperty.RegisterAttached("AlignRightWithPanel", false); /// /// Gets the value of the RelativePanel.AlignRightWith XAML attached property for the target element. /// /// The object from which the property value is read. /// /// The RelativePanel.AlignRightWith XAML attached property value of the specified /// object. (The element to align this element's right edge with.) /// [ResolveByName] public static object GetAlignRightWith(AvaloniaObject obj) { return (object)obj.GetValue(AlignRightWithProperty); } /// /// Sets the value of the RelativePanel.AlignRightWith XAML attached property for a target element. /// /// The object to which the property value is written. /// The value to set. (The element to align this element's right edge with.) [ResolveByName] public static void SetAlignRightWith(AvaloniaObject obj, object value) { obj.SetValue(AlignRightWithProperty, value); } /// /// Identifies the XAML attached property. /// public static readonly AttachedProperty AlignRightWithProperty = AvaloniaProperty.RegisterAttached("AlignRightWith"); /// /// Gets the value of the RelativePanel.AlignTopWithPanel XAML attached property for the target element. /// /// The object from which the property value is read. /// /// The RelativePanel.AlignTopWithPanel XAML attached property value of the specified /// object. (true to align this element's top edge with the panel's top edge; otherwise, /// false.) /// public static bool GetAlignTopWithPanel(AvaloniaObject obj) { return (bool)obj.GetValue(AlignTopWithPanelProperty); } /// /// Sets the value of the RelativePanel.AlignTopWithPanel XAML attached property for a target element. /// /// The object to which the property value is written. /// /// The value to set. (true to align this element's top edge with the panel's top /// edge; otherwise, false.) /// public static void SetAlignTopWithPanel(AvaloniaObject obj, bool value) { obj.SetValue(AlignTopWithPanelProperty, value); } /// /// Identifies the XAML attached property. /// public static readonly AttachedProperty AlignTopWithPanelProperty = AvaloniaProperty.RegisterAttached("AlignTopWithPanel", false); /// /// Gets the value of the RelativePanel.AlignTopWith XAML attached property for the target element. /// /// The object from which the property value is read. /// The value to set. (The element to align this element's top edge with.) [ResolveByName] public static object GetAlignTopWith(AvaloniaObject obj) { return (object)obj.GetValue(AlignTopWithProperty); } /// /// Sets the value of the RelativePanel.AlignTopWith XAML attached property for a target element. /// /// The object to which the property value is written. /// The value to set. (The element to align this element's top edge with.) [ResolveByName] public static void SetAlignTopWith(AvaloniaObject obj, object value) { obj.SetValue(AlignTopWithProperty, value); } /// /// Identifies the XAML attached property. /// public static readonly AttachedProperty AlignTopWithProperty = AvaloniaProperty.RegisterAttached("AlignTopWith"); /// /// Gets the value of the RelativePanel.AlignVerticalCenterWithPanel XAML attached property for the target element. /// /// The object from which the property value is read. /// /// The RelativePanel.AlignVerticalCenterWithPanel XAML attached property value of /// the specified object. (true to vertically center this element in the panel; otherwise, /// false.) /// public static bool GetAlignVerticalCenterWithPanel(AvaloniaObject obj) { return (bool)obj.GetValue(AlignVerticalCenterWithPanelProperty); } /// /// Sets the value of the RelativePanel.AlignVerticalCenterWithPanel XAML attached property for a target element. /// /// The object to which the property value is written. /// /// The value to set. (true to vertically center this element in the panel; otherwise, /// false.) /// public static void SetAlignVerticalCenterWithPanel(AvaloniaObject obj, bool value) { obj.SetValue(AlignVerticalCenterWithPanelProperty, value); } /// /// Identifies the XAML attached property. /// public static readonly AttachedProperty AlignVerticalCenterWithPanelProperty = AvaloniaProperty.RegisterAttached("AlignVerticalCenterWithPanel", false); /// /// Gets the value of the RelativePanel.AlignVerticalCenterWith XAML attached property for the target element. /// /// The object from which the property value is read. /// The value to set. (The element to align this element's vertical center with.) [ResolveByName] public static object GetAlignVerticalCenterWith(AvaloniaObject obj) { return (object)obj.GetValue(AlignVerticalCenterWithProperty); } /// /// Sets the value of the RelativePanel.AlignVerticalCenterWith XAML attached property for a target element. /// /// The object to which the property value is written. /// The value to set. (The element to align this element's horizontal center with.) [ResolveByName] public static void SetAlignVerticalCenterWith(AvaloniaObject obj, object value) { obj.SetValue(AlignVerticalCenterWithProperty, value); } /// /// Identifies the XAML attached property. /// public static readonly AttachedProperty AlignVerticalCenterWithProperty = AvaloniaProperty.RegisterAttached("AlignVerticalCenterWith"); /// /// Gets the value of the RelativePanel.Below XAML attached property for the target element. /// /// The object from which the property value is read. /// /// The RelativePanel.Below XAML attached property value of the specified object. /// (The element to position this element below.) /// [ResolveByName] public static object GetBelow(AvaloniaObject obj) { return (object)obj.GetValue(BelowProperty); } /// /// Sets the value of the RelativePanel.Above XAML attached property for a target element. /// /// The object to which the property value is written. /// The value to set. (The element to position this element below.) [ResolveByName] public static void SetBelow(AvaloniaObject obj, object value) { obj.SetValue(BelowProperty, value); } /// /// Identifies the XAML attached property. /// public static readonly AttachedProperty BelowProperty = AvaloniaProperty.RegisterAttached("Below"); /// /// Gets the value of the RelativePanel.LeftOf XAML attached property for the target element. /// /// The object from which the property value is read. /// /// The RelativePanel.LeftOf XAML attached property value of the specified object. /// (The element to position this element to the left of.) /// [ResolveByName] public static object GetLeftOf(AvaloniaObject obj) { return (object)obj.GetValue(LeftOfProperty); } /// /// Sets the value of the RelativePanel.LeftOf XAML attached property for a target element. /// /// The object to which the property value is written. /// The value to set. (The element to position this element to the left of.) [ResolveByName] public static void SetLeftOf(AvaloniaObject obj, object value) { obj.SetValue(LeftOfProperty, value); } /// /// Identifies the XAML attached property. /// public static readonly AttachedProperty LeftOfProperty = AvaloniaProperty.RegisterAttached("LeftOf"); /// /// Gets the value of the RelativePanel.RightOf XAML attached property for the target element. /// /// The object from which the property value is read. /// /// The RelativePanel.RightOf XAML attached property value of the specified object. /// (The element to position this element to the right of.) /// [ResolveByName] public static object GetRightOf(AvaloniaObject obj) { return (object)obj.GetValue(RightOfProperty); } /// /// Sets the value of the RelativePanel.RightOf XAML attached property for a target element. /// /// The object to which the property value is written. /// The value to set. (The element to position this element to the right of.) [ResolveByName] public static void SetRightOf(AvaloniaObject obj, object value) { obj.SetValue(RightOfProperty, value); } /// /// Identifies the XAML attached property. /// public static readonly AttachedProperty RightOfProperty = AvaloniaProperty.RegisterAttached("RightOf"); } }