I use a higher DPI setting which makes IntelliJ (actually Android Studio) have really messed up fonts.
I use MacType which renders my fonts beautifully elsewhere, but I guess Java VM somehow intercepts it or something, it's killing me.
I’m on a high-dpi display and I got it working with a perfect font rendering, to achieve this you need to:
If you followed the above tips and you’re experiencing lags when fast scrolling the code (this sometimes could happen on Linux distributions with a not optimized gpu driver), try removing the line
Finally, here is a screenshot of the result:
I wrote a little manual howto fix this.
Script to start Intellij Idea
*only note that need to change IDEA_HOME location for your path of idea
More info and screenshots of better fonts: http://urshulyak.com/?p=478
The accepted answer didn't work for me but I got everything working by doing this:
After reading various tutorials and messing with a bunch of fixes I've found a way that works perfectly.
First of all download JDK 8 from Oracle and execute the following lines in the terminal:
Now download the JDK font fix (Courtesy of [Urshulyak Yaroslav]) by executing the following:
This will extract the downloaded zip and move it to /usr/lib/jvm/. Now run the following in the terminal:
Then add the following lines to the very bottom of the bashrc file.
Save it then gedit the idea.sh. (Your script location may be different)
At the very bottom of the script replace the line(s) in the While Do statement at the bottom with these two lines:
Save it then open up IntelliJ, the fonts should work and you will be using Oracle JDK 8 for development. You will likely have to edit Project Settings and set up your JDK again but be sure to use the actual JDK and not the font fix one.
This fix also works with CLion, Android Studio and [PyCharm.
These instructions assume the JDK version was 1.8.0_25, file/path names will change for future versions.
If you can't clear hints with FontForge like guari explained in his answer. Use Cousine (Apache License v2.00) as editor font and set the size to 14. I tried a couple of other monospaced fonts. However, Cousine seems to have a nicer rendering than the most other fonts. See the screenshot at the end