
UI 基本控件
文章平均质量分 75
静守晨昏
这个作者很懒,什么都没留下…
展开
专栏收录文章
- 默认排序
- 最新发布
- 最早发布
- 最多阅读
- 最少阅读
-
设置UIButton的文字显示位置、字体的大小、字体的颜色 .
设置UIButton的文字显示位置、字体的大小、字体的颜色btn.frame = CGRectMake(x, y, width, height);[btn setTitle: @"search" forState: UIControlStateNormal];//设置按钮上的自体的大小//[btn setFont: [UIFont systemFontS转载 2013-11-21 18:48:24 · 1205 阅读 · 0 评论 -
如何创建Tableview
如何创建Tableview今天学习了如何在空的工程中创建新的Tableview:1.在xcode中创建一个空的工程:打开xcode-->new -->project-->Empty Aplliction命名和路径。2.新近一个controller类文件打开新建-->file-->命名3.定义Tableview和实现Tableview的两个必须实现的委托方法:(1)创建一转载 2013-12-25 16:35:09 · 975 阅读 · 0 评论 -
理一理UIViewController
理一理UIViewController 问题:1.loadView, viewDidLoad, viewWillAppear的调用顺序?2.viewDidLoad会在什么时候调用?会调用几次?3.viewDidUnload会在什么时候调用?iOS6上怎么处理内存警告?4.init方法会加载xib文件吗?5.能把controller1.view添加到controller2转载 2013-11-28 21:41:27 · 1100 阅读 · 0 评论 -
iphone UIImage用法介绍
iphone UIImage用法介绍1.根据给定得图片,从其指定区域截取一张新得图片 -(UIImage *)getImageFromImage{ //大图bigImage //定义myImageRect,截图的区域 CGRect myImageRect = CGRectMake(10.0, 10.0, 57.0, 57.0); UIImag转载 2013-11-26 20:15:33 · 1597 阅读 · 0 评论 -
使用UITextFieldDelegate来隐藏键盘
使用UITextFieldDelegate来隐藏键盘原文链接地址:http://blog.sina.com.cn/s/blog_bf9843bf0101f91t.html 方法一:使用UITextFieldDelegate这个协议实现隐藏键盘。需要三步:1. 在你的控制器类中,加入UITextFieldDelegate协议,如: @interface Editin转载 2013-11-24 13:50:43 · 881 阅读 · 0 评论 -
Label用法总结
Label用法总结原文链接:http://blog.sina.com.cn/s/blog_bf9843bf0101f7z7.html(1)初始化UILabel *aLabel=[[UILabel alloc]initWithFrame:CGRectMake(50, 50, 100, 50)];(2)文字内容//位置默认是靠左的[aLabel setText:@"hello"转载 2013-11-24 13:57:19 · 1711 阅读 · 0 评论 -
UIButton使用方法汇总
UIButton使用方法汇总原文链接地址:http://blog.sina.com.cn/s/blog_bf9843bf0101f8hr.html //按钮初始化类方法UIButton *button1 = [UIButton buttonWithType:UIButtonTypeRoundedRect];//这里创建一个圆角矩形的按钮//按钮初始化实例方法UIButton转载 2013-11-24 13:53:09 · 888 阅读 · 0 评论 -
UIApplication详解(转载)
UIApplication详解(转载)原文地址:http://blog.sina.com.cn/s/blog_bf9843bf0101fatt.html UIApplication的核心作用是提供了iOS程序运行期间的控制和协作工作。iPhone应用程序是由主函数main启动,它负责调用UIApplicationMain函数,该函数的形式如下所示: int UIApplicat转载 2013-11-24 14:00:03 · 684 阅读 · 0 评论 -
IOS小型计算器实例代码2
IOS小型计算器实例代码2原文链接:http://blog.sina.com.cn/s/blog_bf9843bf0101fca3.html步骤:1.打开Xcode,单机Creat a new Xcode project2.左边选择ios下Application,右边选择single view Application3.填写项目名称单机Next4.ViewControl转载 2013-11-24 14:08:29 · 988 阅读 · 0 评论 -
UITextField用法总汇 (转载)
UITextField用法总汇 (转载)原文: http://www.3lian.com/edu/2012/11-08/43227.html//初始化textfield并设置位置及大小 UITextField *text = [[UITextField alloc]initWithFrame:CGRectMake(20, 20, 130, 30)]; //设置边框样式,只有设转载 2013-11-24 13:54:55 · 686 阅读 · 0 评论 -
UIAlertView用法
UIAlertView用法原文链接:http://blog.sina.com.cn/s/blog_bf9843bf0101fahf.html1. 最简单的用法UIAlertView*alert = [[UIAlertView alloc]initWithTitle:@"提示" m转载 2013-11-24 13:45:49 · 959 阅读 · 0 评论 -
表格视图UITableView及控制器UITableViewController
表格视图UITableView及控制器UITableViewControllerUITableViewController表格视图控制器UITableViewController类继承自UIViewController类,极大地简化了创建UITableView的过程。UITableViewController负责处理表格布局,并使用一个UITableVi转载 2013-11-23 20:12:39 · 1429 阅读 · 0 评论 -
UIButton事件
转自:http://blog.csdn.net/jb80400812/article/details/6614184创建UIButtonUIButton *btn = [UIButton buttonWithType:UIButtonTypeRoundedRect];btn.frame = CGRectMake(30,360, 90, 35);[转载 2013-11-21 18:38:41 · 1243 阅读 · 0 评论 -
UITextView的基本用法和代理方法
UITextView的基本用法和代理方法在 .m 文件中 (1)加载视图—(void)loadview{ // 4 文本输入框UITextView* textview1=[[UITextViewalloc]initWithFrame:CGRectMake(80, 220, 160, 30)];// 代理指向selftextview1.delega原创 2014-03-04 08:26:44 · 8321 阅读 · 0 评论