]> gerrit.simantics Code Review - simantics/platform.git/blob - bundles/org.simantics.diagram/scl/Simantics/Diagram/ElementTransforms.scl
Duplicate MouseWheelMovedEvent was not actually fixed
[simantics/platform.git] / bundles / org.simantics.diagram / scl / Simantics / Diagram / ElementTransforms.scl
1 module {
2     export = [rotateToNeighborSlope]
3 }
4
5 include "Simantics/DB"
6
7 //-----------------------------------------------------------------------------
8
9 importJava "org.simantics.diagram.elements.ElementTransforms" where
10     """
11         rotateToNeighborSlope element
12     
13     Rotates provided element so that its rotation is the same as the slope of a
14     line drawn between the two other elements the element is connected to.
15     
16     Note that this requires that the element is connected to exactly two other elements.
17     """
18     rotateToNeighborSlope :: Resource -> <WriteGraph, Proc> Double