随笔分类 -  ios开发

iphone/ipad开发
摘要:http://bbs.weiphone.com/read-htm-tid-4008975.html 阅读全文
posted @ 2012-04-25 11:28 lynn_ios 阅读(254) 评论(0) 推荐(0)
摘要:1 -(void)usedSpaceAndfreeSpace{2 NSString* path = [NSSearchPathForDirectoriesInDomains(NSDocumentDirectory, NSUserDomainMask, YES) objectAtIndex:0] ;3 NSFileManager* fileManager = [[NSFileManager alloc ]init];4 NSDictionary *fileSysAttributes = [fileManager attributesOfFileSystemForPath:... 阅读全文
posted @ 2012-04-25 11:26 lynn_ios 阅读(1229) 评论(0) 推荐(0)
摘要:iPhone OS4.0加入了scale factor,这表示point长度/pixel长度。在分辨率为960*640的设备上,我们知道逻辑坐标系还是不变480*320,那么一个point有两个pixel长,所以scale=2.0。在分辨率为480*320的设备商,point和pixel长度相同,scale=1.0。为了程序自动适应分辨率,程序会自动给UIScreen.scale赋值,[UIScreen mainScreen].scale = 1.0 or 2.0。我们编程,画图,窗口,字体等都是矢量图,通过scale能够让我们不管分辨率,按照逻辑坐标480*320来设计界面,效果在所有分辨率 阅读全文
posted @ 2012-04-19 13:29 lynn_ios 阅读(1202) 评论(0) 推荐(0)
摘要:详细的是这样: 0.建立想要保存软件仓库的目录。并在系统设置里面打开Web共享。 sudo su (然后输入密码) mkdir /opt mkdir /opt/svn mkdir /opt/svn/repos 即创建了目录/opt/svn/repos/ 1.创建版本仓库svnadmin create /opt/svn/repos 2.修改授权配置 进入到仓库配置目录 cd /opt/svn/repos/conf (1)编辑配置文件 vi svnserve.conf 取消下列行的注释 anon-access = read auth-access = read password-db = pas. 阅读全文
posted @ 2012-04-17 08:58 lynn_ios 阅读(4498) 评论(1) 推荐(1)
摘要:iPad在横屏模式下,界面区域元素主要由下图所示构成:横屏主要尺寸:宽度:1024px高度:768px状态栏(Status Bar)高度:20px导航条(Nav Bar)高度:44px主内容区域(Main Cotent Area)高度:655px标签栏(Tab Bar)高度:49px键盘高度:352px 阅读全文
posted @ 2012-03-30 11:13 lynn_ios 阅读(1201) 评论(0) 推荐(0)
摘要:1. 下载ZBarSDK 添加到工程 2. 添加需要的framework 3. #import "ZBarSDK.h" 添加协议 ZBarReaderDelegate4. 1 ZBarReaderViewController *reader = [ZBarReaderViewController new]; 2 reader.readerDelegate = self; 3 ZBarImageScanner *scanner = reader.scanner; 4 [scanner setSymbology: ... 阅读全文
posted @ 2012-03-22 08:31 lynn_ios 阅读(1495) 评论(0) 推荐(0)
摘要:typedef enum {UIViewContentModeScaleToFill, UIViewContentModeScaleAspectFit,// contents scaled to fit with fixed aspect. remainder is transparent UIViewContentModeScaleAspectFill, // contents scaled to fill with fixed aspect. some portion of content may be clipped. UIViewContentModeRedraw,// redraw 阅读全文
posted @ 2011-11-03 17:27 lynn_ios 阅读(4667) 评论(0) 推荐(1)
摘要:利用终端进行证书的生成: 1.openssl pkcs12 -clcerts -nokeys -out cert.pem -inCertificates.p122.openssl pkcs12 -nocerts -out key.pem -in Certificates.p123.openssl rsa -in key.pem -out key.unencrypted.pem4.cat cert.pem key.unencrypted.pem > ck.pemphp代码: 1 #!/Applications/XAMPP/xamppfiles/bin/php 2 <?php 3 $d 阅读全文
posted @ 2011-10-31 10:59 lynn_ios 阅读(310) 评论(0) 推荐(0)
摘要:1 -(void)allview:(UIView *)rootview indent:(NSInteger)indent2 {3 NSLog(@"[%2d] %@",indent,rootview);4 indent++;5 for (UIView * aview in [rootview subviews])6 {7 [self allview:aview indent:indent];8 }9 } 阅读全文
posted @ 2011-10-11 16:57 lynn_ios 阅读(236) 评论(0) 推荐(0)