This week's giveaway is in the Android forum.
We're giving away four copies of Android Security Essentials Live Lessons and have Godfrey Nolan on-line!
See this thread for details.
The moose likes Swing / AWT / SWT and the fly likes Problem in changing the font Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Java » Swing / AWT / SWT
Bookmark "Problem in changing the font" Watch "Problem in changing the font" New topic

Problem in changing the font

Hussein Baghdadi
clojure forum advocate

Joined: Nov 08, 2003
Posts: 3476

Hi all.
I have a swing application that contains a button for changing the font, and a text area.
I choosed the font Tahoma then I entered some text into the text area.
now I want to enter some new text using another font.
I changed the font to enter the text, but the problem is the old text has also changed.
I tried various kinds like : JTextArea, JTextPane, JEditorPane.

any ideas ??
Anand Karia
Ranch Hand

Joined: Sep 25, 2004
Posts: 156

Hi john

try this!!!

Love is GOD and GOD is Love.
Anand Karia
IT Concretor.......
M/s. Anand Karia Concreting IT
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
subject: Problem in changing the font
Similar Threads
color in selected text in text area
font in chinese operating system
How to set the fontcolor and size for the selected text of text area ?
Creating an FX label with HTML formating