diff options
author | bobzel <zzzman@gmail.com> | 2021-11-29 09:22:51 -0500 |
---|---|---|
committer | bobzel <zzzman@gmail.com> | 2021-11-29 09:22:51 -0500 |
commit | 7e6baacfe6c1b55a3fe1807903455f9ff3844d74 (patch) | |
tree | b9fdcf540237be724b540fa8f0b4757efd1ad05c /src/fields/InkField.ts | |
parent | 5acef82a26bbbc237d7dac00061d2ca84e731c68 (diff) | |
parent | 8405ed2e3ebaf7ba7842a5619e9b252bf5eb9c4c (diff) |
Merge branch 'ink_v1'
Diffstat (limited to 'src/fields/InkField.ts')
-rw-r--r-- | src/fields/InkField.ts | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/src/fields/InkField.ts b/src/fields/InkField.ts index f16e143d8..f61313674 100644 --- a/src/fields/InkField.ts +++ b/src/fields/InkField.ts @@ -3,6 +3,8 @@ import { Scripting } from "../client/util/Scripting"; import { Deserializable } from "../client/util/SerializationHelper"; import { Copy, ToScriptString, ToString } from "./FieldSymbols"; import { ObjectField } from "./ObjectField"; +import { DocumentView } from "../client/views/nodes/DocumentView"; +import { Bezier } from "bezier-js"; // Helps keep track of the current ink tool in use. export enum InkTool { @@ -20,6 +22,15 @@ export interface PointData { Y: number; } +export interface Intersection { + t?: number; + ink?: DocumentView; + curve?: Bezier; + index?: number; +} + +export type Segment = Array<Bezier>; + // Defines an ink as an array of points. export type InkData = Array<PointData>; |