blob: bbcceecad1f577d66ee4458a2fcc7e926c2a564b (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
|
/******************************************************************************
* Copyright (c) 2006, 2020 Borland Software Corporation, CEA LIST, Artal
*
* All rights reserved. This program and the accompanying materials
* are made available under the terms of the Eclipse Public License 2.0
* which accompanies this distribution, and is available at
* https://www.eclipse.org/legal/epl-2.0/
*
* SPDX-License-Identifier: EPL-2.0
*
* Contributors:
* Artem Tikhomirov (Borland) - initial API and implementation
* Aurelien Didier (ARTAL) - aurelien.didier51@gmail.com - Bug 569174
*****************************************************************************/
«IMPORT 'http://www.eclipse.org/papyrus/gmf/2020/GraphicalDefinition'»
«IMPORT 'http://www.eclipse.org/emf/2002/Ecore'»
«EXTENSION Util»
«REM»Instantiate and define attributes for DecorationFigures«ENDREM»
«DEFINE Instantiate(figureVarName : String) FOR gmfgraph::DecorationFigure-»
«EXPAND Runtime::newInstance(figureVarName)»
«EXPAND Attrs::Init(figureVarName)»
«ENDDEFINE»
«REM»Guess, can't delegate to attrs through Attrs::Init because there's already Init for Polyline«ENDREM»
«DEFINE Instantiate(figureVarName : String) FOR gmfgraph::PolylineDecoration-»
«EXPAND Runtime::newInstance(figureVarName)»
«EXPAND attr::Decoration::polylineAttrs(figureVarName)-»
«ENDDEFINE»
«REM»Copy of above template for PolylineDecoration, just because PolygonDecoration doesn't extend PolylineDecoration in draw2d and gmfgraph«ENDREM»
«DEFINE Instantiate(figureVarName : String) FOR gmfgraph::PolygonDecoration-»
«EXPAND Runtime::newInstance(figureVarName)»
«EXPAND attr::Decoration::polylineAttrs(figureVarName)-»
«ENDDEFINE»
|