• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Tim Cooke
  • paul wheaton
  • Jeanne Boyarsky
  • Ron McLeod
Sheriffs:
  • Paul Clapham
  • Liutauras Vilda
  • Devaka Cooray
Saloon Keepers:
  • Tim Holloway
  • Roland Mueller
Bartenders:

Dynamically increasing row height in JTable

 
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hey guys,
i am trying to set row height for each row individually. I created a JTextArea renderer, (because i need to show multiple lines inside some cells). TextArea knows how many lines should be there, so i set the row height in the getTableCellRendererComponent() method of Renderer based on the preferred of the textArea. I call table.setRowHeight(rowNumber, height_wanted)
where height_wanted is a preferred size of TextArea. It doesn't work. I found one article that mentioned that it doesn't work for 1.4 and works for 1.3 but i wasn't sure if it was fixed yet, or not. I use 1.4_0_1 (the latest available)
Anyone with similar experience??
thanks a lot.
 
polina_keselman
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
ok, it actually works for a regular JTable.. guess the problem is in the table that i use :-(
 
It wasn't my idea to go to some crazy nightclub in the middle of nowhere. I just wanted to stay home and cuddle with this tiny ad:
Smokeless wood heat with a rocket mass heater
https://woodheat.net
reply
    Bookmark Topic Watch Topic
  • New Topic