码迷,mamicode.com
首页 >  
搜索关键字:bounds    ( 955个结果
简单的iOS抽屉效果
#define screenW [UIScreen mainScreen].bounds.size.width #import "ViewController.h" @interface ViewController () @property (nonatomic,strong)UIView * r
分类:移动开发   时间:2016-01-28 17:22:52    阅读次数:151
ios开发获得屏幕尺寸的一些小问题
代码中发掘模拟器跑出来的代码, 用self.view.frame.size.width 获得屏幕尺寸一直都是320 , 无奈改为[UIScreen mainScreen].bounds.size.width高度同样用[UIScreen mainScreen].bounds.size.height
分类:移动开发   时间:2016-01-25 19:35:12    阅读次数:154
根据 字数 确定 UI控件高度
//字体 textLabel.font = [UIFont systemFontOfSize:13]; CGFloat labelWidth = [UIScreen mainScreen].bounds.size.width-100; // 创建文字 NSString *string =@"...
分类:其他好文   时间:2016-01-25 13:08:47    阅读次数:167
Mac - 设置NSButton 的背景色
- (void)drawRect:(NSRect)dirtyRect { [super drawRect:dirtyRect]; [[NSColor clearColor] setFill]; NSRectFill(self.bounds); self.wantsLayer = YES;...
分类:系统相关   时间:2016-01-25 12:48:50    阅读次数:1189
UICollectionViewController既有headerView又有footerView。
#import "FirstHeaderReusableView.h"#import "FirstFooterReusableView.h"#define ITEMWIDTH ([UIScreen mainScreen].bounds.size.width - 30) / 2#define ITEM...
分类:其他好文   时间:2016-01-25 08:47:14    阅读次数:140
UIWindow ,UIlable
1.创建window 1 //1.创建window,UIScreen是屏幕类,创建和屏幕等大的窗口 2 self.window = [[UIWindow alloc] initWithFrame:[UIScreen mainScreen].bounds]; 3 //2.背景颜色 4...
分类:Windows程序   时间:2016-01-23 22:53:17    阅读次数:259
截取桌面图片
Screen s = Screen.PrimaryScreen; Bitmap bit = new Bitmap(s.Bounds.Width, s.Bounds.Height); Graphics g = Graphics.FromImage(bit);...
分类:其他好文   时间:2016-01-23 10:21:30    阅读次数:135
一张图让你明白IOS中bounds和frame的区别
很多人在学习的就搞混了bounds和frame的区别,大家可以看看这张图就会明白它俩的区别:frame: 该view在父view坐标系统中的位置和大小。(参照点是,父亲的坐标系统)bounds:该view在本地坐标系统中的位置和大小。(参照点是,本地坐标系统,就相当于ViewB自己的坐标系统,以0,...
分类:移动开发   时间:2016-01-22 21:51:11    阅读次数:188
3 - 图层几何学
frame frame实际上代表了覆盖在图层旋转之后的整个轴对齐的矩形区域,也就是说,frame的宽高可能和 bounds的宽高不再一致 frame是一个虚拟属性,是根据bounds,position 和 transfrom计算而来 archorPoint视图的 ce...
分类:其他好文   时间:2016-01-22 21:03:20    阅读次数:148
ScrollView详解
创建方式1:StoryBoard/Xib这里StoarBoard就不多说,直接拖就可以,说太多没意思,如果连这个都不会我只能先给你跪了!2:代码:123CGRect bounds = [ [ UIScreen mainScreen ] applicationFrame ] ;UIScrollView...
分类:其他好文   时间:2016-01-21 23:23:08    阅读次数:1638
955条   上一页 1 ... 47 48 49 50 51 ... 96 下一页
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!