Sometimes we need to change font style for Java code in Eclipse, e.g. increasing font size for more readability. This can be done easily in Eclipse, by going to menu Window > Preferences… In the Preferences dialog:

  • Select General > Appearance > Colorsand Fonts (1) in the left pane.
  • Select Java Editor Text Font (2) in the center.
  • Click Edit… button in the right.
change Colors and Fonts in Eclipse

Now, in the Font dialog you can change font name, font style and font size:

font editor in eclipse

Click OK, the Preview pane in the Preferences dialog lets you see the changes before applying it:

Preview font in Eclipse

When the preview suits your need, click OK to close the Preferences dialog, and then the changes take effect immediately. Here’s an example screenshot shows text in a Java code editor has bigger font than usual:

bigger font for Java code

When you want to go back to the default setting, go to the Preferences dialog again, and click Reset button for Java Editor Text Font in Colors and Fonts setting:



Reset java editor text font

 

Other Eclipse Tutorials:


About the Author:

is certified Java programmer (SCJP and SCWCD). He began programming with Java back in the days of Java 1.4 and has been passionate about it ever since. You can connect with him on Facebook and watch his Java videos on YouTube.



Add comment

   


Comments 

#3Pranav2022-12-06 09:56
Thankyou very Much.
I was struggling with this since I have old version of Java and it was not happening with ctrl +/-. THANKYOU SO MUCH ????????
Quote
#2George S Cowan2019-10-12 21:10
Also, you can use the Ctrl-+ and Ctrl-- (Control minus).
Quote
#1Mohit2017-04-07 00:05
nice. Got idea how to change the font.
Quote