diff options
Diffstat (limited to 'plugins/toolsmiths/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/views/ViewStyles.xtend')
-rw-r--r-- | plugins/toolsmiths/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/views/ViewStyles.xtend | 28 |
1 files changed, 14 insertions, 14 deletions
diff --git a/plugins/toolsmiths/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/views/ViewStyles.xtend b/plugins/toolsmiths/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/views/ViewStyles.xtend index 928ccf14b7c..506090587b7 100644 --- a/plugins/toolsmiths/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/views/ViewStyles.xtend +++ b/plugins/toolsmiths/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/views/ViewStyles.xtend @@ -36,22 +36,22 @@ import xpt.diagram.ViewmapAttributesUtils_qvto override dispatch offset(GenExternalNodeLabel it, String viewVar) ''' - «IF labelOffsetX(viewmap, 0) != 0 || labelOffsetY(viewmap, 0) != 0» - «offset(it,viewVar, labelOffsetX(viewmap, 0), labelOffsetY(viewmap, 0))» - «ELSE» - «offset(it,viewVar, 0, 15)» - «ENDIF» + «IF labelOffsetX(viewmap, 0) != 0 || labelOffsetY(viewmap, 0) != 0» + «offset(it,viewVar, labelOffsetX(viewmap, 0), labelOffsetY(viewmap, 0))» + «ELSE» + «offset(it,viewVar, 0, 15)» + «ENDIF» ''' override def offset(GenLabel it, String viewVar, int x, int y) ''' - «val location = stringUniqueIdentifier.toFirstLower+'_Location'» - org.eclipse.gmf.runtime.notation.Location «location» = (org.eclipse.gmf.runtime.notation.Location) «viewVar».getLayoutConstraint(); - «IF it.getDiagram().isPixelMapMode()» - «location».setX(«x»); - «location».setY(«y»); - «ELSE» - «location».setX(org.eclipse.gmf.runtime.diagram.ui.util.MeasurementUnitHelper.getMapMode(«viewVar».getDiagram().getMeasurementUnit()).DPtoLP(«x»)); - «location».setY(org.eclipse.gmf.runtime.diagram.ui.util.MeasurementUnitHelper.getMapMode(«viewVar».getDiagram().getMeasurementUnit()).DPtoLP(«y»)); - «ENDIF» + «val location = stringUniqueIdentifier.toFirstLower+'_Location'» + org.eclipse.gmf.runtime.notation.Location «location» = (org.eclipse.gmf.runtime.notation.Location) «viewVar».getLayoutConstraint(); + «IF it.getDiagram().isPixelMapMode()» + «location».setX(«x»); + «location».setY(«y»); + «ELSE» + «location».setX(org.eclipse.gmf.runtime.diagram.ui.util.MeasurementUnitHelper.getMapMode(«viewVar».getDiagram().getMeasurementUnit()).DPtoLP(«x»)); + «location».setY(org.eclipse.gmf.runtime.diagram.ui.util.MeasurementUnitHelper.getMapMode(«viewVar».getDiagram().getMeasurementUnit()).DPtoLP(«y»)); + «ENDIF» ''' } |