public static LabelForTitle ( string title ) : UILabel | ||
title | string | |
return | UILabel |
private void SetupUI() { var backButton = new UIButton(new RectangleF(0, 0, 25, 25)); backButton.SetBackgroundImage(UIImage.FromFile("Images/General/BackButton.png"), UIControlState.Normal); backButton.SetBackgroundImage(UIImage.FromFile("Images/General/BackButtonHighlighted.png"), UIControlState.Highlighted); backButton.AddTarget((object sender, EventArgs args) => NavigationController.PopViewControllerAnimated(true), UIControlEvent.TouchUpInside); var cancelButton = new UIButton(new RectangleF(0, 0, 25, 25)); cancelButton.SetBackgroundImage(UIImage.FromFile(Images.CancelButton), UIControlState.Normal); cancelButton.SetBackgroundImage(UIImage.FromFile(Images.CancelButtonHighlighted), UIControlState.Highlighted); cancelButton.AddTarget(HandleCancelButtonTapped, UIControlEvent.TouchUpInside); BackButton = new UIBarButtonItem(backButton); CancelButton = new UIBarButtonItem(cancelButton); NavigationController.NavigationItem.BackBarButtonItem = BackButton; NavigationItem.LeftBarButtonItem = CancelButton; NavigationController.NavigationBar.BarStyle = UIBarStyle.Black; NavigationBarLabel = InterfaceHelper.LabelForTitle("SETTINGS"); TableView.BackgroundView = null; TableView.BackgroundColor = UIColor.FromPatternImage(UIImage.FromFile("Images/General/TableBackground.png")); }
public override void ViewWillAppear(bool animated) { base.ViewWillAppear(animated); NavigationController.NavigationBar.SetBackgroundImage(Images.BlankBar, UIBarMetrics.Default); NavigationBarLabel = InterfaceHelper.LabelForTitle("EDIT"); NavigationItem.TitleView = NavigationBarLabel; }
public override void ViewWillAppear(bool animated) { base.ViewWillAppear(animated); NavigationController.NavigationBar.SetBackgroundImage(Images.BlankBar, UIBarMetrics.Default); NavigationBarLabel = InterfaceHelper.LabelForTitle("PRAYERS"); NavigationItem.TitleView = NavigationBarLabel; PrayersTable.Source = new PrayersTableSource(this); }
public override void ViewWillAppear(bool animated) { base.ViewWillAppear(animated); NavigationController.NavigationBar.SetBackgroundImage(UIImage.FromFile(Images.BlankBar), UIBarMetrics.Default); SetupNavigationBar(); navigationBarLabel = InterfaceHelper.LabelForTitle(controllerHeader); NavigationItem.TitleView = navigationBarLabel; }
public override void ViewDidLoad() { base.ViewDidLoad(); SetupNavigationBar(); NavigationController.NavigationBar.SetBackgroundImage(Images.BlankBar, UIBarMetrics.Default); NavigationBarLabel = InterfaceHelper.LabelForTitle(Prayer.Title.ToUpper()); NavigationItem.TitleView = NavigationBarLabel; SetupUI(); }
protected override void PrepareDialogViewController(UIViewController dvc) { base.PrepareDialogViewController(dvc); NavigationBarLabel = InterfaceHelper.LabelForTitle(Caption.ToUpper()); dvc.NavigationItem.TitleView = NavigationBarLabel; var backButton = new UIButton(new RectangleF(0, 0, 25, 25)); backButton.SetBackgroundImage(UIImage.FromFile("Images/General/BackButton.png"), UIControlState.Normal); backButton.SetBackgroundImage(UIImage.FromFile("Images/General/BackButtonHighlighted.png"), UIControlState.Highlighted); backButton.AddTarget((object sender, EventArgs args) => GoBack(dvc), UIControlEvent.TouchUpInside); BackButton = new UIBarButtonItem(backButton); dvc.NavigationItem.LeftBarButtonItem = BackButton; }
void SetupUI() { NavigationController.NavigationBar.SetBackgroundImage(Images.BlankBar, UIBarMetrics.Default); var title = memorizationCategory.ToString().ToUpper(); NavigationBarLabel = InterfaceHelper.LabelForTitle(title); NavigationItem.TitleView = NavigationBarLabel; var backButton = new UIButton(new RectangleF(0, 0, 25, 25)); backButton.SetBackgroundImage(Images.BackButton, UIControlState.Normal); backButton.SetBackgroundImage(Images.BackButtonHighlighted, UIControlState.Highlighted); backButton.AddTarget((sender, args) => NavigationController.PopViewControllerAnimated(true), UIControlEvent.TouchUpInside); BackButton = new UIBarButtonItem(backButton); NavigationItem.LeftBarButtonItem = BackButton; TableView.SeparatorStyle = UITableViewCellSeparatorStyle.None; TableView.SeparatorColor = UIColor.Clear; TableView.BackgroundView = null; TableView.BackgroundColor = UIColor.FromPatternImage(Images.TableViewBackground); }
private void RefreshNavigationBar() { NavigationBarLabel = InterfaceHelper.LabelForTitle(name.ToUpperInvariant()); NavigationItem.TitleView = NavigationBarLabel; }