diff options
| author | bobzel <zzzman@gmail.com> | 2021-09-30 13:11:26 -0400 |
|---|---|---|
| committer | bobzel <zzzman@gmail.com> | 2021-09-30 13:11:26 -0400 |
| commit | 4e4a1ec7bb6c479e8fd1b0a7bfe73e2447bafc74 (patch) | |
| tree | 31f3f09e71d837c713c4878aa8507994e4dcaf5c /src/client/views/InkingStroke.tsx | |
| parent | 065e9acb9243b31f0d15498cf9c46539accd593d (diff) | |
fixed creating/drawing straight horizontal/vertical lines. fixed showing proper context menu for ink.
Diffstat (limited to 'src/client/views/InkingStroke.tsx')
| -rw-r--r-- | src/client/views/InkingStroke.tsx | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/client/views/InkingStroke.tsx b/src/client/views/InkingStroke.tsx index 42a09fa52..5438350d8 100644 --- a/src/client/views/InkingStroke.tsx +++ b/src/client/views/InkingStroke.tsx @@ -123,8 +123,8 @@ export class InkingStroke extends ViewBoxBaseComponent<FieldViewProps, InkDocume inkLeft, inkWidth, inkHeight, - inkScaleX: inkHeight === inkStrokeWidth ? 1 : (this.props.PanelWidth() - inkStrokeWidth) / (inkWidth - inkStrokeWidth), - inkScaleY: inkWidth === inkStrokeWidth ? 1 : (this.props.PanelHeight() - inkStrokeWidth) / (inkHeight - inkStrokeWidth) + inkScaleX: ((this.props.PanelWidth() - inkStrokeWidth) / ((inkWidth - inkStrokeWidth) || 1) || 1), + inkScaleY: ((this.props.PanelHeight() - inkStrokeWidth) / ((inkHeight - inkStrokeWidth) || 1) || 1) }; } |
