Netbeans font type is bold, menu font color is grey

Bug #989624 reported by Thanasis Naskos on 2012-04-27
This bug affects 55 people
Affects Status Importance Assigned to Milestone
netbeans (Ubuntu)

Bug Description

>>lsb_release -rd
Description: Ubuntu 12.04 LTS
Release: 12.04

>>apt-cache policy netbeans
  Installed: 7.0.1+dfsg1-4
  Candidate: 7.0.1+dfsg1-4
  Version table:
 *** 7.0.1+dfsg1-4 0
        500 precise/universe amd64 Packages
        100 /var/lib/dpkg/status

What was expected to happen?
Netbeans environment font type shouldn't be bold.
Netbeans menu font color shouldn't be grey.

What happened instead?
Font type is bold.
Menu font color is grey.

More information:
This bug occurred after the Ubuntu 12.04 LTS amd64 clean install.
Previously, I was using Ubuntu 11.04 and netbeans fonts were fine.

I've also checked the newer version of netbeans (v. 7.1.2), installed using a shell script file downloaded from the official site, same issue occurred.
I've tried setting default java, openjdk6 and sun-java7-jdk but nothing changed in both java versions.

An attached image is provided show this issue.

ProblemType: Bug
DistroRelease: Ubuntu 12.04
Package: netbeans 7.0.1+dfsg1-4
ProcVersionSignature: Ubuntu 3.2.0-24.37-generic 3.2.14
Uname: Linux 3.2.0-24-generic x86_64
ApportVersion: 2.0.1-0ubuntu6
Architecture: amd64
Date: Fri Apr 27 13:52:42 2012
InstallationMedia: Ubuntu 12.04 LTS "Precise Pangolin" - Release amd64 (20120425)
PackageArchitecture: all
SourcePackage: netbeans
UpgradeStatus: No upgrade log present (probably fresh install)

Thanasis Naskos (naskoos) wrote :
affects: ubuntu → netbeans (Ubuntu)

