This week's book giveaway is in the OO, Patterns, UML and Refactoring forum.
We're giving away four copies of Refactoring for Software Design Smells: Managing Technical Debt and have Girish Suryanarayana, Ganesh Samarthyam & Tushar Sharma on-line!
See this thread for details.
The moose likes Swing / AWT / SWT and the fly likes change the text color momentarily Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

JavaRanch » Java Forums » Java » Swing / AWT / SWT
Bookmark "change the text color momentarily" Watch "change the text color momentarily" New topic

change the text color momentarily

Araad Izadkhah

Joined: Nov 07, 2005
Posts: 15
hey folks,
I have a JTextArea that I want to display different things in different color. everytime i use the setForground(Color.whatever) it changes the whole thing, even when i set it back to the original.

any idea?
thx in advance
Michael Dunn
Ranch Hand

Joined: Jun 09, 2003
Posts: 4632
use a JTextPane
I agree. Here's the link:
subject: change the text color momentarily
jQuery in Action, 3rd edition