![](https://img-blog.csdnimg.cn/20201014180756927.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
IOS UI 设计
coly6203
这个作者很懒,什么都没留下…
展开
-
IOS UI 之 去tabelView分割线
[tableView setSeparatorStyle:UITableViewCellSeparatorStyleNone];原创 2015-08-24 11:17:03 · 463 阅读 · 0 评论 -
iOS 地图截屏
上一次截屏的代码真是又丑又长, 看看大神是怎么写的吧- (nullable UIImage *)generateSnapshot:(CGSize)size{ self.addressLabelBg.hidden = YES; self.addressLabel.hidden = YES; self.mapView.showsUserLocation = NO;原创 2016-07-18 09:35:27 · 547 阅读 · 0 评论 -
tableview建立的比较好的方法
@property(nullable, nonatomic, strong) NSArray *itemList; self.itemList = ({ NSMutableArray *array = @[].mutableCopy; { NSDictionary *item = @{ @"title" : @"定位示例",原创 2016-07-18 09:27:39 · 261 阅读 · 0 评论 -
iOS 单元测试
添加测试target 选择无ui得iOS Unit Testing Bundle- (void)testCalculatePageWithLines { // given NSInteger lines = 1; NSInteger columns = 4; NSInteger count = 10; SJPopupMenu *menu =原创 2016-07-27 14:09:33 · 217 阅读 · 0 评论 -
APNs(英文全称:Apple Push Notification service)Demo与实践
APNs(英文全称:Apple Push Notification service)Demo与实践1.将用到的工具 Easy APNs Peovider2.操作步骤一些准备工作1.建立一个Xcode工程 我将其命名为SJAPNSdemo2.一个测试机(自己的手机)因为APNS只能在实体设备上工作3.在apple developer官网上申请一个APP ID并使其与自身项目的Bundle identi原创 2016-06-14 09:28:16 · 665 阅读 · 0 评论 -
ios截屏 裁剪区域
代码参考http://blog.csdn.net/lizitao/article/details/41828697关键点,取正方区域,等比放大,设中心点,观察中心点重设后偏移量 如 375*667屏 假设一个预估截屏区域imageview900X900 等比缩放后的imageview为 900 1600 其中心点坐标为 450 800 这时将中心点坐标重设为预估截屏区域中心点450原创 2016-07-11 10:31:32 · 335 阅读 · 0 评论 -
网络请求问题
这几天在学习 NSURLSession 和 QLPreviewController 遇到一个问题 发现网络请求失败 po了error发现“The resource could not be loaded because the App Transport Security policy requires the use of a secure connection.”原来转载 2016-06-07 09:53:18 · 303 阅读 · 0 评论 -
看github老库的时候遇到的问题以及解决方法
问题:No architectures to compile for (ONLY_ACTIVE_ARCH=YES, active arch=x86_64, VALID_ARCHS=i386).解决方法build settings ---->Architectures——————>Valid Architectures 添加 arm64 armv7 armv7s原创 2016-06-28 10:45:16 · 256 阅读 · 0 评论 -
5/23 大神review菜鸡代码后的学习心得与近期任务
简单总结一下一些编码细节。1 常量声明 菜鸡写法 #define XXXX @“XXXX”大神写法static NSTimeInterval const kSpeechTimeout = 30000;static const 和取名前缀k作用 清晰,避免编译出错2 第三方 尖括号不要手滑变成“” “”是导入用户自定义的头文件3 property取名可原创 2016-05-23 16:56:35 · 264 阅读 · 0 评论 -
segmentedControl与swipe联合控制页面
添加HMSegmentedControl 和 SwipeView 第三方控件加入项目//subviews@property (nonatomic,strong)HMSegmentedControl *segmentedControl;@property (nonatomic,strong)SwipeView *swipeView;viewDidLoad中添加 //原创 2015-09-22 18:44:49 · 671 阅读 · 0 评论 -
设置UIButton字体颜色
[_yearButton setTitle:@"123" forState:UIControlStateNormal];[_yearButton setTitleColor:[UIColor blackColor] forState:UIControlStateNormal];原创 2015-09-21 12:55:02 · 522 阅读 · 0 评论 -
修改tableViewCell的默认checkmark颜色 并实现其单选功能
蓝色是tableViewCell的默认前景色(tintColor),所以我们设置cell.tintColor = [UIColor redColor];就可以改前景色为红色了,同样那个accessoryCheckmark的颜色就变成红色了。 首先我们公开一个属性 @property(nonatomic,strong)NSIndexPath *lastPath;主要是用来原创 2015-08-24 11:32:31 · 2928 阅读 · 0 评论 -
取得tableViewCell中的任意一个cell
UITableViewCell *cell = [self.tableViewcellForRowAtIndexPath:[NSIndexPathindexPathForRow:0inSection:2]];原创 2015-09-21 15:45:19 · 380 阅读 · 0 评论 -
点击cell,在cell下方创建一个新的cell,再次点击,删除该cell
初始化数组: NSDictionary *dic =@{@"Cell":@"MainCell",@"isAttached":@(NO)}; NSArray * array =@[dic,dic,dic,dic,dic,dic]; self.dataArray = [[NSMutableArrayalloc]init]; self.dataAr原创 2015-09-29 10:03:37 · 344 阅读 · 0 评论 -
关于数组切换控制tableview的section切换问题
在进行点击事件(数组移动)这个事件时 需要加上一条判定当前section的命令,否则会出错甚至崩溃出错的原因可能是通过数组创建的cell在数组移动后,点击刷新后生成的cell会将2个section中的cell的点击事件都触发一遍原创 2015-09-25 10:33:30 · 538 阅读 · 0 评论 -
TextField 设置大全
//初始化textfield并设置位置及大小 UITextField *text = [[UITextField alloc]initWithFrame:CGRectMake(20, 20, 130, 30)]; //设置边框样式,只有设置了才会显示边框样式 text.borderStyle = UITextBorderStyleRoundedRect;转载 2015-08-25 09:36:54 · 466 阅读 · 0 评论 -
这段时间使用MKMapView的一点总结(待编辑)
1.MKMapview 使用的是高德地图2.打开定位小蓝点的显示mapview.showsUserLocation = YES;3.定位到一个区域的函数(会重置旋转角度),可以有一个放大的动画效果 [self.mapView setRegion:MKCoordinateRegionMake(userLocation.location.coordinat原创 2016-07-18 12:33:28 · 452 阅读 · 0 评论