1

I'm using GXT 2.2.5

I wonder how can I make neat word wrap in TreeGrid. I've found that i should give whitespace: normal to make text wraped. But then i have ran into bad left margin issue as you can see in attached image.

Any ideas?

Thanks in advance :)

enter image description here

denu
  • 2,170
  • 2
  • 23
  • 28

2 Answers2

0

Try along with whitespace: normal, add this to your css

.x-grid3-row {
height: auto !important;
}
nat
  • 11
  • didn't work unfortunately, lines are wrapped, only top of wrapped letters are visible and they're still panned all to the left, while it should be under the beggining of frirst line, but thanks for answering! appreciate this – denu Apr 06 '12 at 07:56
0

I have an another idea. Instead of making text flow in multiple lines, you can show a fixed number of characters of the text followed by ellipsis. You can use the following styles to achieve this:

   white-space:nowrap;
   overflow:hidden;
   text-overflow:ellipsis;
Ganesh Kumar
  • 3,220
  • 1
  • 19
  • 27
  • unfortunately our customer demands displaying complete node names, so truncating even with ellipsis is not an option. but thanks for reply! – denu Jan 07 '12 at 23:19
  • If you provide a simple working prototype, then it will be helpful for us to come up a solution. – Ganesh Kumar Jan 08 '12 at 12:45
  • sure, try this from sencha's example page ( http://sencha.com/examples/#basictreegrid ) expand Beethoven -> Symphonies, shrink Name column to make it to narrow for track names. Greetz :) – denu Apr 06 '12 at 07:54