iOS 模拟/仿真翻页效果和(AFKPageFlipper)以及对PDF文档的读取
来源:互联网 发布:nodejs高级编程 中文 编辑:程序博客网 时间:2024/06/05 04:33
代码下载
翻页效果的实现采用的是AFKPageFlipper
使用时先导入AFKPageFlipper
http://download.csdn.net/detail/rylt2011/5586259
然后导入QuartzCore.framework
遵循AFKPageFlipperDataSource协议
在viewDidLoad中
self.view.autoresizesSubviews = YES; self.view.autoresizingMask = UIViewAutoresizingFlexibleWidth | UIViewAutoresizingFlexibleHeight; flipper = [[[AFKPageFlipper alloc] initWithFrame:self.view.bounds] autorelease]; flipper.autoresizingMask = UIViewAutoresizingFlexibleWidth | UIViewAutoresizingFlexibleHeight; flipper.dataSource = self; flipper.backgroundColor = [UIColor greenColor]; [self.view addSubview:flipper];
并实现函数
返回整个文档的页数
- (NSInteger) numberOfPagesForPageFlipper: (AFKPageFlipper *)pageFlipper
返回翻转页面所要加载的View
- (UIView *) viewForPage:(NSInteger) page inFlipper:(AFKPageFlipper *) pageFlipper
PDF文件的读取使用的是PDFRendererView
http://download.csdn.net/detail/rylt2011/5586275
同样导入PDFRendererView(目前还不够成熟,少数pdf文件显示格式会乱)
pdfDocument = CGPDFDocumentCreateWithURL((CFURLRef) [NSURL fileURLWithPath:[[NSBundle mainBundle] pathForResource:@"黑客调试技术揭密" ofType:@"pdf"]]);
代码下载
- iOS 模拟/仿真翻页效果和(AFKPageFlipper)以及对PDF文档的读取
- IOS读取和显示PDF文档
- iOS读取和显示PDF文档
- iOS读取和显示PDF文档
- iOS读取和显示PDF文档
- ios的翻页动画效果
- android 模拟真书翻页效果的博客
- 纯css写的仿真图书翻页效果
- 模拟和仿真的区别
- 模拟和仿真的区别
- iOS-编写简单的翻页效果
- IOS 上图书翻页效果的实现
- 【代码笔记】iOS-翻页效果的实现
- iOS 读取 以及 高亮 PDF
- iOS 书翻页效果
- ios图书翻页效果
- ios 翻页效果
- iOS 书翻页效果
- iOS7新特征汇总[03]新特征介绍3
- apt-get命令使用详解
- android Activity之间的参数传递
- Android TextUtils类介绍
- C++程序设计项目:指针操作学生类
- iOS 模拟/仿真翻页效果和(AFKPageFlipper)以及对PDF文档的读取
- 浅说机器学习中“迭代法”
- js中调用AS莫名其妙的错误,不得使用的关键词
- iOS7新特征汇总[04]新特征介绍4
- ArcGIS Server 10.1新特性-- 发布服务
- Handling IRPs: Definition 2: IRP as a Thread-Independent Call Stack
- c#之执行SQL存储过程
- python 抓取腾讯微博数据并做简单的分析
- 数据结构要点归纳总结(转)