- 博客(10)
- 收藏
- 关注
翻译 Drawing Gradients(绘制渐变)
绘制过程: 创建上下文环境 -CGContextRef UIGraphicsGetCurrentContext (void); //CGContextRef currentContext = UIGraphicsGetCurrentContext(); 保存状态 -void CGContextSaveGState (CGContextRef c); // CGContex
2014-03-27 16:18:48 1402
翻译 Adding Shadows to Shapes(添加阴影)
绘制过程: 创建路径 -CGMutablePathRef CGPathCreateMutable (void); //CGMutablePathRef path = CGPathCreateMutable(); 设置矩形 -CGRect CGRectMake (CGFloat x,CGFloat y,CGFloat width,CGFloat height); 将
2014-03-20 14:44:51 861
翻译 Drawing Rectangles(绘制矩形)
绘制过程: 创建路径 -CGMutablePathRef CGPathCreateMutable (void); //CGMutablePathRef path = CGPathCreateMutable(); 设置矩形 -CGRect CGRectMake (CGFloat x,CGFloat y,CGFloat width,CGFloat height); 将
2014-03-20 10:10:36 1161
翻译 Constructing Paths(构建路径)
points -> a shape:多个点构成一个形状shapes -> a path:多个形状构成一个路径绘制过程: 创建路径 -CGMutablePathRef CGPathCreateMutable (void); //CGMutablePathRef path = CGPathCreateMutable(); 设置起点 -void CGPathMoveT
2014-03-19 17:28:05 893
翻译 Drawing Lines(绘制线条)
绘制过程: 设置颜色 - (void)set 设置线条宽度 - (void)CGContextSetLineWidth(CGContextRef c,CGFloat width); 设置连线类型 - (void)CGContextSetLineJoin (CGContextRef c,CGLineJoin join); //默认
2014-03-19 15:55:42 1533
翻译 Drawing Images(绘制图像)
1.加载图像:+ (UIImage *)imageNamed:(NSString *)name //name:imageName 不用加扩展名如.png,...+ (UIImage *)imageWithData:(NSData *)data- (id)initWithContentsOfFile:(NSString *)path //[[UIImage alloc]initWit
2014-03-19 13:51:22 1262
翻译 Drawing Text(二)绘制文本,颜色的使用
//颜色构造 -- alpha:[0,1] 0-完全透明 1-不透明[UIColor redColor], .....+ (UIColor *)colorWithRed:(CGFloat)red green:(CGFloat)green blue:(CGFloat)blue alpha:(CGFloat)alpha //设置绘制的起始位置及样式属性- (void)drawAtP
2014-03-18 16:05:51 2449
翻译 Drawing Text(一)绘制文本
1.Enumerating and Loading Fonts(枚举出系统字体,并正确加载) Font families -> Font faces -(void) enumerateFonts { for (NSString *familyName in[UIFont familyNames]) { NSLog(@"Font Family = %
2014-03-18 11:50:11 746
原创 jQuery Mobile 页面事件
1. 页面初始化事件: pagebeforecreate - 页面即将初始化(即在页面创建前) pagecreate - 页面创建 pageinit - 页面初始化 $(document).on("pagebeforecreate", function (event) {// ..... });2.
2014-03-17 11:00:25 728
原创 jQuery Mobile 基础事件
1. 页面初始化事件:pageinit$(document).on("pageinit", "#pageId", function () {// jQuery事件处理});2. touch事件:用户触摸屏幕时触发tap -用户敲击某个元素时触发 $("p").on("tap", function () {$(this).hide();}); taph
2014-03-17 10:34:52 766
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人