Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Nebula » [Grid] DefaultCellRenderer and wordwrap
[Grid] DefaultCellRenderer and wordwrap [message #59466] Thu, 25 September 2008 16:13 Go to next message
Gregory Dyke is currently offline Gregory DykeFriend
Messages: 8
Registered: July 2009
Junior Member
Hi

I'd like to use Grid/GridViewer to create a table with variable line
heights, with the lines' heights adjusting to show the whole contents of
the line.

When using

gridviewer.setAutoPreferredHeight(true) combined with
column.setWordWrap(true) for each column

I end up with each row being very much too high. I'm using the smallfonts
option running from macosx. Is this a bug? I've looked at the source code:
why doesn't it just call getBounds on the TextLayout object used for
computing row height?

Also, the line height doesn't automatically increase when I make a column
narrower.

Help?

Regards

Greg
Re: [Grid] DefaultCellRenderer and wordwrap [message #59561 is a reply to message #59466] Sat, 27 September 2008 20:26 Go to previous message
Gregory Dyke is currently offline Gregory DykeFriend
Messages: 8
Registered: July 2009
Junior Member
The answer to my problem is that I am an idiot. Some weird "legacy" code I
was running changes the width *after* the row height is calculated.

> When using

> gridviewer.setAutoPreferredHeight(true) combined with
> column.setWordWrap(true) for each column

> I end up with each row being very much too high. I'm using the smallfonts
> option running from macosx. Is this a bug? I've looked at the source code:
> why doesn't it just call getBounds on the TextLayout object used for
> computing row height?

> Also, the line height doesn't automatically increase when I make a column
> narrower.

> Help?

> Regards

> Greg
Re: [Grid] DefaultCellRenderer and wordwrap [message #592373 is a reply to message #59466] Sat, 27 September 2008 20:26 Go to previous message
Gregory Dyke is currently offline Gregory DykeFriend
Messages: 8
Registered: July 2009
Junior Member
The answer to my problem is that I am an idiot. Some weird "legacy" code I
was running changes the width *after* the row height is calculated.

> When using

> gridviewer.setAutoPreferredHeight(true) combined with
> column.setWordWrap(true) for each column

> I end up with each row being very much too high. I'm using the smallfonts
> option running from macosx. Is this a bug? I've looked at the source code:
> why doesn't it just call getBounds on the TextLayout object used for
> computing row height?

> Also, the line height doesn't automatically increase when I make a column
> narrower.

> Help?

> Regards

> Greg
Previous Topic:gantt charts synchronize
Next Topic:[Grid] ComboBoxCellEditor doesn't return focus to the Grid
Goto Forum:
  


Current Time: Fri Apr 26 17:56:53 GMT 2024

Powered by FUDForum. Page generated in 0.02427 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top