Share via


FlexLayout.SetAlignSelf 方法

定义

重载

SetAlignSelf(IView, FlexAlignSelf)
SetAlignSelf(BindableObject, FlexAlignSelf)

设置一个值,该值可选择性地替代该子元素的父元素项目对齐方式。

SetAlignSelf(IView, FlexAlignSelf)

public:
 void SetAlignSelf(Microsoft::Maui::IView ^ view, Microsoft::Maui::Layouts::FlexAlignSelf alignSelf);
public void SetAlignSelf (Microsoft.Maui.IView view, Microsoft.Maui.Layouts.FlexAlignSelf alignSelf);
member this.SetAlignSelf : Microsoft.Maui.IView * Microsoft.Maui.Layouts.FlexAlignSelf -> unit
Public Sub SetAlignSelf (view As IView, alignSelf As FlexAlignSelf)

参数

view
IView
alignSelf
FlexAlignSelf

适用于

SetAlignSelf(BindableObject, FlexAlignSelf)

设置一个值,该值可选择性地替代该子元素的父元素项目对齐方式。

public:
 static void SetAlignSelf(Microsoft::Maui::Controls::BindableObject ^ bindable, Microsoft::Maui::Layouts::FlexAlignSelf value);
public static void SetAlignSelf (Microsoft.Maui.Controls.BindableObject bindable, Microsoft.Maui.Layouts.FlexAlignSelf value);
static member SetAlignSelf : Microsoft.Maui.Controls.BindableObject * Microsoft.Maui.Layouts.FlexAlignSelf -> unit
Public Shared Sub SetAlignSelf (bindable As BindableObject, value As FlexAlignSelf)

参数

bindable
BindableObject

针对其检索属性值的对象。

value
FlexAlignSelf

新自行对齐值。

注解

下图显示了FlexLayout.SetAlignSelf(c, FlexAlignSelf.Start);AlignItemsStretch值为 :

适用于