同样的问题has been asked for Xcode 3 但据说解决方案不适用于Xcode4。并没有新的解决方案。
如何获取键绑定以在Xcode 4中向上/向下移动约10行?
答案 0 :(得分:15)
尤里卡!灵感来自answer on line duplication,这就是你如何通过多线移动赋予Xcode 4权力:
/Applications/Xcode.app/Contents/Frameworks/IDEKit.framework/Versions/A/Resources
IDETextKeyBindingSet.plist
。Customized
和两个新命令(例如,Move Down 10
和Move Up 10
)键,如下面的屏幕截图所示:
为两个命令设置组合键:
最后摆脱Jump To
快捷方式的束缚。享受吧!
使用以下步骤将光标释放到Xcode外:
~/Library/KeyBindings
DefaultKeyBinding.dict
。{
“^ ~n”=(“moveUp:”,“moveUp:”,“moveUp:”,“moveUp:”,“moveUp:”,“moveUp:”,“moveUp:”,“moveUp:”, “moveUp:”,“moveUp:”);
“^ ~p”=(“moveDown:”,“moveDown:”,“moveDown:”,“moveDown:”,“moveDown:”,“moveDown:”,“moveDown:”,“moveDown:”,“moveDown: “,”moveDown:“);}
上述所有内容均适用于10.8.2与Xcode 4.5.1。
答案 1 :(得分:2)
看起来不可能。 回答我自己能够关闭。
答案 2 :(得分:1)
补充courteous answer,我又添加了两个命令:
Move Up 10 Extending Selection
,其值为moveUpAndModifySelection:, moveUpAndModifySelection:, moveUpAndModifySelection:, moveUpAndModifySelection:, moveUpAndModifySelection:, moveUpAndModifySelection:, moveUpAndModifySelection:, moveUpAndModifySelection:, moveUpAndModifySelection:, moveUpAndModifySelection:
和Move Down 10 Extending Selection
,其值为moveDownAndModifySelection:, moveDownAndModifySelection:, moveDownAndModifySelection:, moveDownAndModifySelection:, moveDownAndModifySelection:, moveDownAndModifySelection:, moveDownAndModifySelection:, moveDownAndModifySelection:, moveDownAndModifySelection:, moveDownAndModifySelection:
然后在XCode中分配了快捷方式: