aspose file tools*
The moose likes Applets and the fly likes Display problem in JTable of an Applet Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Spring in Action this week in the Spring forum!
JavaRanch » Java Forums » Java » Applets
Bookmark "Display problem in JTable of an Applet" Watch "Display problem in JTable of an Applet" New topic
Author

Display problem in JTable of an Applet

Maki Jav
Ranch Hand

Joined: May 09, 2002
Posts: 436
Hi,

I am using an JApplet for displaying two JLists and two JTables in the central panel.

Applet is doing some computing and then displays files in the table above say table1. When this table is clicked on the row, appropriate file is selected and its word contents are displayed in second table which is below.

Image is here

This second table row gets sort of "bend", which straightens on selecting but some other row gets "bend" and so on till the table soon gets ugly.

I am using a class BadarTableModel which extends AbstractTableModel. Both the tables use it.

Maybe changing row values to String from Object will affect its behaviour?

Thanks,

Maki Jav


Help gets you when you need it!
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 42289
    
  64
All the lines in that picture look perfectly straight to me (and I doubt that JTable is capable of drawing non-straight lines). Can you be more specific about what the problem is?


Ping & DNS - my free Android networking tools app
Maki Jav
Ranch Hand

Joined: May 09, 2002
Posts: 436
Hi,

Please see that image again. i have put the different image. Sorry for that

I made the table editable and copied those two rows that were troubling me and got these.

<html>a target, when t<body bgcolor=yellow text=red><b>here</b> is matching (similar</body></html>

<html>present a message "t<body bgcolor=yellow text=red><b>here</b> is no matching"</body></html>

Seems like there is a problem in my logic that is causing this problem. What I am doing is
highlighting the words found.

Thanks,

Maki Jav
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
 
subject: Display problem in JTable of an Applet