@bitbybit-dev/base 1.6.2 → 1.7.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/api/GlobalCDNProvider.js +1 -1
- package/lib/api/inputs/base-inputs.d.ts +20 -7
- package/lib/api/inputs/base-inputs.js +10 -0
- package/lib/api/inputs/io-inputs.d.ts +527 -59
- package/lib/api/inputs/io-inputs.js +432 -40
- package/lib/api/inputs/line-inputs.d.ts +17 -0
- package/lib/api/inputs/line-inputs.js +15 -0
- package/lib/api/kernel-calls/index.d.ts +1 -0
- package/lib/api/kernel-calls/index.js +1 -0
- package/lib/api/kernel-calls/settings.d.ts +82 -0
- package/lib/api/kernel-calls/settings.js +123 -0
- package/lib/api/recipes/surface-mesh.d.ts +2 -1
- package/lib/api/recipes/surface-mesh.js +5 -3
- package/lib/api/resolved-inputs/index.d.ts +22 -2
- package/lib/api/services/base-bitbybit.d.ts +12 -0
- package/lib/api/services/base-bitbybit.js +19 -3
- package/lib/api/services/color.js +2 -3
- package/lib/api/services/helpers/color/color-forms.constants.d.ts +3 -0
- package/lib/api/services/helpers/color/color-forms.constants.js +3 -0
- package/lib/api/services/helpers/color/color-forms.d.ts +1 -0
- package/lib/api/services/helpers/color/color-forms.js +4 -1
- package/lib/api/services/helpers/color/css-colors.constants.d.ts +9 -0
- package/lib/api/services/helpers/color/css-colors.constants.js +158 -0
- package/lib/api/services/helpers/color/css-colors.d.ts +1 -0
- package/lib/api/services/helpers/color/css-colors.js +61 -0
- package/lib/api/services/helpers/curves/bezier-pieces.constants.d.ts +5 -0
- package/lib/api/services/helpers/curves/bezier-pieces.constants.js +5 -0
- package/lib/api/services/helpers/curves/bezier-pieces.d.ts +24 -0
- package/lib/api/services/helpers/curves/bezier-pieces.js +149 -0
- package/lib/api/services/helpers/curves/conic-arcs.constants.d.ts +5 -0
- package/lib/api/services/helpers/curves/conic-arcs.constants.js +5 -0
- package/lib/api/services/helpers/curves/conic-arcs.d.ts +24 -0
- package/lib/api/services/helpers/curves/conic-arcs.js +85 -0
- package/lib/api/services/helpers/curves/nurbs-forms.d.ts +20 -0
- package/lib/api/services/helpers/curves/nurbs-forms.js +112 -0
- package/lib/api/services/helpers/curves/nurbs.d.ts +4 -0
- package/lib/api/services/helpers/curves/nurbs.js +10 -9
- package/lib/api/services/helpers/files/drawing/drawing-budget.d.ts +3 -0
- package/lib/api/services/helpers/files/drawing/drawing-budget.js +24 -0
- package/lib/api/services/helpers/files/drawing/drawing-geometry.d.ts +18 -0
- package/lib/api/services/helpers/files/drawing/drawing-geometry.js +84 -0
- package/lib/api/services/helpers/files/drawing/drawing-model.d.ts +5 -0
- package/lib/api/services/helpers/files/drawing/drawing-model.js +252 -0
- package/lib/api/services/helpers/files/drawing/drawing-types.d.ts +60 -0
- package/lib/api/services/helpers/files/drawing/drawing-types.js +1 -0
- package/lib/api/services/helpers/files/drawing/drawing.constants.d.ts +28 -0
- package/lib/api/services/helpers/files/drawing/drawing.constants.js +29 -0
- package/lib/api/services/helpers/files/dxf/dxf-colors.d.ts +5 -0
- package/lib/api/services/helpers/files/dxf/dxf-colors.js +45 -0
- package/lib/api/services/helpers/files/dxf/dxf-entities.d.ts +17 -0
- package/lib/api/services/helpers/files/dxf/dxf-entities.js +193 -0
- package/lib/api/services/helpers/files/dxf/dxf-file-text.d.ts +1 -0
- package/lib/api/services/helpers/files/dxf/dxf-file-text.js +50 -0
- package/lib/api/services/helpers/files/dxf/dxf-generator.d.ts +2 -36
- package/lib/api/services/helpers/files/dxf/dxf-generator.js +81 -523
- package/lib/api/services/helpers/files/dxf/dxf-reader-dtos.d.ts +6 -0
- package/lib/api/services/helpers/files/dxf/dxf-reader-dtos.js +81 -0
- package/lib/api/services/helpers/files/dxf/dxf-reader-geometry.d.ts +21 -0
- package/lib/api/services/helpers/files/dxf/dxf-reader-geometry.js +67 -0
- package/lib/api/services/helpers/files/dxf/dxf-reader-types.d.ts +69 -0
- package/lib/api/services/helpers/files/dxf/dxf-reader-types.js +1 -0
- package/lib/api/services/helpers/files/dxf/dxf-reader.constants.d.ts +71 -0
- package/lib/api/services/helpers/files/dxf/dxf-reader.constants.js +78 -0
- package/lib/api/services/helpers/files/dxf/dxf-reader.d.ts +2 -0
- package/lib/api/services/helpers/files/dxf/dxf-reader.js +556 -0
- package/lib/api/services/helpers/files/dxf/dxf-tables.d.ts +27 -0
- package/lib/api/services/helpers/files/dxf/dxf-tables.js +247 -0
- package/lib/api/services/helpers/files/dxf/dxf-text.d.ts +26 -0
- package/lib/api/services/helpers/files/dxf/dxf-text.js +97 -0
- package/lib/api/services/helpers/files/dxf/dxf-tokens.d.ts +9 -0
- package/lib/api/services/helpers/files/dxf/dxf-tokens.js +65 -0
- package/lib/api/services/helpers/files/dxf/dxf.constants.d.ts +32 -1
- package/lib/api/services/helpers/files/dxf/dxf.constants.js +34 -1
- package/lib/api/services/helpers/files/file-bytes.d.ts +1 -0
- package/lib/api/services/helpers/files/file-bytes.js +15 -0
- package/lib/api/services/helpers/files/ground-axes.d.ts +2 -0
- package/lib/api/services/helpers/files/ground-axes.js +4 -0
- package/lib/api/services/helpers/files/mesh-file-axes.d.ts +7 -0
- package/lib/api/services/helpers/files/mesh-file-axes.js +17 -0
- package/lib/api/services/helpers/files/stl-axes.d.ts +4 -0
- package/lib/api/services/helpers/files/stl-axes.js +22 -0
- package/lib/api/services/helpers/files/stl-types.d.ts +7 -0
- package/lib/api/services/helpers/files/stl-types.js +1 -0
- package/lib/api/services/helpers/files/stl.constants.d.ts +11 -0
- package/lib/api/services/helpers/files/stl.constants.js +11 -0
- package/lib/api/services/helpers/files/stl.d.ts +3 -0
- package/lib/api/services/helpers/files/stl.js +93 -0
- package/lib/api/services/helpers/files/svg/svg-css.d.ts +48 -0
- package/lib/api/services/helpers/files/svg/svg-css.js +444 -0
- package/lib/api/services/helpers/files/svg/svg-dash-patterns.d.ts +2 -0
- package/lib/api/services/helpers/files/svg/svg-dash-patterns.js +35 -0
- package/lib/api/services/helpers/files/svg/svg-document.d.ts +26 -0
- package/lib/api/services/helpers/files/svg/svg-document.js +89 -0
- package/lib/api/services/helpers/files/svg/svg-memo.d.ts +1 -0
- package/lib/api/services/helpers/files/svg/svg-memo.js +8 -0
- package/lib/api/services/helpers/files/svg/svg-normalizer.d.ts +6 -0
- package/lib/api/services/helpers/files/svg/svg-normalizer.js +433 -0
- package/lib/api/services/helpers/files/svg/svg-numbers.d.ts +15 -0
- package/lib/api/services/helpers/files/svg/svg-numbers.js +61 -0
- package/lib/api/services/helpers/files/svg/svg-path-data.constants.d.ts +8 -0
- package/lib/api/services/helpers/files/svg/svg-path-data.constants.js +10 -0
- package/lib/api/services/helpers/files/svg/svg-path-data.d.ts +9 -0
- package/lib/api/services/helpers/files/svg/svg-path-data.js +203 -0
- package/lib/api/services/helpers/files/svg/svg-path-types.d.ts +33 -0
- package/lib/api/services/helpers/files/svg/svg-path-types.js +1 -0
- package/lib/api/services/helpers/files/svg/svg-reader.constants.d.ts +35 -0
- package/lib/api/services/helpers/files/svg/svg-reader.constants.js +35 -0
- package/lib/api/services/helpers/files/svg/svg-reading.constants.d.ts +9 -0
- package/lib/api/services/helpers/files/svg/svg-reading.constants.js +9 -0
- package/lib/api/services/helpers/files/svg/svg-reading.d.ts +6 -0
- package/lib/api/services/helpers/files/svg/svg-reading.js +233 -0
- package/lib/api/services/helpers/files/svg/svg-scene-types.d.ts +54 -0
- package/lib/api/services/helpers/files/svg/svg-scene-types.js +1 -0
- package/lib/api/services/helpers/files/svg/svg-shapes.d.ts +6 -0
- package/lib/api/services/helpers/files/svg/svg-shapes.js +102 -0
- package/lib/api/services/helpers/files/svg/svg-strokes.d.ts +38 -0
- package/lib/api/services/helpers/files/svg/svg-strokes.js +108 -0
- package/lib/api/services/helpers/files/svg/svg-style.d.ts +26 -0
- package/lib/api/services/helpers/files/svg/svg-style.js +211 -0
- package/lib/api/services/helpers/files/svg/svg-transform.d.ts +10 -0
- package/lib/api/services/helpers/files/svg/svg-transform.js +76 -0
- package/lib/api/services/helpers/files/svg/svg-writer.d.ts +16 -0
- package/lib/api/services/helpers/files/svg/svg-writer.js +153 -0
- package/lib/api/services/helpers/files/svg/svg-xml.d.ts +11 -0
- package/lib/api/services/helpers/files/svg/svg-xml.js +322 -0
- package/lib/api/services/helpers/files/svg/svg.constants.d.ts +13 -0
- package/lib/api/services/helpers/files/svg/svg.constants.js +13 -0
- package/lib/api/services/helpers/files/work-budget.d.ts +11 -0
- package/lib/api/services/helpers/files/work-budget.js +26 -0
- package/lib/api/services/helpers/geometry/affine2.d.ts +8 -0
- package/lib/api/services/helpers/geometry/affine2.js +18 -0
- package/lib/api/services/helpers/geometry/ellipse-arcs.d.ts +14 -0
- package/lib/api/services/helpers/geometry/ellipse-arcs.js +96 -0
- package/lib/api/services/helpers/geometry/frame-axes.d.ts +3 -1
- package/lib/api/services/helpers/geometry/polygon-nesting.constants.d.ts +6 -0
- package/lib/api/services/helpers/geometry/polygon-nesting.constants.js +6 -0
- package/lib/api/services/helpers/geometry/polygon-nesting.d.ts +31 -0
- package/lib/api/services/helpers/geometry/polygon-nesting.js +251 -0
- package/lib/api/services/helpers/geometry/vectors.d.ts +1 -0
- package/lib/api/services/helpers/geometry/vectors.js +6 -0
- package/lib/api/services/io/drawing.d.ts +170 -0
- package/lib/api/services/io/drawing.js +212 -0
- package/lib/api/services/io/dxf.d.ts +134 -0
- package/lib/api/services/io/dxf.js +167 -0
- package/lib/api/services/io/index.d.ts +4 -0
- package/lib/api/services/io/index.js +4 -0
- package/lib/api/services/io/io.d.ts +14 -0
- package/lib/api/services/io/io.js +15 -0
- package/lib/api/services/io/svg.d.ts +64 -0
- package/lib/api/services/io/svg.js +102 -0
- package/lib/api/services/line.d.ts +17 -0
- package/lib/api/services/line.js +20 -1
- package/lib/api/services/point.d.ts +4 -1
- package/lib/api/services/point.js +9 -4
- package/lib/api/services/recipes.d.ts +3 -0
- package/lib/api/services/recipes.js +4 -1
- package/lib/api/services/text.d.ts +4 -1
- package/lib/api/services/text.js +8 -3
- package/package.json +1 -1
- package/lib/api/services/helpers/files/dxf/dxf.d.ts +0 -87
- package/lib/api/services/helpers/files/dxf/dxf.js +0 -111
- package/lib/api/services/io.d.ts +0 -9
- package/lib/api/services/io.js +0 -10
|
@@ -5,164 +5,337 @@ import type { Base } from "./base-inputs";
|
|
|
5
5
|
*/
|
|
6
6
|
export declare namespace IO {
|
|
7
7
|
/**
|
|
8
|
-
*
|
|
8
|
+
* How the lines of a drawing part are drawn: whole, or broken into dashes, the dashes scaled to
|
|
9
|
+
* the drawing's size. DXF writes the matching line type, SVG a dash pattern.
|
|
9
10
|
*/
|
|
10
|
-
|
|
11
|
-
|
|
11
|
+
enum lineTypeEnum {
|
|
12
|
+
continuous = "continuous",
|
|
13
|
+
dashed = "dashed",
|
|
14
|
+
hidden = "hidden",
|
|
15
|
+
center = "center",
|
|
16
|
+
dotted = "dotted"
|
|
17
|
+
}
|
|
18
|
+
/**
|
|
19
|
+
* A straight line in a drawing path, from `start` to `end`. Points may carry a Z coordinate; one
|
|
20
|
+
* without it lies at Z 0.
|
|
21
|
+
*/
|
|
22
|
+
class DrawingLineSegmentDto {
|
|
23
|
+
constructor(start?: Base.Point2 | Base.Point3, end?: Base.Point2 | Base.Point3);
|
|
12
24
|
/**
|
|
13
|
-
*
|
|
25
|
+
* Where the line starts.
|
|
14
26
|
* @default undefined
|
|
15
27
|
*/
|
|
16
|
-
start: Base.Point2;
|
|
28
|
+
start: Base.Point2 | Base.Point3;
|
|
17
29
|
/**
|
|
18
|
-
*
|
|
30
|
+
* Where the line ends.
|
|
19
31
|
* @default undefined
|
|
20
32
|
*/
|
|
21
|
-
end: Base.Point2;
|
|
33
|
+
end: Base.Point2 | Base.Point3;
|
|
22
34
|
}
|
|
23
35
|
/**
|
|
24
|
-
*
|
|
36
|
+
* A circular arc in a drawing path, running counterclockwise from `startAngle` to `endAngle`
|
|
37
|
+
* about its `center`, in the XY plane unless a `normal` tilts it.
|
|
25
38
|
*/
|
|
26
|
-
class
|
|
27
|
-
constructor(center?: Base.Point2, radius?: number, startAngle?: number, endAngle?: number);
|
|
39
|
+
class DrawingArcSegmentDto {
|
|
40
|
+
constructor(center?: Base.Point2 | Base.Point3, radius?: number, startAngle?: number, endAngle?: number, normal?: Base.Vector3);
|
|
28
41
|
/**
|
|
29
|
-
*
|
|
42
|
+
* The center of the arc's circle.
|
|
30
43
|
* @default undefined
|
|
31
44
|
*/
|
|
32
|
-
center: Base.Point2;
|
|
45
|
+
center: Base.Point2 | Base.Point3;
|
|
33
46
|
/**
|
|
34
47
|
* Distance from the center to the arc, in drawing units.
|
|
35
48
|
* @default undefined
|
|
49
|
+
* @minimum 0
|
|
50
|
+
* @exclusiveMinimum true
|
|
36
51
|
*/
|
|
37
52
|
radius: number;
|
|
38
53
|
/**
|
|
39
|
-
*
|
|
54
|
+
* Where the arc starts, in degrees counterclockwise from the X axis (the X axis CAD programs
|
|
55
|
+
* derive from the `normal` when one is given).
|
|
40
56
|
* @default undefined
|
|
41
57
|
*/
|
|
42
58
|
startAngle: number;
|
|
43
59
|
/**
|
|
44
|
-
*
|
|
60
|
+
* Where the arc ends, in degrees; the arc runs counterclockwise from the start, through 0
|
|
61
|
+
* when the end is below the start.
|
|
45
62
|
* @default undefined
|
|
46
63
|
*/
|
|
47
64
|
endAngle: number;
|
|
65
|
+
/**
|
|
66
|
+
* The direction the arc's plane faces, counterclockwise seen from its tip. Leave it out for an
|
|
67
|
+
* arc in the XY plane facing +Z.
|
|
68
|
+
* @default undefined
|
|
69
|
+
* @optional true
|
|
70
|
+
*/
|
|
71
|
+
normal?: Base.Vector3 | undefined;
|
|
48
72
|
}
|
|
49
73
|
/**
|
|
50
|
-
* A full circle in a
|
|
74
|
+
* A full circle in a drawing path, given by its center and radius, in the XY plane unless a
|
|
75
|
+
* `normal` tilts it.
|
|
51
76
|
*/
|
|
52
|
-
class
|
|
53
|
-
constructor(center?: Base.Point2, radius?: number);
|
|
77
|
+
class DrawingCircleSegmentDto {
|
|
78
|
+
constructor(center?: Base.Point2 | Base.Point3, radius?: number, normal?: Base.Vector3);
|
|
54
79
|
/**
|
|
55
|
-
*
|
|
80
|
+
* Where the circle's center lies; without a Z it lies at Z 0.
|
|
56
81
|
* @default undefined
|
|
57
82
|
*/
|
|
58
|
-
center: Base.Point2;
|
|
83
|
+
center: Base.Point2 | Base.Point3;
|
|
59
84
|
/**
|
|
60
85
|
* Distance from the center to the circle, in drawing units.
|
|
61
86
|
* @default undefined
|
|
87
|
+
* @minimum 0
|
|
88
|
+
* @exclusiveMinimum true
|
|
62
89
|
*/
|
|
63
90
|
radius: number;
|
|
91
|
+
/**
|
|
92
|
+
* The direction the circle's plane faces. Leave it out for a circle in the XY plane.
|
|
93
|
+
* @default undefined
|
|
94
|
+
* @optional true
|
|
95
|
+
*/
|
|
96
|
+
normal?: Base.Vector3 | undefined;
|
|
64
97
|
}
|
|
65
98
|
/**
|
|
66
|
-
*
|
|
67
|
-
*
|
|
99
|
+
* Connected straight segments through `points`, each of which a bulge can bend into an arc. A
|
|
100
|
+
* polyline whose points do not all share one Z is written as a 3D polyline, which takes no bulges.
|
|
68
101
|
*/
|
|
69
|
-
class
|
|
70
|
-
constructor(points?: Base.Point2[], closed?: boolean, bulges?: number[]);
|
|
102
|
+
class DrawingPolylineSegmentDto {
|
|
103
|
+
constructor(points?: (Base.Point2 | Base.Point3)[], closed?: boolean, bulges?: number[]);
|
|
71
104
|
/**
|
|
72
|
-
*
|
|
105
|
+
* The vertices, in order. A last point equal to the first closes the polyline as `closed`
|
|
106
|
+
* does.
|
|
73
107
|
* @default undefined
|
|
74
108
|
*/
|
|
75
|
-
points: Base.Point2[];
|
|
109
|
+
points: (Base.Point2 | Base.Point3)[];
|
|
76
110
|
/**
|
|
77
|
-
* Whether the
|
|
111
|
+
* Whether a segment joins the last vertex back to the first.
|
|
78
112
|
* @default false
|
|
79
113
|
*/
|
|
80
114
|
closed?: boolean | undefined;
|
|
81
115
|
/**
|
|
82
|
-
* One
|
|
83
|
-
*
|
|
84
|
-
* only.
|
|
116
|
+
* One per vertex, bending the segment after it into an arc: the tangent of a quarter of its
|
|
117
|
+
* turn, 0 for straight, positive counterclockwise. Left out, every segment is straight.
|
|
85
118
|
* @default undefined
|
|
86
119
|
* @optional true
|
|
87
120
|
*/
|
|
88
121
|
bulges?: number[] | undefined;
|
|
89
122
|
}
|
|
90
123
|
/**
|
|
91
|
-
*
|
|
124
|
+
* A B-spline or NURBS curve in a drawing path, given by its control points, degree and
|
|
125
|
+
* optionally its knots and weights. Without knots the curve starts and ends at its end points.
|
|
92
126
|
*/
|
|
93
|
-
class
|
|
94
|
-
constructor(controlPoints?: Base.Point2[], degree?: number, closed?: boolean);
|
|
127
|
+
class DrawingSplineSegmentDto {
|
|
128
|
+
constructor(controlPoints?: (Base.Point2 | Base.Point3)[], degree?: number, closed?: boolean, knots?: number[], weights?: number[]);
|
|
95
129
|
/**
|
|
96
|
-
*
|
|
130
|
+
* The control points the curve is pulled towards; there must be more of them than the
|
|
131
|
+
* degree.
|
|
97
132
|
* @default undefined
|
|
98
133
|
*/
|
|
99
|
-
controlPoints: Base.Point2[];
|
|
134
|
+
controlPoints: (Base.Point2 | Base.Point3)[];
|
|
100
135
|
/**
|
|
101
|
-
*
|
|
136
|
+
* The degree of the curve: 1 draws the control polygon, 2 and 3 smooth curves.
|
|
102
137
|
* @default 3
|
|
138
|
+
* @minimum 1
|
|
139
|
+
* @maximum Infinity
|
|
140
|
+
* @step 1
|
|
103
141
|
*/
|
|
104
142
|
degree?: number | undefined;
|
|
105
143
|
/**
|
|
106
|
-
*
|
|
144
|
+
* Without `knots`, whether the curve wraps around its control points into a smooth closed
|
|
145
|
+
* loop. With `knots`, the knots decide, and this is ignored.
|
|
107
146
|
* @default false
|
|
108
147
|
*/
|
|
109
148
|
closed?: boolean | undefined;
|
|
149
|
+
/**
|
|
150
|
+
* The full knot vector: never decreasing, one more value than the control points and the
|
|
151
|
+
* degree together. Left out, the curve starts and ends at its end points.
|
|
152
|
+
* @default undefined
|
|
153
|
+
* @optional true
|
|
154
|
+
*/
|
|
155
|
+
knots?: number[] | undefined;
|
|
156
|
+
/**
|
|
157
|
+
* One positive weight per control point, which makes the curve rational (a NURBS curve). Leave
|
|
158
|
+
* it out for a weight of 1 everywhere.
|
|
159
|
+
* @default undefined
|
|
160
|
+
* @optional true
|
|
161
|
+
*/
|
|
162
|
+
weights?: number[] | undefined;
|
|
163
|
+
}
|
|
164
|
+
/**
|
|
165
|
+
* An ellipse or an arc of one in a drawing path: its center, the vector to the end of its major
|
|
166
|
+
* axis and the minor to major ratio, in the XY plane unless `normal` tilts it.
|
|
167
|
+
*/
|
|
168
|
+
class DrawingEllipseSegmentDto {
|
|
169
|
+
constructor(center?: Base.Point2 | Base.Point3, majorAxis?: Base.Vector2 | Base.Vector3, ratio?: number, startParameter?: number, endParameter?: number, normal?: Base.Vector3);
|
|
170
|
+
/**
|
|
171
|
+
* Where the ellipse's center lies; without a Z it lies at Z 0.
|
|
172
|
+
* @default undefined
|
|
173
|
+
*/
|
|
174
|
+
center: Base.Point2 | Base.Point3;
|
|
175
|
+
/**
|
|
176
|
+
* The vector from the center to one end of the major axis; its length is the major radius,
|
|
177
|
+
* in drawing units.
|
|
178
|
+
* @default undefined
|
|
179
|
+
*/
|
|
180
|
+
majorAxis: Base.Vector2 | Base.Vector3;
|
|
181
|
+
/**
|
|
182
|
+
* The minor radius divided by the major radius.
|
|
183
|
+
* @default undefined
|
|
184
|
+
* @minimum 0
|
|
185
|
+
* @maximum 1
|
|
186
|
+
* @exclusiveMinimum true
|
|
187
|
+
*/
|
|
188
|
+
ratio: number;
|
|
189
|
+
/**
|
|
190
|
+
* Where the arc starts, as the ellipse's parameter t in radians (the point center +
|
|
191
|
+
* cos(t) `majorAxis` + sin(t) minor axis), the angle only when `ratio` is 1.
|
|
192
|
+
* @default 0
|
|
193
|
+
* @minimum -Infinity
|
|
194
|
+
* @maximum Infinity
|
|
195
|
+
*/
|
|
196
|
+
startParameter?: number | undefined;
|
|
197
|
+
/**
|
|
198
|
+
* Where the arc ends, as the same parameter in radians; the arc runs counterclockwise from the
|
|
199
|
+
* start, through 0 when the end is below the start.
|
|
200
|
+
* @default 6.283185307179586
|
|
201
|
+
* @minimum -Infinity
|
|
202
|
+
* @maximum Infinity
|
|
203
|
+
*/
|
|
204
|
+
endParameter?: number | undefined;
|
|
205
|
+
/**
|
|
206
|
+
* The direction the ellipse's plane faces, perpendicular to `majorAxis`. Leave it out for an
|
|
207
|
+
* ellipse in the XY plane facing +Z.
|
|
208
|
+
* @default undefined
|
|
209
|
+
* @optional true
|
|
210
|
+
*/
|
|
211
|
+
normal?: Base.Vector3 | undefined;
|
|
110
212
|
}
|
|
111
213
|
/**
|
|
112
|
-
* A path
|
|
113
|
-
*
|
|
214
|
+
* A path of a drawing: segments of any kind (lines, arcs, circles, polylines, splines and
|
|
215
|
+
* ellipses), in the order they are drawn, like the edges of a wire.
|
|
114
216
|
*/
|
|
115
|
-
class
|
|
116
|
-
constructor(segments?: (
|
|
217
|
+
class DrawingPathDto {
|
|
218
|
+
constructor(segments?: (DrawingLineSegmentDto | DrawingArcSegmentDto | DrawingCircleSegmentDto | DrawingPolylineSegmentDto | DrawingSplineSegmentDto | DrawingEllipseSegmentDto)[]);
|
|
117
219
|
/**
|
|
118
|
-
*
|
|
119
|
-
*
|
|
220
|
+
* The segments of the path, in order; where one ends at the next one's start, SVG draws them
|
|
221
|
+
* as one stroke.
|
|
120
222
|
* @default undefined
|
|
121
223
|
*/
|
|
122
|
-
segments: (
|
|
224
|
+
segments: (DrawingLineSegmentDto | DrawingArcSegmentDto | DrawingCircleSegmentDto | DrawingPolylineSegmentDto | DrawingSplineSegmentDto | DrawingEllipseSegmentDto)[];
|
|
123
225
|
}
|
|
124
226
|
/**
|
|
125
|
-
* A part
|
|
227
|
+
* A part of a drawing: paths drawn on one layer with one color and one line type, which
|
|
228
|
+
* `io.dxf.dxfCreate` writes as DXF and `io.svg.svgCreate` as SVG.
|
|
126
229
|
*/
|
|
127
|
-
class
|
|
128
|
-
constructor(layer?: string, color?: Base.Color, paths?:
|
|
230
|
+
class DrawingPartDto {
|
|
231
|
+
constructor(layer?: string, color?: Base.Color, paths?: DrawingPathDto[], lineType?: lineTypeEnum);
|
|
129
232
|
/**
|
|
130
|
-
*
|
|
233
|
+
* The layer the paths go on. Parts may share a layer, which takes the first part's color and
|
|
234
|
+
* line type; every part's paths keep their own.
|
|
131
235
|
* @default Default
|
|
132
236
|
*/
|
|
133
237
|
layer?: string | undefined;
|
|
134
238
|
/**
|
|
135
|
-
*
|
|
239
|
+
* The color of every path in the part, as a hex string such as `#000000`.
|
|
136
240
|
* @default #000000
|
|
137
241
|
*/
|
|
138
242
|
color?: Base.Color | undefined;
|
|
139
243
|
/**
|
|
140
|
-
*
|
|
244
|
+
* The paths of the part, each a run of segments.
|
|
141
245
|
* @default undefined
|
|
142
246
|
*/
|
|
143
|
-
paths:
|
|
247
|
+
paths: DrawingPathDto[];
|
|
248
|
+
/**
|
|
249
|
+
* Whether the lines are whole or dashed, such as `hidden` for edges a view cannot see.
|
|
250
|
+
* @default continuous
|
|
251
|
+
*/
|
|
252
|
+
lineType?: lineTypeEnum | undefined;
|
|
253
|
+
}
|
|
254
|
+
/**
|
|
255
|
+
* A straight line in a drawing path, under its former DXF name.
|
|
256
|
+
*
|
|
257
|
+
* @deprecated Use `DrawingLineSegmentDto`, the same DTO under the drawing's own name; this one is removed
|
|
258
|
+
* in the next major version.
|
|
259
|
+
*/
|
|
260
|
+
class DxfLineSegmentDto extends DrawingLineSegmentDto {
|
|
261
|
+
}
|
|
262
|
+
/**
|
|
263
|
+
* A circular arc in a drawing path, under its former DXF name.
|
|
264
|
+
*
|
|
265
|
+
* @deprecated Use `DrawingArcSegmentDto`, the same DTO under the drawing's own name; this one is removed
|
|
266
|
+
* in the next major version.
|
|
267
|
+
*/
|
|
268
|
+
class DxfArcSegmentDto extends DrawingArcSegmentDto {
|
|
269
|
+
}
|
|
270
|
+
/**
|
|
271
|
+
* A full circle in a drawing path, under its former DXF name.
|
|
272
|
+
*
|
|
273
|
+
* @deprecated Use `DrawingCircleSegmentDto`, the same DTO under the drawing's own name; this one is removed
|
|
274
|
+
* in the next major version.
|
|
275
|
+
*/
|
|
276
|
+
class DxfCircleSegmentDto extends DrawingCircleSegmentDto {
|
|
277
|
+
}
|
|
278
|
+
/**
|
|
279
|
+
* Connected straight segments in a drawing path, under its former DXF name.
|
|
280
|
+
*
|
|
281
|
+
* @deprecated Use `DrawingPolylineSegmentDto`, the same DTO under the drawing's own name; this one is removed
|
|
282
|
+
* in the next major version.
|
|
283
|
+
*/
|
|
284
|
+
class DxfPolylineSegmentDto extends DrawingPolylineSegmentDto {
|
|
285
|
+
}
|
|
286
|
+
/**
|
|
287
|
+
* A B-spline or NURBS curve in a drawing path, under its former DXF name.
|
|
288
|
+
*
|
|
289
|
+
* @deprecated Use `DrawingSplineSegmentDto`, the same DTO under the drawing's own name; this one is removed
|
|
290
|
+
* in the next major version.
|
|
291
|
+
*/
|
|
292
|
+
class DxfSplineSegmentDto extends DrawingSplineSegmentDto {
|
|
293
|
+
}
|
|
294
|
+
/**
|
|
295
|
+
* An ellipse or an arc of one in a drawing path, under its former DXF name.
|
|
296
|
+
*
|
|
297
|
+
* @deprecated Use `DrawingEllipseSegmentDto`, the same DTO under the drawing's own name; this one is removed
|
|
298
|
+
* in the next major version.
|
|
299
|
+
*/
|
|
300
|
+
class DxfEllipseSegmentDto extends DrawingEllipseSegmentDto {
|
|
301
|
+
}
|
|
302
|
+
/**
|
|
303
|
+
* A path of a drawing, under its former DXF name.
|
|
304
|
+
*
|
|
305
|
+
* @deprecated Use `DrawingPathDto`, the same DTO under the drawing's own name; this one is removed
|
|
306
|
+
* in the next major version.
|
|
307
|
+
*/
|
|
308
|
+
class DxfPathDto extends DrawingPathDto {
|
|
309
|
+
}
|
|
310
|
+
/**
|
|
311
|
+
* A part of a drawing: paths on one layer with one color and one line type, under its former DXF name.
|
|
312
|
+
*
|
|
313
|
+
* @deprecated Use `DrawingPartDto`, the same DTO under the drawing's own name; this one is removed
|
|
314
|
+
* in the next major version.
|
|
315
|
+
*/
|
|
316
|
+
class DxfPathsPartDto extends DrawingPartDto {
|
|
144
317
|
}
|
|
145
318
|
/**
|
|
146
|
-
* A whole DXF drawing
|
|
147
|
-
* write.
|
|
319
|
+
* A whole DXF drawing for `io.dxf.dxfCreate`: its path parts by layer and color, and the color
|
|
320
|
+
* format, the version and the unit to write.
|
|
148
321
|
*/
|
|
149
322
|
class DxfModelDto {
|
|
150
|
-
constructor(dxfPathsParts?:
|
|
323
|
+
constructor(dxfPathsParts?: DrawingPartDto[], colorFormat?: "aci" | "truecolor", acadVersion?: "AC1009" | "AC1015", unit?: Base.unitOfLengthEnum, curveTolerance?: number);
|
|
151
324
|
/**
|
|
152
325
|
* Array of path parts, each containing paths with segments
|
|
153
326
|
* @default undefined
|
|
154
327
|
*/
|
|
155
|
-
dxfPathsParts:
|
|
328
|
+
dxfPathsParts: DrawingPartDto[];
|
|
156
329
|
/**
|
|
157
|
-
* How colors are written: `aci`, the AutoCAD
|
|
158
|
-
*
|
|
330
|
+
* How colors are written: `aci`, the nearest of AutoCAD's 255 index colors, or `truecolor`,
|
|
331
|
+
* the exact color beside that index (`AC1015` only; `AC1009` writes the index).
|
|
159
332
|
* @default aci
|
|
160
333
|
*/
|
|
161
334
|
colorFormat?: "aci" | "truecolor" | undefined;
|
|
162
335
|
/**
|
|
163
|
-
* The DXF version
|
|
164
|
-
*
|
|
165
|
-
* @default
|
|
336
|
+
* The DXF version: `AC1015` (AutoCAD 2000), which keeps splines and ellipses exact, or `AC1009`
|
|
337
|
+
* (AutoCAD R12) for old software, where they become polylines within `curveTolerance`.
|
|
338
|
+
* @default AC1015
|
|
166
339
|
*/
|
|
167
340
|
acadVersion?: "AC1009" | "AC1015" | undefined;
|
|
168
341
|
/**
|
|
@@ -172,5 +345,300 @@ export declare namespace IO {
|
|
|
172
345
|
* @optional true
|
|
173
346
|
*/
|
|
174
347
|
unit?: Base.unitOfLengthEnum | undefined;
|
|
348
|
+
/**
|
|
349
|
+
* The largest distance, in drawing units, between a curve and the polyline that stands in for
|
|
350
|
+
* it where the version cannot hold the curve exactly.
|
|
351
|
+
* @default 0.01
|
|
352
|
+
* @minimum 0
|
|
353
|
+
* @exclusiveMinimum true
|
|
354
|
+
*/
|
|
355
|
+
curveTolerance?: number | undefined;
|
|
356
|
+
}
|
|
357
|
+
/**
|
|
358
|
+
* The text of a DXF file for `io.dxf.dxfRead`, which reads its drawing into path parts, and
|
|
359
|
+
* whether layers that are switched off or frozen are read too.
|
|
360
|
+
*/
|
|
361
|
+
class DxfReadDto {
|
|
362
|
+
constructor(dxf?: string | Uint8Array, includeHiddenLayers?: boolean);
|
|
363
|
+
/**
|
|
364
|
+
* An ASCII DXF file from R12 on, as text or bytes; older bytes not in UTF-8 are read in the
|
|
365
|
+
* header's code page, or as Windows-1252.
|
|
366
|
+
* @default undefined
|
|
367
|
+
*/
|
|
368
|
+
dxf: string | Uint8Array;
|
|
369
|
+
/**
|
|
370
|
+
* When true, layers the file has switched off or frozen are read as well.
|
|
371
|
+
* @default false
|
|
372
|
+
*/
|
|
373
|
+
includeHiddenLayers?: boolean | undefined;
|
|
374
|
+
}
|
|
375
|
+
/**
|
|
376
|
+
* A drawing read from a DXF file by `io.dxf.dxfRead`: its parts by layer, color and line type, in
|
|
377
|
+
* the shape `io.dxf.dxfCreate` and `io.svg.svgCreate` write, with the unit and what was left out.
|
|
378
|
+
*/
|
|
379
|
+
class DxfDrawingDto {
|
|
380
|
+
/**
|
|
381
|
+
* The parts, one for each layer, color and line type that holds anything, each entity one path.
|
|
382
|
+
* @default undefined
|
|
383
|
+
*/
|
|
384
|
+
parts: DrawingPartDto[];
|
|
385
|
+
/**
|
|
386
|
+
* The unit the file states, when it is one of millimetres, centimetres, metres or inches.
|
|
387
|
+
* @default undefined
|
|
388
|
+
* @optional true
|
|
389
|
+
*/
|
|
390
|
+
unit?: Base.unitOfLengthEnum | undefined;
|
|
391
|
+
/**
|
|
392
|
+
* The DXF version the file states, such as `AC1015`, or an empty text when it states none.
|
|
393
|
+
* @default undefined
|
|
394
|
+
*/
|
|
395
|
+
version: string;
|
|
396
|
+
/**
|
|
397
|
+
* What was left out and why, each kind once with its count.
|
|
398
|
+
* @default undefined
|
|
399
|
+
*/
|
|
400
|
+
warnings: string[];
|
|
401
|
+
}
|
|
402
|
+
/**
|
|
403
|
+
* A whole SVG drawing for `io.svg.svgCreate`: its path parts by layer, color and line type, the
|
|
404
|
+
* unit that gives it its true size, and how wide the lines and the border are.
|
|
405
|
+
*/
|
|
406
|
+
class SvgModelDto {
|
|
407
|
+
constructor(parts?: DrawingPartDto[], unit?: Base.unitOfLengthEnum, strokeWidth?: number, margin?: number, tolerance?: number);
|
|
408
|
+
/**
|
|
409
|
+
* The parts of the drawing; each layer becomes a group that Inkscape reads as a layer.
|
|
410
|
+
* @default undefined
|
|
411
|
+
*/
|
|
412
|
+
parts: DrawingPartDto[];
|
|
413
|
+
/**
|
|
414
|
+
* The unit the drawing is in, which gives the file its true width and height. Left out, the
|
|
415
|
+
* file states no size and viewers fit it to the window.
|
|
416
|
+
* @default undefined
|
|
417
|
+
* @optional true
|
|
418
|
+
*/
|
|
419
|
+
unit?: Base.unitOfLengthEnum | undefined;
|
|
420
|
+
/**
|
|
421
|
+
* How wide the lines are, in drawing units. Left out, a five-hundredth of the drawing's larger
|
|
422
|
+
* side.
|
|
423
|
+
* @default undefined
|
|
424
|
+
* @optional true
|
|
425
|
+
* @minimum 0
|
|
426
|
+
* @exclusiveMinimum true
|
|
427
|
+
*/
|
|
428
|
+
strokeWidth?: number | undefined;
|
|
429
|
+
/**
|
|
430
|
+
* The empty border around the drawing, in drawing units. Left out, a fortieth of the
|
|
431
|
+
* drawing's larger side.
|
|
432
|
+
* @default undefined
|
|
433
|
+
* @optional true
|
|
434
|
+
* @minimum 0
|
|
435
|
+
*/
|
|
436
|
+
margin?: number | undefined;
|
|
437
|
+
/**
|
|
438
|
+
* The largest distance, in drawing units, between a curve SVG cannot draw exactly (a rational
|
|
439
|
+
* or higher degree spline) and the cubic curves that stand in for it.
|
|
440
|
+
* @default 0.01
|
|
441
|
+
* @minimum 0
|
|
442
|
+
* @exclusiveMinimum true
|
|
443
|
+
*/
|
|
444
|
+
tolerance?: number | undefined;
|
|
445
|
+
}
|
|
446
|
+
/**
|
|
447
|
+
* One drawing path for `io.svg.pathData`, and how its coordinates are written.
|
|
448
|
+
*/
|
|
449
|
+
class SvgPathDataDto {
|
|
450
|
+
constructor(path?: DrawingPathDto, flipY?: boolean, tolerance?: number);
|
|
451
|
+
/**
|
|
452
|
+
* The path to write as SVG path data.
|
|
453
|
+
* @default undefined
|
|
454
|
+
*/
|
|
455
|
+
path: DrawingPathDto;
|
|
456
|
+
/**
|
|
457
|
+
* Whether Y is negated, as an SVG file needs (its Y runs down); leave it off for data drawn
|
|
458
|
+
* inside a group that flips Y itself.
|
|
459
|
+
* @default true
|
|
460
|
+
*/
|
|
461
|
+
flipY?: boolean | undefined;
|
|
462
|
+
/**
|
|
463
|
+
* The largest distance, in drawing units, between a curve SVG cannot draw exactly and the
|
|
464
|
+
* cubic curves that stand in for it.
|
|
465
|
+
* @default 0.01
|
|
466
|
+
* @minimum 0
|
|
467
|
+
* @exclusiveMinimum true
|
|
468
|
+
*/
|
|
469
|
+
tolerance?: number | undefined;
|
|
470
|
+
}
|
|
471
|
+
/**
|
|
472
|
+
* The text of an SVG file for `io.svg.svgRead`, which reads its drawing into path parts, with the
|
|
473
|
+
* unit that brings it in at true size and whether hidden elements are read too.
|
|
474
|
+
*/
|
|
475
|
+
class SvgReadDto {
|
|
476
|
+
constructor(svg?: string, unit?: Base.unitOfLengthEnum, includeInvisible?: boolean);
|
|
477
|
+
/**
|
|
478
|
+
* The whole text of an SVG file.
|
|
479
|
+
* @default undefined
|
|
480
|
+
*/
|
|
481
|
+
svg: string;
|
|
482
|
+
/**
|
|
483
|
+
* The unit to read the drawing in at its true size, with the page's top left corner at the
|
|
484
|
+
* origin. Left out, coordinates stay in the file's own user units.
|
|
485
|
+
* @default undefined
|
|
486
|
+
* @optional true
|
|
487
|
+
*/
|
|
488
|
+
unit?: Base.unitOfLengthEnum | undefined;
|
|
489
|
+
/**
|
|
490
|
+
* When true, elements hidden by `display` or `visibility` are read as well.
|
|
491
|
+
* @default false
|
|
492
|
+
*/
|
|
493
|
+
includeInvisible?: boolean | undefined;
|
|
494
|
+
}
|
|
495
|
+
/**
|
|
496
|
+
* A drawing read from an SVG file by `io.svg.svgRead`: its parts by layer, color and line type, in
|
|
497
|
+
* the shape `io.dxf.dxfCreate` and `io.svg.svgCreate` write, with the unit, the view box and what
|
|
498
|
+
* was left out.
|
|
499
|
+
*/
|
|
500
|
+
class SvgDrawingDto {
|
|
501
|
+
/**
|
|
502
|
+
* The parts, one for each layer, color and line type that holds anything, each subpath one path.
|
|
503
|
+
* @default undefined
|
|
504
|
+
*/
|
|
505
|
+
parts: DrawingPartDto[];
|
|
506
|
+
/**
|
|
507
|
+
* The unit the drawing was read in, when one was asked for.
|
|
508
|
+
* @default undefined
|
|
509
|
+
* @optional true
|
|
510
|
+
*/
|
|
511
|
+
unit?: Base.unitOfLengthEnum | undefined;
|
|
512
|
+
/**
|
|
513
|
+
* The view box the file gives its root, as x, y, width and height in the file's own
|
|
514
|
+
* coordinates, where Y runs down.
|
|
515
|
+
* @default undefined
|
|
516
|
+
* @optional true
|
|
517
|
+
*/
|
|
518
|
+
viewBox?: number[] | undefined;
|
|
519
|
+
/**
|
|
520
|
+
* What was left out or read differently and why, each kind once with its count.
|
|
521
|
+
* @default undefined
|
|
522
|
+
*/
|
|
523
|
+
warnings: string[];
|
|
524
|
+
}
|
|
525
|
+
/**
|
|
526
|
+
* An SVG file for `io.drawing.svgToDxf`, which reads it as `io.svg.svgRead` does and writes it as
|
|
527
|
+
* `io.dxf.dxfCreate` does, with the options of both.
|
|
528
|
+
*/
|
|
529
|
+
class SvgToDxfDto {
|
|
530
|
+
constructor(svg?: string, unit?: Base.unitOfLengthEnum, includeInvisible?: boolean, colorFormat?: "aci" | "truecolor", acadVersion?: "AC1009" | "AC1015", curveTolerance?: number);
|
|
531
|
+
/**
|
|
532
|
+
* The whole text of an SVG file.
|
|
533
|
+
* @default undefined
|
|
534
|
+
*/
|
|
535
|
+
svg: string;
|
|
536
|
+
/**
|
|
537
|
+
* The unit to read the drawing in at true size, also stated in the DXF (`AC1015` only). Left
|
|
538
|
+
* out, user units are written and no unit is stated.
|
|
539
|
+
* @default undefined
|
|
540
|
+
* @optional true
|
|
541
|
+
*/
|
|
542
|
+
unit?: Base.unitOfLengthEnum | undefined;
|
|
543
|
+
/**
|
|
544
|
+
* When true, elements hidden by `display` or `visibility` are written as well.
|
|
545
|
+
* @default false
|
|
546
|
+
*/
|
|
547
|
+
includeInvisible?: boolean | undefined;
|
|
548
|
+
/**
|
|
549
|
+
* How colors are written: `aci`, the nearest of AutoCAD's 255 index colors, or `truecolor`,
|
|
550
|
+
* the exact color beside that index (`AC1015` only; `AC1009` writes the index).
|
|
551
|
+
* @default aci
|
|
552
|
+
*/
|
|
553
|
+
colorFormat?: "aci" | "truecolor" | undefined;
|
|
554
|
+
/**
|
|
555
|
+
* The DXF version: `AC1015` (AutoCAD 2000), which keeps splines and ellipses exact, or `AC1009`
|
|
556
|
+
* (AutoCAD R12) for old software, where they become polylines within `curveTolerance`.
|
|
557
|
+
* @default AC1015
|
|
558
|
+
*/
|
|
559
|
+
acadVersion?: "AC1009" | "AC1015" | undefined;
|
|
560
|
+
/**
|
|
561
|
+
* The largest distance, in drawing units, between a curve and the polyline that stands in for
|
|
562
|
+
* it where the version cannot hold the curve exactly.
|
|
563
|
+
* @default 0.01
|
|
564
|
+
* @minimum 0
|
|
565
|
+
* @exclusiveMinimum true
|
|
566
|
+
*/
|
|
567
|
+
curveTolerance?: number | undefined;
|
|
568
|
+
}
|
|
569
|
+
/**
|
|
570
|
+
* What `io.drawing.svgToDxf` returns: the DXF file it wrote from an SVG file, and what the
|
|
571
|
+
* reading left out or read differently.
|
|
572
|
+
*/
|
|
573
|
+
class SvgToDxfResultDto {
|
|
574
|
+
/**
|
|
575
|
+
* The DXF file as text.
|
|
576
|
+
* @default undefined
|
|
577
|
+
*/
|
|
578
|
+
dxf: string;
|
|
579
|
+
/**
|
|
580
|
+
* What was left out or read differently and why, each kind once with its count.
|
|
581
|
+
* @default undefined
|
|
582
|
+
*/
|
|
583
|
+
warnings: string[];
|
|
584
|
+
}
|
|
585
|
+
/**
|
|
586
|
+
* A DXF file for `io.drawing.dxfToSvg`, which reads it as `io.dxf.dxfRead` does and writes it as
|
|
587
|
+
* `io.svg.svgCreate` does, with the options of both.
|
|
588
|
+
*/
|
|
589
|
+
class DxfToSvgDto {
|
|
590
|
+
constructor(dxf?: string | Uint8Array, includeHiddenLayers?: boolean, strokeWidth?: number, margin?: number, tolerance?: number);
|
|
591
|
+
/**
|
|
592
|
+
* An ASCII DXF file from R12 on, as text or bytes; older bytes not in UTF-8 are read in the
|
|
593
|
+
* header's code page, or as Windows-1252.
|
|
594
|
+
* @default undefined
|
|
595
|
+
*/
|
|
596
|
+
dxf: string | Uint8Array;
|
|
597
|
+
/**
|
|
598
|
+
* When true, layers the file has switched off or frozen are written as well.
|
|
599
|
+
* @default false
|
|
600
|
+
*/
|
|
601
|
+
includeHiddenLayers?: boolean | undefined;
|
|
602
|
+
/**
|
|
603
|
+
* How wide the lines are, in drawing units. Left out, a five-hundredth of the drawing's larger
|
|
604
|
+
* side.
|
|
605
|
+
* @default undefined
|
|
606
|
+
* @optional true
|
|
607
|
+
* @minimum 0
|
|
608
|
+
* @exclusiveMinimum true
|
|
609
|
+
*/
|
|
610
|
+
strokeWidth?: number | undefined;
|
|
611
|
+
/**
|
|
612
|
+
* The empty border around the drawing, in drawing units. Left out, a fortieth of the
|
|
613
|
+
* drawing's larger side.
|
|
614
|
+
* @default undefined
|
|
615
|
+
* @optional true
|
|
616
|
+
* @minimum 0
|
|
617
|
+
*/
|
|
618
|
+
margin?: number | undefined;
|
|
619
|
+
/**
|
|
620
|
+
* The largest distance, in drawing units, between a curve SVG cannot draw exactly (a rational
|
|
621
|
+
* or higher degree spline) and the cubic curves that stand in for it.
|
|
622
|
+
* @default 0.01
|
|
623
|
+
* @minimum 0
|
|
624
|
+
* @exclusiveMinimum true
|
|
625
|
+
*/
|
|
626
|
+
tolerance?: number | undefined;
|
|
627
|
+
}
|
|
628
|
+
/**
|
|
629
|
+
* What `io.drawing.dxfToSvg` returns: the SVG file it wrote from a DXF file, and what the reading
|
|
630
|
+
* left out.
|
|
631
|
+
*/
|
|
632
|
+
class DxfToSvgResultDto {
|
|
633
|
+
/**
|
|
634
|
+
* The SVG file as text.
|
|
635
|
+
* @default undefined
|
|
636
|
+
*/
|
|
637
|
+
svg: string;
|
|
638
|
+
/**
|
|
639
|
+
* What was left out and why, each kind once with its count.
|
|
640
|
+
* @default undefined
|
|
641
|
+
*/
|
|
642
|
+
warnings: string[];
|
|
175
643
|
}
|
|
176
644
|
}
|