如何更改 Eclipse IDE 中所有视图的背景?

2022-01-20 00:00:00 customization ide eclipse

我想为 Eclipse IDE (Aptana) 提供一个黑暗的外观.我更改了代码编辑器的背景颜色和其他颜色.但我不知道如何更改所有视图的背景颜色...在 Window -> Prefenreces -> Appearance -> Colors and Fonts 中,我只能调整几个视图(插件管理器、脚本视图、文件视图),但不是全部.有没有办法做到这一点?我应该编辑哪些配置文件?

解决方案

2012 年 7 月更新(31 个月后):

使用最新的 Eclipse4.2(2012 年 6 月,Juno")版本,您将不再依赖操作系统颜色,并且可以为 IDE 的每个视图(或任何其他元素)精确选择颜色.
请参阅 中提到的,这种设置主要关注

但是对于 eclipse 编辑器的其余部分,这个线程 指出困难:

<块引用>

这实际上是一个相当困难的问题,因为似乎每个插件都有自己的颜色,并且您无法设置会继承到不同插件的默认值.

不,您需要做的是更改每个插件的颜色.我认为这通常是 Eclipse 色彩管理中的问题,而不是 PDT 的问题.

Eclipse 的深色方案? 的答案提到了:

<块引用>

大多数其他视图由操作系统指定的颜色控制.
例如,在 Windows 上,您可以前往高级外观"设置并使用所需颜色更改窗口"项目.
当然,这意味着您的所有应用程序都会在整个操作系统中发生变化,这取决于您的喜好.

I would like to get a dark look for Eclipse IDE (Aptana). I changed background color of code editors and other colors. But i can't figure out, how to change background color of all views ... In Window -> Prefenreces -> Appearance -> Colors and Fonts i can tweak only few views (Plugin Manager, Script view, file view) but not all. Is there a way to do it ? What configuration files should i edit ?

解决方案

Update July 2012 (31 months later):

With the latest Eclipse4.2 (June 2012, "Juno") release, you won't depend on the OS colors anymore and can choose precisely the colors for each view (or any other elements) of your IDE.
See the article by Lars Vogel in "Eclipse 4 is beautiful – Create your own Eclipse 4 theme":

If you want to play with it, you only need to write a plug-in, create a CSS file and use the org.eclipse.e4.ui.css.swt.theme extension point to point to your file.
If you export your plug-in, place it in the "dropins" folder of your Eclipse installation and your styling is available.


Original answer: December 2009

As mentioned in the question Color Themes for Eclipse?, that kind of setting mainly concern the editor:

But for the rest of the eclipse editor, this thread points out the difficulty:

This is actually quite hard problem, because it seems that every plugin has it's own colors and you cannot any way set defaults which would inherit down to different plugins.

No, what you need to do is to change colors in every plugin. I think this is a problem in Eclipse's color management in general and not a PDT's problem.

The SO answer to Dark color scheme for Eclipse? mentions:

Most of the other views are controlled by the colors specified by the operating system.
For example, on Windows you can head to the Advanced Appearance settings and change the Window item with your desired colors.
Of course, this means all your applications change across the entire operating system, which may be good or bad depending on your taste.

相关文章