August 20th, 1999, 03:59 PM
Hi,
I'm using JDK1.2.2.I've a TextArea with 10 lines.Each line should be displayed
in one,one color.How can I do this?.Any idea/suggestion will be greatly helpful for me.
Thanks in advance.
August 23rd, 1999, 02:14 AM
hai,
If you want to display each line in a TextArea in a different color, it is not possible to do that directly. Your setForeground(Color) method of TextArea will change the color of the entire text displayed in the TextArea. What I would suggest U is to override the paint(Graphics ) method of TextArea. In the overriding method U will have to use setColor(Color ) of Graphics. This will help U achieve that. U may also go through the source code of TextArea provided by Sun. This will give you a clearer picture in such circumstances
thanx,
devi prasad m. p.
java_devi_prasad@mailcity.com
k_venkurao
May 6th, 2000, 05:40 AM
can you be more eloberate please
send to my mail id
k_venkurao@yahoo.com
thanks in advance