@syncfusion/ej2-docx-renderer 0.0.0-stage → 35.2.15

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.
Files changed (129) hide show
  1. package/README.md +2 -2
  2. package/base.d.ts +4 -0
  3. package/base.js +4 -0
  4. package/dist/ej2-docx-renderer.umd.min.js +2 -0
  5. package/dist/ej2-docx-renderer.umd.min.js.map +1 -0
  6. package/dist/es6/ej2-docx-renderer.es2015.js +52432 -0
  7. package/dist/es6/ej2-docx-renderer.es2015.js.map +1 -0
  8. package/dist/es6/ej2-docx-renderer.es5.js +54425 -0
  9. package/dist/es6/ej2-docx-renderer.es5.js.map +1 -0
  10. package/dist/global/ej2-docx-renderer.min.js +2 -0
  11. package/dist/global/ej2-docx-renderer.min.js.map +1 -0
  12. package/dist/global/index.d.ts +5 -0
  13. package/format.d.ts +4 -0
  14. package/format.js +4 -0
  15. package/helper.d.ts +4 -0
  16. package/helper.js +4 -0
  17. package/index.d.ts +4 -0
  18. package/index.js +4 -0
  19. package/license +10 -0
  20. package/list.d.ts +4 -0
  21. package/list.js +4 -0
  22. package/package.json +26 -4
  23. package/parser.d.ts +4 -0
  24. package/parser.js +4 -0
  25. package/src/base/constants.d.ts +2 -0
  26. package/src/base/constants.js +2 -0
  27. package/src/base/dictionary.d.ts +52 -0
  28. package/src/base/dictionary.js +137 -0
  29. package/src/base/index.d.ts +9 -0
  30. package/src/base/index.js +9 -0
  31. package/src/base/keywords.d.ts +422 -0
  32. package/src/base/keywords.js +422 -0
  33. package/src/base/types.d.ts +2590 -0
  34. package/src/base/types.js +1056 -0
  35. package/src/base/unique-format.d.ts +87 -0
  36. package/src/base/unique-format.js +858 -0
  37. package/src/base/unique-formats.d.ts +32 -0
  38. package/src/base/unique-formats.js +87 -0
  39. package/src/document-canvas.d.ts +61 -0
  40. package/src/document-canvas.js +221 -0
  41. package/src/docx-renderer.d.ts +941 -0
  42. package/src/docx-renderer.js +2251 -0
  43. package/src/format/border.d.ts +53 -0
  44. package/src/format/border.js +600 -0
  45. package/src/format/borders.d.ts +44 -0
  46. package/src/format/borders.js +314 -0
  47. package/src/format/cell-format.d.ts +42 -0
  48. package/src/format/cell-format.js +309 -0
  49. package/src/format/character-format.d.ts +152 -0
  50. package/src/format/character-format.js +1224 -0
  51. package/src/format/index.d.ts +14 -0
  52. package/src/format/index.js +14 -0
  53. package/src/format/list-format.d.ts +32 -0
  54. package/src/format/list-format.js +238 -0
  55. package/src/format/paragraph-format.d.ts +103 -0
  56. package/src/format/paragraph-format.js +854 -0
  57. package/src/format/row-format.d.ts +119 -0
  58. package/src/format/row-format.js +545 -0
  59. package/src/format/section-format.d.ts +89 -0
  60. package/src/format/section-format.js +689 -0
  61. package/src/format/shading.d.ts +24 -0
  62. package/src/format/shading.js +137 -0
  63. package/src/format/style.d.ts +106 -0
  64. package/src/format/style.js +286 -0
  65. package/src/format/table-format.d.ts +51 -0
  66. package/src/format/table-format.js +395 -0
  67. package/src/global.js +1 -0
  68. package/src/helper/document-editor-helper.d.ts +515 -0
  69. package/src/helper/document-editor-helper.js +1302 -0
  70. package/src/helper/document-editor-settings.d.ts +293 -0
  71. package/src/helper/document-editor-settings.js +94 -0
  72. package/src/helper/index.d.ts +5 -0
  73. package/src/helper/index.js +5 -0
  74. package/src/helper/layout-helper-methods.d.ts +539 -0
  75. package/src/helper/layout-helper-methods.js +1065 -0
  76. package/src/helper/renderer-hooks.d.ts +74 -0
  77. package/src/helper/renderer-hooks.js +14 -0
  78. package/src/helper/revision-helper-methods.d.ts +199 -0
  79. package/src/helper/revision-helper-methods.js +362 -0
  80. package/src/index.d.ts +18 -0
  81. package/src/index.js +18 -0
  82. package/src/layout-helper.d.ts +190 -0
  83. package/src/layout-helper.js +1368 -0
  84. package/src/layout.d.ts +779 -0
  85. package/src/layout.js +17232 -0
  86. package/src/list/abstract-list.d.ts +25 -0
  87. package/src/list/abstract-list.js +67 -0
  88. package/src/list/index.d.ts +7 -0
  89. package/src/list/index.js +7 -0
  90. package/src/list/level-override.d.ts +22 -0
  91. package/src/list/level-override.js +43 -0
  92. package/src/list/list-level.d.ts +57 -0
  93. package/src/list/list-level.js +249 -0
  94. package/src/list/list.d.ts +30 -0
  95. package/src/list/list.js +100 -0
  96. package/src/page.d.ts +4155 -0
  97. package/src/page.js +11342 -0
  98. package/src/parser/index.d.ts +1 -0
  99. package/src/parser/index.js +1 -0
  100. package/src/parser/sfdt-reader.d.ts +254 -0
  101. package/src/parser/sfdt-reader.js +4569 -0
  102. package/src/render.d.ts +226 -0
  103. package/src/render.js +4222 -0
  104. package/src/text-helper.d.ts +144 -0
  105. package/src/text-helper.js +1079 -0
  106. package/src/text-helpers/index.d.ts +2 -0
  107. package/src/text-helpers/index.js +2 -0
  108. package/src/text-helpers/optimized.d.ts +45 -0
  109. package/src/text-helpers/optimized.js +121 -0
  110. package/src/text-helpers/regular.d.ts +37 -0
  111. package/src/text-helpers/regular.js +93 -0
  112. package/src/themes/font-scheme.d.ts +28 -0
  113. package/src/themes/font-scheme.js +107 -0
  114. package/src/themes/index.d.ts +6 -0
  115. package/src/themes/index.js +6 -0
  116. package/src/themes/major-minor-font-scheme.d.ts +14 -0
  117. package/src/themes/major-minor-font-scheme.js +45 -0
  118. package/src/themes/themes.d.ts +11 -0
  119. package/src/themes/themes.js +31 -0
  120. package/src/utility/index.d.ts +1 -0
  121. package/src/utility/index.js +1 -0
  122. package/src/utility/path-util.d.ts +133 -0
  123. package/src/utility/path-util.js +639 -0
  124. package/text-helpers.d.ts +4 -0
  125. package/text-helpers.js +4 -0
  126. package/themes.d.ts +4 -0
  127. package/themes.js +4 -0
  128. package/utility.d.ts +4 -0
  129. package/utility.js +4 -0
