12/19/17

DrJava Font Size Problem

I'm helping my son learning Java. One of the first things to do when learning Java is picking an IDE. I like DrJava for its simplicity and small size. However, when I first run DrJava, its font size is way too small on my 4K monitor.

There are 2 ways to fix this - the easy way and the hard way.

The easy way first.
Click Edit:Preferences, then click "Display Options", change "Look and Feel" to the one that ends with "Plastic3DLookandFeel".  Do this on Windows only, for Mac and Linux, default "Look and Feel" is fine.
Click "Font" under "Display Options", change all fonts to double the original size:
Press "OK", then close DrJava then open it again.  Now the fonts should be big enough to read.

(The changes you make are actually saved in a configuration file .drjava in your home directory,  you can edit the file directly for changes, but it's not recommended)

Now the hard way.
For the "easy way", we just changed DrJava's default configuration preferences.  The hard way is to compile a DrJava program with these changes already made in the source code so we don't have to change preferences.

Clone the DrJava repository on github: https://github.com/DrJavaAtRice/drjava

Try to compile it first:
cd drjava/drjava
ant jar

You must have ant already installed.  If it's compiled OK, try run it:
java -jar drjava.jar
(You can just double click drjava.jar file too)

Open src/edu/rice/cs/drjava/config/OptionConstants.java for editing:
Change "Monaco-12" to "Monaco-24"; change "Monospaced-12" to "Monospaced-24";
chanage "dialog-10" to "dialog-20"; change "dialog-12" to "dialog-24".

Save the file then recompile (ant jar).  Now DrJava is "pre-configured" with big fonts.

You might say this "hard way" is pointless.  Why on earth would anyone want to do this? I agree.  But just maybe one wants to provide a "pre-configured" copy of DrJava to his students.  I just show one way to do it.  Another way is to write a .drjava configuration file upon installation.  This is way more complex. Besides, I'm using a standalone jar file, there's no installation to speak of.


13 comments:

Nannie Co Pam said...

Amazing & Great informative blog,it gives very useful practical information to developer like me. Besides that Wisen has established as Best Java Online Training India . or learn thru Online Training mode Java Online Training From India . Nowadays Hibernate ORM has tons of job opportunities on various vertical industry.

Unknown said...

Please a video tutorial on this changing the font size in java in both method.
As I am a student I cant understand
The second process
My Gmail Id (deva740640@gmail.com)
Please send the tutorial

priya said...

Great thoughts you got there, believe I may possibly try just some of it throughout my daily life.
Data Science Training in Indira nagar
Data Science Training in btm layout
Data Science Training in Kalyan nagar
Data Science training in Indira nagar
Data science training in bangalore

Amy Wong said...

Hi, I met one gambling site, new a casino online it was very cool, it was fun and spent some time with the conclusion that there were no problems the very best site cool design, a bunch of slots and slot machines

pavithra dass said...

Great post!
Thanks for sharing this list!
It helps me a lot finding a relevant blog in my niche!
Java Training in Chennai
Java Training in Coimbatore
Java Training in Bangalore

Riya Raj said...

The blog which you have shared is more creative... Waiting for your upcoming data...
Python Training in Chennai
Python course in Chennai
Python Training
Best Python Training Institute in Chennai
Python Training in Velachery
Python training in Adyar
Hadoop Training in Chennai
Software testing training in chennai
JAVA Training in Chennai

sherya said...

Thank you for this awesome blog. You are giving a professional touch to your content. It makes your article worth reading. Looking forward to learn more from you.
Automation Anywhere Training in Chennai
Automation Anywhere course in Chennai
AWS Training in Chennai
Azure Training in Chennai
Cloud Computing Training in Chennai
Automation Anywhere Training in Vadapalani
Automation anywhere training in Guindy
Automation anywhere training in Thiruvanmiyur

Manisha Sudha said...

Awesome blog...thanks for sharing valuable articles.....
Struts Training in Chennai
Struts Training institutes in Chennai
Struts Training Chennai
struts Training in Anna Nagar
struts Training in T Nagar
Wordpress Training in Chennai
SAS Training in Chennai
Spring Training in Chennai
Photoshop Classes in Chennai
DOT NET Training in Chennai

diya shivanya said...

Thanks for posting keep updating it.
Ionic Training in Chennai
Ionic training course
German Classes in Chennai
TOEFL Coaching in Chennai
Informatica Training in Chennai
Spoken English Classes in Chennai
Ionic Training in Tambaram
Ionic Training in Adyar

chintu said...

nice blog..valuable information....thanks for sharing...
C C++ Training in Chennai
C Language Training in Chennai
c c++ course fees in chennai
C C++ training in tambaram
C C++ training in porur
javascript training in chennai
core java training in chennai
Html5 Training in Chennai
DOT NET Training in Chennai
QTP Training in Chennai

Anbarasan14 said...

I have been reading all your blogs regularly..I admit, this is one of the best blogs I have read till date. Great going.. Waiting for the next...
Spoken English Classes in Chennai
Spoken English in Chennai
Top 10 Spoken English Classes in Chennai
Best IELTS Coaching in Chennai
IELTS Coaching Centre in Chennai
English Classes in Mumbai
English Speaking Classes in Mumbai
Best IELTS Coaching in Mumbai
IELTS Coaching in Mumbai
Spoken English Class in Anna Nagar

Manthra said...

I want to thank for sharing this blog, really great and informative. Share more stuff like this.
Ethical Hacking course in Chennai
Ethical Hacking Training in Chennai
Hacking course
ccna course in Chennai
Salesforce Training in Chennai
Angular 7 Training in Chennai
Web Designing course in Chennai
Ethical Hacking course in Thiruvanmiyur
Ethical Hacking course in Porur
Ethical Hacking course in Adyar

Laura Bush said...

Thanks for taking the time to share this article here about the Java font size problem. Your article is very informative and nicely describes the solution of Java font size problem. codingbytes offers the Best Core Java Course in Delhi.