dnnta.com
域名年龄: 14年2个月9天HTTP/1.1 200 OK 服务器:GitHub.com 访问时间:2013年10月30日 17:02:47 类型:text/html 修改日期:2012年04月06日 16:09:15 Transfer-Encoding: chunked 连接:keep-alive 过期时间:2013年10月30日 17:12:47 缓存控制:max-age=600 动作:Accept-Encoding Content-Encoding: gzip 页面编码:utf-8
Dnnta's blogRSSBlogArchivesCALayersMar 2nd, 2012Setting CALayer Corner Radius and Image Content123456789101112131415161718CALayer *sublayer = [CALayer layer];sublayer.backgroundColor = [UIColor blueColor].CGColor;sublayer.shadowOffset = CGSizeMake(0, 3);sublayer.shadowRadius = 5.0;sublayer.shadowColor = [UIColor blackColor].CGColor;sublayer.shadowOpacity = 0.8;sublayer.frame = CGRectMake(30, 30, 128, 192);sublayer.borderColor = [UIColor blackColor].CGColor;sublayer.borderWidth = 2.0;sublayer.cornerRadius = 10.0;[self.view.layer addSublayer:sublayer];CALayer *imageLayer = [CALayer layer];imageLayer.frame = sublayer.bounds;imageLayer.cornerRadius = 10.0;imageLayer.contents = (id) [UIImage imageNamed:@"BattleMapSplashScreen.jpg"].CGImage;imageLayer.masksToBounds = YES;[sublayer addSublayer:imageLayerRead on →iOS开发常识图解Dec 1st, 2011开源协议图解Read on →UITableViewNov 23rd, 2011UITableViewCell局部刷新1[self.tableView reloadRowsAtIndexPaths:[NSArray arrayWithObjects:indexPathOfYourCell, nil] withRowAnimation:UITableViewRowAnimationNone];下拉刷新 关键字pull refresh字体占用空间Helvetica1CGSize size = [text sizeWithFont:font constrainedToSize:CGSizeMake(175.0f, 2000.0f) lineBreakMode:UILineBreakModeWordWrap];UINavigationBarNov 3rd, 2011custom UITabbarItem1234567891011121314151617181920212223242526272829UIFont *font = [UIFont fontWithName:@"Helvetica" size:13.0f];UIButton *backBtn = [UIButton buttonWithType:UIButtonTypeCustom];[backBtn setBackgroundImage:[UIImage imageNamed:@"btn_left.png"] forState:UIControlStateNormal];[backBtn addTarget:self action:@selector(back:) forControlEvents:UIControlEventTouchUpInside];backBtn.frame = CGRectMake(0, 0, 57, 38);[backBtn setTitle:@" 返回" forState:UIControlStateNormal];backBtn.titleLabel.font = font;[backBtn setTitleShadowColor:[UIColor blackColor] forState:UIControlStateNormal];backBtn.titleLabel.shadowOffset = CGSizeMake(0, -1);UIBarButtonItem *backItem = [[UIBarButtonItem alloc] initWithCustomView:backBtn];self.navigationItem.leftBarButtonItem = backItem;[backItem release]; UIButton *rightBtn = [UIButton buttonWithType:UIButtonTypeCustom];[rightBtn setBackgroundImage:[UIImage imageNamed:@"btn_right.png"] forState:UIControlStateNormal];[rightBtn addTarget:self action:nil forControlEvents:UIControlEventTouchUpInside];rightBtn.frame = CGRectMake(0, 0, 57, 39);[rightBtn setTitle:@"纠错" forState:UIControlStateNormal];[rightBtn setTitleShadowColor:[UIColor blackColor] forState:UIControlStateNormal];rightBtn.titleLabel.shadowOffset = CGSizeMake(0, -1);rightBtn.titleLabel.font = font;UIBarButtonItem *rightItem = [[UIBarButtonItem alloc] initWithCustomView:rightBtn];self.navigationItem.rightBarButtonItem = rightItem;[rightItem release];- (void)back:(id)sender {[self.navigationController popViewControllerAnimated:YES];}设置UIBarButtonItem里面图片的偏移123//moves the image 4 pixels down.float topInset = 4.0f;myUIBarButton.imageInsets = UIEdgeInsetsMake(topInset, 0.0f, -topInset, 0.0f);R
© 2010 - 2020 网站综合信息查询 同IP网站查询 相关类似网站查询 网站备案查询网站地图 最新查询 最近更新 优秀网站 热门网站 全部网站 同IP查询 备案查询
2024-05-01 08:42, Process in 0.0093 second.