Đang chuẩn bị liên kết để tải về tài liệu:
Lập trình Wrox Professional Xcode 3 cho Mac OS part 31
Đang chuẩn bị nút TẢI XUỐNG, xin hãy chờ
Tải xuống
Giao diện Builder cung cấp một "đầu pad" mặc định người dùng fi le cho mỗi tài liệu ngòi mô phỏng. Điều này đặt tạm thời ưu đãi có thể được thiết lập để được định kỳ, hoặc bằng tay, bị tẩy xóa từ tab Simulator của Builder sở thích giao diện. Tẩy xoá các ưu đãi xóa tất cả các giá trị mặc định người sử dụng, như ứng dụng đã được chạy lần rst fi. | 236 CHAPTER 13 INTERFACE BUILDER Interface Builder provides a scratch pad user defaults file for each simulated nib document. This transient set of preferences can be set to be periodically or manually erased from the Simulator tab of the Interface Builder preferences. Erasing the preferences clears all user default values as though the application was being run for the first time. Building Your Project from Interface Builder If you look at the workflow diagram in Figure 13-2 you ll see that it s very typical to write code make connections in Interface Builder switch back to Xcode and then build and test your application. Interface Builder provides a shortcut the File Build and Go in Xcode Shift Command R command switches back to Xcode builds your project and launches it. INTERFACE BUILDER S INTERFACE This section starts with a brief tour of Interface Builder s interface. One reason it will be brief and also one of the reasons Interface Builder is so easy to use is that there are basically only three interface elements the nib document window the inspector palette and the library palette. All three are shown in Figures 13-4 and 13-5. FIGURE 13-4 Download at getcoolebook.com Interface Builder s Interface 237 FIGURE 13-5 Figure 13-4 shows a Cocoa nib document and Figure 13-5 shows a Cocoa Touch iPhone iPod nib document. When you open a nib document the contents of the file are represented abstractly in the nib document window as shown in the lower left of Figures 13-4 and 13-5. Nib documents contain objects and those objects are shown here either as icons hierarchically or in a browser. You select which view you want to see in the toolbar. Figure 13-6 shows the contents of a nib document in all three views. The icon view only shows the top-level objects. You will also find a few special objects listed these are described later in the section Placeholder Objects. FIGURE 13-6 The two important palettes are the inspector palette and the library palette both described .