本文整理汇总了C#中UIButton.Above方法的典型用法代码示例。如果您正苦于以下问题:C# UIButton.Above方法的具体用法?C# UIButton.Above怎么用?C# UIButton.Above使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类UIButton
的用法示例。
在下文中一共展示了UIButton.Above方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: LoadView
public override void LoadView ()
{
View = new UIImageView () {
UserInteractionEnabled = true,
} .Apply (Style.Welcome.Background);
View.Add (logoImageView = new UIImageView ().Apply (Style.Welcome.Logo));
View.Add (sloganLabel = new UILabel () {
Text = "WelcomeSlogan".Tr (),
} .Apply (Style.Welcome.Slogan));
View.Add (createButton = new UIButton ().Apply (Style.Welcome.CreateAccount));
View.Add (passwordButton = new UIButton ().Apply (Style.Welcome.PasswordLogin));
View.Add (googleButton = new UIButton ().Apply (Style.Welcome.GoogleLogin));
createButton.SetTitle ("WelcomeCreate".Tr (), UIControlState.Normal);
passwordButton.SetTitle ("WelcomePassword".Tr (), UIControlState.Normal);
googleButton.SetTitle ("WelcomeGoogle".Tr (), UIControlState.Normal);
createButton.TouchUpInside += OnCreateButtonTouchUpInside;
passwordButton.TouchUpInside += OnPasswordButtonTouchUpInside;
googleButton.TouchUpInside += OnGoogleButtonTouchUpInside;
View.AddConstraints (
logoImageView.AtTopOf (View, 70f),
logoImageView.WithSameCenterX (View),
sloganLabel.Below (logoImageView, 18f),
sloganLabel.AtLeftOf (View, 25f),
sloganLabel.AtRightOf (View, 25f),
googleButton.AtBottomOf (View, 20f),
googleButton.AtLeftOf (View),
googleButton.AtRightOf (View),
googleButton.Height ().EqualTo (60f),
passwordButton.Above (googleButton, 25f),
passwordButton.AtLeftOf (View),
passwordButton.AtRightOf (View),
passwordButton.Height ().EqualTo (60f),
createButton.Above (passwordButton, 5f),
createButton.AtLeftOf (View),
createButton.AtRightOf (View),
createButton.Height ().EqualTo (60f)
);
View.SubviewsDoNotTranslateAutoresizingMaskIntoConstraints ();
}