Eclipse 多文本选择,如 Sublime Text 2

标签 eclipse

eclipse 是否有一个选项或插件可以在同一编辑器中同时进行多个选择。

在 Sublime Text 中,选择一些文本,然后按 Ctrl+d 会将相同文本的下一个实例添加到选择中(如果可能)。选择所需的实例后,编辑器有多个插入符号(不一定位于相同或相邻的列和行上)。在此模式下,可以同时向前或向后移动所有光标,并同时编辑所有文本实例。

我发现这个功能非常有用,并且在 Eclipse 中非常怀念它..

最佳答案

此 Eclipse 插件尝试提供此功能:https://github.com/caspark/eclipse-multicursor 。来自自述文件:

What is this?

A work-in-progress attempt to provide Sublime-Text-like multi cursor support for text editors in the Eclipse IDE.

What works?

  • Multiple identical lines can be edited simultaneously using Eclipse linked mode editing (similar to existing "rename in file" functionality)

Next steps

  • "select next" functionality + associated editing using Eclipse linked mode

  • "find next" + associated editing

  • editing of non-identical text / editing without using linked mode

  • split selection to lines

  • regexp support for find next

关于Eclipse 多文本选择,如 Sublime Text 2,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/12583201/

相关文章:

Android 设备不断与 adb/eclipse 断开连接

XML(非 C++)文件中的 Eclipse CDT 拼写检查

eclipse indigo 无法创建新服务器 jboss 5.1

eclipse - 我在 eclipse 中看到的唯一错误是:could not find or load main class. It compiles or gives this, nothing else. How can i see errors on console again?

eclipse - Eclipse 中的 "Open with..."无需切换默认编辑器

java - Eclipse for PHP 和 Eclipse 或 Java 互相搞乱了?

java - "Class header expected instead"错误

java - Maven 编译 UTF-8 和属性文件

java - Eclipse 项目和 SQLite Manager 之间的 SQLite-DB 不一致

java - Eclipse 格式化程序 : Wrap Nested ArrayList Declarations