Skip to main content



      Home
Home » Eclipse Projects » BPMN 2.0 Modeler » how to show the property tab of new elements
how to show the property tab of new elements [message #1218495] Fri, 29 November 2013 04:48 Go to next message
Eclipse UserFriend
Hello,

I am creating an extension for BPMN2 Modeler. The new created elements extend the Group metaclass. These elements have a new attribute, "Importance" and in order to show it in the properties of the elements, I have created a propertyTab (in the Extensions tab of the MANIFEST.MF) for this feature. However, when I run the Plugin project and I create a new BPMN2 Model I get the following error :

"The Property Sheet is empty because the model element "Group" has no visible features
At least one of these element features must be enabled: Importance.
Please configure the Tool Enablement Preferences for this project accordingly"

To create the extension I have been following the CustomTask Example.
- I have create the propertyTab as is indicated in the Example for the "My Event Definition" element
- And I have also enable the object and the feature in the modelEnablement section of the plugin.xml
Someone knows if I have to make any other modification or define other properties?

Thank you very much
Re: how to show the property tab of new elements [message #1219577 is a reply to message #1218495] Wed, 04 December 2013 12:33 Go to previous messageGo to next message
Eclipse UserFriend
In order to display the extension attributes in the Property Tab, you need to add a <modelEnablement> element to your plugin.xml for the new feature, something like this:

	<modelEnablement
			runtimeId="org.my.runtime.id"
			type="Process"
			profile="My Profile">
		<enable object="Group" feature="Importance"/>

	</modelEnablement>


Let me know if you still have problems.

Bob
Re: how to show the property tab of new elements [message #1219676 is a reply to message #1219577] Thu, 05 December 2013 06:09 Go to previous messageGo to next message
Eclipse UserFriend
Thank you very much. It has been very helpful.

The problem was that I did not activate the "Group" object and that I did not create the class NewElementPropertySection. I used the "default" class.

Nevertheless, I have another doubt (I hope this is the last one). When I use the new element (the one extending the Group artifact) in the model, it does not reflect anything special nor different from the standard Groups. For elements extending Tasks or Events, an associated icon is shown, but this icon is not shown for Groups. Is it possible to show a name and change the color of the new created Group in order to be easily recognizable?

Finally, when I create new elements, they are shown two times in the palette. Is there a way to show them only once (the same happens when I deploy the example CustomTask)?
Re: how to show the property tab of new elements [message #1219708 is a reply to message #1219676] Thu, 05 December 2013 08:58 Go to previous messageGo to next message
Eclipse UserFriend
You can change the appearance of the Group figure by overriding decorateShape(IAddContext,ContainerShape,Group) in your AddFeature class. Have a look at the AddGroupFeature to see the default Group rendering.

The duplicate toolpalette entries is a bug Embarrassed but it has been fixed in yesterday's nightly build.
Re: how to show the property tab of new elements [message #1219840 is a reply to message #1219708] Fri, 06 December 2013 03:52 Go to previous message
Eclipse UserFriend
Thank you very much, Bob. All you indications have been very helpful.
Previous Topic:Derive a CategoryValue Ref to the Tasks included in a Group
Next Topic:Old Collaboration diagrams are shown as corrupt
Goto Forum:
  


Current Time: Mon Jul 14 03:36:27 EDT 2025

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

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

Back to the top