original link: http://blog.csdn.net/phunxm/article/details/17044337
1. Themes and Fonts
"Command+," call out preferences (preferences), select "Fonts & Colors", select a topic (theme), such as "Midnight", and then shift selects all items in the source editor/console. Click Fonts to set the font. Xcode default font is Menlo, optional other equal-width font consolas/monaco.
2.View and Navigate
View Navigator
Command+0:show/hide left tool panel
Command+1-8:project/symbol/find/issue/test/debug/breakpoint/log Navigator
Option+command+0:show/hide Right Tool panel
Option+command+1:show The file Inspector
Option+command+2:show Quick Help Inspector
View Editor Organization
Control+1:show Related Items (for example, Callers/callees, includes/included by). You can enter a real-time search match.
Control+2/3:show Previous/next History. You can enter a real-time search match. Control+4:show Top Level Items
Control+5:show Group files (all files in the current folder). You can enter a real-time search match.
Control+6:show document Items (symbols of the current file). You can enter a real-time search match.
You can select the symbol directly, and then "navigate->reveal in symbol Navigator" to open a list of symbols for that interface.
COMMAND+J: Focus switch (move focused), with mouse and arrow keys. The ' + ' move focus to a new assistant editor can quickly open the opening file (*.h)/implementation file (*.M,*.MM) in the Secondary editing window.
Shift+command+j: Locates the current file in the Project Navigator (Reveal in Project Navigator).
3. Basic Operation
Command+[/]: Indent forward/Backward
command+/: Note the selected code
command+shift+[/]: Toggle tab page
Single pointing left and right sliding (control+command+←/→): Switching between multiple files opened on a single label page
option+command+←/→: Collapses the current code block
option+shift+command+←/→: Collapses all code blocks within the file (method/function)
Option+command+[/]:move Line Up/down
Shift+command+y: Display Console (show/hide the debug area)
Option+command+r: Edit configuration (Edit Scheme)
bracket Matching : Double-click a delimiter (such as {}, (), [], and so on), and Xcode will select the matching code block.
Focus column : The gray depth is related to the code nesting depth, the mouse hover can highlight the corresponding code block on the right, and the mouse clicks to collapse the corresponding code block on the right side (code folding).
description : From left to right, followed by the Navigation Pane (Navigator)-> Edge column (gutter)-> Focus Ribbon Code editing window (Standard Editor) ".
4. Symbol Positioning Jump
Control+command+↑/↓: Toggle Header/Implementation files (switch between a source file (. m,*.mm,*.cc) and the associated header (. h) file).
Shift+command+o:open Quickly, you can quickly find "file", symbol.
Shift+command+f (command+3): Global lookup.
command+ Click the symbol selected in Editor: Jump to the symbol definition (jump to definition).
Control+command+j: Jumps to the definition or implementation of the specified symbol (go to declaration/definition).
Right-click or menu file->show in Finder: Locate the file in the Finder
5. Auxiliary editing window (Assistant Editor)
Assistant Editor is somewhat similar to the code Definition Window in VC.
Option+command+enter: open Assistant Editor.
Command+enter: close Assistant Editor.
When you use shortcut keys to toggle or jump actions, you can open the appropriate file or symbol (for optional navigation (Option-clickingor option-choosing a file) in the Secondary editing window if you press Option at the same time. Opens the file in a new Assistant Editor pane.). If you are working in a secondary window, open it in the main window (Standard Editor).
option+ Click the file selected in Project Navigator: Open the selected file in the Secondary editing window.
option+command+ Click the symbol selected in editor: Open the symbol definition in the secondary edit window (jump to definition in Assistant editor).
Option+control+command+↑/↓: Opens the corresponding header file (*.h)/implementation file (*.m,*.mm,*.cc) in the secondary window.
When you click to view the selected file or symbol for Shift+command+o, shift+command+f (command+3), you can open it in the secondary editing window by pressing option at the same time.
When you open a selection result in control+1~6, you can open the option in Assistant editor at the same time.
If you press SHIFT while pressing the option, a Navigation Pane appears, which you can choose to open in the new window/tab/assistant-editor display.
For option-shift navigation (option-shift-click or option-shift-choose a file), Xcode displays a graphical Naviga tion Chooser showing the current layout. The chooser prompts you to open the ' file in any ' Open Editor pane in ' Any Windows and tab, or to open the ' file in ' a new Edito R pane, window, or tab.
6. The code completes the function automatically
ESC calls out / hides the Auto completion prompt on the current input context; the UP and DOWN ARROW keys select options in the prompt, enter (return) to Select , tab to one cut to match ; tab can move between individual placeholders .
Enter Objective-c object and ], automatically completes infix character (infix natation) surround.
7. Help documentation (documentation and API References helps)
option+ Click: View the Help prompt for the selected symbol (Quick helps for Selected Item).
option+ double-click to open the Help document for the selected symbol.
8. Environment variable (build Setting Macros)
(1) View environment variable macros
The command line enters the HelloWorld engineering directory, executes the Xcodebuild command, and takes the "-showbuildsettings" parameter:
Imac-faner:helloworld faner$ xcodebuild-project helloworld.xcodeproj-target helloworld-configuration Debug- Showbuildsettings > Xcodebuild_showbuildsettings.txt
The build settings for action build and target "HelloWorld" are saved in Xcodebuild_showbuildsettings.txt: All of the environment variables are dump.
(2) Partial environment variables of XCODE5 (macosx10.9)
Convention 1:~= The home directory of the current account, such as "/users/faner".
Contract 2:build Build Base path:build_path = ~/library/developer/xcode/deriveddata/build. You can view the Derived Data Locationthrough the File->project Settings.
Contract 3: Environment variable macro (build Setting Macros) reference format: ${macro}, syntax in the same build phases Run script.
The following are some of the commonly used environment variables selected from Xcodebuild_showbuildsettings.txt.
(a) ARCH & PLATFORM & SDK
Archs = i386
Current_arch = i386
Platform_dir =/applications/xcode.app/contents/developer/platforms/macosx.platform
Platform_name = MacOSX
Sdkroot =/applications/xcode.app/contents/developer/platforms/macosx.platform/developer/sdks/macosx10.9.sdk
Sdk_dir =/applications/xcode.app/contents/developer/platforms/macosx.platform/developer/sdks/macosx10.9.sdk
Sdk_name = macosx10.9
(b) PROJECT & SOURCE
PROJECT = HelloWorld
project_dir =~/projects/learn Objective-c/helloworld
Project_file_path =${project_dir}/helloworld.xcodeproj
Project_Name = HelloWorld
Source_root =${project_dir}
Srcroot =${project_dir}
(c) Build & CONFIGURATION
Build_dir =build_path/products
Build_root =build_path/products
Built_products_dir =build_path/products/debug
CONFIGURATION = Debug
Configuration_build_dir =build_path/products/debug
Configuration_temp_dir =build_path/intermediates/helloworld.build/debug
(d) PRODUCT & TARGET
Product_Name = HelloWorld
Product_type = com.apple.product-type.tool//Project Template:command line tool
Target_build_dir =build_path/products/debug
<