Java Reference
In-Depth Information
preferred approach. For more information on producing diagrams using the
tooling and extending the generative approach, see Chapter 4 and Chapter 11,
“Graphical Modeling Framework Tooling.”
Figure 10-54
Mindmap generated extension-point contributions
You learned in Section 4.3.5, “Adding Custom Layout,” that it's possible to
extend an existing diagram through the use of a customization plug-in. In this
case, we were able to add a custom layout to our Mindmap diagram, along with
an Insert Subtopic action using standard Eclipse UI contribution techniques. In
Section 4.6.7, “Custom Parsers,” we similarly were able contribute a custom
parser for attributes in our Color Modeling diagram. In this section, we continue
the extension story and demonstrate how to add custom figures to an existing
diagram. Specifically, we add an SVG version of the BPMN Intermediate Event
node for use in our Scenario diagram.
10.9.1 Scenario Diagram Custom View and Edit Providers
We begin by creating a new plug-in project named
org.eclipse.sce-
nario.diagram.custom
in our workspace. Add a dependency to our
org.eclipse.scenario.diagram
plug-in, along with
org.eclipse.
gmf.runtime.diagram.ui
and
org.eclipse.gmf.runtime.draw2d.
ui.render
. To override the default
View
and
EditPart
providers in the
Search WWH ::
Custom Search