详解UILabel的adjustsFontSizeToFitWidth值UILabel有一个属性值,叫adjustsFontSizeToFitWidth,看着名字就知道,他是用来让文字自动适应UILabel宽度的。先看看显示效果:测试用源码://// RootViewController.m// ....
分类:
其他好文 时间:
2014-09-14 23:17:37
阅读次数:
282
UITabBarController是IOS中很常用的一个viewController,例如系统的闹钟程序,ipod程序等。UITabBarController通常作为整个程序的rootViewController,而且不能添加到别的container viewController中。 首先我们看....
分类:
其他好文 时间:
2014-09-13 00:46:44
阅读次数:
325
firstViewController*firstVC=[[firstViewControlleralloc]init];NViewController*RootController=[[NViewControlleralloc]initWithRootViewController:firstVC];//RootViewController*RootController=[[RootViewControlleralloc]initWithRootViewController:firstVC];[firstVC..
分类:
其他好文 时间:
2014-09-05 03:24:11
阅读次数:
231
//UIViewController(基类)//1.管理视图//2.分担AppDelegate的任务//3.实现模块的独立,提高复用性//4.桥梁//抽象工厂设计模式://提供一个抽象的基类(提供基本的功能),使用时使用具体的子类//比如UIView,UIViewController都是抽象的基类.//创建视图控制器对象RootViewController*..
分类:
其他好文 时间:
2014-09-05 03:21:20
阅读次数:
197
假设在storyBoard中共有两个控制器。 1.rootViewController :根控制器 2.testViewController: 测试用的控制器,它的storyBoardID设置为test根控制器中得代码:#import "rootViewController.h"#import "....
分类:
移动开发 时间:
2014-09-04 20:49:00
阅读次数:
262
IOS通用的 只需要在RootViewController.mm文件里面 1 - (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation {
return UIInterfaceOrientationIsPortrait( interfa...
分类:
移动开发 时间:
2014-09-02 20:03:25
阅读次数:
186
动态切换tableView中的cell的种类为什么要动态切换tableView中cell的种类呢?如果项目经理不出这种需求,你也就见不到这篇文章了:)效果:源码:首先,你要准备3种cell,直接继承系统的就行了.//// RootViewController.m// ChangeCell////.....
分类:
其他好文 时间:
2014-08-29 21:15:58
阅读次数:
255
模拟系统照相机图片裁剪的功能效果如下:源码://// RootViewController.m// ScrollView//// Copyright (c) 2014年 Y.X. All rights reserved.//#import "RootViewController.h"@inte...
分类:
其他好文 时间:
2014-08-26 09:47:45
阅读次数:
201
不废话上代码 想学的跟着写一遍 注释很全了。
//
// RootViewController.m
// SearchTable
//
// Created by ALei on 14-8-22.
// Copyright (c) 2014年 MinjieShou. All rights reserved.
//
#i...
分类:
移动开发 时间:
2014-08-22 17:53:49
阅读次数:
326
- (void)show{ if ([UIApplication sharedApplication].keyWindow.rootViewController.navigationController) { [[UIApplication sharedApplication].keyWin...
分类:
其他好文 时间:
2014-08-15 09:27:27
阅读次数:
182