xcode 设置快捷键 整行上下移动
生活随笔
收集整理的這篇文章主要介紹了
xcode 设置快捷键 整行上下移动
小編覺得挺不錯的,現在分享給大家,幫大家做個參考.
2019獨角獸企業重金招聘Python工程師標準>>>
設置整行代碼上下移動:
找到Xcode中的自帶的配置文件:
/Applications/Xcode.app/Contents/Frameworks/IDEKit.framework/Versions/A/
Resources/IDETextKeyBindingSet.plist
用文本編輯IDETextKeyBindingSet.plist,并添加以下代碼:
?
1 <dict> 2 <key>GDI Duplicate Current Line</key> 3 <string>selectLine:, copy:, moveToEndOfLine:,insertNewline:, paste:, deleteBackward:</string> 4 <key>GDI Delete Current Line</key> 5 <string>moveToEndOfLine:, deleteToBeginningOfLine:,deleteBackward:,moveDown:,moveToEndOfLine:</string> 6 <key>GDI Move Current Line Up</key> 7 <string>selectLine:, cut:, moveUp:, moveToBeginningOfLine:, insertNewLine:, paste:, moveBackward:</string> 8 <key>GDI Move Current Line Down</key> 9 <string>selectLine:, cut:, moveDown:, moveToBeginningOfLine:, insertNewLine:, paste:, moveBackward:</string> 10 <key>GDI Insert Line Above</key> 11 <string>moveUp:, moveToEndOfLine:, insertNewline:</string> 12 <key>GDI Insert Line Below</key> 13 <string>moveToEndOfLine:, insertNewline:</string> 14 </dict>這個dict是一組可以設置快捷鍵的操作,里面的key是名稱,對應的string是對應的一組操作
GDI Duplicate Current Line?? ?復制當前行到下面一行
GDI Delete Current Line 刪除當前行
GDI Move Current Line Up 把當前行往上移動一行
GDI Move Current Line Down 把當前行往下移動一行
GDI Insert Line Above 在當前行上面增加一空行
GDI Insert Line Below 在當前行下面增加一空行(不管光標是否在行尾)
3. 重啟Xcode,在Xcode菜單中,打開Preferences,選中Key Binding,在右上方搜索GDI:
轉載于:https://my.oschina.net/u/2363463/blog/635917
總結
以上是生活随笔為你收集整理的xcode 设置快捷键 整行上下移动的全部內容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: Chrome插件 - 突破百度网盘下载限
- 下一篇: win10无线投屏花屏