Changing UI color in Eclipse - eclipse

I'm aware of color themes for Eclipse: I've used it to change most of the editor colors, and that's great.
But that wasn't enough, there's still too much white. How to change it? (It hurts my eyes.)
I've searched in the preferences (both using Eclipse itself and editing the files) for instances of white (255,255,255) and changed them all. Looks like I'm missing something.

Each time you see white or gray color, this is more than likely related to OS system colors.
In other word, to truly have an Eclipse full dark theme, you need first to have a dark theme for your OS, and then your Eclipse will follow.
Here is an example on a Windows7, modifying just one parameter:
alt text http://img92.imageshack.us/img92/5053/eclipsered.png

Probably not the answer you're looking for, but the IntelliJ community edition is an excellent free IDE and is very easy to use. The background colours can be set and changed to many colours. There are also a number of free plugins which can customize backgrounds and the look and feel. Well worth a look if you don't find exactly what you're looking for with Eclipse.

I see you're on the Mac - the easiest thing to do would go to System Preferences -> Accessibility -> Seeing -> Display -> "White on Black". It will invert everything on your screen though, I don't know, if you'd like that?

YES, THERE IS A WAY TO DO IT
You will need to configure 3 things in order to get your dark UI.
1) Java Editor Colors
This is the source code edition area. You can use http://eclipsecolorthemes.org/ for the editor part, though those colors can be manually edited by default.
2) Eclipse UI
The UI colors can be edited with the addin Chrome Theme which can be found in the eclipse market place or in the following link https://github.com/jeeeyul/eclipse-themes/. If you want a dark theme just edit away until you find the colors that suit you.
3) Final touches
After doing the previous steps, some colors will still match the OS colors. To darken what's left, just get the pre-baked Dark Juno theme from https://github.com/eclipse-color-theme/eclipse-ui-themes. Download the zip file and unzip it into your dropins folder (which is located in your eclipse folder). If the dropins folder doesn't exist, just create it.
Restart eclipse and you are set.

You can try these steps:
Find the path: ~/.p2/pool/plugins/org.eclipse.ui.themes_*.*.****.v********-****/css/e4_basestyle.css;
Use a text editor (example: Sublime Text 3) to open e4_basestyle.css if you used default theme config;
Append this code and save
#org-eclipse-jdt-ui-PackageExplorer Tree,
#org-eclipse-ui-navigator-ProjectExplorer Tree {
font-size: 10px;
font-family: "DejaVu Sans Mono for Powerline";
background-color: RGB(223,238,223);
},
#org-eclipse-ui-views-ContentOutline Tree,
#PerspectiveSwitcher ToolBar {
font-size: 10px;
font-family: "DejaVu Sans Mono for Powerline";
background-color: RGB(223,238,223);
}
Restart Eclipse. It is like this: result

Related

Eclipse 2019 black background

After install of 2019-12 version of Eclipse I can't set black background while using Dark theme and Default set of colors.
If I change color in General -> Editors -> Text Editors -> Appearance color options -> Background color - I see line numbers background color get changed to my choice, while text area remain in same dark grey, regardless of the color I choose.
I tried to manually edit epf preferences and import them back, but even this way doesn't work.
Is there a some change/bug in Eclipse 2019-12 which override the user chose?
There are some already answered questions about Eclipse colors, but I believe they are not helpful after recent changes.
For those who come here by googling, you can change the color of Java editor, Package Explorer and Outline views background in one place, see file
<..>.p2\pool\plugins\org.eclipse.ui.themes_<version>\css\dark\e4-dark_partstyle.css
and then edit background-color
.MPart DependenciesComposite > SashForm > Section > * { /* Section > DependenciesComposite$... */
background-color: #151515;
color: #AAAAAA;
}
I found #151515 better than default one.
There seems to be a recent Eclipse bug with possibly a duplicate.
There is a possibly duplicate question here which has at least one additional suggested workaround besides the other answer to this question.

Eclipse Kepler change tree selection color or background CSS

In Eclipse Kepler on Linux Mint, selecting items from a tree-view like the Project window is pretty straightforward:
But on the Searches window, matches and potential matches have no background color when you select them. Hence, they become invisible:
How to I change the color of selected text there? I'm guessing it defaults to a system color, but for most other colors you can override that.
In Eclipse Juno this was not a problem, because the selection background color was, like in the Project Window, the same as the system default:
I think that in Kepler the system default background is not working in the Searches window because they forgot to implement it after manually allowing the contents of the tree view to have a different color from the system color specifically for potential matches:
Unfortunately, they didn't add options to change the definite matches and the selected matches color here, otherwise I would probably have figured this out myself. ;)
edit I figured out how to change the background-color of the entire Tree:
Tree {
background-color: #f00;
color: inherit;
background-image: none;
}
But I cannot change for the life of me the color or background of single items. At all. In the end, I'd like to change the background for the selected item so it becomes readable.
Just trying a bunch of stuff, but not working:
.TreeItem:even,
.TreeItem:linesvisible,
.TreeItem:selected,
.TreeItem:unfocused,
.Tree-RowOverlay,
.Tree-Cell,
.Tree-GridLine,
.Tree-Indent {
background-color: #0f0;
color: #f00;
}
Note - In the Kepler screenshots I use the Jeeeyul's Eclipse Themes plugin to change some of the hideous unbelievably terrible design decisions the Eclipse team made for Kepler, but this is unrelated. The font, the colors and the problem of the selections are the same with or without the plugin.

