[go: up one dir, main page]

Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Nebula » Grid - Cell Height
Grid - Cell Height [message #17931] Tue, 28 November 2006 20:22 Go to next message
Eclipse UserFriend
Originally posted by: x_naren.hotmail.com

How to set cell height in Grid?

Naren
Re: Grid - Cell Height [message #17963 is a reply to message #17931] Tue, 28 November 2006 21:52 Go to previous messageGo to next message
Chris Gross is currently offline Chris GrossFriend
Messages: 253
Registered: July 2009
Senior Member
This is currently only possible if you write your own custom cell renderer.

-Chris

Naren wrote:
> How to set cell height in Grid?
>
> Naren
>
Re: Grid - Cell Height [message #20439 is a reply to message #17963] Tue, 12 December 2006 15:53 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: x_naren.hotmail.com

Hi Chris,

While I was trying to do this I noticed that

void newItem(GridItem item, int index) {
..............

if (items.size() == 1)
rowHeight = computeRowHeight(sizingGC);
}

which means that rowHeight is based on row 1 and is computed once during
the creation and cannot be changed later

say, If I create
class MyTable extends Grid

and still cannot override either
newItem (package access)
computeRowHeight (private)
rowHeight (private)

In my case, I need to set the itemheight if the shell is resized (all the
rows will be of same height). I tried to change font height to reflect
this, font in the table changes but not the item height.

Please, let me know if there is any other way to reflect this behavior.

Thanks

Naren

Chris Gross wrote:

> This is currently only possible if you write your own custom cell renderer.

> -Chris

> Naren wrote:
>> How to set cell height in Grid?
>>
>> Naren
>>
Re: Grid - Cell Height [message #21026 is a reply to message #20439] Tue, 12 December 2006 15:56 Go to previous message
Chris Gross is currently offline Chris GrossFriend
Messages: 253
Registered: July 2009
Senior Member
I'm working on setItemHeight in Grid.

Naren wrote:
> Hi Chris,
>
> While I was trying to do this I noticed that
> void newItem(GridItem item, int index) {
> ..............
>
> if (items.size() == 1)
> rowHeight = computeRowHeight(sizingGC);
> }
>
> which means that rowHeight is based on row 1 and is computed once during
> the creation and cannot be changed later
>
> say, If I create
> class MyTable extends Grid
> and still cannot override either
> newItem (package access)
> computeRowHeight (private)
> rowHeight (private)
>
> In my case, I need to set the itemheight if the shell is resized (all
> the rows will be of same height). I tried to change font height to
> reflect this, font in the table changes but not the item height.
>
> Please, let me know if there is any other way to reflect this behavior.
>
> Thanks
>
> Naren
>
> Chris Gross wrote:
>
>> This is currently only possible if you write your own custom cell
>> renderer.
>
>> -Chris
>
>> Naren wrote:
>>> How to set cell height in Grid?
>>>
>>> Naren
>>>
>
>
Re: Grid - Cell Height [message #569699 is a reply to message #17931] Tue, 28 November 2006 21:52 Go to previous message
Chris Gross is currently offline Chris GrossFriend
Messages: 471
Registered: July 2009
Senior Member
This is currently only possible if you write your own custom cell renderer.

-Chris

Naren wrote:
> How to set cell height in Grid?
>
> Naren
>
Re: Grid - Cell Height [message #572644 is a reply to message #17963] Tue, 12 December 2006 15:53 Go to previous message
Naren is currently offline NarenFriend
Messages: 8
Registered: July 2009
Junior Member
Hi Chris,

While I was trying to do this I noticed that

void newItem(GridItem item, int index) {
..............

if (items.size() == 1)
rowHeight = computeRowHeight(sizingGC);
}

which means that rowHeight is based on row 1 and is computed once during
the creation and cannot be changed later

say, If I create
class MyTable extends Grid

and still cannot override either
newItem (package access)
computeRowHeight (private)
rowHeight (private)

In my case, I need to set the itemheight if the shell is resized (all the
rows will be of same height). I tried to change font height to reflect
this, font in the table changes but not the item height.

Please, let me know if there is any other way to reflect this behavior.

Thanks

Naren

Chris Gross wrote:

> This is currently only possible if you write your own custom cell renderer.

> -Chris

> Naren wrote:
>> How to set cell height in Grid?
>>
>> Naren
>>
Re: Grid - Cell Height [message #572705 is a reply to message #20439] Tue, 12 December 2006 15:56 Go to previous message
Chris Gross is currently offline Chris GrossFriend
Messages: 471
Registered: July 2009
Senior Member
I'm working on setItemHeight in Grid.

Naren wrote:
> Hi Chris,
>
> While I was trying to do this I noticed that
> void newItem(GridItem item, int index) {
> ..............
>
> if (items.size() == 1)
> rowHeight = computeRowHeight(sizingGC);
> }
>
> which means that rowHeight is based on row 1 and is computed once during
> the creation and cannot be changed later
>
> say, If I create
> class MyTable extends Grid
> and still cannot override either
> newItem (package access)
> computeRowHeight (private)
> rowHeight (private)
>
> In my case, I need to set the itemheight if the shell is resized (all
> the rows will be of same height). I tried to change font height to
> reflect this, font in the table changes but not the item height.
>
> Please, let me know if there is any other way to reflect this behavior.
>
> Thanks
>
> Naren
>
> Chris Gross wrote:
>
>> This is currently only possible if you write your own custom cell
>> renderer.
>
>> -Chris
>
>> Naren wrote:
>>> How to set cell height in Grid?
>>>
>>> Naren
>>>
>
>
Previous Topic:New Nebula Presentation Component...
Next Topic:Right click event
Goto Forum:
  


Current Time: Fri Dec 13 21:05:17 GMT 2024

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

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

Back to the top