Eclipse PDT 区分 MVC 的文件名选项卡?
在 Eclipse 中使用 MVC 时,您可能经常会同时打开同名的模型、视图和控制器。查看每个文件选项卡时,您并不总是知道哪个是哪个,并且必须单击它们,有时这可能会很麻烦。我听说某些编辑器中可以根据路径对文件进行颜色编码。例如,具有路径模型的选项卡可以设置为绿色,路径控制器设置为黄色等。这在 Eclipse 中可能吗?或者是否有类似的插件?如果不是,您如何才能更轻松地区分选项卡?我听说人们总是按特定顺序打开 MVC 集。因此,您会知道最左边的选项卡是控制器,最右边的选项卡是视图等。但是,这也意味着您每次都需要打开所有 3 个文件。还有更好的提示或技巧吗?
关于文件选项卡的另一件令人烦恼的事情是,当您有更多文件无法容纳在一行中时,Eclipse 会弹出一个箭头,您必须单击该箭头才能查看其余文件。哪些选项卡被推掉似乎是随机的,也许是最少使用的选项卡,我不知道......这再加上上面的问题有点烦人。我试图找到一种方法来禁用此功能,只显示无法在一行中显示的选项卡以显示在第二行上,但令人惊讶的是找不到这样的选项(话又说回来,如果没有插件)。
希望针对这两个问题有一些解决方案。谢谢。
When working with MVC in Eclipse you might often have a model, view, and controller all with the same name open at the same time. When looking at each of the file tabs, you won't always know which is which and have to click through them, which can be quite a hassle sometimes. I've heard of being able to color code files based on the path in some editors. For example, tabs with path model could be set as green, path controller set as yellow, etc. Is this possible in Eclipse, or is there a plugin for something like this? If not, what do you do to more easily differentiate between the tabs? I've heard of people always opening a MVC set in a certain order. So you'll know the leftmost tab is the controller, the right most is the view, etc. However, that must also mean you need to open all 3 files each time. Any better tips or tricks?
Another thing about the file tabs that can be annoying is that when you have more files that can't fit in one line, eclipse pushes off to an arrow which you have to click to see the rest. It seems to be random which tabs get pushed off there, maybe the least used ones, I have no idea... This coupled with the problem above gets kind of annoying. I was trying to find a way to disable this and just show tabs that can't fit in one line to show up on a second line, but surprisingly couldn't find such an option (then again you also can't wordwrap without a plugin).
Hopefully there are some solutions to these two problems. Thanks.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
也许这会有所帮助
http://www .dipherence.com/2011/03/20/full-coloured-eclipse-navigator-plug-in/
Maybe this can be helpful
http://www.dipherence.com/2011/03/20/full-coloured-eclipse-navigator-plug-in/
使用最新版本的 Eclipse(Kepler 4.3.1,内部版本 M20130911-1000),当打开两个或多个具有相同基本名称的文件时,选项卡还将显示父目录名称。
With the latest version of Eclipse (Kepler 4.3.1, build M20130911-1000) when two or more files with the same base name are opened, tab will show also the parent directory name.