Change Eclipse window color

I've been using Eclipse for a while now, as we need it in class to work with xml files.
I'm rather a fan of using dark backgrounds, as I find it easyer for the eyes.
I've found this topic on how to change the theme in Eclipse, but this only changes the color scheme in the coding window.
Is there a way to change the entire color scheme for the whole program (sidebars, background color, foreground color, ...) in Eclipse like you have in Visual Studio?
offtopic: I want to do the same in NetBeans
EDIT: finally got it to work, but my color scheme s*cks.
Does anyone have a good scheme I can use or some CSS file I may import?
It would be perfect if it fits with any dark Color Theme (Monokai, NightLion Aptana Theme, Oblivion, Obsidian, Pastel, RecognEyes, Sublime Text 2, Sunburst, Wombat or zenburn). Looking at this list, I notice a lot of themes are dark. Too bad the program itself hasn't got themes (unless the Chrome Theme to change everything ourselves)
If you are using Eclipse 4, you can use the Eclipse 4 Chrome Theme to style everything in the program using CSS (or properties for the most used UI elements).
Many of the colors can be adjusted via Preferences > General > Appearance > Colors and Fonts. For things that are not configurable there, they're controlled by tour operating system color settings.

Eclipse's Package explorer background color follows windows theme. I want to change the color without changing windows' theme. Possible?

Maybe a way to alter the colors locally (as in application dependant)?
A background color of eclipse is white, the same white of windows' active window background color. If I change the color on the theme, eclipse changes to the color.
I want to change this software's color without changing the whole theme (because then every program gets weird colors). Is this possible? I thought that maybe there was a way to apply different windows themes to different programs, or something.
I'm using windows XP, classic windows theme.
Install the "Eclipse 4 Chrome Theme" from
http://marketplace.eclipse.org/content/eclipse-4-chrome-theme
Then you can customize a lot of the Eclipse UI widgets.
But not what you want, at least not out of the box.
For that you should go to the CSS tab (in Eclipse 4 Chrome Theme) and paste this:
Tree, List, Table {
background-color: #202020;
color: #d0d0d0;
}
You can change almost anything, the problem is finding out what, and the fact that some things are bitmaps that you can't change (so if the bitmap is dark and you set a dark background you will "loose" the bitmap)
This list of widgets might help, http://download.eclipse.org/rt/rap/doc/1.5/help/html/reference/theming/index.html but they give you generic info on the widget names, not the Eclipse info (with IDs and all), so be careful :-)
== Very late addition ==
Everything you need in one place, including links to a custom dark theme: http://mihai-nita.net/2013/09/19/dark-eclipse/
Mac Screen Shot Example as of Sept 2013 (please be sure to restart Eclipse after changing file):
Just search "Theme" in the Eclipse Market Place. Install Moonrise. (Should be first option). Then go to the General, appearance, Click on appearance, change theme to moonrise, Then there you go.
Knowing the way the workbench is built, I'm sure your request is not possible on the Eclipse side. You can do this for the editors, because they are StyledText widgets, and you are exposed some preferences to customize these.
The other views are various widgets, some are Trees, some are Text, some are composed from various other widgets. All of them are created with the default constructor which just uses the Windows theme.
I don't know of a way to change every Eclipse window to your color scheme, but I can get you at least as far as changing some of the editing windows...
Open up "Window -> Preferences", then under "General | Editors | Text Editors" you will find a section that will allow you to set the "Appearance color options", Background color is one of those options.
PS: I'm using Eclipse 3.6 (Helios)
Sadly, this is not possible (which is crazy).
However, Aptana Studio (which is an Eclipse derivative) lets you theme the entire IDE.
I did some research and found that actualy it is posible to change all colors, but abit harder.
there are two methods that I found so far.
first since eclipse is using OS themes, you can change your OS background settings, like folder background etc., or just change the whole theme if your using windows, but the downside is that all windowses will be same color, in linux and mac os it is also posible, but in different way, I did read it somewhere, but can't remember where :)
second creating a specific theme for eclipse, for example http://rogerdudler.github.io/eclipse-ui-themes/ or any other theme like google chrome etc.
Install the theme from here as per the instruction in the github:
https:// github.com/guari/eclipse-ui-theme
If you don't like the editor color theme, there are bunch of 'em here
http://eclipsecolorthemes.org/
Combination of both just works like charm for me!

Eclipse syntax colors for HTML files

I'm using eclipse for a few months, I realy like gvim better but eclipse makes my life easier with pydev and phpeclipse. Everything is pretty nice, I have a black fluxbox and black GTK themes, I've changed the syntax colors for py and php and now everything is dark background, light foreground (including the eclipse menu/borders/etc), very nice.
But.. I can't find a way to change the syntax colors for html files. It's really bad, occasionally I will want to open a html file in eclipse and standard text is black (same as my background). I've changed every background-related color setting I could find but the html editor's colors don't change. Am I missing something? Does anyone know how to change this?
You need to install the WTP plugin to add all that HTML/JS/CSS support.
I would also recommend using the PDT plugin for all your PHP needs.
After installing these plugins.. you should be able to access their properties in Window>Preferences...
Hope this helps :)
For others who may not be as familiar with the Preferences for Eclipse you can find most of these color settings (once you have the plugins mentioned here installed) at:
Preferences > Text editors > Appearance color options
and
Preferences > Appearance > Colors and Fonts
Don't forget to use the search features built into the Eclipse preference panes to find the exact element you are trying to modify.