@@ -0,0 +1,779 @@
1
+ import { ListLevelPattern, FootEndNoteNumberFormat } from './base/types';
2
+ import { FootNoteWidgetsInfo, WrapPosition, SizeInfo } from './helper/layout-helper-methods';
3
+ import { WBorder } from './format/border';
4
+ import { WBorders } from './format/borders';
5
+ import { WCharacterFormat } from './format/character-format';
6
+ import { WSectionFormat } from './format/section-format';
7
+ import { WAbstractList } from './list/abstract-list';
8
+ import { WList } from './list/list';
9
+ import { WListLevel } from './list/list-level';
10
+ import { BlockContainer, BlockWidget, BodyWidget, CommentElementBox, ElementBox, FieldElementBox, HeaderFooterWidget, IWidget, LineWidget, ListTextElementBox, Page, ParagraphWidget, Rect, TableCellWidget, TableRowWidget, TableWidget, Widget, CheckBoxFormField, FootnoteElementBox, FootNoteWidget, GroupShapeElementBox } from './page';
11
+ import { LayoutHelper, PageLayoutHelper } from './layout-helper';
12
+ import { DocxRenderer } from './docx-renderer';
13
+ /**
14
+ * @private
15
+ */
16
+ export declare class Layout {
17
+ private documentHelper;
18
+ private value;
19
+ private previousPara;
20
+ /**
21
+ * @private
22
+ */
23
+ islayoutFootnote: boolean;
24
+ /**
25
+ * @private
26
+ */
27
+ isMultiColumnDoc: boolean;
28
+ /**
29
+ * @private
30
+ */
31
+ allowLayout: boolean;
32
+ /**
33
+ * @private
34
+ */
35
+ isReplaceAll: boolean;
36
+ /**
37
+ * @private
38
+ */
39
+ isTextFormat: boolean;
40
+ /**
41
+ * @private
42
+ */
43
+ isSectionBreakCont: boolean;
44
+ /**
45
+ * @private
46
+ */
47
+ isReplacingAll: boolean;
48
+ /**
49
+ * @private
50
+ */
51
+ footHeight: number;
52
+ /**
53
+ * @private
54
+ */
55
+ existFootnoteHeight: number;
56
+ /**
57
+ * @private
58
+ */
59
+ isfootMove: boolean;
60
+ /**
61
+ * @private
62
+ */
63
+ footnoteHeight: number;
64
+ /**
65
+ * @private
66
+ */
67
+ isTableFootNote: boolean;
68
+ /**
69
+ * @private
70
+ */
71
+ isRelayout: boolean;
72
+ /**
73
+ * @private
74
+ */
75
+ isRelayoutneed: boolean;
76
+ /**
77
+ * @private
78
+ */
79
+ isOverlapFloatTable: boolean;
80
+ isInitialLoad: boolean;
81
+ /**
82
+ * @private
83
+ */
84
+ isInsertFormField: boolean;
85
+ private fieldBegin;
86
+ private maxTextHeight;
87
+ private maxBaseline;
88
+ private maxTextBaseline;
89
+ private isFieldCode;
90
+ private isRtlFieldCode;
91
+ private isRTLLayout;
92
+ private isSkipFirstLineIndent;
93
+ currentCell: TableCellWidget;
94
+ isFootnoteContentChanged: boolean;
95
+ isEndnoteContentChanged: boolean;
96
+ private keepWithNext;
97
+ private effectiveJustifyWidth;
98
+ private mergedParagraph;
99
+ private mergedParagraphOffset;
100
+ private is2013Justification;
101
+ private nextElementToLayout;
102
+ private endNoteHeight;
103
+ private isMultiColumnSplit;
104
+ private isMultiColumnLayout;
105
+ private skipUpdateContainerWidget;
106
+ private isIFfield;
107
+ private skip2003;
108
+ private textWrappingBottom;
109
+ private istableYpositionChange;
110
+ /**
111
+ * @private
112
+ */
113
+ startat: number;
114
+ isLayoutWhole: boolean;
115
+ /**
116
+ * @private
117
+ */
118
+ isBidiReLayout: boolean;
119
+ /**
120
+ * @private
121
+ */
122
+ defaultTabWidthPixel: number;
123
+ /**
124
+ * @private
125
+ */
126
+ isRelayoutFootnote: boolean;
127
+ private isRelayoutOverlap;
128
+ private skipRelayoutOverlap;
129
+ private startOverlapWidget;
130
+ private endOverlapWidget;
131
+ private isWrapText;
132
+ private isYPositionUpdated;
133
+ private isXPositionUpdated;
134
+ private hasFloatingElement;
135
+ private isFootNoteLayoutStart;
136
+ wrapPosition: WrapPosition[];
137
+ private isRtlShapeWrapAtStart;
138
+ private shiftedFloatingItemsFromTable;
139
+ isDocumentContainsRtl: boolean;
140
+ /**
141
+ * @private
142
+ */
143
+ isPastingContent: boolean;
144
+ private layoutedFootnoteElement;
145
+ /**
146
+ * @private
147
+ */
148
+ lastScrollUpdatePageIndex: number;
149
+ /**
150
+ * @private
151
+ */
152
+ isAllColumnHasAutoWidthType: boolean;
153
+ /**
154
+ * @private
155
+ */
156
+ isLayoutSwitch: boolean;
157
+ private readonly owner;
158
+ private isSameStyle;
159
+ private updateFirstParagraphSpacingBasedOnContextualSpacing;
160
+ private updateLastParagraphSpacingBasedOnContextualSpacing;
161
+ private checkOwnerTablePrevItem;
162
+ constructor(documentHelper: DocxRenderer);
163
+ private readonly viewer;
164
+ layout(): void;
165
+ /**
166
+ * Releases un-managed and - optionally - managed resources.
167
+ *
168
+ * @returns {void}
169
+ */
170
+ destroy(): void;
171
+ layoutItems(sections: BodyWidget[], isReLayout: boolean, isContinuousSection?: boolean, isAsync?: boolean): void | Promise<void>;
172
+ shouldScrollUpdateIn(): boolean;
173
+ private layoutSection;
174
+ /**
175
+ * @private
176
+ *
177
+ */
178
+ reLayoutMultiColumn(section: BodyWidget, isFirstBlock: boolean, blockIndex: number): void;
179
+ private combineMultiColumnForRelayout;
180
+ private reLayoutMultiColumnBlock;
181
+ splitBodyWidgetBasedOnColumn(section: BodyWidget): void;
182
+ /**
183
+ * @private
184
+ */
185
+ getColumnBreak(section: BodyWidget): boolean;
186
+ layoutMultiColumnBody(nonEqualBody: BodyWidget, updatePosition: boolean): void;
187
+ getNextWidgetHeight(body: BodyWidget): number;
188
+ private getHeight;
189
+ private getBookmarkMargin;
190
+ private getCountOrLine;
191
+ private getCountOrLineTable;
192
+ /**
193
+ * @private
194
+ */
195
+ combineMultiColumn(section: BodyWidget): void;
196
+ private updateCellHeightInCombinedTable;
197
+ layoutHeaderFooter(section: BodyWidget, viewer: PageLayoutHelper, page: Page): void;
198
+ /**
199
+ * @private
200
+ */
201
+ layoutHeaderFooterInternal(section: BodyWidget, viewer: PageLayoutHelper, page: Page): void;
202
+ /**
203
+ * @private
204
+ * @param {HeaderFooterWidget} headerWidget - header widget whose floating items are adjusted.
205
+ * @returns {HeaderFooterWidget} - the adjusted header widget.
206
+ */
207
+ shiftItemsForVerticalAlignment(headerWidget: HeaderFooterWidget): HeaderFooterWidget;
208
+ updateHeaderFooterToParent(node: HeaderFooterWidget): HeaderFooterWidget;
209
+ updateRevisionsToHeaderFooter(clone: HeaderFooterWidget, page: Page): any;
210
+ private updateRevisionRange;
211
+ private updateRevisionsToHeaderFooterParagraph;
212
+ private updateRevisionsToHeaderFooterTable;
213
+ private linkFieldInHeaderFooter;
214
+ /**
215
+ * @private
216
+ */
217
+ linkFieldInParagraph(widget: ParagraphWidget): void;
218
+ /**
219
+ * @private
220
+ */
221
+ getCommentById(commentsCollection: CommentElementBox[], commentId: string): CommentElementBox;
222
+ linkFieldInTable(widget: TableWidget): void;
223
+ layoutHeaderFooterItems(viewer: LayoutHelper, widget: HeaderFooterWidget): HeaderFooterWidget;
224
+ private shiftChildLocation;
225
+ private shiftChildLocationForTableWidget;
226
+ private shiftChildLocationForTableRowWidget;
227
+ private shiftChildLocationForTableCellWidget;
228
+ layoutBlock(block: BlockWidget, index: number, isUpdatedList?: boolean, isAsync?: boolean): BlockWidget | Promise<BlockWidget>;
229
+ private updateTableYPositionBasedonTextWrap;
230
+ private shiftWrapStyle;
231
+ private checkAndRelayoutPreviousOverlappingBlock;
232
+ private getLineHeigth;
233
+ private addParagraphWidget;
234
+ isNeedToUpdateXPositionForEmptyParagraph(paragraphWidget: ParagraphWidget): boolean;
235
+ private updateXPositionForEmptyParagraph;
236
+ /**
237
+ * @private
238
+ */
239
+ addLineWidget(paragraphWidget: ParagraphWidget): LineWidget;
240
+ isFirstElementWithPageBreak(paragraphWidget: ParagraphWidget): boolean;
241
+ /**
242
+ * Layouts specified paragraph.
243
+ *
244
+ * @private
245
+ * @param footnote
246
+ */
247
+ layoutfootNote(footnote: FootNoteWidget): BlockContainer;
248
+ private getFootNoteBodyHeight;
249
+ private splitFootNoteWidgetBasedOnColumn;
250
+ updateColumnIndex(section: BodyWidget, increase: boolean, isEditor?: boolean): void;
251
+ private shiftChildWidgetInFootnote;
252
+ /**
253
+ * @private
254
+ */
255
+ getBodyWidgetHeight(bodyWidget: BodyWidget): number;
256
+ private checkBlockHasField;
257
+ private checkTableHasField;
258
+ private layoutParagraph;
259
+ private normalizeBookmarkEndForParagraph;
260
+ private checkIsFieldParagraph;
261
+ private checkIsHiddenElement;
262
+ private clearLineMeasures;
263
+ private layoutFloatElements;
264
+ private layoutShape;
265
+ layoutGroupShape(groupShape: GroupShapeElementBox): void;
266
+ private getExtentXValue;
267
+ private getExtentYValue;
268
+ private updateShapeTextPosition;
269
+ private updateChildShapePosition;
270
+ private updateNestedShapePosition;
271
+ private splitFirstWordFromElement;
272
+ private moveElementFromNextLine;
273
+ private layoutLine;
274
+ /**
275
+ *
276
+ * @private
277
+ * @returns {boolean}
278
+ */
279
+ checkFormatToCombineText(currentFormat: WCharacterFormat, previousFormat: WCharacterFormat): boolean;
280
+ private getWholeTextWidth;
281
+ private layoutElement;
282
+ private hasPreviousListElement;
283
+ /**
284
+ * @private
285
+ */
286
+ adjustPosition(element: ElementBox, bodyWidget: BlockContainer, isEmptyPara?: boolean): void;
287
+ private hasPrecedingContentInLine;
288
+ private getFirstElement;
289
+ private updateWrapPosition;
290
+ private isFirstitemInPage;
291
+ private isNeedToWrapParaMarkToRightSide;
292
+ private isTextFitBelow;
293
+ private isNeedToWrapForTopAndBottom;
294
+ private isNeedToWrapForSquareTightAndThrough;
295
+ private isNeedToWrapForSquareTightAndThroughForTable;
296
+ private isContinuationAtColumnStart;
297
+ private getPriorColumnFloatingTables;
298
+ private isNeedToWrapLeafWidget;
299
+ private getMinWidth;
300
+ private getNextTextRangeWidth;
301
+ private isLeafWidgetNextSiblingIsTextRange;
302
+ private isNextSibligSizeNeedToBeMeasure;
303
+ private isNeedDoIntermediateWrapping;
304
+ private isFloatingItemOnLeft;
305
+ private getNextSibling;
306
+ private getIntersectingSquareItemBounds;
307
+ private getXPositionOfIntersectionFloatingItemBasedOnHorizontally;
308
+ private getBottomPositionOfIntersectionFloatingItemBasedOnHorizontally;
309
+ private adjustClientAreaBasedOnTextWrap;
310
+ private isShapeInsideTable;
311
+ private adjustClientAreaBasedOnTextWrapForTable;
312
+ private getNestedTable;
313
+ private startAt;
314
+ layoutFootEndNoteElement(element: FootnoteElementBox): boolean;
315
+ layoutEndNoteElement(): void;
316
+ hasValidElement(paragraph: ParagraphWidget): boolean;
317
+ /**
318
+ * @private
319
+ */
320
+ isConsiderAsEmptyLineWidget(lineWidget: LineWidget): boolean;
321
+ private updateFieldText;
322
+ private checkLineWidgetWithClientArea;
323
+ private checkAndSplitTabOrLineBreakCharacter;
324
+ private moveFromNextPage;
325
+ private cutClientWidth;
326
+ private layoutFieldCharacters;
327
+ private getCheckBoxText;
328
+ private checkAndUpdateFieldData;
329
+ /**
330
+ * Set the checkbox font size
331
+ * @returns {void}
332
+ */
333
+ setCheckBoxFontSize(formFieldData: CheckBoxFormField, format: WCharacterFormat): void;
334
+ private layoutEmptyLineWidget;
335
+ private layoutSectionBreakParagraph;
336
+ private getLineYPosition;
337
+ private hasVisibleElement;
338
+ private getMergedParagraphOffset;
339
+ private getHiddenParagraphMarkWidth;
340
+ /**
341
+ * @private
342
+ */
343
+ isMergedWithNextParagraph(paragraph: ParagraphWidget): boolean;
344
+ private getLineXPosition;
345
+ private getLineWidth;
346
+ private isUpdateMarginForCurrentLine;
347
+ private adjustPositionBasedOnTopAndBottom;
348
+ private layoutListItems;
349
+ private layoutList;
350
+ /**
351
+ * Reduces the layout width of the list number based on the list level alignment (w:lvlJc), as in DocIO.
352
+ * Left takes the full width, center takes half the width and right takes no width.
353
+ * The number is drawn shifted to the left by the remaining width.
354
+ *
355
+ * @private
356
+ * @param {ListTextElementBox} element - Specifies the list number element.
357
+ * @param {WListLevel} listLevel - Specifies the list level.
358
+ * @param {ParagraphWidget} paragraph - Specifies the paragraph.
359
+ * @returns {void}
360
+ */
361
+ applyListNumberAlignment(element: ListTextElementBox, listLevel: WListLevel, paragraph: ParagraphWidget): void;
362
+ addBodyWidget(area: Rect, widget?: BodyWidget): BodyWidget;
363
+ /**
364
+ * @private
365
+ */
366
+ addListLevels(abstractList: WAbstractList): void;
367
+ private addSplittedLineWidget;
368
+ private addElementToLine;
369
+ private splitElementForClientArea;
370
+ private splitByWord;
371
+ private spitTextElementByWhitespace;
372
+ private splitErrorCollection;
373
+ private splitByCharacter;
374
+ private updateRevisionForSplittedElement;
375
+ private splitTextElementWordByWord;
376
+ private isSplitByHyphen;
377
+ private splitTextForClientArea;
378
+ private isRtlNonBreakableNumeric;
379
+ private splitByLineBreakOrTab;
380
+ /**
381
+ * @private
382
+ */
383
+ updateMargin(line: LineWidget): void;
384
+ private moveToNextLine;
385
+ private isImageOnlyLine;
386
+ private checkPrevElementTextWrappingStyle;
387
+ private updateNestedGroupShapeX;
388
+ private updateNestedGroupShapeY;
389
+ private updateShapeYPosition;
390
+ getBodyWidget(section: BodyWidget, isFirstBody: boolean): BodyWidget;
391
+ private splitParagraphForMultiColumn;
392
+ private checkInbetweenShapeOverlap;
393
+ private getLineY;
394
+ private isFormFieldCheckBox;
395
+ private updateLineWidget;
396
+ /**
397
+ * @private
398
+ */
399
+ reLayoutEndnote(): void;
400
+ private moveEndnoteToNextPage;
401
+ private moveToNextPage;
402
+ private isImagePresent;
403
+ private updateShapeBaseLocation;
404
+ private moveChildsToParagraph;
405
+ /**
406
+ * @param {ParagraphWidget} paragarph - the paragraph
407
+ * @param {BodyWidget} body - the bodyWidget
408
+ * @param {boolean} add - to specify add or remove floating elements from body widget.
409
+ */
410
+ private addRemoveFloatElementsFromBody;
411
+ /**
412
+ * Align block based on keep with next and keep lines together property.
413
+ */
414
+ private alignBlockElement;
415
+ private getPreviousBlock;
416
+ private splitRow;
417
+ private splitParagraph;
418
+ private updateClientPositionForBlock;
419
+ private updateClientAreaForNextBlock;
420
+ private layoutStartEndBlocks;
421
+ private isTextFollowWithtab;
422
+ private alignLineElements;
423
+ private updateWidgetToPage;
424
+ private shiftFooterChildLocation;
425
+ private shiftFootnoteChildLocation;
426
+ private checkPreviousElement;
427
+ clearListElementBox(paragraph: ParagraphWidget): void;
428
+ /**
429
+ * @private
430
+ */
431
+ clearInvalidList(list: WList): void;
432
+ getListNumber(paragraph: ParagraphWidget, isAutoList?: boolean): string;
433
+ private ClearSubListLevelValues;
434
+ getListStartValue(listLevelNumber: number, list: WList): number;
435
+ private getListValues;
436
+ private updateListValues;
437
+ private getListText;
438
+ getAsLetter(number: number): string;
439
+ getListTextListLevel(listLevel: WListLevel, listValue: number, localeId: number, customPattern?: ListLevelPattern): string;
440
+ private getAsAlphabet;
441
+ private getAsHebrewNumber;
442
+ getFootEndNote(numberFormat: FootEndNoteNumberFormat, value: number): string;
443
+ private generateNumber;
444
+ private getAsLeadingZero;
445
+ getAsRoman(number: number): string;
446
+ private getOrdinalText;
447
+ private numberToWords;
448
+ private getOrdinalTextInSpanish;
449
+ private numberToSpanishWords;
450
+ /**
451
+ * Returns true when the highest tab stop of the paragraph reaches or exceeds the right edge of the client area.
452
+ * Tab stop positions are measured from the left margin, so the client area right edge is converted to the same origin.
453
+ */
454
+ private isHighestTabStopReachesClientArea;
455
+ private isTabStopBeyondRightMargin;
456
+ private isTextAfterTabToRetainInLine;
457
+ private getAsOrdinal;
458
+ private getOrdinalInEnglish;
459
+ private getOrdinalInSwedish;
460
+ private getOrdinalInCatalan;
461
+ private getOrdinalInDanish;
462
+ getListLevel(list: WList, listLevelNumber: number): WListLevel;
463
+ private getOverrideListLevel;
464
+ private isNeedToConsiderTabStopPosition;
465
+ private getTabWidth;
466
+ private getJustificationTabWidth;
467
+ private getRightTabWidth;
468
+ private getSplitIndexByWord;
469
+ private getTextSplitIndexByCharacter;
470
+ private getSubWidth;
471
+ private getUnroundedLineWidth;
472
+ /**
473
+ * Returns true only when the line ends with consecutive spaces (more than one space character)
474
+ * and the line fits the client width without those trailing spaces, i.e. the overflow is caused purely by them.
475
+ */
476
+ private isOverflowOnlyByTrailingSpaces;
477
+ private getSubWidthBasedOnTextWrap;
478
+ private isWordFittedByJustification;
479
+ /**
480
+ * Returns the total space width in line widget.
481
+ * @param {LineWidget} lineWidget - the line widget
482
+ * @param {number} count - the space count to be considered.
483
+ * @returns {number} the total space width.
484
+ */
485
+ private getTotalSpaceWidth;
486
+ private getSubWidthInfo;
487
+ getBeforeSpacing(paragraph: ParagraphWidget, isFromMoveToNextPage?: boolean): number;
488
+ getAfterSpacing(paragraph: ParagraphWidget): number;
489
+ getLineSpacing(paragraph: ParagraphWidget, maxHeight: number, alterLineSpacing?: boolean): number;
490
+ private isParagraphFirstLine;
491
+ private isParagraphLastLine;
492
+ private getTextIndexAfterSpace;
493
+ moveNextWidgetsToTable(tableWidget: TableWidget[], currentRow: TableRowWidget, moveFromNext: boolean): void;
494
+ private addTableCellWidget;
495
+ private checkPreviousMargins;
496
+ private addWidgetToTable;
497
+ private updateRowHeightByFloatingElements;
498
+ private layoutFootnoteInSplittedRow;
499
+ private getFootNoteHeight;
500
+ private getFootnoteHeightInternal;
501
+ updateRowHeightBySpannedCell(tableWidget: TableWidget, row: TableRowWidget, insertIndex: number): void;
502
+ private updateRowHeight;
503
+ private updateSpannedRowCollection;
504
+ private updateRowHeightByCellSpacing;
505
+ /**
506
+ * Removes the splitted cell widgets left over from a different table. Such stale cells would otherwise be treated as
507
+ * row span of the current table row, so the row is never fitted and is moved to the next page endlessly.
508
+ */
509
+ private removeStaleSplittedCellWidgets;
510
+ private isRowSpanEnd;
511
+ isVerticalMergedCellContinue(row: TableRowWidget): boolean;
512
+ private splitWidgets;
513
+ private getSplittedWidgetForRow;
514
+ private combineSplittedRowWidgets;
515
+ private getSplittedWidgetForSpannedRow;
516
+ private getFootNoteHeightInLine;
517
+ private getFootnoteFromLine;
518
+ updateWidgetsToTable(tableWidgets: TableWidget[], rowWidgets: TableRowWidget[], row: TableRowWidget, rearrangeRow: boolean, lineIndexInCell?: number, cellIndex?: number, isMultiColumnSplit?: boolean): void;
519
+ private updateHeader;
520
+ getHeader(table: TableWidget): TableRowWidget;
521
+ private getHeaderHeight;
522
+ private getHeaderHeightForSpannedRow;
523
+ private updateWidgetToRow;
524
+ private updateHeightForRowWidget;
525
+ private updateHeightForCellWidget;
526
+ getRowHeight(row: TableRowWidget, rowCollection: TableRowWidget[]): number;
527
+ private splitSpannedCellWidget;
528
+ private insertSplittedCellWidgets;
529
+ private insertRowSpannedWidget;
530
+ private insertEmptySplittedCellWidget;
531
+ private isColumnExistsInCurrentRow;
532
+ private getSplittedWidget;
533
+ private getNextFootNoteHeight;
534
+ private getFootHeightFromTable;
535
+ private getFootHeightFromPara;
536
+ private updateFootHeight;
537
+ private updateFootHeightForTable;
538
+ getListLevelPattern(value: number): ListLevelPattern;
539
+ private createCellWidget;
540
+ private createTableWidget;
541
+ private getSplittedWidgetForPara;
542
+ getSplittedWidgetForTable(bottom: number, tableCollection: TableWidget[], tableWidget: TableWidget, footNoteCollection: FootnoteElementBox[], lineIndexInCell?: number, isMultiColumnSplit?: boolean, count?: number): TableWidget;
543
+ private isFirstLineFitForPara;
544
+ isFirstLineFitForTable(bottom: number, tableWidget: TableWidget): boolean;
545
+ private isFirstLineFitForRow;
546
+ private isFirstLineFitForCell;
547
+ private updateWidgetLocation;
548
+ updateChildLocationForTable(top: number, tableWidget: TableWidget, bodyWidget?: BodyWidget, updatePosition?: boolean, updateXPosition?: boolean): void;
549
+ shiftXPosition(widget: Widget, offset: number): void;
550
+ updateChildLocationForRow(top: number, rowWidget: TableRowWidget, bodyWidget?: BodyWidget, updatePosition?: boolean, updateXPosition?: boolean): void;
551
+ private updateChildLocationForCellOrShape;
552
+ updateCellVerticalPosition(cellWidget: TableCellWidget, isUpdateToTop: boolean, isInsideTable: boolean): void;
553
+ private updateCellContentVerticalPosition;
554
+ private updateShapeInsideCell;
555
+ private updateTableWidgetLocation;
556
+ private getDisplacement;
557
+ private getCellContentHeight;
558
+ private getFloatingItemsHeight;
559
+ private considerPositionTableHeight;
560
+ getTableLeftBorder(borders: WBorders): WBorder;
561
+ getTableRightBorder(borders: WBorders): WBorder;
562
+ getTableTopBorder(borders: WBorders): WBorder;
563
+ getTableBottomBorder(borders: WBorders): WBorder;
564
+ getCellDiagonalUpBorder(tableCell: TableCellWidget): WBorder;
565
+ getCellDiagonalDownBorder(tableCell: TableCellWidget): WBorder;
566
+ getTableWidth(table: TableWidget): number;
567
+ layoutNextItemsBlock(blockAdv: BlockWidget, viewer: LayoutHelper, isFootnoteReLayout?: boolean, isNextBlockToShift?: boolean): void;
568
+ /**
569
+ * Update the client area for the line widget.
570
+ *
571
+ * @param {LineWidget} startLineWidget LineWidget instance.
572
+ * @private
573
+ */
574
+ updateClientAreaForLine(startLineWidget: LineWidget): void;
575
+ /**
576
+ * @private
577
+ */
578
+ isAuto(table: TableWidget): boolean;
579
+ getParentTable(block: BlockWidget): TableWidget;
580
+ reLayoutParagraph(paragraphWidget: ParagraphWidget, lineIndex: number, elementBoxIndex: number, isBidi?: boolean, isSkip?: boolean, isEmptySelection?: boolean): void;
581
+ private getParentRow;
582
+ /**
583
+ * @private
584
+ */
585
+ getParentCell(block: BlockWidget): TableCellWidget;
586
+ private reLayoutRow;
587
+ reLayoutTable(block: BlockWidget, isFootnoteReLayout?: boolean): void;
588
+ private getYPosition;
589
+ private clearFootnoteReference;
590
+ /**
591
+ * @private
592
+ */
593
+ clearTableWidget(table: TableWidget, clearPosition: boolean, clearHeight: boolean, clearGrid?: boolean, updateClientHeight?: boolean, skipToClearPara?: boolean): void;
594
+ /**
595
+ * @private
596
+ */
597
+ clearRowWidget(row: TableRowWidget, clearPosition: boolean, clearHeight: boolean, clearGrid: boolean, skipToClearPara?: boolean): void;
598
+ /**
599
+ * @private
600
+ */
601
+ clearCellWidget(cell: TableCellWidget, clearPosition: boolean, clearHeight: boolean, clearGrid: boolean, skipToClearPara?: boolean): void;
602
+ /**
603
+ * @private
604
+ */
605
+ clearBlockWidget(blocks: IWidget[], clearPosition: boolean, clearHeight: boolean, clearGrid: boolean, skipToClearPara?: boolean): void;
606
+ layoutBodyWidgetCollection(blockIndex: number, bodyWidget: Widget, block: BlockWidget, shiftNextWidget: boolean, isSkipShifting?: boolean, isSelectionInsideTable?: boolean): void;
607
+ /**
608
+ * @private
609
+ */
610
+ checkAndGetBlock(containerWidget: Widget, blockIndex: number): BlockWidget;
611
+ layoutTable(table: TableWidget, startIndex: number, isAsync?: boolean): BlockWidget | Promise<BlockWidget>;
612
+ /**
613
+ * Checks whether a floating (wrap text around) table was split into pieces that ended up in the same page body
614
+ * (out of order) although the whole table fits in a single page.
615
+ * Such a table is moved as a whole to the next page. Tables whose pieces are on different pages are left untouched.
616
+ */
617
+ private isFloatTableSplitOnPageThatFits;
618
+ private layoutFloatTableOnNextPage;
619
+ private updateFootnoteHeight;
620
+ private updateClientAreaForWrapTable;
621
+ addTableWidget(area: Rect, table: TableWidget[], create?: boolean): TableWidget;
622
+ updateWidgetsToPage(tables: TableWidget[], rows: TableRowWidget[], table: TableWidget, rearrangeRow: boolean, endRowWidget?: TableRowWidget): void;
623
+ updateHeightForTableWidget(tables: TableWidget[], rows: TableRowWidget[], tableWidget: TableWidget, endRowWidget?: TableRowWidget): void;
624
+ layoutRow(tableWidget: TableWidget[], row: TableRowWidget, isRowLayout?: boolean): TableRowWidget;
625
+ private updateExistingFootnoteHeight;
626
+ private isIntersecting;
627
+ private getAdjacentRowCell;
628
+ private addTableRowWidget;
629
+ private getMaxTopCellMargin;
630
+ private getMaxBottomCellMargin;
631
+ private layoutCell;
632
+ private isInsertTable;
633
+ private updateTopBorders;
634
+ private isMultiColumnStartUnchanged;
635
+ shiftLayoutedItems(reLayout: boolean, isMultiColumnShift?: boolean, isSkiptUpdateScrollBars?: boolean): void;
636
+ /**
637
+ * @private
638
+ * @returns {void}
639
+ */
640
+ updateSectionIndex(sectionFormat: WSectionFormat, startBodyWidget: BodyWidget, increaseIndex: boolean): void;
641
+ private isSectionEndsWithColumnBreak;
642
+ /**
643
+ * @private
644
+ */
645
+ checkAndShiftEndnote(isRelayout?: boolean): void;
646
+ updateFieldElements(reLayout?: boolean): void;
647
+ private reLayoutOrShiftWidgets;
648
+ private isNeedToRelayout;
649
+ private updateParaOnBeforeSpacing;
650
+ private shiftWidgetsBlock;
651
+ private shiftWidgetsForPara;
652
+ private shiftBodyWidget;
653
+ private updateFloatingElementPosition;
654
+ private isPageBreakInsideField;
655
+ private isPageBreakInsideContentControl;
656
+ /**
657
+ * @private
658
+ * Get the footnote of the block widget.
659
+ *
660
+ * @param {BlockWidget} widget BlockWidget instance.
661
+ * @returns
662
+ */
663
+ getFootNotesOfBlock(widget: BlockWidget, footnoteElements?: FootnoteElementBox[]): FootnoteElementBox[];
664
+ getFootnoteElementsOfParagraph(paragraph: ParagraphWidget): FootnoteElementBox[];
665
+ private getFootNotesWidgetsInLine;
666
+ private getFootNoteWidgetsBy;
667
+ /**
668
+ * @param widget
669
+ * @private
670
+ */
671
+ getFootNoteWidgetsOf(widget: BlockWidget, isShifting?: boolean): BodyWidget[];
672
+ getFootNodeWidgetsToShiftToPage(paragraph: ParagraphWidget): FootNoteWidgetsInfo;
673
+ shiftTableWidget(table: TableWidget, viewer: LayoutHelper, isClearHeight?: boolean): TableWidget;
674
+ shiftRowWidget(tables: TableWidget[], row: TableRowWidget, isClearHeight?: boolean): TableRowWidget;
675
+ private updateFootnoteToBody;
676
+ private getFootnoteBody;
677
+ shiftCellWidget(cell: TableCellWidget, maxCellMarginTop: number, maxCellMarginBottom: number, isClearHeight: boolean): void;
678
+ shiftParagraphWidget(paragraph: ParagraphWidget, skipCellContentHeightCalc?: boolean): void;
679
+ private updateContainerForTable;
680
+ private shiftWidgetsForTable;
681
+ private updateVerticalPositionToTop;
682
+ private splitWidget;
683
+ private getMaximumLineHeightToSplit;
684
+ /**
685
+ * @private
686
+ * @param footnoteWidgets
687
+ * @param fromBodyWidget
688
+ * @param toBodyWidget
689
+ */
690
+ moveFootNotesToPage(footnoteWidgets: BodyWidget[], fromBodyWidget: BodyWidget, toBodyWidget: BodyWidget): void;
691
+ private addEmptyFootNoteToBody;
692
+ private getMaxElementHeight;
693
+ getParagraphMarkSize(paragraph: ParagraphWidget, topMargin: number, bottomMargin: number): SizeInfo;
694
+ private createOrGetNextBodyWidget;
695
+ private isFitInClientArea;
696
+ private isLineInFootNote;
697
+ private shiftToPreviousWidget;
698
+ private updateParagraphWidgetInternal;
699
+ private shiftFloatingElements;
700
+ private shiftNextWidgets;
701
+ updateContainerWidget(widget: Widget, bodyWidget: BodyWidget, index: number, destroyAndScroll: boolean, footWidget?: BodyWidget[]): void;
702
+ private getBodyWidgetOfPreviousBlock;
703
+ moveBlocksToNextPage(block: BlockWidget, moveFootnoteFromLastBlock?: boolean, childStartIndex?: number, sectionBreakContinuous?: boolean, isEndnote?: boolean, isTableSplit?: boolean, isPageBreak?: boolean): BodyWidget;
704
+ private createSplitBody;
705
+ private createOrGetNextColumnBody;
706
+ /**
707
+ * Gets the x position of the paragraph without the offset applied for a preceding merged hidden paragraph.
708
+ * @private
709
+ */
710
+ getParagraphBaseX(paragraph: ParagraphWidget): number;
711
+ /**
712
+ * The paragraph after a hidden paragraph starts at the end of the hidden paragraph's last line.
713
+ * When the hidden paragraph is edited, relayout the next paragraph so its offset and line breaks stay in sync.
714
+ */
715
+ private reLayoutParagraphAfterHidden;
716
+ private moveToNextColumnByBodyWidget;
717
+ reLayoutLine(paragraph: ParagraphWidget, lineIndex: number, isBidi: boolean, isSkip?: boolean, isSkipList?: boolean, elementIndex?: number): void;
718
+ isContainsRtl(lineWidget: LineWidget): boolean;
719
+ private shiftElementsForRTLLayouting;
720
+ private isNumberNonReversingCharacter;
721
+ private isNumberReverseLangForSlash;
722
+ private isNumberReverseLangForOthers;
723
+ private isStartMarker;
724
+ private isEndMarker;
725
+ private getNextValidWidget;
726
+ private hasTextRangeBidi;
727
+ private isContainsRTLText;
728
+ private updateCharacterRange;
729
+ private isPageOrNumPageField;
730
+ private isNeedToConsiderPagefieldAsBidi;
731
+ private reorderElements;
732
+ private isInsertWordSplitToLeft;
733
+ private shiftLayoutFloatingItems;
734
+ private getFloatingItemPoints;
735
+ private adjustPositionForFloatingTableCollision;
736
+ private getLeftMarginHorizPosition;
737
+ private getRightMarginHorizPosition;
738
+ private getVerticalPosition;
739
+ private getHorizontalPosition;
740
+ private updateTableFloatPoints;
741
+ isTocField(element: FieldElementBox): boolean;
742
+ private getTotalColumnSpan;
743
+ private getMaximumRightCellBorderWidth;
744
+ private getDefaultBorderSpacingValue;
745
+ private getMinimumWidthRequiredForTable;
746
+ private shiftFloatingItemsFromTable;
747
+ /**
748
+ * @param block
749
+ * @private
750
+ * @returns {void}
751
+ */
752
+ updateWholeListItems(block: BlockWidget, isFindingListParagraph?: boolean, listID?: number): ParagraphWidget;
753
+ private getNextBlockForList;
754
+ private updateListItems;
755
+ private updateListItemsForTable;
756
+ private updateListItemsForRow;
757
+ private updateListItemsForCell;
758
+ /**
759
+ * @param block
760
+ * @private
761
+ * @returns {void}
762
+ */
763
+ updateRenderedListItems(block: BlockWidget): void;
764
+ private updateRenderedListItemsForTable;
765
+ private updateRenderedListItemsForRow;
766
+ private updateRenderedListItemsForCell;
767
+ private updateListItemsForPara;
768
+ private updateRenderedListItemsForPara;
769
+ private updateListNumber;
770
+ /**
771
+ * @param blockAdv
772
+ * @param updateNextBlockList
773
+ * @param blockAdv
774
+ * @param updateNextBlockList
775
+ * @private
776
+ * @returns {void}
777
+ */
778
+ updateListItemsTillEnd(blockAdv: BlockWidget, updateNextBlockList: boolean): void;
779
+ }