Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [sapphire-dev] Questions about hooking up the Properties view to a Node

Hi Brain,

The properties view for the diagram page is sensitive to the selections. If the diagram page is in focus and nothing is seletced on the diagram, it displays the properties page for the diagram. Since you probably don't have properties page defined for the diagram, you'd see "No Properties" in the properties view. Once you select a node in the diagram page, you should see the properties view to change to display the properties for the node. If you selected multiple nodes, then you see "No Properties" again.

The syntax for your composite node properties page seems all right. One thing that is a little odd is

<property>composites</property>

I'd expect your "composites" list property to be "Composites"? 

Shenxue

-----Original Message-----
From: Brian Fitzpatrick [mailto:bfitzpat@xxxxxxxxxx] 
Sent: Wednesday, May 18, 2011 10:55 AM
To: Sapphire project
Subject: [sapphire-dev] Questions about hooking up the Properties view to a Node

Hi all...

So I'm back to seeing how the Graphiti + Properties view hookup works and am running into some issues.

The Architecture example defines one <properties-view> element at the <diagram-page> level:

[code]
        <properties-view>
            <page>
                <label>description</label>
                <content>
                    <property-editor>
                        <property>Description</property>
                        <hint>
                            <name>show.label</name>
                            <value>false</value>
                        </hint>
                        <hint>
                            <name>expand.vertically</name>
                            <value>true</value>
                        </hint>
                    </property-editor>
                </content>
            </page>
        </properties-view>
    </diagram-page>[/code]

And another at the <node> level and another at the <connection-binding> level.

I just have one <properties-view> element defined at the node level and it's not getting hooked up properly:

[code]
    <diagram-page>
        <id>diagram</id>
        <page-name>SwitchyardDiagram</page-name>
        <page-header-text>SwitchYard Diagram</page-header-text>
        <node>
            <id>composites</id>
            <tool-palette-label>composite</tool-palette-label>
            <tool-palette-desc>service composite</tool-palette-desc>
            <property>composites</property>
            <label>${Name == null ? &quot;&lt;composite&gt;&quot; : Name}</label>
            <instance-id>${Name}</instance-id>
            <properties-view>
                <page>
                    <label>Composite Properties</label>
                    <content>
                        <property-editor>
                            <property>Name</property>
                        </property-editor>
                    </content>
                </page>
            </properties-view>
        </node>
        ...
     </diagram-page>
[/code]

Do I need to define the <properties-view> linkage in three different places to get it to show up? Right now where it is I see "No Properties" in the properties view when I hook up my node. I don't really have any properties for the root level diagram element, so defining a page there makes no sense to me. 

Am I looking at this wrong?

Thanks in advance for any guidance. :)

--Fitz

_______________________________
Brian Fitzpatrick (aka "Fitz")
Senior Software Engineer, SOA-P
JBoss by Red Hat

_______________________________________________
sapphire-dev mailing list
sapphire-dev@xxxxxxxxxxx
http://dev.eclipse.org/mailman/listinfo/sapphire-dev


Back to the top