Turning off text anti-aliasing with NetBeans 8.2, 8.1, 7.3, 7.2, 7.1 on OS X

Posted: March 5th, 2012 | Author: | Filed under: Uncategorized | Tags: , , | 1 Comment »

Update 2016/09/19: For NetBeans 8.1 or 8.2, just add ” -J-Dorg.netbeans.editor.aa.text=false” to the line described below.

Update 2013/02/10: This also works with NetBeans 7.3.

Update 2012/07/24: This post was originally written about 7.1. Everything here also applies to Netbeans 7.2, so I’ve update this to refer to 7.2.

Another version of NetBeans, another hack to get it to turn off text anti-aliasing. Previously, I showed how with NetBeans 7.0. NetBeans 7.3.x is nearly the same, but a bit simpler.

Just make the following changes to the definition of netbeans_default_options in /Applications/NetBeans/NetBeans\ 7.3.app/Contents/Resources/NetBeans/etc/netbeans.conf (or something similar if you didn’t install it in the default location):

Add:

-J-Dswing.aatext=false

Change:

-J-Dapple.awt.graphics.UseQuartz=false

Restart NetBeans and you should have non-anti-aliased fonts.

Notes

Note that, unlike NetBeans 7.0, you no longer need to add -J-Dawt.useSystemAAFontSettings=off.

See some notes about text anti-aliasing on the NetBeans wiki.


Turning off text anti-aliasing with NetBeans 7.0 on OS X

Posted: May 2nd, 2011 | Author: | Filed under: Uncategorized | Tags: , , | 3 Comments »

See the updated post for NetBeans 7.1 and 7.2.

The quick version

For those who want to turn off text anti-aliasing in NetBeans 7.0.x on Mac OS X without reading my tirades, just make the following changes to the definition of netbeans_default_options in /Applications/NetBeans/NetBeans\ 7.0.app/Contents/Resources/NetBeans/etc/netbeans.conf (or something similar if you didn’t install it in the default location):

Add:

-J-Dswing.aatext=false -J-Dawt.useSystemAAFontSettings=off 

Change:

-J-Dapple.awt.graphics.UseQuartz=false

Restart NetBeans and you should have non-anti-aliased fonts.

The full story

The perfect programming font: many have searched; few have found.

It’s Monaco, 10pt, no anti-aliasing.

But I digress. My goal here is not to discuss fonts (but seriously, I love discussing fonts), but to write the most keyword-heavy post for those trying to figure out how to turn off text anti-aliasing in NetBeans 7 on Mac OS X. By default, NetBeans uses anti-aliasing for its editor, which, for most fonts, is great, but not for Monaco 10pt.

When I used NetBeans 6.x, I found this page to be quite useful. However, when I tried turning off anti-aliasing with NetBeans 7.0, it did not work.

After a bit of exploring, I found the key to be setting -J-Dapple.awt.graphics.UseQuartz=false. I believe Quartz refers to the 2D graphics rendering API for OS X, but for the sake of your non-anti-aliased font, you certainly don’t need it.

In-Application Setting

NetBeans has been well aware of the issue for quite some time, so don’t expect the anti-aliasing setting to be modifiable inside the application any time soon.


How to fully maximize Chrome windows in OS X

Posted: July 1st, 2010 | Author: | Filed under: Browsers | Tags: , , | No Comments »

(Edit 2013/06/28) Quick version: press Shift when you click the green “Maximize” button.

(Full version) I, along with many of my friends and coworkers, have run into issues with maximizing Google Chrome windows on Mac OS X. It seems that, when clicking on the green button in the title bar, that the window resizes vertically, but not horizontally. And when you’re actually trying to get the window to fill up the full screen, this is highly unfortunate.

What’s going on

The green button is not the Maximize button in OS X; it’s the Zoom button. As described in Chrome’s issues tracker, Chrome’s intended behavior for this button is to “size-to-best-fit, not fill-screen”. Therefore, it will only make the window wider if there is some visible content on the page that’s wider than the window is currently, i.e., if there’s a horizontal scrollbar. This page shows it quite wonderfully: there’s a 65k-pixel-wide div at the bottom that will make the window expand to the full screen size when you Zoom. Hide the div, and the window will only expand vertically.

How to make Zoom fill the full screen

Despite this somewhat unexpected default behavior, there are a couple ways to fill the screen anyway when Zooming:

  • Press Shift when you click on the Zoom button. This, as implemented by Chrome, will make the window fill the full screen.
  • This one has some subtlety: Under System Preferences->Keyboard->Keyboard Shortcuts->Application Shortcuts, add a shortcut for Chrome. Make the Menu Title be “Zoom” (it’s under the Window menu). Since Command+M is the keyboard shortcut for Minimize, let’s make the Keyboard Shortcut for Zoom be Command+Shift+M. Go back to Chrome and try it out your keyboard shortcut. Voila! But wait–if you just click on Zoom in the menu, it will continue to resize only vertically. What’s going on here? Because you’re pressing Shift while activating Zoom with the keyboard shortcut, it works just like pressing Shift while clicking the green button. No joke.

Versions and such:

  • Chrome version: 5.0.375.8628.0.1500.52 (/always)
  • OS X version: 10.6.4 (/all)