Nullptr
Nullptr

Reputation: 3183

Eclipse Juno: How to change background of code folding regions

enter image description here

I'm currently using Eclipse Juno (the latest version as of Aug 30, 2012). I switched to a dark theme using Eclipse Color Theme plugin.

I modified some background colors to match this dark theme. However, I can never find an option to change the back ground of the code folding regions (the space between line numbers and the code).

Please help me to change this background color!

Upvotes: 5

Views: 3622

Answers (2)

Dustin Biser
Dustin Biser

Reputation: 372

I was able to solve this problem using Eclipse-Juno on Ubuntu with the Dark Juno theme installed by doing the following:

  • Click on Window->Preferences to open up your Preferences panel
  • Open up the tab for the language you are using. For me this was C/C++
  • Goto Folding, and then uncheck "Enable folding when opening a new editor".
  • Click Apply and OK.

enter image description here

Now go back to your editor, and close and reopen any editors that you may have open (restarting Eclipse should also work). The default code folding will be gone, along with the white background.

You can re-enable code folding at any time (with a black background) by typing CTRL + NUMPAD_DIVIDE.

enter image description here

Upvotes: 8

JHD
JHD

Reputation: 11

To fix this open the following file in a text editor:

org.eclipse.ui.editors.prefs

Once open look for the following line:

printMarginColor=101,101,101 

The numbers represent the current color of the margin in RGB format. Simply change the color to your desired color, save and close the editor. Save and close any editor tabbed windows in Eclipse and re-open them .

If you are in Linux the org.eclipse.ui.editors.prefs file will be located in the following location:

~/[your workspace folder]/.metadata/.plugins/org.eclipse.core.runtime/.settings

Upvotes: 0

Related Questions