This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 67463 - Need way to control overall color of IDE
Summary: Need way to control overall color of IDE
Status: NEW
Alias: None
Product: platform
Classification: Unclassified
Component: Window System (show other bugs)
Version: 5.x
Hardware: All All
: P3 blocker (vote)
Assignee: issues@platform
Depends on:
Reported: 2005-10-24 22:37 UTC by ivan
Modified: 2013-11-08 18:38 UTC (History)
1 user (show)

See Also:
Exception Reporter:


Note You need to log in before you can comment on or make changes to this bug.
Description ivan 2005-10-24 22:37:58 UTC
> Date: Thu, 20 Oct 2005 11:25:45 -0400
> From: Thomas Wolf <>
> To:
> Subject: [nbui] Can we add an option to set overall colors in NB 5?
> ...
> Will this change?  More importantly to me, how do I change those window
> background colors?  Do I still have to delve into some arcane
> configuration file?
> Am I the only one who can't stand white? :-)

No you're not.

After using newer aqua L&F for a while I get eye-strain. 

My C++ compiler engineer friend Lawrence next-door is even more
sensitive so he had trouble with even the metal L&F. That's
one of his must-fixes before he even tries an NB-based IDE.

While I could sympathise with Lawrence I hadn't "felt" the strain
myself. What set me over the edge interestingly enough wasn't the
Backgrounds since in metal L&F backgrounds are also white, but the edges
becoming so bright. Now _everything_ is bright. because of this border
effect I'm curious to know whether being able to turn down the BG's
will help or just cause othe rproblems ... I remembere reading an article
on the early IBM PC monitor where they were proud of how the monitor
graded from dark sreen to lighter plastic shell to lightest outer plastic
shell to provide visual transition from supposedly brighter surroundings to
the darker inner screen.

I know of a computer guy who is albino. The lack of pigmentation
extends into the eye so their eye, instead of being optically black
like cameras and telescopes is white. This is one way their
vision gets affected. Dimming things helps.

I raised this on nbui a while a go with the mind to verify my "theory"
that this whitening happens because of the shift to laptops
and more work being done in high-ambient-light environments.
In general if your surroundings are brighter your iris contracts and
then the ultra-bright IDE shouldn't cause as much eye-strain. 

But I'd still rather have controls on the IDE than to have to come out
of my "cave".
Comment 1 _ tboudreau 2005-11-14 02:36:14 UTC
There are some existing ways you can do this:  Theme support (though barely supported these days 
since it's only really applicable to Metal L&F) can do this for Metal L&F.  

The bottom line is this is going to be plain impossible on some look and feels.  For L&Fs that rely on 
colors stored in UIManager.getDefault(), NetBeans code can change them - this is what theme support 
does - and one of the reasons it's no longer really supported is that it can only really work on Metal 

Synth based look and feels (GTK & I believe Mustang's Windows L&F) use JNI + native painting to paint 
widgets - the IDE doesn't have much chance of helping here - the code doing the painting is not Java.  
As a case in point, we cannot support --fontsize either on GTK L&F (and presumably the newer 
Windows L&F) - because we cannot control the fonts.

There are plenty of options nonetheless, just not ones that NetBeans can affect, for the most part:
 - Run Metal L&F and use an XML theme file - it should still work
 - Run Windows or GTK L&F and set the OS-wide theme to something you like - anywhere NetBeans 
ignores this is a bug (though not necessarily a fixable bug - there will be cases of clashes, as custom 
widgets do not, of course, use native painting - a general problem of Synth based look and feels is that 
they make no provision whatsoever for how to handle custom widgets - the Swing team *has* made 
some basic UIManager key/value pairs like UIManager.getColor("control") try to do something 
reasonable where that information is available - but it is not guaranteed to be available in the case of 
native painting, and all controls have to try to do something reasonable in the absence of such 
information).  Generally all custom NB widgets take their values from UIManager.getColor() with 
fallbacks for null, so if enough basic information is available, they should usually do something 
 - Run with one of the other L&Fs out there with a dark theme - looks 
promising and has some dark themes, and there is a project to even do UI delegates for NetBeans 
custom controls

Sorry if that's not the answer you're looking for, but the sands are shifting as to how, and whether, 
Swing applications have any control over their appearance - and generally in the direction of less 

Alas, I suspect this issue will have to be closed as wontfix - there simply isn't anything you can do to 
solve this problem on a growing number of platforms.
Comment 2 ivan 2005-11-14 19:55:39 UTC
Perhaps this is unfixable but ...

- What happens under KDE?

- Considering that the question is a FAQ I'd like to see a proper section
  in the documentation or somewhere dedicated to this.

- An update to the Theme control. Last time I tried it it wasn't working.
  Could you please spiff it up, verify it and repost in this IZ where
  one can get the spec for themes?

- Is there an analogous FAQ (with a comprehensive answer) on the java web

- I'm not buying the "wherever the tide Swings" argument anymore.
  As the main thick-client platform for Java (am I exaggerating here?)
  NB is the front of the user experience. If you get enough feedback 
  regarding this issue, isn't it NB's obligation to work with Swing 
  and stem the tide?
Comment 3 Peter Pis 2007-08-31 12:00:10 UTC
Reassigining to "core".
Comment 4 David Simonek 2008-10-22 10:33:44 UTC
I came across similar enhancement which talked about overall background color and overall font, can't find the number
now, but it was many many years old.

Implementation would be tricky and not working on all L&Fs, but we may try following:

- have an option in Options/Misc/Appearance which will try to set proper color key in UIManager and trigger repaint.
- it would be implementable only for some L&Fs such as Metal, Nimbus (!*NOT* Nimbus GTK theme!), Windows.
- AFAIK it is not implementable for GTK L&F (default on Linux with gnome, Solaris) and for Aqua L&F (Mac)

For L&Fs which we can't support, color option should be disabled with tooltip which explains that colors are completely
driven by OS

Comment 5 markiewb 2013-11-08 18:38:14 UTC
Dup of ?