From bda82f15f69a3824b333a1397a1cd234917309a4 Mon Sep 17 00:00:00 2001 From: sbosse Date: Mon, 21 Jul 2025 23:40:35 +0200 Subject: [PATCH] Mon 21 Jul 22:43:21 CEST 2025 --- .../src/js/view/mxConnectionConstraint.js | 42 +++++++++++++++++++ 1 file changed, 42 insertions(+) create mode 100644 js/ui/mxgraph/src/js/view/mxConnectionConstraint.js diff --git a/js/ui/mxgraph/src/js/view/mxConnectionConstraint.js b/js/ui/mxgraph/src/js/view/mxConnectionConstraint.js new file mode 100644 index 0000000..c2b0a58 --- /dev/null +++ b/js/ui/mxgraph/src/js/view/mxConnectionConstraint.js @@ -0,0 +1,42 @@ +/** + * Copyright (c) 2006-2015, JGraph Ltd + * Copyright (c) 2006-2015, Gaudenz Alder + */ +/** + * Class: mxConnectionConstraint + * + * Defines an object that contains the constraints about how to connect one + * side of an edge to its terminal. + * + * Constructor: mxConnectionConstraint + * + * Constructs a new connection constraint for the given point and boolean + * arguments. + * + * Parameters: + * + * point - Optional that specifies the fixed location of the point + * in relative coordinates. Default is null. + * perimeter - Optional boolean that specifies if the fixed point should be + * projected onto the perimeter of the terminal. Default is true. + */ +function mxConnectionConstraint(point, perimeter) +{ + this.point = point; + this.perimeter = (perimeter != null) ? perimeter : true; +}; + +/** + * Variable: point + * + * that specifies the fixed location of the connection point. + */ +mxConnectionConstraint.prototype.point = null; + +/** + * Variable: perimeter + * + * Boolean that specifies if the point should be projected onto the perimeter + * of the terminal. + */ +mxConnectionConstraint.prototype.perimeter = null;