@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.
- package/README.md +2 -2
- package/base.d.ts +4 -0
- package/base.js +4 -0
- package/dist/ej2-docx-renderer.umd.min.js +2 -0
- package/dist/ej2-docx-renderer.umd.min.js.map +1 -0
- package/dist/es6/ej2-docx-renderer.es2015.js +52432 -0
- package/dist/es6/ej2-docx-renderer.es2015.js.map +1 -0
- package/dist/es6/ej2-docx-renderer.es5.js +54425 -0
- package/dist/es6/ej2-docx-renderer.es5.js.map +1 -0
- package/dist/global/ej2-docx-renderer.min.js +2 -0
- package/dist/global/ej2-docx-renderer.min.js.map +1 -0
- package/dist/global/index.d.ts +5 -0
- package/format.d.ts +4 -0
- package/format.js +4 -0
- package/helper.d.ts +4 -0
- package/helper.js +4 -0
- package/index.d.ts +4 -0
- package/index.js +4 -0
- package/license +10 -0
- package/list.d.ts +4 -0
- package/list.js +4 -0
- package/package.json +26 -4
- package/parser.d.ts +4 -0
- package/parser.js +4 -0
- package/src/base/constants.d.ts +2 -0
- package/src/base/constants.js +2 -0
- package/src/base/dictionary.d.ts +52 -0
- package/src/base/dictionary.js +137 -0
- package/src/base/index.d.ts +9 -0
- package/src/base/index.js +9 -0
- package/src/base/keywords.d.ts +422 -0
- package/src/base/keywords.js +422 -0
- package/src/base/types.d.ts +2590 -0
- package/src/base/types.js +1056 -0
- package/src/base/unique-format.d.ts +87 -0
- package/src/base/unique-format.js +858 -0
- package/src/base/unique-formats.d.ts +32 -0
- package/src/base/unique-formats.js +87 -0
- package/src/document-canvas.d.ts +61 -0
- package/src/document-canvas.js +221 -0
- package/src/docx-renderer.d.ts +941 -0
- package/src/docx-renderer.js +2251 -0
- package/src/format/border.d.ts +53 -0
- package/src/format/border.js +600 -0
- package/src/format/borders.d.ts +44 -0
- package/src/format/borders.js +314 -0
- package/src/format/cell-format.d.ts +42 -0
- package/src/format/cell-format.js +309 -0
- package/src/format/character-format.d.ts +152 -0
- package/src/format/character-format.js +1224 -0
- package/src/format/index.d.ts +14 -0
- package/src/format/index.js +14 -0
- package/src/format/list-format.d.ts +32 -0
- package/src/format/list-format.js +238 -0
- package/src/format/paragraph-format.d.ts +103 -0
- package/src/format/paragraph-format.js +854 -0
- package/src/format/row-format.d.ts +119 -0
- package/src/format/row-format.js +545 -0
- package/src/format/section-format.d.ts +89 -0
- package/src/format/section-format.js +689 -0
- package/src/format/shading.d.ts +24 -0
- package/src/format/shading.js +137 -0
- package/src/format/style.d.ts +106 -0
- package/src/format/style.js +286 -0
- package/src/format/table-format.d.ts +51 -0
- package/src/format/table-format.js +395 -0
- package/src/global.js +1 -0
- package/src/helper/document-editor-helper.d.ts +515 -0
- package/src/helper/document-editor-helper.js +1302 -0
- package/src/helper/document-editor-settings.d.ts +293 -0
- package/src/helper/document-editor-settings.js +94 -0
- package/src/helper/index.d.ts +5 -0
- package/src/helper/index.js +5 -0
- package/src/helper/layout-helper-methods.d.ts +539 -0
- package/src/helper/layout-helper-methods.js +1065 -0
- package/src/helper/renderer-hooks.d.ts +74 -0
- package/src/helper/renderer-hooks.js +14 -0
- package/src/helper/revision-helper-methods.d.ts +199 -0
- package/src/helper/revision-helper-methods.js +362 -0
- package/src/index.d.ts +18 -0
- package/src/index.js +18 -0
- package/src/layout-helper.d.ts +190 -0
- package/src/layout-helper.js +1368 -0
- package/src/layout.d.ts +779 -0
- package/src/layout.js +17232 -0
- package/src/list/abstract-list.d.ts +25 -0
- package/src/list/abstract-list.js +67 -0
- package/src/list/index.d.ts +7 -0
- package/src/list/index.js +7 -0
- package/src/list/level-override.d.ts +22 -0
- package/src/list/level-override.js +43 -0
- package/src/list/list-level.d.ts +57 -0
- package/src/list/list-level.js +249 -0
- package/src/list/list.d.ts +30 -0
- package/src/list/list.js +100 -0
- package/src/page.d.ts +4155 -0
- package/src/page.js +11342 -0
- package/src/parser/index.d.ts +1 -0
- package/src/parser/index.js +1 -0
- package/src/parser/sfdt-reader.d.ts +254 -0
- package/src/parser/sfdt-reader.js +4569 -0
- package/src/render.d.ts +226 -0
- package/src/render.js +4222 -0
- package/src/text-helper.d.ts +144 -0
- package/src/text-helper.js +1079 -0
- package/src/text-helpers/index.d.ts +2 -0
- package/src/text-helpers/index.js +2 -0
- package/src/text-helpers/optimized.d.ts +45 -0
- package/src/text-helpers/optimized.js +121 -0
- package/src/text-helpers/regular.d.ts +37 -0
- package/src/text-helpers/regular.js +93 -0
- package/src/themes/font-scheme.d.ts +28 -0
- package/src/themes/font-scheme.js +107 -0
- package/src/themes/index.d.ts +6 -0
- package/src/themes/index.js +6 -0
- package/src/themes/major-minor-font-scheme.d.ts +14 -0
- package/src/themes/major-minor-font-scheme.js +45 -0
- package/src/themes/themes.d.ts +11 -0
- package/src/themes/themes.js +31 -0
- package/src/utility/index.d.ts +1 -0
- package/src/utility/index.js +1 -0
- package/src/utility/path-util.d.ts +133 -0
- package/src/utility/path-util.js +639 -0
- package/text-helpers.d.ts +4 -0
- package/text-helpers.js +4 -0
- package/themes.d.ts +4 -0
- package/themes.js +4 -0
- package/utility.d.ts +4 -0
- package/utility.js +4 -0
|
@@ -0,0 +1,144 @@
|
|
|
1
|
+
import { WCharacterFormat } from './format/character-format';
|
|
2
|
+
import { Dictionary } from './base/dictionary';
|
|
3
|
+
import { TextElementBox, ListTextElementBox, ParagraphWidget } from './page';
|
|
4
|
+
import { LtrRtlTextInfo, RtlInfo } from './helper/layout-helper-methods';
|
|
5
|
+
import { BiDirectionalOverride, CharacterRangeType, FontScriptType } from './base/types';
|
|
6
|
+
import { DocxRenderer } from './docx-renderer';
|
|
7
|
+
/**
|
|
8
|
+
* @private
|
|
9
|
+
*/
|
|
10
|
+
export interface TextSizeInfo {
|
|
11
|
+
Height?: number;
|
|
12
|
+
BaselineOffset?: number;
|
|
13
|
+
Width?: number;
|
|
14
|
+
}
|
|
15
|
+
/**
|
|
16
|
+
* @private
|
|
17
|
+
*/
|
|
18
|
+
export interface FontSizeInfo {
|
|
19
|
+
HeightFactor?: number;
|
|
20
|
+
BaselineFactor?: number;
|
|
21
|
+
}
|
|
22
|
+
/**
|
|
23
|
+
* @private
|
|
24
|
+
*/
|
|
25
|
+
export interface TextHeightInfo {
|
|
26
|
+
[key: string]: TextSizeInfo;
|
|
27
|
+
}
|
|
28
|
+
/**
|
|
29
|
+
* @private
|
|
30
|
+
*/
|
|
31
|
+
export interface FontHeightInfo {
|
|
32
|
+
[key: string]: FontSizeInfo;
|
|
33
|
+
}
|
|
34
|
+
/**
|
|
35
|
+
* @private
|
|
36
|
+
*/
|
|
37
|
+
export declare class TextHelper {
|
|
38
|
+
private documentHelper;
|
|
39
|
+
private context;
|
|
40
|
+
private paragraphMarkInfo;
|
|
41
|
+
private _position;
|
|
42
|
+
/**
|
|
43
|
+
* @private
|
|
44
|
+
* Current position of the fulltext
|
|
45
|
+
*/
|
|
46
|
+
position: number;
|
|
47
|
+
private static wordSplitCharacters;
|
|
48
|
+
private static numberNonReversingCharacters;
|
|
49
|
+
private readonly paragraphMark;
|
|
50
|
+
private readonly lineBreakMark;
|
|
51
|
+
getEnSpaceCharacter(): string;
|
|
52
|
+
repeatChar(char: string, count: number): string;
|
|
53
|
+
constructor(documentHelper: DocxRenderer);
|
|
54
|
+
getParagraphMarkWidth(characterFormat: WCharacterFormat): number;
|
|
55
|
+
getParagraphMarkSize(characterFormat: WCharacterFormat): TextSizeInfo;
|
|
56
|
+
getTextSize(elementBox: TextElementBox, characterFormat: WCharacterFormat): number;
|
|
57
|
+
getHeight(characterFormat: WCharacterFormat, scriptType?: FontScriptType): TextSizeInfo;
|
|
58
|
+
getFormatText(characterFormat: WCharacterFormat, fontToRender?: string): string;
|
|
59
|
+
measureTextExcludingSpaceAtEnd(text: string, characterFormat: WCharacterFormat, scriptType: FontScriptType): number;
|
|
60
|
+
getWidth(text: string, characterFormat: WCharacterFormat, scriptType?: FontScriptType): number;
|
|
61
|
+
getWidthWithZWJ(firstText: string, zwj: string, nextText: string, characterFormat: WCharacterFormat, scriptType?: FontScriptType): number;
|
|
62
|
+
setText(textToRender: string, isBidi: boolean, bdo: BiDirectionalOverride, isRender?: boolean): string;
|
|
63
|
+
measureText(text: string, characterFormat: WCharacterFormat, scriptType?: FontScriptType): TextSizeInfo;
|
|
64
|
+
updateTextSize(elementBox: ListTextElementBox, paragraph: ParagraphWidget): void;
|
|
65
|
+
containsSpecialCharAlone(text: string): boolean;
|
|
66
|
+
containsNumberAlone(text: string): boolean;
|
|
67
|
+
containsCombinationText(element: TextElementBox): boolean;
|
|
68
|
+
inverseCharacter(ch: string): string;
|
|
69
|
+
containsSpecialChar(text: string): boolean;
|
|
70
|
+
/**
|
|
71
|
+
* @private
|
|
72
|
+
* @param {string} text - Specifies the text
|
|
73
|
+
* @returns {boolean} - Returns true if given text it right to left.
|
|
74
|
+
*/
|
|
75
|
+
isRTLText(text: string): boolean;
|
|
76
|
+
/**
|
|
77
|
+
* @private
|
|
78
|
+
* @param {string} text - Specifies the text
|
|
79
|
+
* @param {FontScriptType} scriptType - Specifies the script type
|
|
80
|
+
* @returns {boolean} - Returns true if given text is unicode text.
|
|
81
|
+
*/
|
|
82
|
+
isUnicodeText(text: string, scriptType: FontScriptType, isWordBreak?: boolean): boolean;
|
|
83
|
+
/**
|
|
84
|
+
* @private
|
|
85
|
+
* @param {string} text - Specifies the text
|
|
86
|
+
* @param {Dictionary<TextElementBox, number>} elements - Elements of the text
|
|
87
|
+
* @param {boolean} isAutoWidth
|
|
88
|
+
* @param {boolean} isAllColumnHasAutoWidthType
|
|
89
|
+
*/
|
|
90
|
+
readWord(text: string, elements: Dictionary<TextElementBox, number>, isAutoWidth: boolean, isAllowAutoFit: boolean, isAllColumnHasAutoWidthType: boolean): string;
|
|
91
|
+
/**
|
|
92
|
+
* @private
|
|
93
|
+
* @param {number} pos - Current text position
|
|
94
|
+
* @param {Dictionary<TextElementBox, number>} elements - Elements of the text
|
|
95
|
+
*/
|
|
96
|
+
getElementBoxOfChar(pos: number, elements: Dictionary<TextElementBox, number>): TextElementBox;
|
|
97
|
+
/**
|
|
98
|
+
* @private
|
|
99
|
+
* @param {string} text - Text which contains non-breaking space character.
|
|
100
|
+
*/
|
|
101
|
+
isTextContainsNonBreakingSpaceCharacter(text: string): boolean;
|
|
102
|
+
/**
|
|
103
|
+
* @private
|
|
104
|
+
* @param {string} text - Text which contains non-breaking space character.
|
|
105
|
+
* @param {number} pos - Position of the empty space character
|
|
106
|
+
*/
|
|
107
|
+
isNonBreakingCharacterCombinedWithSpace(text: string, pos: number): boolean;
|
|
108
|
+
/**
|
|
109
|
+
* @private
|
|
110
|
+
* @param {string} text - Specifies the text
|
|
111
|
+
* @returns {RtlInfo} - Returns the text info.
|
|
112
|
+
*/
|
|
113
|
+
getRtlLanguage(text: string): RtlInfo;
|
|
114
|
+
/**
|
|
115
|
+
* @private
|
|
116
|
+
*/
|
|
117
|
+
splitTextByConsecutiveLtrAndRtl(text: string, isTextBidi: boolean, isRTLLang: boolean, characterRangeTypes: CharacterRangeType[], isPrevLTRText: LtrRtlTextInfo, hasRTLCharacter: LtrRtlTextInfo, isPrevLTRBidi: LtrRtlTextInfo, isPrevHebrewText?: LtrRtlTextInfo): string[];
|
|
118
|
+
/**
|
|
119
|
+
* @private
|
|
120
|
+
*/
|
|
121
|
+
isRightToLeftLanguage(lang: number): boolean;
|
|
122
|
+
private isNumber;
|
|
123
|
+
/**
|
|
124
|
+
* @private
|
|
125
|
+
*/
|
|
126
|
+
isWordSplitChar(character: string): boolean;
|
|
127
|
+
/**
|
|
128
|
+
* @private
|
|
129
|
+
*/
|
|
130
|
+
static isNumberNonReversingCharacter(character: string, isTextBidi: boolean): boolean;
|
|
131
|
+
/**
|
|
132
|
+
* @private
|
|
133
|
+
*/
|
|
134
|
+
isNonWordSplitCharacter(character: string): boolean;
|
|
135
|
+
getFontNameToRender(scriptType: FontScriptType, charFormat: WCharacterFormat): string;
|
|
136
|
+
private isEastAsiaScript;
|
|
137
|
+
private getFontNameEAToRender;
|
|
138
|
+
private getFontNameAsciiToRender;
|
|
139
|
+
private getFontNameBidiToRender;
|
|
140
|
+
private getFontNameFromTheme;
|
|
141
|
+
private updateFontNameFromTheme;
|
|
142
|
+
private getFontNameWithFontScript;
|
|
143
|
+
destroy(): void;
|
|
144
|
+
}
|