Tables

View: New views
7 Messages — Rating Filter:   Alert me  

Tables

by Q Beukes :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hey,

I'm looking for a way to display tabular data in the explorer.

What I want to do is the following:
1. Have data items (which are object instances)
2. Display each item as a row, with selected properties in columns
3. Have an action item like a button in another column
4. Be able to link this with property sheets. For ex. you double click it and a property view pops up to the left. The property sheet will then display more information, as well as listen for services to provide extra information related to this entity.

I would like to refrain from standard JTables, so I can hook into the NB explorer/nodes api a bit better.

I heard of a tree table, which, as I understand it is the explorer API view on nodes, but displayed in a table. This sounds fine, as I would then only have root nodes to display one level data?

Quintin Beukes

Re: Tables

by Q Beukes :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hey,

I found a component called TableView. Though through extensive google/codesearch and a lot of trying, I can't even instantiate it. 

Can anyone perhaps explain to me how I should use this? How the nodes should be structured, how the table model fits in? I tried making table models that return raw values, properties by row/column, properties by node/property, everything I could think of. I can't even get it to load. It just ends up in an AssertionException.

Any help would be appreciated.

Quintin Beukes


On Sun, Nov 1, 2009 at 12:21 AM, Quintin Beukes <quintin@...> wrote:
Hey,

I'm looking for a way to display tabular data in the explorer.

What I want to do is the following:
1. Have data items (which are object instances)
2. Display each item as a row, with selected properties in columns
3. Have an action item like a button in another column
4. Be able to link this with property sheets. For ex. you double click it and a property view pops up to the left. The property sheet will then display more information, as well as listen for services to provide extra information related to this entity.

I would like to refrain from standard JTables, so I can hook into the NB explorer/nodes api a bit better.

I heard of a tree table, which, as I understand it is the explorer API view on nodes, but displayed in a table. This sounds fine, as I would then only have root nodes to display one level data?

Quintin Beukes


Re: Tables

by Q Beukes :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

OK. I got a TreeTableView going. The normal TableView is still a mystery to me. Though by hiding the root node this seems to do something.

3 questions:
1. How can I hide the first column which displays the node itself
2. All the String fields have a little ellipse button next to it to view the full string. How can I hide this?
3. How do I display custom components in a cell, specifically a JButton.

Thanks,
Quintin Beukes


On Sun, Nov 1, 2009 at 1:38 AM, Quintin Beukes <quintin@...> wrote:
Hey,

I found a component called TableView. Though through extensive google/codesearch and a lot of trying, I can't even instantiate it. 

Can anyone perhaps explain to me how I should use this? How the nodes should be structured, how the table model fits in? I tried making table models that return raw values, properties by row/column, properties by node/property, everything I could think of. I can't even get it to load. It just ends up in an AssertionException.

Any help would be appreciated.

Quintin Beukes



On Sun, Nov 1, 2009 at 12:21 AM, Quintin Beukes <quintin@...> wrote:
Hey,

I'm looking for a way to display tabular data in the explorer.

What I want to do is the following:
1. Have data items (which are object instances)
2. Display each item as a row, with selected properties in columns
3. Have an action item like a button in another column
4. Be able to link this with property sheets. For ex. you double click it and a property view pops up to the left. The property sheet will then display more information, as well as listen for services to provide extra information related to this entity.

I would like to refrain from standard JTables, so I can hook into the NB explorer/nodes api a bit better.

I heard of a tree table, which, as I understand it is the explorer API view on nodes, but displayed in a table. This sounds fine, as I would then only have root nodes to display one level data?

Quintin Beukes



Re: Tables

by Q Beukes :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message


1. How can I hide the first column which displays the node itself
Can't find this, though I guess it's not too critical.
 
2. All the String fields have a little ellipse button next to it to view the full string. How can I hide this.

Found this by returning a generic PropertyEditorSupport for the node property as it's editor.
 
3. How do I display custom components in a cell, specifically a JButton.

For this I was thinking of seeing how existing properties do it. Where can I find the code of the color property editor, like for a components fore/background color? I search on codesearch for the descriptions of these properties, but can't even find them.


Re: Re: Tables

by Florian Brunner :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Yes, I also had problems with TableView. I could instantiate it, but it
behaved strangly. I filed an issue. Please vote for it & add a comment:
http://www.netbeans.org/issues/show_bug.cgi?id=154359

-Florian

Quintin Beukes schrieb:

