@leapfrog/interactive-canvas 2.0.15 → 2.0.16
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/dist/abstract-interactive-canvas.d.ts +375 -375
- package/dist/dimensions/millimeter-dimensions.d.ts +15 -15
- package/dist/dimensions/pixel-canvas-dimensions.d.ts +13 -13
- package/dist/dimensions/print-6-col-canvas-dimensions.d.ts +18 -18
- package/dist/dimensions/print-8-col-canvas-dimensions.d.ts +18 -18
- package/dist/font/font-library.d.ts +27 -27
- package/dist/font/font-library.interface.d.ts +24 -24
- package/dist/font/font.interface.d.ts +20 -20
- package/dist/font/unknown-font.d.ts +6 -6
- package/dist/headless-interactive-canvas.d.ts +10 -10
- package/dist/index.d.ts +54 -54
- package/dist/interactive-canvas.d.ts +25 -25
- package/dist/interactive-canvas.es.js +3855 -3864
- package/dist/interactive-canvas.interface.d.ts +297 -297
- package/dist/interactive-canvas.js +3855 -3868
- package/dist/layout/abstract-layout-manager.d.ts +17 -17
- package/dist/layout/advanced-layout-manager.d.ts +16 -16
- package/dist/layout/function/pin-to-bottom.layout-function.d.ts +4 -4
- package/dist/layout/function/redraw-all.layout-function.d.ts +4 -4
- package/dist/layout/function/reposition-backgrounds.layout-function.d.ts +4 -4
- package/dist/layout/function/reposition-borders.layout-function.d.ts +4 -4
- package/dist/layout/function/reposition-cutoffs.layout-function.d.ts +4 -4
- package/dist/layout/function/resize-canvas.layout-function.d.ts +4 -4
- package/dist/layout/function/stack-objects.layout-function.d.ts +11 -11
- package/dist/layout/function/update-object-dimensions.layout-function.d.ts +4 -4
- package/dist/layout/layout-manager.enum.d.ts +5 -5
- package/dist/layout/layout-manager.interface.d.ts +13 -13
- package/dist/layout/standard-layout-manager.d.ts +40 -40
- package/dist/mutator/mutable-background-color.interface.d.ts +15 -15
- package/dist/mutator/mutable-color.interface.d.ts +6 -6
- package/dist/mutator/mutable-image.interface.d.ts +28 -28
- package/dist/mutator/mutable-position.interface.d.ts +63 -63
- package/dist/mutator/mutable-stroke.interface.d.ts +8 -8
- package/dist/mutator/mutable-text-style.interface.d.ts +163 -163
- package/dist/mutator/mutable-text.interface.d.ts +80 -80
- package/dist/object/abstract-canvas-object.d.ts +207 -207
- package/dist/object/canvas-object-data.d.ts +24 -24
- package/dist/object/canvas-object.interface.d.ts +109 -109
- package/dist/object/impl/background-image.d.ts +38 -38
- package/dist/object/impl/border.d.ts +70 -70
- package/dist/object/impl/cutoff.d.ts +59 -59
- package/dist/object/impl/extended-fabric-object.interface.d.ts +7 -7
- package/dist/object/impl/extended-fabric-textbox.interface.d.ts +7 -7
- package/dist/object/impl/horizontal-rule.d.ts +83 -83
- package/dist/object/impl/image.d.ts +76 -76
- package/dist/object/impl/rectangle.d.ts +78 -78
- package/dist/object/impl/rich-text.d.ts +39 -39
- package/dist/object/impl/text.d.ts +322 -322
- package/dist/object/impl/vertical-rule.d.ts +83 -83
- package/dist/profile/canvas-profile.interface.d.ts +22 -22
- package/dist/profile/default-canvas-profile.d.ts +23 -23
- package/dist/types/canvas-dimension-restrictions.interface.d.ts +15 -15
- package/dist/types/canvas-dimensions.interface.d.ts +21 -21
- package/dist/types/canvas-state.interface.d.ts +11 -11
- package/dist/types/dimension-restrictions.interface.d.ts +6 -6
- package/dist/types/image-type.enum.d.ts +6 -6
- package/dist/types/margin.interface.d.ts +6 -6
- package/dist/types/object-dimensions.interface.d.ts +23 -23
- package/dist/types/object-type.enum.d.ts +12 -12
- package/dist/types/overflow.interface.d.ts +4 -4
- package/dist/types/position.interface.d.ts +9 -9
- package/dist/types/rect.interface.d.ts +6 -6
- package/dist/types/selection-data.interface.d.ts +28 -28
- package/dist/types/text-alignment.interface.d.ts +1 -1
- package/dist/undo-stack.d.ts +27 -27
- package/dist/undo-stack.interface.d.ts +6 -6
- package/package.json +1 -1
|
@@ -1,322 +1,322 @@
|
|
|
1
|
-
import { Observable } from "rxjs";
|
|
2
|
-
import { IFont } from "../../font/font.interface";
|
|
3
|
-
import { IInteractiveCanvas } from "../../interactive-canvas.interface";
|
|
4
|
-
import { IMutableBackgroundColor } from "../../mutator/mutable-background-color.interface";
|
|
5
|
-
import { IMutableColor } from "../../mutator/mutable-color.interface";
|
|
6
|
-
import { IMutableText } from "../../mutator/mutable-text.interface";
|
|
7
|
-
import { IMutableTextStyle } from "../../mutator/mutable-text-style.interface";
|
|
8
|
-
import { ITextSelection } from "../../mutator/mutable-text-style.interface";
|
|
9
|
-
import { IMutablePosition } from "../../mutator/mutable-position.interface";
|
|
10
|
-
import { TextAlignment } from "../../types/text-alignment.interface";
|
|
11
|
-
import { ICanvasObject } from "../canvas-object.interface";
|
|
12
|
-
import { AbstractCanvasObject } from "../abstract-canvas-object";
|
|
13
|
-
import { CanvasObjectData } from "../canvas-object-data";
|
|
14
|
-
import { fabric } from "fabric";
|
|
15
|
-
import { ExtendedFabricTextbox } from "./extended-fabric-textbox.interface";
|
|
16
|
-
/**
|
|
17
|
-
* Text field. Displays customizable text.
|
|
18
|
-
*/
|
|
19
|
-
export interface IText extends ICanvasObject, IMutableColor, IMutableText, IMutableTextStyle, IMutablePosition, IMutableBackgroundColor {
|
|
20
|
-
/**
|
|
21
|
-
* @return Whether this text object should resize the canvas.
|
|
22
|
-
*/
|
|
23
|
-
isResizeCanvas(): boolean;
|
|
24
|
-
/**
|
|
25
|
-
* Set whether this text object should resize the canvas.
|
|
26
|
-
*/
|
|
27
|
-
setResizeCanvas(value: boolean): void;
|
|
28
|
-
/**
|
|
29
|
-
* Focus input on the text object.
|
|
30
|
-
*/
|
|
31
|
-
focus(): void;
|
|
32
|
-
/**
|
|
33
|
-
* @return Is the text box currently being edited.
|
|
34
|
-
*/
|
|
35
|
-
isEditing(): boolean;
|
|
36
|
-
/**
|
|
37
|
-
* Start editing the text.
|
|
38
|
-
*/
|
|
39
|
-
enterEditing(): void;
|
|
40
|
-
/**
|
|
41
|
-
* Select all text.
|
|
42
|
-
*/
|
|
43
|
-
selectAllText(): void;
|
|
44
|
-
/**
|
|
45
|
-
* Set the prefill type used for this text field.
|
|
46
|
-
*/
|
|
47
|
-
setPrefillType(prefillType: string): void;
|
|
48
|
-
/**
|
|
49
|
-
* Get the prefill type used for this text field.
|
|
50
|
-
*/
|
|
51
|
-
getPrefillType(): string;
|
|
52
|
-
/**
|
|
53
|
-
* Return the margin needed for bullets on this object.
|
|
54
|
-
*/
|
|
55
|
-
getBulletMargin(): number;
|
|
56
|
-
/**
|
|
57
|
-
* Return the margin needed for ordered lists on this object.
|
|
58
|
-
*/
|
|
59
|
-
getOrderedListMargin(): number;
|
|
60
|
-
}
|
|
61
|
-
export declare class Text extends AbstractCanvasObject<ExtendedFabricTextbox> implements IText {
|
|
62
|
-
private readonly fontLibrary;
|
|
63
|
-
private baseComponentHeight;
|
|
64
|
-
private readonly text$;
|
|
65
|
-
private readonly textSelection$;
|
|
66
|
-
constructor(canvas: IInteractiveCanvas, fabricObject: fabric.Textbox, persistedField?: CanvasObjectData);
|
|
67
|
-
/**
|
|
68
|
-
* @override
|
|
69
|
-
* @inheritDoc
|
|
70
|
-
*/
|
|
71
|
-
getText(): string;
|
|
72
|
-
/**
|
|
73
|
-
* @override
|
|
74
|
-
* @inheritDoc
|
|
75
|
-
*/
|
|
76
|
-
getText$(): Observable<string>;
|
|
77
|
-
/**
|
|
78
|
-
* @override
|
|
79
|
-
* @inheritDoc
|
|
80
|
-
*/
|
|
81
|
-
setText(text: string): void;
|
|
82
|
-
/**
|
|
83
|
-
* @override
|
|
84
|
-
* @inheritDoc
|
|
85
|
-
*/
|
|
86
|
-
replaceText(target: string, replacement: string): void;
|
|
87
|
-
/**
|
|
88
|
-
* @override
|
|
89
|
-
* @inheritDoc
|
|
90
|
-
*/
|
|
91
|
-
insertText(text: string, style?: any[], start?: number, end?: number): void;
|
|
92
|
-
/**
|
|
93
|
-
* @override
|
|
94
|
-
* @inheritDoc
|
|
95
|
-
*/
|
|
96
|
-
insertTextAtSelection(text: string, style?: any[]): void;
|
|
97
|
-
/**
|
|
98
|
-
* @override
|
|
99
|
-
* @inheritDoc
|
|
100
|
-
*/
|
|
101
|
-
getColor(): string;
|
|
102
|
-
/**
|
|
103
|
-
* @override
|
|
104
|
-
* @inheritDoc
|
|
105
|
-
*/
|
|
106
|
-
setColor(color: string): void;
|
|
107
|
-
/**
|
|
108
|
-
* @override
|
|
109
|
-
* @inheritDoc
|
|
110
|
-
*/
|
|
111
|
-
getTextSelection(): ITextSelection;
|
|
112
|
-
/**
|
|
113
|
-
* @override
|
|
114
|
-
* @inheritDoc
|
|
115
|
-
*/
|
|
116
|
-
getTextSelection$(): Observable<ITextSelection>;
|
|
117
|
-
/**
|
|
118
|
-
* @override
|
|
119
|
-
* @inheritDoc
|
|
120
|
-
*/
|
|
121
|
-
setTextAlign(alignment: TextAlignment): void;
|
|
122
|
-
/**
|
|
123
|
-
* @override
|
|
124
|
-
* @inheritDoc
|
|
125
|
-
*/
|
|
126
|
-
setCharSpacing(spacing: number): void;
|
|
127
|
-
/**
|
|
128
|
-
* @override
|
|
129
|
-
* @inheritDoc
|
|
130
|
-
*/
|
|
131
|
-
setLineHeight(height: number): void;
|
|
132
|
-
/**
|
|
133
|
-
* @override
|
|
134
|
-
* @inheritDoc
|
|
135
|
-
*/
|
|
136
|
-
setBold(bold?: boolean): void;
|
|
137
|
-
/**
|
|
138
|
-
* @override
|
|
139
|
-
* @inheritDoc
|
|
140
|
-
*/
|
|
141
|
-
setBoldRegion(start: number, end: number, bold?: boolean): void;
|
|
142
|
-
/**
|
|
143
|
-
* @override
|
|
144
|
-
* @inheritDoc
|
|
145
|
-
*/
|
|
146
|
-
setItalic(italic?: boolean): void;
|
|
147
|
-
/**
|
|
148
|
-
* @override
|
|
149
|
-
* @inheritDoc
|
|
150
|
-
*/
|
|
151
|
-
setItalicRegion(start: number, end: number, italic?: boolean): void;
|
|
152
|
-
/**
|
|
153
|
-
* @override
|
|
154
|
-
* @inheritDoc
|
|
155
|
-
*/
|
|
156
|
-
setStrikethrough(strikethrough?: boolean): void;
|
|
157
|
-
/**
|
|
158
|
-
* @override
|
|
159
|
-
* @inheritDoc
|
|
160
|
-
*/
|
|
161
|
-
setUnderline(underline?: boolean): void;
|
|
162
|
-
/**
|
|
163
|
-
* @override
|
|
164
|
-
* @inheritDoc
|
|
165
|
-
*/
|
|
166
|
-
setFont(font: IFont): void;
|
|
167
|
-
/**
|
|
168
|
-
* @override
|
|
169
|
-
* @inheritDoc
|
|
170
|
-
*/
|
|
171
|
-
setFontSize(fontSize: number): void;
|
|
172
|
-
/**
|
|
173
|
-
* @override
|
|
174
|
-
* @inheritDoc
|
|
175
|
-
*/
|
|
176
|
-
setTextBackgroundColor(color: string): void;
|
|
177
|
-
/**
|
|
178
|
-
* @override
|
|
179
|
-
* @inheritDoc
|
|
180
|
-
*/
|
|
181
|
-
centerHorizontally(): void;
|
|
182
|
-
/**
|
|
183
|
-
* @override
|
|
184
|
-
* @inheritDoc
|
|
185
|
-
*/
|
|
186
|
-
centerVertically(): void;
|
|
187
|
-
/**
|
|
188
|
-
* @override
|
|
189
|
-
* @inheritDoc
|
|
190
|
-
*/
|
|
191
|
-
nudgeUp(): void;
|
|
192
|
-
/**
|
|
193
|
-
* @override
|
|
194
|
-
* @inheritDoc
|
|
195
|
-
*/
|
|
196
|
-
nudgeDown(): void;
|
|
197
|
-
/**
|
|
198
|
-
* @override
|
|
199
|
-
* @inheritDoc
|
|
200
|
-
*/
|
|
201
|
-
nudgeLeft(): void;
|
|
202
|
-
/**
|
|
203
|
-
* @override
|
|
204
|
-
* @inheritDoc
|
|
205
|
-
*/
|
|
206
|
-
nudgeRight(): void;
|
|
207
|
-
/**
|
|
208
|
-
* @override
|
|
209
|
-
* @inheritDoc
|
|
210
|
-
*/
|
|
211
|
-
getBackgroundColor(): string;
|
|
212
|
-
/**
|
|
213
|
-
* @override
|
|
214
|
-
* @inheritDoc
|
|
215
|
-
*/
|
|
216
|
-
setBackgroundColor(color: string): void;
|
|
217
|
-
/**
|
|
218
|
-
* @override
|
|
219
|
-
* @inheritDoc
|
|
220
|
-
*/
|
|
221
|
-
setPrefillType(prefillType: string): void;
|
|
222
|
-
/**
|
|
223
|
-
* @override
|
|
224
|
-
* @inheritDoc
|
|
225
|
-
*/
|
|
226
|
-
getPrefillType(): string;
|
|
227
|
-
/**
|
|
228
|
-
* @override
|
|
229
|
-
* @inheritDoc
|
|
230
|
-
*/
|
|
231
|
-
getBulletMargin(): number;
|
|
232
|
-
/**
|
|
233
|
-
* @override
|
|
234
|
-
* @inheritDoc
|
|
235
|
-
*/
|
|
236
|
-
getOrderedListMargin(): number;
|
|
237
|
-
/**
|
|
238
|
-
* @override
|
|
239
|
-
* @inheritDoc
|
|
240
|
-
*/
|
|
241
|
-
isResizeCanvas(): boolean;
|
|
242
|
-
/**
|
|
243
|
-
* @override
|
|
244
|
-
* @inheritDoc
|
|
245
|
-
*/
|
|
246
|
-
setResizeCanvas(value: boolean): void;
|
|
247
|
-
/**
|
|
248
|
-
* @override
|
|
249
|
-
* @inheritDoc
|
|
250
|
-
*/
|
|
251
|
-
focus(): void;
|
|
252
|
-
/**
|
|
253
|
-
* @override
|
|
254
|
-
* @inheritDoc
|
|
255
|
-
*/
|
|
256
|
-
isEditing(): boolean;
|
|
257
|
-
/**
|
|
258
|
-
* @override
|
|
259
|
-
* @inheritDoc
|
|
260
|
-
*/
|
|
261
|
-
enterEditing(): void;
|
|
262
|
-
/**
|
|
263
|
-
* @override
|
|
264
|
-
* @inheritDoc
|
|
265
|
-
*/
|
|
266
|
-
selectAllText(): void;
|
|
267
|
-
/**
|
|
268
|
-
* @override
|
|
269
|
-
* @inheritDoc
|
|
270
|
-
*/
|
|
271
|
-
isBulleted(): boolean;
|
|
272
|
-
/**
|
|
273
|
-
* @override
|
|
274
|
-
* @inheritDoc
|
|
275
|
-
*/
|
|
276
|
-
enableBullets(): void;
|
|
277
|
-
/**
|
|
278
|
-
* @override
|
|
279
|
-
* @inheritDoc
|
|
280
|
-
*/
|
|
281
|
-
disableBullets(): void;
|
|
282
|
-
/**
|
|
283
|
-
* @override
|
|
284
|
-
* @inheritDoc
|
|
285
|
-
*/
|
|
286
|
-
isOrderedList(): boolean;
|
|
287
|
-
/**
|
|
288
|
-
* @override
|
|
289
|
-
* @inheritDoc
|
|
290
|
-
*/
|
|
291
|
-
enableOrderedList(): void;
|
|
292
|
-
/**
|
|
293
|
-
* @override
|
|
294
|
-
* @inheritDoc
|
|
295
|
-
*/
|
|
296
|
-
disableOrderedList(): void;
|
|
297
|
-
/**
|
|
298
|
-
* @override
|
|
299
|
-
* @inheritDoc
|
|
300
|
-
*/
|
|
301
|
-
setOrderedListStart(start: number): void;
|
|
302
|
-
/**
|
|
303
|
-
* @override
|
|
304
|
-
* @inheritDoc
|
|
305
|
-
*/
|
|
306
|
-
getOrderedListStart(): number;
|
|
307
|
-
getSizeIncreaseSinceCreation(): number;
|
|
308
|
-
private removeBullets;
|
|
309
|
-
private removeOrderedListMarkers;
|
|
310
|
-
private applyBulletListMonkeyPatches;
|
|
311
|
-
/**
|
|
312
|
-
* @override
|
|
313
|
-
* @inheritDoc
|
|
314
|
-
*/
|
|
315
|
-
protected updateFabricObjectBehavior(): void;
|
|
316
|
-
protected onTextChange(): void;
|
|
317
|
-
protected onDelete(): void;
|
|
318
|
-
protected onSelectionChange(): void;
|
|
319
|
-
private hasTextSelection;
|
|
320
|
-
private updateTextSelection;
|
|
321
|
-
private notifyCanvasOfTextChanges;
|
|
322
|
-
}
|
|
1
|
+
import { Observable } from "rxjs";
|
|
2
|
+
import { IFont } from "../../font/font.interface";
|
|
3
|
+
import { IInteractiveCanvas } from "../../interactive-canvas.interface";
|
|
4
|
+
import { IMutableBackgroundColor } from "../../mutator/mutable-background-color.interface";
|
|
5
|
+
import { IMutableColor } from "../../mutator/mutable-color.interface";
|
|
6
|
+
import { IMutableText } from "../../mutator/mutable-text.interface";
|
|
7
|
+
import { IMutableTextStyle } from "../../mutator/mutable-text-style.interface";
|
|
8
|
+
import { ITextSelection } from "../../mutator/mutable-text-style.interface";
|
|
9
|
+
import { IMutablePosition } from "../../mutator/mutable-position.interface";
|
|
10
|
+
import { TextAlignment } from "../../types/text-alignment.interface";
|
|
11
|
+
import { ICanvasObject } from "../canvas-object.interface";
|
|
12
|
+
import { AbstractCanvasObject } from "../abstract-canvas-object";
|
|
13
|
+
import { CanvasObjectData } from "../canvas-object-data";
|
|
14
|
+
import { fabric } from "fabric";
|
|
15
|
+
import { ExtendedFabricTextbox } from "./extended-fabric-textbox.interface";
|
|
16
|
+
/**
|
|
17
|
+
* Text field. Displays customizable text.
|
|
18
|
+
*/
|
|
19
|
+
export interface IText extends ICanvasObject, IMutableColor, IMutableText, IMutableTextStyle, IMutablePosition, IMutableBackgroundColor {
|
|
20
|
+
/**
|
|
21
|
+
* @return Whether this text object should resize the canvas.
|
|
22
|
+
*/
|
|
23
|
+
isResizeCanvas(): boolean;
|
|
24
|
+
/**
|
|
25
|
+
* Set whether this text object should resize the canvas.
|
|
26
|
+
*/
|
|
27
|
+
setResizeCanvas(value: boolean): void;
|
|
28
|
+
/**
|
|
29
|
+
* Focus input on the text object.
|
|
30
|
+
*/
|
|
31
|
+
focus(): void;
|
|
32
|
+
/**
|
|
33
|
+
* @return Is the text box currently being edited.
|
|
34
|
+
*/
|
|
35
|
+
isEditing(): boolean;
|
|
36
|
+
/**
|
|
37
|
+
* Start editing the text.
|
|
38
|
+
*/
|
|
39
|
+
enterEditing(): void;
|
|
40
|
+
/**
|
|
41
|
+
* Select all text.
|
|
42
|
+
*/
|
|
43
|
+
selectAllText(): void;
|
|
44
|
+
/**
|
|
45
|
+
* Set the prefill type used for this text field.
|
|
46
|
+
*/
|
|
47
|
+
setPrefillType(prefillType: string): void;
|
|
48
|
+
/**
|
|
49
|
+
* Get the prefill type used for this text field.
|
|
50
|
+
*/
|
|
51
|
+
getPrefillType(): string;
|
|
52
|
+
/**
|
|
53
|
+
* Return the margin needed for bullets on this object.
|
|
54
|
+
*/
|
|
55
|
+
getBulletMargin(): number;
|
|
56
|
+
/**
|
|
57
|
+
* Return the margin needed for ordered lists on this object.
|
|
58
|
+
*/
|
|
59
|
+
getOrderedListMargin(): number;
|
|
60
|
+
}
|
|
61
|
+
export declare class Text extends AbstractCanvasObject<ExtendedFabricTextbox> implements IText {
|
|
62
|
+
private readonly fontLibrary;
|
|
63
|
+
private baseComponentHeight;
|
|
64
|
+
private readonly text$;
|
|
65
|
+
private readonly textSelection$;
|
|
66
|
+
constructor(canvas: IInteractiveCanvas, fabricObject: fabric.Textbox, persistedField?: CanvasObjectData);
|
|
67
|
+
/**
|
|
68
|
+
* @override
|
|
69
|
+
* @inheritDoc
|
|
70
|
+
*/
|
|
71
|
+
getText(): string;
|
|
72
|
+
/**
|
|
73
|
+
* @override
|
|
74
|
+
* @inheritDoc
|
|
75
|
+
*/
|
|
76
|
+
getText$(): Observable<string>;
|
|
77
|
+
/**
|
|
78
|
+
* @override
|
|
79
|
+
* @inheritDoc
|
|
80
|
+
*/
|
|
81
|
+
setText(text: string): void;
|
|
82
|
+
/**
|
|
83
|
+
* @override
|
|
84
|
+
* @inheritDoc
|
|
85
|
+
*/
|
|
86
|
+
replaceText(target: string, replacement: string): void;
|
|
87
|
+
/**
|
|
88
|
+
* @override
|
|
89
|
+
* @inheritDoc
|
|
90
|
+
*/
|
|
91
|
+
insertText(text: string, style?: any[], start?: number, end?: number): void;
|
|
92
|
+
/**
|
|
93
|
+
* @override
|
|
94
|
+
* @inheritDoc
|
|
95
|
+
*/
|
|
96
|
+
insertTextAtSelection(text: string, style?: any[]): void;
|
|
97
|
+
/**
|
|
98
|
+
* @override
|
|
99
|
+
* @inheritDoc
|
|
100
|
+
*/
|
|
101
|
+
getColor(): string;
|
|
102
|
+
/**
|
|
103
|
+
* @override
|
|
104
|
+
* @inheritDoc
|
|
105
|
+
*/
|
|
106
|
+
setColor(color: string): void;
|
|
107
|
+
/**
|
|
108
|
+
* @override
|
|
109
|
+
* @inheritDoc
|
|
110
|
+
*/
|
|
111
|
+
getTextSelection(): ITextSelection;
|
|
112
|
+
/**
|
|
113
|
+
* @override
|
|
114
|
+
* @inheritDoc
|
|
115
|
+
*/
|
|
116
|
+
getTextSelection$(): Observable<ITextSelection>;
|
|
117
|
+
/**
|
|
118
|
+
* @override
|
|
119
|
+
* @inheritDoc
|
|
120
|
+
*/
|
|
121
|
+
setTextAlign(alignment: TextAlignment): void;
|
|
122
|
+
/**
|
|
123
|
+
* @override
|
|
124
|
+
* @inheritDoc
|
|
125
|
+
*/
|
|
126
|
+
setCharSpacing(spacing: number): void;
|
|
127
|
+
/**
|
|
128
|
+
* @override
|
|
129
|
+
* @inheritDoc
|
|
130
|
+
*/
|
|
131
|
+
setLineHeight(height: number): void;
|
|
132
|
+
/**
|
|
133
|
+
* @override
|
|
134
|
+
* @inheritDoc
|
|
135
|
+
*/
|
|
136
|
+
setBold(bold?: boolean): void;
|
|
137
|
+
/**
|
|
138
|
+
* @override
|
|
139
|
+
* @inheritDoc
|
|
140
|
+
*/
|
|
141
|
+
setBoldRegion(start: number, end: number, bold?: boolean): void;
|
|
142
|
+
/**
|
|
143
|
+
* @override
|
|
144
|
+
* @inheritDoc
|
|
145
|
+
*/
|
|
146
|
+
setItalic(italic?: boolean): void;
|
|
147
|
+
/**
|
|
148
|
+
* @override
|
|
149
|
+
* @inheritDoc
|
|
150
|
+
*/
|
|
151
|
+
setItalicRegion(start: number, end: number, italic?: boolean): void;
|
|
152
|
+
/**
|
|
153
|
+
* @override
|
|
154
|
+
* @inheritDoc
|
|
155
|
+
*/
|
|
156
|
+
setStrikethrough(strikethrough?: boolean): void;
|
|
157
|
+
/**
|
|
158
|
+
* @override
|
|
159
|
+
* @inheritDoc
|
|
160
|
+
*/
|
|
161
|
+
setUnderline(underline?: boolean): void;
|
|
162
|
+
/**
|
|
163
|
+
* @override
|
|
164
|
+
* @inheritDoc
|
|
165
|
+
*/
|
|
166
|
+
setFont(font: IFont): void;
|
|
167
|
+
/**
|
|
168
|
+
* @override
|
|
169
|
+
* @inheritDoc
|
|
170
|
+
*/
|
|
171
|
+
setFontSize(fontSize: number): void;
|
|
172
|
+
/**
|
|
173
|
+
* @override
|
|
174
|
+
* @inheritDoc
|
|
175
|
+
*/
|
|
176
|
+
setTextBackgroundColor(color: string): void;
|
|
177
|
+
/**
|
|
178
|
+
* @override
|
|
179
|
+
* @inheritDoc
|
|
180
|
+
*/
|
|
181
|
+
centerHorizontally(): void;
|
|
182
|
+
/**
|
|
183
|
+
* @override
|
|
184
|
+
* @inheritDoc
|
|
185
|
+
*/
|
|
186
|
+
centerVertically(): void;
|
|
187
|
+
/**
|
|
188
|
+
* @override
|
|
189
|
+
* @inheritDoc
|
|
190
|
+
*/
|
|
191
|
+
nudgeUp(): void;
|
|
192
|
+
/**
|
|
193
|
+
* @override
|
|
194
|
+
* @inheritDoc
|
|
195
|
+
*/
|
|
196
|
+
nudgeDown(): void;
|
|
197
|
+
/**
|
|
198
|
+
* @override
|
|
199
|
+
* @inheritDoc
|
|
200
|
+
*/
|
|
201
|
+
nudgeLeft(): void;
|
|
202
|
+
/**
|
|
203
|
+
* @override
|
|
204
|
+
* @inheritDoc
|
|
205
|
+
*/
|
|
206
|
+
nudgeRight(): void;
|
|
207
|
+
/**
|
|
208
|
+
* @override
|
|
209
|
+
* @inheritDoc
|
|
210
|
+
*/
|
|
211
|
+
getBackgroundColor(): string;
|
|
212
|
+
/**
|
|
213
|
+
* @override
|
|
214
|
+
* @inheritDoc
|
|
215
|
+
*/
|
|
216
|
+
setBackgroundColor(color: string): void;
|
|
217
|
+
/**
|
|
218
|
+
* @override
|
|
219
|
+
* @inheritDoc
|
|
220
|
+
*/
|
|
221
|
+
setPrefillType(prefillType: string): void;
|
|
222
|
+
/**
|
|
223
|
+
* @override
|
|
224
|
+
* @inheritDoc
|
|
225
|
+
*/
|
|
226
|
+
getPrefillType(): string;
|
|
227
|
+
/**
|
|
228
|
+
* @override
|
|
229
|
+
* @inheritDoc
|
|
230
|
+
*/
|
|
231
|
+
getBulletMargin(): number;
|
|
232
|
+
/**
|
|
233
|
+
* @override
|
|
234
|
+
* @inheritDoc
|
|
235
|
+
*/
|
|
236
|
+
getOrderedListMargin(): number;
|
|
237
|
+
/**
|
|
238
|
+
* @override
|
|
239
|
+
* @inheritDoc
|
|
240
|
+
*/
|
|
241
|
+
isResizeCanvas(): boolean;
|
|
242
|
+
/**
|
|
243
|
+
* @override
|
|
244
|
+
* @inheritDoc
|
|
245
|
+
*/
|
|
246
|
+
setResizeCanvas(value: boolean): void;
|
|
247
|
+
/**
|
|
248
|
+
* @override
|
|
249
|
+
* @inheritDoc
|
|
250
|
+
*/
|
|
251
|
+
focus(): void;
|
|
252
|
+
/**
|
|
253
|
+
* @override
|
|
254
|
+
* @inheritDoc
|
|
255
|
+
*/
|
|
256
|
+
isEditing(): boolean;
|
|
257
|
+
/**
|
|
258
|
+
* @override
|
|
259
|
+
* @inheritDoc
|
|
260
|
+
*/
|
|
261
|
+
enterEditing(): void;
|
|
262
|
+
/**
|
|
263
|
+
* @override
|
|
264
|
+
* @inheritDoc
|
|
265
|
+
*/
|
|
266
|
+
selectAllText(): void;
|
|
267
|
+
/**
|
|
268
|
+
* @override
|
|
269
|
+
* @inheritDoc
|
|
270
|
+
*/
|
|
271
|
+
isBulleted(): boolean;
|
|
272
|
+
/**
|
|
273
|
+
* @override
|
|
274
|
+
* @inheritDoc
|
|
275
|
+
*/
|
|
276
|
+
enableBullets(): void;
|
|
277
|
+
/**
|
|
278
|
+
* @override
|
|
279
|
+
* @inheritDoc
|
|
280
|
+
*/
|
|
281
|
+
disableBullets(): void;
|
|
282
|
+
/**
|
|
283
|
+
* @override
|
|
284
|
+
* @inheritDoc
|
|
285
|
+
*/
|
|
286
|
+
isOrderedList(): boolean;
|
|
287
|
+
/**
|
|
288
|
+
* @override
|
|
289
|
+
* @inheritDoc
|
|
290
|
+
*/
|
|
291
|
+
enableOrderedList(): void;
|
|
292
|
+
/**
|
|
293
|
+
* @override
|
|
294
|
+
* @inheritDoc
|
|
295
|
+
*/
|
|
296
|
+
disableOrderedList(): void;
|
|
297
|
+
/**
|
|
298
|
+
* @override
|
|
299
|
+
* @inheritDoc
|
|
300
|
+
*/
|
|
301
|
+
setOrderedListStart(start: number): void;
|
|
302
|
+
/**
|
|
303
|
+
* @override
|
|
304
|
+
* @inheritDoc
|
|
305
|
+
*/
|
|
306
|
+
getOrderedListStart(): number;
|
|
307
|
+
getSizeIncreaseSinceCreation(): number;
|
|
308
|
+
private removeBullets;
|
|
309
|
+
private removeOrderedListMarkers;
|
|
310
|
+
private applyBulletListMonkeyPatches;
|
|
311
|
+
/**
|
|
312
|
+
* @override
|
|
313
|
+
* @inheritDoc
|
|
314
|
+
*/
|
|
315
|
+
protected updateFabricObjectBehavior(): void;
|
|
316
|
+
protected onTextChange(): void;
|
|
317
|
+
protected onDelete(): void;
|
|
318
|
+
protected onSelectionChange(): void;
|
|
319
|
+
private hasTextSelection;
|
|
320
|
+
private updateTextSelection;
|
|
321
|
+
private notifyCanvasOfTextChanges;
|
|
322
|
+
}
|