A little tweaking Eclipse Juno: get rid of the huge tabs and buttons closing the tab

In the new Eclipse Juno (version 4.2), a new model of the interface based on the UI plug-ins and CSS-like styles. And if the earlier part of the tuning interface you can do from settings, but now there virgin empty:



So you'll have to dig into CSS skins (that's CSS-like styles are now used in this environment).



That looks like a window when you first start:



What's not to like: great Taba, cross to close the tab, non-configurable font. Also don't like the rounded corners for tabs, but this is beyond this article, so long as we score.

So to fully edit CSS styles, you need to put the plugin, put it with the update-site download.eclipse.org/e4/updates/0.12, and the name of the plugin E4 CSS Editor (located in the E4 tools). Put it at the same time you can put the plugin E4 CSS Spy, it will help to delve into the classes of a running Eclipse to understand which styles what componey to prescribe.

Restart Eclipse after installing the plugin, go to settings and the place is nearly empty page settings interface see basic editor CSS styles:



First change the font in the header tab (in the block .MPartStack 11 change to 8, add the element font-family with the name of your favorite font):

the
.MPartStack {
font-size: 8;
swt-simple: false;
font-family: "PT Sans";
swt-mru-visible: false;
}


Now important: save the document using Ctrl+S and then click Apply or OK! To guarantee you can restart Eclipse to see changes.

Now change the height of the header tabs (I had to change for tabs documents, rest satisfied, therefore, add the ID of the block and to find out the ID through the CSS Spy which is started by the hotkey Shift+Alt+F4):

the
CTabFolder#org-eclipse-e4-primaryDataStack
{
swt-tab-height: 16px;
}


Now remove the close button of the tab, we remove globally (I prefer tabs to close the middle mouse button, and the button takes an undue amount of space on the tab):

the
CTabItem {
swt-show-close: false;
}


And that's what happens in the end:



This approach you can configure a lot of interface, but not all, unfortunately. Ready CSS file is better to keep them in a safe place, when suddenly some updating it will carry.

Detailed and complete documentation on the CSS used in the network, will either have to use CSS Spy, or see the source code of the renderer. But for the initial reading there are several useful links:

the
Article based on information from habrahabr.ru

Comments

Popular posts from this blog

Powershell and Cyrillic in the console (updated)

Active/Passive PostgreSQL Cluster, using Pacemaker, Corosync

Experience with the GPS logger Holux M-241. Working from under Windows, Mac OS X, Linux