Add more Button to Nav Bar xamarin.ios
来源:互联网 发布:centos snmpwalk 编辑:程序博客网 时间:2024/06/06 04:10
this.Title = "Inspection";
this.NavigationController.NavigationBar.TitleTextAttributes = new UIStringAttributes ()
{
ForegroundColor=UIColor.White
};
this.NavigationController.NavigationBar.TintColor = UIColor.White;
this.NavigationController.NavigationBar.BarTintColor = UIColor.FromRGB (85,116,163);
this.NavigationController.NavigationBar.Translucent = false;
this.NavigationController.NavigationBarHidden = false;
this.NavigationController.NavigationBar.BarStyle = UIBarStyle.BlackTranslucent;
var customButton = new UIBarButtonItem(
UIImage.FromFile("ic_camera_alt_white_48dp.png"),
UIBarButtonItemStyle.Plain,
(s, e) => {
System.Diagnostics.Debug.WriteLine("button tapped");
}
);
var customButton2 = new UIBarButtonItem(
UIImage.FromFile("mic_attach_file_white_48dp.png"),
UIBarButtonItemStyle.Plain,
(s, e) => {
System.Diagnostics.Debug.WriteLine("button tapped");
}
);
var customButton3 = new UIBarButtonItem(
UIImage.FromFile("ic_save_white_48dp.png"),
UIBarButtonItemStyle.Plain,
(s, e) =>
{
System.Diagnostics.Debug.WriteLine("button tapped");
}
);
NavigationItem.RightBarButtonItems= new UIBarButtonItem[] { customButton, customButton2 ,customButton3 };
this.NavigationController.NavigationBar.TitleTextAttributes = new UIStringAttributes ()
{
ForegroundColor=UIColor.White
};
this.NavigationController.NavigationBar.TintColor = UIColor.White;
this.NavigationController.NavigationBar.BarTintColor = UIColor.FromRGB (85,116,163);
this.NavigationController.NavigationBar.Translucent = false;
this.NavigationController.NavigationBarHidden = false;
this.NavigationController.NavigationBar.BarStyle = UIBarStyle.BlackTranslucent;
var customButton = new UIBarButtonItem(
UIImage.FromFile("ic_camera_alt_white_48dp.png"),
UIBarButtonItemStyle.Plain,
(s, e) => {
System.Diagnostics.Debug.WriteLine("button tapped");
}
);
var customButton2 = new UIBarButtonItem(
UIImage.FromFile("mic_attach_file_white_48dp.png"),
UIBarButtonItemStyle.Plain,
(s, e) => {
System.Diagnostics.Debug.WriteLine("button tapped");
}
);
var customButton3 = new UIBarButtonItem(
UIImage.FromFile("ic_save_white_48dp.png"),
UIBarButtonItemStyle.Plain,
(s, e) =>
{
System.Diagnostics.Debug.WriteLine("button tapped");
}
);
NavigationItem.RightBarButtonItems= new UIBarButtonItem[] { customButton, customButton2 ,customButton3 };
0 0
- Add more Button to Nav Bar xamarin.ios
- Xamarin iOS+MvvmCross TableCell add Button
- Add Text To Image xamarin.ios
- ion-nav-bar中添加button
- nav state bar
- ion-nav-bar
- Change Xamarin iOS navigation and status bar color
- How to add a button to PreferenceScreen
- How to add customized button to SM30.
- How to add custom title bar to android application
- xamarin.ios中设置button的边框及样式
- xamarin ios 怎样捕获UITableViewCell中button的点击事件
- One method to disable close button on title bar
- How to Add Virtual Keys on Status Bar
- How To Add Search Bar in Table View
- 只在本视图隐藏nav bar
- How to add one or more control files
- ios Nav自定义返回
- java网络编程四:InetAddress类、URL类、URLConnection类解析及用法示例
- HTML简单学习笔记(主要来自W3S)
- Android Studio Gradle构建速度优化
- 如何成为一名优秀的iOS开发工程师
- 触摸事件的传递
- Add more Button to Nav Bar xamarin.ios
- CV codes代码分类整理合集
- Android内存优化
- tomat上使用redis共享session
- JVM内存管理的机制和调优
- Hexagon DSP SDK--DSP处理器
- ABAP简介以及OpenSQL与NativeSQL的区别
- PAT1035插入与归并
- java网络编程五:暴力法破解登录系统的完全实现(木子)