diff options
| author | bobzel <zzzman@gmail.com> | 2022-05-02 18:38:03 -0400 |
|---|---|---|
| committer | bobzel <zzzman@gmail.com> | 2022-05-02 18:38:03 -0400 |
| commit | a969d0212c69844cbbe82b24f124a496145a1d9b (patch) | |
| tree | 9c4d563da1be74df59ca7605b12b18dbfce9fb5e /src/client/views/InkingStroke.tsx | |
| parent | a2df645d2ffe83be24c20997c26eaf7257e847c0 (diff) | |
disallowed dragging a control point past another control point.
Diffstat (limited to 'src/client/views/InkingStroke.tsx')
| -rw-r--r-- | src/client/views/InkingStroke.tsx | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/client/views/InkingStroke.tsx b/src/client/views/InkingStroke.tsx index 1871ab5a4..5e9990444 100644 --- a/src/client/views/InkingStroke.tsx +++ b/src/client/views/InkingStroke.tsx @@ -335,6 +335,9 @@ export class InkingStroke extends ViewBoxBaseComponent<FieldViewProps>() { markerScale, undefined, inkScaleX, inkScaleY, "", this.props.pointerEvents ?? (this.props.layerProvider?.(this.props.Document) === false ? "none" : "visiblepainted"), 0.0, false, downHdlr); const fsize = +(StrCast(this.props.Document.fontSize, "12px").replace("px", "")); + // bootsrap 3 style sheet sets line height to be 20px for default 14 point font size. + // this attempts to figure out the lineHeight ratio by inquiring the body's lineHeight and dividing by the fontsize which should yield 1.428571429 + // see: https://bibwild.wordpress.com/2019/06/10/bootstrap-3-to-4-changes-in-how-font-size-line-height-and-spacing-is-done-or-what-happened-to-line-height-computed/ const lineHeightGuess = (+getComputedStyle(document.body).lineHeight.replace("px", "")) / (+getComputedStyle(document.body).fontSize.replace("px", "")); const interactions = { onPointerLeave: action(() => this._nearestScrPt = undefined), |
