Home » Eclipse Projects » Nebula » Examples
Examples [message #2045] |
Wed, 17 May 2006 11:32  |
Eclipse User |
|
|
|
Hi,
I can see from the home page that you have some example code for how to
use this widget. I have been unsuccessful in trying to find it however
and was wondering if you could point me in the right direction.
Drew
|
|
| | | | |
Re: Examples [message #3552 is a reply to message #3519] |
Wed, 31 May 2006 09:41   |
Eclipse User |
|
|
|
Yes that picture is definitely the Grid. I don't have that code handy.
Its not very exciting code anyway. Generally Grid is designed to
match the SWT Table's API. The are differences but rather few. For
example, the Grid can function without any selection highlighting and
therefore you *must* pass either SWT.SINGLE or SWT.MULTI or no selection
highlighting will occur. The normal Table defaults to SWT.SINGLE.
Some of the other features visible in that screenshot that might not
exist in Table:
Column Groups:
Create a GridColumnGroup and create columns as children of it. If you
want the group to be collapsible, use the SWT.TOGGLE style in the
constructor of GridColumnGroup and set the detail/summary properties on
the individual columns.
Checkboxes in multiple cols:
Grid doesn't utilize the SWT.CHECK style in the main constructor, but
rather in individual column constructors, allowing checkbox per col.
Column spanning:
GridItem.setColumnSpan()
Hierarchical:
Creating items as children of other items as you would with a Tree. Set
one column as the 'tree' column (i.e. shows the toggle) by calling
GridColumn.setTree(true).
There will be examples and snippets (and better javadoc) as the project
progresses.
-Chris
Daniel wrote:
> Hi there,
>
> From what I've seen of the Grid so far and what I've been able to
> deduce from the source code, this has the makings of a great Table
> extension (of which I am in some need :-P). I can't wait to see some
> samples. Just out of curiosity, was the screenshot on the Grid homepage
> actually done using the widget itself, and if so, is that code available
> anywhere? Thanks so much!
>
> - Daniel
>
|
|
|
Re: Examples [message #3646 is a reply to message #3552] |
Wed, 31 May 2006 16:17   |
Eclipse User |
|
|
|
Originally posted by: steve_northover.ca.ibm.com
Hi Chris,
Some thoughts ...
"Chris Gross" <chris.gross@us.ibm.com> wrote in message
news:e5k6ec$f07$1@utils.eclipse.org...
> Yes that picture is definitely the Grid. I don't have that code handy.
> Its not very exciting code anyway. Generally Grid is designed to
> match the SWT Table's API. The are differences but rather few. For
> example, the Grid can function without any selection highlighting and
> therefore you *must* pass either SWT.SINGLE or SWT.MULTI or no selection
> highlighting will occur. The normal Table defaults to SWT.SINGLE.
>
I know this is a better API but given that the native table has shipped and
doesn't
work this way means that this sort of difference will be an unexpected
annoyance.
A better solution might be to add an API to get rid of the selection. The
API
could offer to set the selection mode dynamically or it could just be
something
like "setSelectionEnabled()" or something like that.
> Some of the other features visible in that screenshot that might not
> exist in Table:
>
> Column Groups:
> Create a GridColumnGroup and create columns as children of it. If you
> want the group to be collapsible, use the SWT.TOGGLE style in the
> constructor of GridColumnGroup and set the detail/summary properties on
> the individual columns.
>
> Checkboxes in multiple cols:
> Grid doesn't utilize the SWT.CHECK style in the main constructor, but
> rather in individual column constructors, allowing checkbox per col.
>
You might consider supporting the SWT.CHECK in the main constructor
too, to be compatible. NOTE: If this turns out to be a lot of pain for
some
reason, then don't consider it.
> Column spanning:
> GridItem.setColumnSpan()
>
> Hierarchical:
> Creating items as children of other items as you would with a Tree. Set
> one column as the 'tree' column (i.e. shows the toggle) by calling
> GridColumn.setTree(true).
>
>
> There will be examples and snippets (and better javadoc) as the project
> progresses.
>
> -Chris
>
>
>
> Daniel wrote:
> > Hi there,
> >
> > From what I've seen of the Grid so far and what I've been able to
> > deduce from the source code, this has the makings of a great Table
> > extension (of which I am in some need :-P). I can't wait to see some
> > samples. Just out of curiosity, was the screenshot on the Grid homepage
> > actually done using the widget itself, and if so, is that code available
> > anywhere? Thanks so much!
> >
> > - Daniel
> >
|
|
|
Re: Examples [message #3679 is a reply to message #3646] |
Thu, 01 June 2006 09:40   |
Eclipse User |
|
|
|
Those changes definitely sound reasonable. I'll add them to the next
update.
-Chris
Steve Northover wrote:
> Hi Chris,
>
> Some thoughts ...
>
> "Chris Gross" <chris.gross@us.ibm.com> wrote in message
> news:e5k6ec$f07$1@utils.eclipse.org...
>> Yes that picture is definitely the Grid. I don't have that code handy.
>> Its not very exciting code anyway. Generally Grid is designed to
>> match the SWT Table's API. The are differences but rather few. For
>> example, the Grid can function without any selection highlighting and
>> therefore you *must* pass either SWT.SINGLE or SWT.MULTI or no selection
>> highlighting will occur. The normal Table defaults to SWT.SINGLE.
>>
>
> I know this is a better API but given that the native table has shipped and
> doesn't
> work this way means that this sort of difference will be an unexpected
> annoyance.
> A better solution might be to add an API to get rid of the selection. The
> API
> could offer to set the selection mode dynamically or it could just be
> something
> like "setSelectionEnabled()" or something like that.
>
>> Some of the other features visible in that screenshot that might not
>> exist in Table:
>>
>> Column Groups:
>> Create a GridColumnGroup and create columns as children of it. If you
>> want the group to be collapsible, use the SWT.TOGGLE style in the
>> constructor of GridColumnGroup and set the detail/summary properties on
>> the individual columns.
>>
>> Checkboxes in multiple cols:
>> Grid doesn't utilize the SWT.CHECK style in the main constructor, but
>> rather in individual column constructors, allowing checkbox per col.
>>
>
> You might consider supporting the SWT.CHECK in the main constructor
> too, to be compatible. NOTE: If this turns out to be a lot of pain for
> some
> reason, then don't consider it.
>
>> Column spanning:
>> GridItem.setColumnSpan()
>>
>> Hierarchical:
>> Creating items as children of other items as you would with a Tree. Set
>> one column as the 'tree' column (i.e. shows the toggle) by calling
>> GridColumn.setTree(true).
>>
>>
>> There will be examples and snippets (and better javadoc) as the project
>> progresses.
>>
>> -Chris
>>
>>
>>
>> Daniel wrote:
>>> Hi there,
>>>
>>> From what I've seen of the Grid so far and what I've been able to
>>> deduce from the source code, this has the makings of a great Table
>>> extension (of which I am in some need :-P). I can't wait to see some
>>> samples. Just out of curiosity, was the screenshot on the Grid homepage
>>> actually done using the widget itself, and if so, is that code available
>>> anywhere? Thanks so much!
>>>
>>> - Daniel
>>>
>
>
|
|
|
Re: Examples [message #3711 is a reply to message #3679] |
Fri, 02 June 2006 11:19   |
Eclipse User |
|
|
|
Originally posted by: steve_northover.ca.ibm.com
My rule of thumb is that style bits and API that are the same as a similar
control should work the same, even if the new usage is "better" (like your
changes are). Being able to substitute one widget for another or have a new
widget work the same way as one you already understand is valuable. Of
course, common sense overrides everything. For example, if it requires a
ton of code to be compatible or the implementation becomes a nightmare then
the rule goes out the window.
"Chris Gross" <chris.gross@us.ibm.com> wrote in message
news:e5mqo3$jj4$1@utils.eclipse.org...
> Those changes definitely sound reasonable. I'll add them to the next
> update.
>
> -Chris
>
> Steve Northover wrote:
> > Hi Chris,
> >
> > Some thoughts ...
> >
> > "Chris Gross" <chris.gross@us.ibm.com> wrote in message
> > news:e5k6ec$f07$1@utils.eclipse.org...
> >> Yes that picture is definitely the Grid. I don't have that code handy.
> >> Its not very exciting code anyway. Generally Grid is designed to
> >> match the SWT Table's API. The are differences but rather few. For
> >> example, the Grid can function without any selection highlighting and
> >> therefore you *must* pass either SWT.SINGLE or SWT.MULTI or no
selection
> >> highlighting will occur. The normal Table defaults to SWT.SINGLE.
> >>
> >
> > I know this is a better API but given that the native table has shipped
and
> > doesn't
> > work this way means that this sort of difference will be an unexpected
> > annoyance.
> > A better solution might be to add an API to get rid of the selection.
The
> > API
> > could offer to set the selection mode dynamically or it could just be
> > something
> > like "setSelectionEnabled()" or something like that.
> >
> >> Some of the other features visible in that screenshot that might not
> >> exist in Table:
> >>
> >> Column Groups:
> >> Create a GridColumnGroup and create columns as children of it. If you
> >> want the group to be collapsible, use the SWT.TOGGLE style in the
> >> constructor of GridColumnGroup and set the detail/summary properties on
> >> the individual columns.
> >>
> >> Checkboxes in multiple cols:
> >> Grid doesn't utilize the SWT.CHECK style in the main constructor, but
> >> rather in individual column constructors, allowing checkbox per col.
> >>
> >
> > You might consider supporting the SWT.CHECK in the main constructor
> > too, to be compatible. NOTE: If this turns out to be a lot of pain for
> > some
> > reason, then don't consider it.
> >
> >> Column spanning:
> >> GridItem.setColumnSpan()
> >>
> >> Hierarchical:
> >> Creating items as children of other items as you would with a Tree.
Set
> >> one column as the 'tree' column (i.e. shows the toggle) by calling
> >> GridColumn.setTree(true).
> >>
> >>
> >> There will be examples and snippets (and better javadoc) as the project
> >> progresses.
> >>
> >> -Chris
> >>
> >>
> >>
> >> Daniel wrote:
> >>> Hi there,
> >>>
> >>> From what I've seen of the Grid so far and what I've been able to
> >>> deduce from the source code, this has the makings of a great Table
> >>> extension (of which I am in some need :-P). I can't wait to see some
> >>> samples. Just out of curiosity, was the screenshot on the Grid
homepage
> >>> actually done using the widget itself, and if so, is that code
available
> >>> anywhere? Thanks so much!
> >>>
> >>> - Daniel
> >>>
> >
> >
|
|
|
Re: Examples [message #4032 is a reply to message #3711] |
Fri, 02 June 2006 15:26  |
Eclipse User |
|
|
|
Sounds good. Consistency is very valuable and in Nebula we aren't
trying to necessarily invent new paradigms.
-Chris
Steve Northover wrote:
> My rule of thumb is that style bits and API that are the same as a similar
> control should work the same, even if the new usage is "better" (like your
> changes are). Being able to substitute one widget for another or have a new
> widget work the same way as one you already understand is valuable. Of
> course, common sense overrides everything. For example, if it requires a
> ton of code to be compatible or the implementation becomes a nightmare then
> the rule goes out the window.
>
> "Chris Gross" <chris.gross@us.ibm.com> wrote in message
> news:e5mqo3$jj4$1@utils.eclipse.org...
>> Those changes definitely sound reasonable. I'll add them to the next
>> update.
>>
>> -Chris
>>
>> Steve Northover wrote:
>>> Hi Chris,
>>>
>>> Some thoughts ...
>>>
>>> "Chris Gross" <chris.gross@us.ibm.com> wrote in message
>>> news:e5k6ec$f07$1@utils.eclipse.org...
>>>> Yes that picture is definitely the Grid. I don't have that code handy.
>>>> Its not very exciting code anyway. Generally Grid is designed to
>>>> match the SWT Table's API. The are differences but rather few. For
>>>> example, the Grid can function without any selection highlighting and
>>>> therefore you *must* pass either SWT.SINGLE or SWT.MULTI or no
> selection
>>>> highlighting will occur. The normal Table defaults to SWT.SINGLE.
>>>>
>>> I know this is a better API but given that the native table has shipped
> and
>>> doesn't
>>> work this way means that this sort of difference will be an unexpected
>>> annoyance.
>>> A better solution might be to add an API to get rid of the selection.
> The
>>> API
>>> could offer to set the selection mode dynamically or it could just be
>>> something
>>> like "setSelectionEnabled()" or something like that.
>>>
>>>> Some of the other features visible in that screenshot that might not
>>>> exist in Table:
>>>>
>>>> Column Groups:
>>>> Create a GridColumnGroup and create columns as children of it. If you
>>>> want the group to be collapsible, use the SWT.TOGGLE style in the
>>>> constructor of GridColumnGroup and set the detail/summary properties on
>>>> the individual columns.
>>>>
>>>> Checkboxes in multiple cols:
>>>> Grid doesn't utilize the SWT.CHECK style in the main constructor, but
>>>> rather in individual column constructors, allowing checkbox per col.
>>>>
>>> You might consider supporting the SWT.CHECK in the main constructor
>>> too, to be compatible. NOTE: If this turns out to be a lot of pain for
>>> some
>>> reason, then don't consider it.
>>>
>>>> Column spanning:
>>>> GridItem.setColumnSpan()
>>>>
>>>> Hierarchical:
>>>> Creating items as children of other items as you would with a Tree.
> Set
>>>> one column as the 'tree' column (i.e. shows the toggle) by calling
>>>> GridColumn.setTree(true).
>>>>
>>>>
>>>> There will be examples and snippets (and better javadoc) as the project
>>>> progresses.
>>>>
>>>> -Chris
>>>>
>>>>
>>>>
>>>> Daniel wrote:
>>>>> Hi there,
>>>>>
>>>>> From what I've seen of the Grid so far and what I've been able to
>>>>> deduce from the source code, this has the makings of a great Table
>>>>> extension (of which I am in some need :-P). I can't wait to see some
>>>>> samples. Just out of curiosity, was the screenshot on the Grid
> homepage
>>>>> actually done using the widget itself, and if so, is that code
> available
>>>>> anywhere? Thanks so much!
>>>>>
>>>>> - Daniel
>>>>>
>>>
>
>
|
|
|
Re: Examples [message #561435 is a reply to message #2045] |
Wed, 17 May 2006 14:39  |
Eclipse User |
|
|
|
"Grid"-widget-Example: http://www.eclipse.org/nebula
related source is found in cvs
(host: dev.eclipse.org, repository path: /cvsroot/technology, user:
anonymous, con type: pserver)
head: org.eclipse.swt.nebula
michael
"Andrew Elegante" <aelegante@qcomm.com> schrieb im Newsbeitrag
news:3b944325a6fa4b2f0fbbfdf5c8a7f862$1@www.eclipse.org...
> Hi,
>
> I can see from the home page that you have some example code for how to
> use this widget. I have been unsuccessful in trying to find it however
> and was wondering if you could point me in the right direction.
>
> Drew
>
|
|
|
Re: Examples [message #561518 is a reply to message #2045] |
Thu, 18 May 2006 11:13  |
Eclipse User |
|
|
|
Hi Drew,
I hope to have an example plugin soon.
Regards,
-Chris
Andrew Elegante wrote:
> Hi,
>
> I can see from the home page that you have some example code for how to
> use this widget. I have been unsuccessful in trying to find it however
> and was wondering if you could point me in the right direction.
>
> Drew
>
|
|
|
Re: Examples [message #561757 is a reply to message #2060] |
Thu, 25 May 2006 14:46  |
Eclipse User |
|
|
|
Originally posted by: mail.mherbst.de
Hi,
> related source is found in cvs
>
> (host: dev.eclipse.org, repository path: /cvsroot/technology, user:
> anonymous, con type: pserver)
>
> head: org.eclipse.swt.nebula
>
I found the source of the grid in the repository, but no sample code.
Did I overlook something?
Martin
|
|
|
Re: Examples [message #561814 is a reply to message #2113] |
Tue, 30 May 2006 16:14  |
Eclipse User |
|
|
|
Hi there,
From what I've seen of the Grid so far and what I've been able to
deduce from the source code, this has the makings of a great Table
extension (of which I am in some need :-P). I can't wait to see some
samples. Just out of curiosity, was the screenshot on the Grid homepage
actually done using the widget itself, and if so, is that code available
anywhere? Thanks so much!
- Daniel
|
|
|
Re: Examples [message #561835 is a reply to message #3519] |
Wed, 31 May 2006 09:41  |
Eclipse User |
|
|
|
Yes that picture is definitely the Grid. I don't have that code handy.
Its not very exciting code anyway. Generally Grid is designed to
match the SWT Table's API. The are differences but rather few. For
example, the Grid can function without any selection highlighting and
therefore you *must* pass either SWT.SINGLE or SWT.MULTI or no selection
highlighting will occur. The normal Table defaults to SWT.SINGLE.
Some of the other features visible in that screenshot that might not
exist in Table:
Column Groups:
Create a GridColumnGroup and create columns as children of it. If you
want the group to be collapsible, use the SWT.TOGGLE style in the
constructor of GridColumnGroup and set the detail/summary properties on
the individual columns.
Checkboxes in multiple cols:
Grid doesn't utilize the SWT.CHECK style in the main constructor, but
rather in individual column constructors, allowing checkbox per col.
Column spanning:
GridItem.setColumnSpan()
Hierarchical:
Creating items as children of other items as you would with a Tree. Set
one column as the 'tree' column (i.e. shows the toggle) by calling
GridColumn.setTree(true).
There will be examples and snippets (and better javadoc) as the project
progresses.
-Chris
Daniel wrote:
> Hi there,
>
> From what I've seen of the Grid so far and what I've been able to
> deduce from the source code, this has the makings of a great Table
> extension (of which I am in some need :-P). I can't wait to see some
> samples. Just out of curiosity, was the screenshot on the Grid homepage
> actually done using the widget itself, and if so, is that code available
> anywhere? Thanks so much!
>
> - Daniel
>
|
|
|
Re: Examples [message #561904 is a reply to message #3552] |
Wed, 31 May 2006 16:17  |
Eclipse User |
|
|
|
Hi Chris,
Some thoughts ...
"Chris Gross" <chris.gross@us.ibm.com> wrote in message
news:e5k6ec$f07$1@utils.eclipse.org...
> Yes that picture is definitely the Grid. I don't have that code handy.
> Its not very exciting code anyway. Generally Grid is designed to
> match the SWT Table's API. The are differences but rather few. For
> example, the Grid can function without any selection highlighting and
> therefore you *must* pass either SWT.SINGLE or SWT.MULTI or no selection
> highlighting will occur. The normal Table defaults to SWT.SINGLE.
>
I know this is a better API but given that the native table has shipped and
doesn't
work this way means that this sort of difference will be an unexpected
annoyance.
A better solution might be to add an API to get rid of the selection. The
API
could offer to set the selection mode dynamically or it could just be
something
like "setSelectionEnabled()" or something like that.
> Some of the other features visible in that screenshot that might not
> exist in Table:
>
> Column Groups:
> Create a GridColumnGroup and create columns as children of it. If you
> want the group to be collapsible, use the SWT.TOGGLE style in the
> constructor of GridColumnGroup and set the detail/summary properties on
> the individual columns.
>
> Checkboxes in multiple cols:
> Grid doesn't utilize the SWT.CHECK style in the main constructor, but
> rather in individual column constructors, allowing checkbox per col.
>
You might consider supporting the SWT.CHECK in the main constructor
too, to be compatible. NOTE: If this turns out to be a lot of pain for
some
reason, then don't consider it.
> Column spanning:
> GridItem.setColumnSpan()
>
> Hierarchical:
> Creating items as children of other items as you would with a Tree. Set
> one column as the 'tree' column (i.e. shows the toggle) by calling
> GridColumn.setTree(true).
>
>
> There will be examples and snippets (and better javadoc) as the project
> progresses.
>
> -Chris
>
>
>
> Daniel wrote:
> > Hi there,
> >
> > From what I've seen of the Grid so far and what I've been able to
> > deduce from the source code, this has the makings of a great Table
> > extension (of which I am in some need :-P). I can't wait to see some
> > samples. Just out of curiosity, was the screenshot on the Grid homepage
> > actually done using the widget itself, and if so, is that code available
> > anywhere? Thanks so much!
> >
> > - Daniel
> >
|
|
|
Re: Examples [message #561926 is a reply to message #3646] |
Thu, 01 June 2006 09:40  |
Eclipse User |
|
|
|
Those changes definitely sound reasonable. I'll add them to the next
update.
-Chris
Steve Northover wrote:
> Hi Chris,
>
> Some thoughts ...
>
> "Chris Gross" <chris.gross@us.ibm.com> wrote in message
> news:e5k6ec$f07$1@utils.eclipse.org...
>> Yes that picture is definitely the Grid. I don't have that code handy.
>> Its not very exciting code anyway. Generally Grid is designed to
>> match the SWT Table's API. The are differences but rather few. For
>> example, the Grid can function without any selection highlighting and
>> therefore you *must* pass either SWT.SINGLE or SWT.MULTI or no selection
>> highlighting will occur. The normal Table defaults to SWT.SINGLE.
>>
>
> I know this is a better API but given that the native table has shipped and
> doesn't
> work this way means that this sort of difference will be an unexpected
> annoyance.
> A better solution might be to add an API to get rid of the selection. The
> API
> could offer to set the selection mode dynamically or it could just be
> something
> like "setSelectionEnabled()" or something like that.
>
>> Some of the other features visible in that screenshot that might not
>> exist in Table:
>>
>> Column Groups:
>> Create a GridColumnGroup and create columns as children of it. If you
>> want the group to be collapsible, use the SWT.TOGGLE style in the
>> constructor of GridColumnGroup and set the detail/summary properties on
>> the individual columns.
>>
>> Checkboxes in multiple cols:
>> Grid doesn't utilize the SWT.CHECK style in the main constructor, but
>> rather in individual column constructors, allowing checkbox per col.
>>
>
> You might consider supporting the SWT.CHECK in the main constructor
> too, to be compatible. NOTE: If this turns out to be a lot of pain for
> some
> reason, then don't consider it.
>
>> Column spanning:
>> GridItem.setColumnSpan()
>>
>> Hierarchical:
>> Creating items as children of other items as you would with a Tree. Set
>> one column as the 'tree' column (i.e. shows the toggle) by calling
>> GridColumn.setTree(true).
>>
>>
>> There will be examples and snippets (and better javadoc) as the project
>> progresses.
>>
>> -Chris
>>
>>
>>
>> Daniel wrote:
>>> Hi there,
>>>
>>> From what I've seen of the Grid so far and what I've been able to
>>> deduce from the source code, this has the makings of a great Table
>>> extension (of which I am in some need :-P). I can't wait to see some
>>> samples. Just out of curiosity, was the screenshot on the Grid homepage
>>> actually done using the widget itself, and if so, is that code available
>>> anywhere? Thanks so much!
>>>
>>> - Daniel
>>>
>
>
|
|
|
Re: Examples [message #561949 is a reply to message #3679] |
Fri, 02 June 2006 11:19  |
Eclipse User |
|
|
|
My rule of thumb is that style bits and API that are the same as a similar
control should work the same, even if the new usage is "better" (like your
changes are). Being able to substitute one widget for another or have a new
widget work the same way as one you already understand is valuable. Of
course, common sense overrides everything. For example, if it requires a
ton of code to be compatible or the implementation becomes a nightmare then
the rule goes out the window.
"Chris Gross" <chris.gross@us.ibm.com> wrote in message
news:e5mqo3$jj4$1@utils.eclipse.org...
> Those changes definitely sound reasonable. I'll add them to the next
> update.
>
> -Chris
>
> Steve Northover wrote:
> > Hi Chris,
> >
> > Some thoughts ...
> >
> > "Chris Gross" <chris.gross@us.ibm.com> wrote in message
> > news:e5k6ec$f07$1@utils.eclipse.org...
> >> Yes that picture is definitely the Grid. I don't have that code handy.
> >> Its not very exciting code anyway. Generally Grid is designed to
> >> match the SWT Table's API. The are differences but rather few. For
> >> example, the Grid can function without any selection highlighting and
> >> therefore you *must* pass either SWT.SINGLE or SWT.MULTI or no
selection
> >> highlighting will occur. The normal Table defaults to SWT.SINGLE.
> >>
> >
> > I know this is a better API but given that the native table has shipped
and
> > doesn't
> > work this way means that this sort of difference will be an unexpected
> > annoyance.
> > A better solution might be to add an API to get rid of the selection.
The
> > API
> > could offer to set the selection mode dynamically or it could just be
> > something
> > like "setSelectionEnabled()" or something like that.
> >
> >> Some of the other features visible in that screenshot that might not
> >> exist in Table:
> >>
> >> Column Groups:
> >> Create a GridColumnGroup and create columns as children of it. If you
> >> want the group to be collapsible, use the SWT.TOGGLE style in the
> >> constructor of GridColumnGroup and set the detail/summary properties on
> >> the individual columns.
> >>
> >> Checkboxes in multiple cols:
> >> Grid doesn't utilize the SWT.CHECK style in the main constructor, but
> >> rather in individual column constructors, allowing checkbox per col.
> >>
> >
> > You might consider supporting the SWT.CHECK in the main constructor
> > too, to be compatible. NOTE: If this turns out to be a lot of pain for
> > some
> > reason, then don't consider it.
> >
> >> Column spanning:
> >> GridItem.setColumnSpan()
> >>
> >> Hierarchical:
> >> Creating items as children of other items as you would with a Tree.
Set
> >> one column as the 'tree' column (i.e. shows the toggle) by calling
> >> GridColumn.setTree(true).
> >>
> >>
> >> There will be examples and snippets (and better javadoc) as the project
> >> progresses.
> >>
> >> -Chris
> >>
> >>
> >>
> >> Daniel wrote:
> >>> Hi there,
> >>>
> >>> From what I've seen of the Grid so far and what I've been able to
> >>> deduce from the source code, this has the makings of a great Table
> >>> extension (of which I am in some need :-P). I can't wait to see some
> >>> samples. Just out of curiosity, was the screenshot on the Grid
homepage
> >>> actually done using the widget itself, and if so, is that code
available
> >>> anywhere? Thanks so much!
> >>>
> >>> - Daniel
> >>>
> >
> >
|
|
|
Re: Examples [message #561971 is a reply to message #3711] |
Fri, 02 June 2006 15:26  |
Eclipse User |
|
|
|
Sounds good. Consistency is very valuable and in Nebula we aren't
trying to necessarily invent new paradigms.
-Chris
Steve Northover wrote:
> My rule of thumb is that style bits and API that are the same as a similar
> control should work the same, even if the new usage is "better" (like your
> changes are). Being able to substitute one widget for another or have a new
> widget work the same way as one you already understand is valuable. Of
> course, common sense overrides everything. For example, if it requires a
> ton of code to be compatible or the implementation becomes a nightmare then
> the rule goes out the window.
>
> "Chris Gross" <chris.gross@us.ibm.com> wrote in message
> news:e5mqo3$jj4$1@utils.eclipse.org...
>> Those changes definitely sound reasonable. I'll add them to the next
>> update.
>>
>> -Chris
>>
>> Steve Northover wrote:
>>> Hi Chris,
>>>
>>> Some thoughts ...
>>>
>>> "Chris Gross" <chris.gross@us.ibm.com> wrote in message
>>> news:e5k6ec$f07$1@utils.eclipse.org...
>>>> Yes that picture is definitely the Grid. I don't have that code handy.
>>>> Its not very exciting code anyway. Generally Grid is designed to
>>>> match the SWT Table's API. The are differences but rather few. For
>>>> example, the Grid can function without any selection highlighting and
>>>> therefore you *must* pass either SWT.SINGLE or SWT.MULTI or no
> selection
>>>> highlighting will occur. The normal Table defaults to SWT.SINGLE.
>>>>
>>> I know this is a better API but given that the native table has shipped
> and
>>> doesn't
>>> work this way means that this sort of difference will be an unexpected
>>> annoyance.
>>> A better solution might be to add an API to get rid of the selection.
> The
>>> API
>>> could offer to set the selection mode dynamically or it could just be
>>> something
>>> like "setSelectionEnabled()" or something like that.
>>>
>>>> Some of the other features visible in that screenshot that might not
>>>> exist in Table:
>>>>
>>>> Column Groups:
>>>> Create a GridColumnGroup and create columns as children of it. If you
>>>> want the group to be collapsible, use the SWT.TOGGLE style in the
>>>> constructor of GridColumnGroup and set the detail/summary properties on
>>>> the individual columns.
>>>>
>>>> Checkboxes in multiple cols:
>>>> Grid doesn't utilize the SWT.CHECK style in the main constructor, but
>>>> rather in individual column constructors, allowing checkbox per col.
>>>>
>>> You might consider supporting the SWT.CHECK in the main constructor
>>> too, to be compatible. NOTE: If this turns out to be a lot of pain for
>>> some
>>> reason, then don't consider it.
>>>
>>>> Column spanning:
>>>> GridItem.setColumnSpan()
>>>>
>>>> Hierarchical:
>>>> Creating items as children of other items as you would with a Tree.
> Set
>>>> one column as the 'tree' column (i.e. shows the toggle) by calling
>>>> GridColumn.setTree(true).
>>>>
>>>>
>>>> There will be examples and snippets (and better javadoc) as the project
>>>> progresses.
>>>>
>>>> -Chris
>>>>
>>>>
>>>>
>>>> Daniel wrote:
>>>>> Hi there,
>>>>>
>>>>> From what I've seen of the Grid so far and what I've been able to
>>>>> deduce from the source code, this has the makings of a great Table
>>>>> extension (of which I am in some need :-P). I can't wait to see some
>>>>> samples. Just out of curiosity, was the screenshot on the Grid
> homepage
>>>>> actually done using the widget itself, and if so, is that code
> available
>>>>> anywhere? Thanks so much!
>>>>>
>>>>> - Daniel
>>>>>
>>>
>
>
|
|
|
Goto Forum:
Current Time: Thu May 01 08:29:48 EDT 2025
Powered by FUDForum. Page generated in 0.10257 seconds
|