I get this reproduced only on Netbeans 7.1.2 (installed from downloaded bin at

I do not get this reproduced in Netbeans 7.0.1 (installed from ubuntu repository)

lsb_release -rd
Description: Ubuntu 12.04 LTS
Release: 12.04

apt-cache policy netbeans
  Installed: 7.0.1+dfsg1-4
  Candidate: 7.0.1+dfsg1-4
  Version table:
 *** 7.0.1+dfsg1-4 0
        500 precise/universe amd64 Packages
        100 /var/lib/dpkg/status

See attached image

Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in netbeans (Ubuntu):
status: New → Confirmed
Daniel Harvey (daniel.harvey) wrote :

Suggested work-around copied from James Powell on a Netbeans forum page ( ).

Hi guys, you may have noticed that a new LTS been released several hours ago.
It has a bug in a default gtk2 theme "Ambiance".
All java applications menus will have a black font on a black background.
Bug already reported on launchpad, but have no idea when it will be fixed, so here is a solution:
sudo vim /usr/share/themes/Ambiance/gtk-2.0/gtkrc

Find a row 338 with contents:
style "menu" {

and make it look like this:
style "menu" = "dark" {

save and your java menus will be fine.

Suggested workaround does not work.

Thanasis Naskos (naskoos) wrote :

#4 Daniel Harvey suggestion worked for me... menu titles are now white, not grey, but bold font still remains....

Flatline (luciano-longo) wrote :

Same as Thanasis Naskos (naskoos), menu fonts are now white, but still bold.

I'm specifying my issue, related to the initial bug report: I have no issue with the font color/background color. Only that the font is bold in the latest Netbeans version, so I can't see if a file opened in Netbeans has unsaved changes or not..

Thanasis Naskos (naskoos) wrote :

Suggested work-around copied from sidtj from the same forum as suggested by Daniel ( ).

"Append "--laf Metal" (without quotes) to your netbeans exec link.
Here i have:

Exec=/bin/sh "/home/username/bin/netbeans-7.1/bin/netbeans" --laf Metal

This is not the best laf (look and feel) but is better than the current one on 12.04. No more bold in everywhere and visible menu, including in the ambiance theme."

These work around fixes bold font issue... I don't like the look of Netbeans with this look and feel, but it is a temporary solution until a fix release...

A better workaround, but I agree that the LAF is not the best and personally I would wait for a fix rather than a workaround

We have the same problems with iReport, which is no surprise since it is Netbeans based.
The suggested solution --laf Metal eases the pain a little, but the looks of the applications become unfamiliar
hence it is not easy to work with them.

I don't know how you decide what is a duplicate or not, but I really do not think this is a dup, since this bug is about the font-weight (bold)/font-type, not the font-size. The older bug is from 2010, weirdly it is not fixed as well..

And to add, the older "dup" bug is about the COLOUR of the font, this bug is NOT

Thanasis Naskos (naskoos) wrote :

Duplicate status is definitively wrong!!
+1 Alexander

Matt Raines (matt-raines) wrote :

I agree that this does not seem to be a duplicate of #669159.

Daniel Harvey (daniel.harvey) wrote :

Agree this is not a duplicate. Perhaps related but two distinct issues.

martins (martins256) wrote :

You can also run netbeans with "--laf Nimbus"

7.0.1 (fine): OpenJDK 1.6.0_24
7.1.1, 7.2.1 (emboldened text): OpenJDK 1.7.0_03

More laf (look-and-feel) options for anyone using that work-around:

Paolo Foletto (paolo-foletto) wrote :

I confirm the bug and the solution for the dark color menu proposed with message #4
Ubuntu 12.04 64 bit OpenJDK 1.7.0_03 and NetBeans 7.1

To clarify, it is not a solution, it is a work around (proposed in message #4)

Hunter Perrin (hperrin) wrote :

To fix the menu problem, you can also use a plugin to make NetBeans work with the global menu:

Tools -> Plugins -> Settings -> Add

Name: Java Ayatana

Then install the Java Ayatana plugin.

IMHO, this should be integrated with NetBeans.

Hunter Perrin (hperrin) wrote :

I developed a workaround that does fix the problem. HOWEVER, it will change the default font in EVERY GTK2 application!

Run these commands:

MYTHEME="Ambiance" # Using a different theme? Change it.

MYFONT="Sans 10" # Replace with another font if you prefer.

echo -e "\ninclude \"apps/netbeans.rc\"" | sudo tee -a /usr/share/themes/$MYTHEME/gtk-2.0/gtkrc

echo -e "# NetBeans bold font workaround.\nstyle \"netbeans_window\" {\n\tfont_name = \"$MYFONT\"\n}\nwidget \"*\" style \"netbeans_window\"" | sudo tee /usr/share/themes/$MYTHEME/gtk-2.0/apps/netbeans.rc

Now change your theme, and change it back. (Or restart.) And load up NetBeans. Bam! No more bold. You're welcome. ;)

Hunter Perrin (hperrin) wrote :

And make sure those commands are one line each. Launchpad split them up. Grr.

Franco (francogpellegrini) wrote :

The #4 fix work for me.

The bold text is a FONT problem. Dont use ubuntu font... change it to, for example, to "Droid Sans" and it'll work again (see

#4 Daniel Harvey suggestion worked for me too. Netbeans menu is now white.

higuita (higuita) wrote :

as per bug #937200 ( :

after some debug i found that the /etc/font/conf.d/65-nonlatin.conf is the one that makes java use a bad font.

remove it and restart the java and things will be back to normal.

of course, i dont know what removing that font definition will break, possible non-latin languages :)

Lukasz Pozniak (rox-lukas) wrote :


in Netbeans 7.0 everything looks fine, 7.1.2 is all bold

#26 solution worked for me, thanks!

Rocko (rockorequin) wrote :

Another workaround suggested in bug #937200 fixes the bold font issue for me: remove the fonts-unfonts-core package with 'sudo apt-get remove fonts-unfonts-core'.

And Daniel's workaround in comment 4 fixes the menu colour for me (thanks!). Attached is the patch corresponding to his change (use 'sudo patch -p0 < netbeans-fix-menu-colour.diff' to apply it).

The attachment "fix netbeans menu colour in Ambiance" of this bug report has been identified as being a patch. The ubuntu-reviewers team has been subscribed to the bug report so that they can review the patch. In the event that this is in fact not a patch you can resolve this situation by removing the tag 'patch' from the bug report and editing the attachment so that it is not flagged as a patch. Additionally, if you are member of the ubuntu-reviewers team please also unsubscribe the team from this bug report.

[This is an automated message performed by a Launchpad user owned by Brian Murray. Please contact him regarding any issues with the action taken in this bug report.]

tags: added: patch
SerP (serp2002) wrote :

reply #21 fix the problem!

Erki Hallingu (erkiha) wrote :

At some point ubuntu 12.10 fixed the font automatically, but reply #21 makes it perfect integrated ubuntu app.

Sergio Benjamim (sergio-br2) wrote :

Change fonts from Ubuntu to Droid Sans work for me, but Droid Sans fonts is ugly fonts to a lcd screen, it's rendering very bad in java applications.

mokaddim (shiplu-net) wrote :

I am using --laf Nimbus . Its working good. Better than Metal.

To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Duplicates of this bug

Other bug subscribers