> Hey,
>
> I found a component called TableView. Though through extensive
> google/codesearch and a lot of trying, I can't even instantiate it.
>
> Can anyone perhaps explain to me how I should use this? How the nodes
> should be structured, how the table model fits in? I tried making
> table models that return raw values, properties by row/column,
> properties by node/property, everything I could think of. I can't even
> get it to load. It just ends up in an AssertionException.
>
> Any help would be appreciated.
>
> Quintin Beukes
>
>
> On Sun, Nov 1, 2009 at 12:21 AM, Quintin Beukes <quintin@...
> <mailto:quintin@...>> wrote:
>
>     Hey,
>
>     I'm looking for a way to display tabular data in the explorer.
>
>     What I want to do is the following:
>     1. Have data items (which are object instances)
>     2. Display each item as a row, with selected properties in columns
>     3. Have an action item like a button in another column
>     4. Be able to link this with property sheets. For ex. you double
>     click it and a property view pops up to the left. The property
>     sheet will then display more information, as well as listen for
>     services to provide extra information related to this entity.
>
>     I would like to refrain from standard JTables, so I can hook into
>     the NB explorer/nodes api a bit better.
>
>     I heard of a tree table, which, as I understand it is the explorer
>     API view on nodes, but displayed in a table. This sounds fine, as
>     I would then only have root nodes to display one level data?
>
>     Quintin Beukes
>
>


Re: Re: Tables

by Quintin Beukes-2 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Does TreeTableView support hiding the first column?

Quintin Beukes


On Mon, Nov 2, 2009 at 12:16 PM, Florian Brunner <fbrunnerlist@...> wrote:
Yes, I also had problems with TableView. I could instantiate it, but it behaved strangly. I filed an issue. Please vote for it & add a comment:
http://www.netbeans.org/issues/show_bug.cgi?id=154359

-Florian

Quintin Beukes schrieb:
Hey,

I found a component called TableView. Though through extensive google/codesearch and a lot of trying, I can't even instantiate it.
Can anyone perhaps explain to me how I should use this? How the nodes should be structured, how the table model fits in? I tried making table models that return raw values, properties by row/column, properties by node/property, everything I could think of. I can't even get it to load. It just ends up in an AssertionException.

Any help would be appreciated.

Quintin Beukes


On Sun, Nov 1, 2009 at 12:21 AM, Quintin Beukes <quintin@... <mailto:quintin@...>> wrote:

   Hey,

   I'm looking for a way to display tabular data in the explorer.

   What I want to do is the following:
   1. Have data items (which are object instances)
   2. Display each item as a row, with selected properties in columns
   3. Have an action item like a button in another column
   4. Be able to link this with property sheets. For ex. you double
   click it and a property view pops up to the left. The property
   sheet will then display more information, as well as listen for
   services to provide extra information related to this entity.

   I would like to refrain from standard JTables, so I can hook into
   the NB explorer/nodes api a bit better.

   I heard of a tree table, which, as I understand it is the explorer
   API view on nodes, but displayed in a table. This sounds fine, as
   I would then only have root nodes to display one level data?

   Quintin Beukes





Re: Re: Tables

by Florian Brunner :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

As far as I know, it doesn't. That's why I ended up with JXTable (SwingX).

-Florian

Quintin Beukes schrieb:

> Does TreeTableView support hiding the first column?
>
> Quintin Beukes
>
>
> On Mon, Nov 2, 2009 at 12:16 PM, Florian Brunner <fbrunnerlist@...
> <mailto:fbrunnerlist@...>> wrote:
>
>     Yes, I also had problems with TableView. I could instantiate it,
>     but it behaved strangly. I filed an issue. Please vote for it &
>     add a comment:
>     http://www.netbeans.org/issues/show_bug.cgi?id=154359
>
>     -Florian
>
>     Quintin Beukes schrieb:
>
>         Hey,
>
>         I found a component called TableView. Though through extensive
>         google/codesearch and a lot of trying, I can't even
>         instantiate it.
>         Can anyone perhaps explain to me how I should use this? How
>         the nodes should be structured, how the table model fits in? I
>         tried making table models that return raw values, properties
>         by row/column, properties by node/property, everything I could
>         think of. I can't even get it to load. It just ends up in an
>         AssertionException.
>
>         Any help would be appreciated.
>
>         Quintin Beukes
>
>
>         On Sun, Nov 1, 2009 at 12:21 AM, Quintin Beukes
>         <quintin@... <mailto:quintin@...>
>         <mailto:quintin@... <mailto:quintin@...>>> wrote:
>
>            Hey,
>
>            I'm looking for a way to display tabular data in the explorer.
>
>            What I want to do is the following:
>            1. Have data items (which are object instances)
>            2. Display each item as a row, with selected properties in
>         columns
>            3. Have an action item like a button in another column
>            4. Be able to link this with property sheets. For ex. you
>         double
>            click it and a property view pops up to the left. The property
>            sheet will then display more information, as well as listen for
>            services to provide extra information related to this entity.
>
>            I would like to refrain from standard JTables, so I can
>         hook into
>            the NB explorer/nodes api a bit better.
>
>            I heard of a tree table, which, as I understand it is the
>         explorer
>            API view on nodes, but displayed in a table. This sounds
>         fine, as
>            I would then only have root nodes to display one level data?
>
>            Quintin Beukes
>
>
>
>