java.lang.Object
org.palladiosimulator.editors.sirius.custom.style.styleconfiguration.anchorprovider.PixelOffsetDecorator
All Implemented Interfaces:
org.eclipse.sirius.ext.gmf.runtime.gef.ui.figures.util.AnchorProvider

public class PixelOffsetDecorator extends Object implements org.eclipse.sirius.ext.gmf.runtime.gef.ui.figures.util.AnchorProvider
This is an AnchorProvider which decorates another AnchorProvider with an additional Offset.

It moves the tip of the edges connection 2 PIXELS away from the usually calculated anchorPoint.
This is to cope with the rendered arrow thickness of Sirius, which is 2 PIXELs.
  • Constructor Summary

    Constructors
    Constructor
    Description
    PixelOffsetDecorator(org.eclipse.sirius.ext.gmf.runtime.gef.ui.figures.util.AnchorProvider anchorProvider)
    Creates a new PixelOffsetDecorator.
  • Method Summary

    Modifier and Type
    Method
    Description
    org.eclipse.draw2d.ConnectionAnchor
    createAnchor(org.eclipse.sirius.ext.gmf.runtime.gef.ui.figures.AirDefaultSizeNodeFigure figure, org.eclipse.draw2d.geometry.PrecisionPoint p)
     
    org.eclipse.draw2d.ConnectionAnchor
    createDefaultAnchor(org.eclipse.sirius.ext.gmf.runtime.gef.ui.figures.AirDefaultSizeNodeFigure figure)
     

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • PixelOffsetDecorator

      public PixelOffsetDecorator(org.eclipse.sirius.ext.gmf.runtime.gef.ui.figures.util.AnchorProvider anchorProvider)
      Creates a new PixelOffsetDecorator.
      Parameters:
      anchorProvider - the AnchorProvider which should be decorated
  • Method Details

    • createDefaultAnchor

      public org.eclipse.draw2d.ConnectionAnchor createDefaultAnchor(org.eclipse.sirius.ext.gmf.runtime.gef.ui.figures.AirDefaultSizeNodeFigure figure)
      Specified by:
      createDefaultAnchor in interface org.eclipse.sirius.ext.gmf.runtime.gef.ui.figures.util.AnchorProvider
    • createAnchor

      public org.eclipse.draw2d.ConnectionAnchor createAnchor(org.eclipse.sirius.ext.gmf.runtime.gef.ui.figures.AirDefaultSizeNodeFigure figure, org.eclipse.draw2d.geometry.PrecisionPoint p)
      Specified by:
      createAnchor in interface org.eclipse.sirius.ext.gmf.runtime.gef.ui.figures.util.AnchorProvider