aboutsummaryrefslogtreecommitdiff
path: root/src/client/util/InteractionUtils.tsx
diff options
context:
space:
mode:
authormehekj <mehek.jethani@gmail.com>2021-09-12 12:32:49 -0400
committermehekj <mehek.jethani@gmail.com>2021-09-12 12:32:49 -0400
commitd71bc56628c2193b537b92a186785eaffa3a1eef (patch)
tree0e346527d01ef4d32a28cf9738323c6f49656dfb /src/client/util/InteractionUtils.tsx
parent23db5275a9477d5894e76a2ad6f1795fb0f99b71 (diff)
parent9ac6931dabac40a7e530d144c1d1123548de373f (diff)
Merge branch 'master' into temporalmedia-mehek
Diffstat (limited to 'src/client/util/InteractionUtils.tsx')
-rw-r--r--src/client/util/InteractionUtils.tsx9
1 files changed, 3 insertions, 6 deletions
diff --git a/src/client/util/InteractionUtils.tsx b/src/client/util/InteractionUtils.tsx
index ba935e3bf..8429a806a 100644
--- a/src/client/util/InteractionUtils.tsx
+++ b/src/client/util/InteractionUtils.tsx
@@ -209,8 +209,9 @@ export namespace InteractionUtils {
points={strpts}
style={{
// filter: drawHalo ? "url(#inkSelectionHalo)" : undefined,
- fill: fill ? fill : "none",
- opacity: strokeWidth !== width ? 0.5 : undefined,
+ fill: fill && fill !== "transparent" ? fill : "none",
+ opacity: 1.0,
+ // opacity: strokeWidth !== width ? 0.5 : undefined,
pointerEvents: pevents as any,
stroke: color ?? "rgb(0, 0, 0)",
strokeWidth: strokeWidth,
@@ -299,8 +300,6 @@ export namespace InteractionUtils {
return points;
case "circle":
-
-
const centerX = (Math.max(left, right) + Math.min(left, right)) / 2;
const centerY = (Math.max(top, bottom) + Math.min(top, bottom)) / 2;
const radius = Math.max(centerX - Math.min(left, right), centerY - Math.min(top, bottom));
@@ -315,7 +314,6 @@ export namespace InteractionUtils {
points.push({ X: newX, Y: y });
}
points.push({ X: Math.sqrt(Math.pow(radius, 2) - (Math.pow((Math.min(top, bottom) - centerY), 2))) + centerX, Y: Math.min(top, bottom) });
-
} else {
for (var x = Math.min(left, right); x < Math.max(left, right); x++) {
const y = Math.sqrt(Math.pow(radius, 2) - (Math.pow((x - centerX), 2))) + centerY;
@@ -327,7 +325,6 @@ export namespace InteractionUtils {
points.push({ X: x, Y: newY });
}
points.push({ X: Math.min(left, right), Y: Math.sqrt(Math.pow(radius, 2) - (Math.pow((Math.min(left, right) - centerX), 2))) + centerY });
-
}
return points;
// case "arrow":