Xcode 4.2中是否有命令在助手编辑器模式下从左到右交换两个视图,反之亦然? [英] Is there a command in Xcode 4.2 to swap two views in Assistant Editor mode from left to right and vice versa?

查看:67
本文介绍了Xcode 4.2中是否有命令在助手编辑器模式下从左到右交换两个视图,反之亦然?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想从一侧快速交换两个视图,并想知道是否有此功能的热键吗?

I would like to quickly swap two views from one side to the other and wonder if there is a hotkey for this functionality?

推荐答案

单个助理编辑器

这可以分两个步骤完成.您可以从主"编辑器或助理"编辑器中的光标开始.

Single Assistant Editor

This can be done in two steps. You can start with the cursor in either the Primary or the Assistant editor.

-在助手/主编辑器中打开

如果您在Assistant Editor中,它将在Primary Editor中打开当前文件(光标所在的位置),反之亦然.最后,您打开了两个完全相同的文件.

It opens the current file (where the cursor is) in Primary Editor if you are in Assistant Editor and vice versa. You end up with two exact same files open.

^ `-将焦点移至下一个编辑器(自Xcode 8开始可用,在较早版本中使用 J )

^` - Move Focus to Next Editor (available since Xcode 8, in older version use J)

^ -返回(并打开结果)在主/助理编辑器中

^ - Go Back (and open the result) in Primary / Assistant Editor

这将在第一个编辑器中打开另一个编辑器的上一个文件.

This opens the previous file of the other editor in the first one.

想法:甚至可以使用

Idea: It might be even possible to assign a custom shortcut to it using the technique used in Xcode duplicate line. I have not gone so far.

如果使用多个助手编辑器,则可以使用图形导航选择器选择每个动作的目的地.您可以从任何编辑器开始,甚至可以用这种方式交换两个助理编辑器的内容.

If you are using multiple assistant editors, you can use graphical navigation chooser to choose the destination of each action. You can start in any editor and you can even swap the content of two assistant editors this way.

-在...中打开,然后选择第二位编辑器
J -将焦点移至编辑器... 并选择第二个编辑器(或使用 ^ `多次)
^ -返回... 并选择第一个编辑器

, - Open in... and choose the second editor
J - Move Focus to Editor... and choose the second editor (or use ^` multiple times)
^ - Go Back in... and choose the first editor

这篇关于Xcode 4.2中是否有命令在助手编辑器模式下从左到右交换两个视图,反之亦然?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