iphone 下Three20库(From Facebook)的设置使用方法
来源:互联网 发布:数控磨床怎么编程 编辑:程序博客网 时间:2024/05/19 23:54
原文地址:http://www.cnblogs.com/chen1987lei/archive/2010/03/10/1682796.html
Three20是一个编译的静态类库,在Xcode中的项目实用此类库也非常方便,以下是一些基础步骤:
1,从Three20 Git上获 取 最新文 件 ,在终端命 令 输入:git clone git://github.com/joehewitt/three20.git,必须确保此项目文件必须有一个固定的存放路 径 ,因为你的项目如果实用此类库,在XCode中需要引用此项目(说明:Git是一种版本控制器,也就类似于源代 码 管理的东西了,如果还没安装,请到下面网址下 载 :http://git-scm.com/download ,并进行安装)
2,经过一些时间下载数据后打开“Three20.xcode proj”, 一般项目想在的默认路径会在”/computerName/Document/three20″中的”src”文件夹中。 把”Three20.xcodeproj”拖入到你的项目中的”Groups and Files”中的”Framworks”类目中。出现对话框后,取消选择”Copy item”,在“Reference Type”的选项中选中” Relative To Project” ,然后点击”Add”
3,现在你需要在你的项目中关联Three20的静态类库。点击刚才添 加的”Three20.xcodeproj”,在右侧”Details”里选中最后一个复选框
4,增加Three20作为 dependency,这样Xcode才能正确编译Three20:打開 Targets并双击你的target,在General标签下的的Direct Dependencies按“+”后选择Three20,最后按下 Add Target
5,在src中找到Three20.bundle并拖入项目,在跳出的对话框中的选中 Create Folder References,取消选择Copy items,Reference Type中选择 Relative to Project
6, 加入 Core QuartzCore.framework
7,加入搜寻路径:
打开Project Settings并切换到Build
在Search Paths分类找到Header Search Paths于你的项目相对 three20/src 的相对路径 (如 “http://www.cnblogs.com/../3rdLibrarys/three20/src”)
在Linker分类下找到 Other Linkder Flags新增“-ObjC”和”-all_load”
8,最后实用时只需加入#import “Three20/Three20.h”就ok了
原文地 址 http://github.com/joehewitt/three20
Three20 is compiled as a static library, and the easiest way to add it to your project is to use Xcode’s “dependent project” facilities. Here is how:Clone the three20 git repository: git clone git://github.com/joehewitt/three20.git. Make sure you store the repository in a permanent place because Xcode will need to reference the files every time you compile your project.Locate the “Three20.xcodeproj” file under “three20/src”. Drag Three20.xcodeproj and drop it onto the root of your Xcode project’s “Groups and Files” sidebar. A dialog will appear — make sure “Copy items” is unchecked and “Reference Type” is “Relative to Project” before clicking “Add”.Now you need to link the Three20 static library to your project. Click the “Three20.xcodeproj” item that has just been added to the sidebar. Under the “Details” table, you will see a single item: libThree20.a. Check the checkbox on the far right of libThree20.a.Now you need to add Three20 as a dependency of your project, so Xcode compiles it whenever you compile your project. Expand the “Targets” section of the sidebar and double-click your application’s target. Under the “General” tab you will see a “Direct Dependencies” section. Click the “+” button, select “Three20″, and click “Add Target”.Now you need to add the bundle of images and strings to your app. Locate “Three20.bundle” under “three20/src” and drag and drop it into your project. A dialog will appear — make sure “Create Folder References” is selected, “Copy items” is unchecked, and “Reference Type” is “Relative to Project” before clicking “Add”.Now you need to add the Core Animation framework to your project. Right click on the “Frameworks” group in your project (or equivalent) and select Add > Existing Frameworks. Then locate QuartzCore.framework and add it to the project.Finally, we need to tell your project where to find the Three20 headers. Open your “Project Settings” and go to the “Build” tab. Look for “Header Search Paths” and double-click it. Add the relative path from your project’s directory to the “three20/src” directory.While you are in Project Settings, go to “Other Linker Flags” under the “Linker” section, and add “-ObjC” and “-all_load” to the list of flags.You’re ready to go. Just #import “Three20/Three20.h” anywhere you want to use Three20 classes in your project.Three20 is compiled as a static library, and the easiest way to add it to your project is to use Xcode’s “dependent project” facilities. Here is how:
Clone the three20 git repository: git clone git://github.com/joehewitt/three20.git. Make sure you store the repository in a permanent place because Xcode will need to reference the files every time you compile your project.
Locate the “Three20.xcodeproj” file under “three20/src”. Drag Three20.xcodeproj and drop it onto the root of your Xcode project’s “Groups and Files” sidebar. A dialog will appear — make sure “Copy items” is unchecked and “Reference Type” is “Relative to Project” before clicking “Add”.
Now you need to link the Three20 static library to your project. Click the “Three20.xcodeproj” item that has just been added to the sidebar. Under the “Details” table, you will see a single item: libThree20.a. Check the checkbox on the far right of libThree20.a.
Now you need to add Three20 as a dependency of your project, so Xcode compiles it whenever you compile your project. Expand the “Targets” section of the sidebar and double-click your application’s target. Under the “General” tab you will see a “Direct Dependencies” section. Click the “+” button, select “Three20″, and click “Add Target”.
Now you need to add the bundle of images and strings to your app. Locate “Three20.bundle” under “three20/src” and drag and drop it into your project. A dialog will appear — make sure “Create Folder References” is selected, “Copy items” is unchecked, and “Reference Type” is “Relative to Project” before clicking “Add”.
Now you need to add the Core Animation framework to your project. Right click on the “Frameworks” group in your project (or equivalent) and select Add > Existing Frameworks. Then locate QuartzCore.framework and add it to the project.
Finally, we need to tell your project where to find the Three20 headers. Open your “Project Settings” and go to the “Build” tab. Look for “Header Search Paths” and double-click it. Add the relative path from your project’s directory to the “three20/src” directory.
While you are in Project Settings, go to “Other Linker Flags” under the “Linker” section, and add “-ObjC” and “-all_load” to the list of flags.
You’re ready to go. Just #import “Three20/Three20.h” anywhere you want to use Three20 classes in your project.
- iphone 下Three20库(From Facebook)的设置使用方法
- iphone 下Three20库(From Facebook)的设置使用方法
- Three20库的使用方法
- iPhone开发--运行Three20的示例程序
- iphone three20 保存本地的图片
- iphone——Three20库代码初探
- [Three20] Three20的擴充模組
- [Three20] Three20的擴充模組
- [Three20] Three20 模組架構簡介(下)
- [Three20] Three20 模組架構簡介(下)
- iphone 委托的使用方法。
- Three20学习之使用TTableViewController实现简单的设置界面
- iphone调用facebook相应的api
- 关于Three20框架下的本地化不能使用的问题
- [Three20]iPhone知名第三方框架Three20簡介
- three20运行在ios6 SDK下相关问题的解决
- 3、Facebook图谱API的使用方法整理
- iPhone 中数据库的使用方法
- Three20中TTNavigator用法总结
- javascript深入了解(继承)
- Java 小结-线程
- 程序的本质在于逻辑
- vim 编辑器基本用法
- iphone 下Three20库(From Facebook)的设置使用方法
- 生产制作工艺详解(工程师必备)
- C++的类型转换符:static_cast、dynamic_cast、reinterpret_cast和const_cast
- Three20 模组架构简介
- 导入Android2.2包到工程里
- Ext-3.4 使用
- Struts2释疑之一(web.xml中/*与/dwr/*冲突解决)
- 第十周实验指导--任务3--先建立一个Point(点)类,再派生出一个Circle(圆)类,再派生出一个Cylinder(圆柱体)类
- 最近更新的资源(其实是很早以前写的东西了)