@syncfusion/ej2-pdf-export 24.1.41 → 24.1.47

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 (164) hide show
  1. package/CHANGELOG.md +8 -0
  2. package/dist/ej2-pdf-export.min.js +2 -2
  3. package/dist/ej2-pdf-export.umd.min.js +2 -2
  4. package/dist/ej2-pdf-export.umd.min.js.map +1 -1
  5. package/dist/es6/ej2-pdf-export.es2015.js +157 -28
  6. package/dist/es6/ej2-pdf-export.es2015.js.map +1 -1
  7. package/dist/es6/ej2-pdf-export.es5.js +157 -28
  8. package/dist/es6/ej2-pdf-export.es5.js.map +1 -1
  9. package/dist/global/ej2-pdf-export.min.js +2 -2
  10. package/dist/global/ej2-pdf-export.min.js.map +1 -1
  11. package/dist/global/index.d.ts +1 -1
  12. package/package.json +5 -5
  13. package/src/implementation/graphics/pdf-graphics.d.ts +35 -0
  14. package/src/implementation/graphics/pdf-graphics.js +157 -29
  15. package/dist/ts/implementation/actions/action.ts +0 -76
  16. package/dist/ts/implementation/actions/uri-action.ts +0 -52
  17. package/dist/ts/implementation/annotations/action-link-annotation.ts +0 -43
  18. package/dist/ts/implementation/annotations/annotation-collection.ts +0 -159
  19. package/dist/ts/implementation/annotations/annotation.ts +0 -241
  20. package/dist/ts/implementation/annotations/document-link-annotation.ts +0 -118
  21. package/dist/ts/implementation/annotations/link-annotation.ts +0 -32
  22. package/dist/ts/implementation/annotations/pdf-text-web-link.ts +0 -265
  23. package/dist/ts/implementation/annotations/uri-annotation.ts +0 -86
  24. package/dist/ts/implementation/collections/dictionary.ts +0 -150
  25. package/dist/ts/implementation/collections/object-object-pair/dictionary.ts +0 -125
  26. package/dist/ts/implementation/collections/utils.ts +0 -38
  27. package/dist/ts/implementation/document/automatic-fields/automatic-field-info-collection.ts +0 -39
  28. package/dist/ts/implementation/document/automatic-fields/automatic-field-info.ts +0 -108
  29. package/dist/ts/implementation/document/automatic-fields/automatic-field.ts +0 -127
  30. package/dist/ts/implementation/document/automatic-fields/composite-field.ts +0 -76
  31. package/dist/ts/implementation/document/automatic-fields/multiple-value-field.ts +0 -37
  32. package/dist/ts/implementation/document/automatic-fields/page-count-field.ts +0 -75
  33. package/dist/ts/implementation/document/automatic-fields/pdf-numbers-convertor.ts +0 -157
  34. package/dist/ts/implementation/document/automatic-fields/pdf-page-number-field.ts +0 -82
  35. package/dist/ts/implementation/document/automatic-fields/pdf-template-value-pair.ts +0 -60
  36. package/dist/ts/implementation/document/automatic-fields/single-value-field.ts +0 -48
  37. package/dist/ts/implementation/document/pdf-catalog.ts +0 -65
  38. package/dist/ts/implementation/document/pdf-document-base.ts +0 -180
  39. package/dist/ts/implementation/document/pdf-document-template.ts +0 -310
  40. package/dist/ts/implementation/document/pdf-document.ts +0 -342
  41. package/dist/ts/implementation/document/pdf-viewer-preferences.ts +0 -578
  42. package/dist/ts/implementation/drawing/pdf-drawing.ts +0 -218
  43. package/dist/ts/implementation/general/enum.ts +0 -21
  44. package/dist/ts/implementation/general/functions/pdf-function.ts +0 -66
  45. package/dist/ts/implementation/general/functions/pdf-sampled-function.ts +0 -63
  46. package/dist/ts/implementation/general/pdf-cache-collection.ts +0 -97
  47. package/dist/ts/implementation/general/pdf-collection.ts +0 -41
  48. package/dist/ts/implementation/general/pdf-destination.ts +0 -170
  49. package/dist/ts/implementation/graphics/brushes/enum.ts +0 -237
  50. package/dist/ts/implementation/graphics/brushes/pdf-blend.ts +0 -294
  51. package/dist/ts/implementation/graphics/brushes/pdf-brush.ts +0 -68
  52. package/dist/ts/implementation/graphics/brushes/pdf-brushes.ts +0 -2438
  53. package/dist/ts/implementation/graphics/brushes/pdf-color-blend.ts +0 -295
  54. package/dist/ts/implementation/graphics/brushes/pdf-gradient-brush.ts +0 -311
  55. package/dist/ts/implementation/graphics/brushes/pdf-linear-gradient-brush.ts +0 -406
  56. package/dist/ts/implementation/graphics/brushes/pdf-radial-gradient-brush.ts +0 -290
  57. package/dist/ts/implementation/graphics/brushes/pdf-solid-brush.ts +0 -107
  58. package/dist/ts/implementation/graphics/brushes/pdf-tiling-brush.ts +0 -304
  59. package/dist/ts/implementation/graphics/constants.ts +0 -31
  60. package/dist/ts/implementation/graphics/enum.ts +0 -413
  61. package/dist/ts/implementation/graphics/figures/arc.ts +0 -133
  62. package/dist/ts/implementation/graphics/figures/base/draw-element.ts +0 -59
  63. package/dist/ts/implementation/graphics/figures/base/element-layouter.ts +0 -260
  64. package/dist/ts/implementation/graphics/figures/base/fill-element.ts +0 -72
  65. package/dist/ts/implementation/graphics/figures/base/graphics-element.ts +0 -34
  66. package/dist/ts/implementation/graphics/figures/base/pdf-shape-element.ts +0 -69
  67. package/dist/ts/implementation/graphics/figures/base/shape-layouter.ts +0 -276
  68. package/dist/ts/implementation/graphics/figures/base/text-layouter.ts +0 -205
  69. package/dist/ts/implementation/graphics/figures/ellipse-part.ts +0 -76
  70. package/dist/ts/implementation/graphics/figures/enum.ts +0 -80
  71. package/dist/ts/implementation/graphics/figures/layout-element.ts +0 -132
  72. package/dist/ts/implementation/graphics/figures/path.ts +0 -646
  73. package/dist/ts/implementation/graphics/figures/pdf-template.ts +0 -205
  74. package/dist/ts/implementation/graphics/figures/rectangle-area.ts +0 -108
  75. package/dist/ts/implementation/graphics/figures/text-element.ts +0 -445
  76. package/dist/ts/implementation/graphics/fonts/enum.ts +0 -385
  77. package/dist/ts/implementation/graphics/fonts/pdf-font-metrics.ts +0 -248
  78. package/dist/ts/implementation/graphics/fonts/pdf-font.ts +0 -316
  79. package/dist/ts/implementation/graphics/fonts/pdf-standard-font-metrics-factory.ts +0 -606
  80. package/dist/ts/implementation/graphics/fonts/pdf-standard-font.ts +0 -243
  81. package/dist/ts/implementation/graphics/fonts/pdf-string-format.ts +0 -474
  82. package/dist/ts/implementation/graphics/fonts/pdf-true-type-font.ts +0 -165
  83. package/dist/ts/implementation/graphics/fonts/rtl/rtl-bidirectional.ts +0 -958
  84. package/dist/ts/implementation/graphics/fonts/rtl/rtl-text-shape.ts +0 -374
  85. package/dist/ts/implementation/graphics/fonts/rtl-renderer.ts +0 -255
  86. package/dist/ts/implementation/graphics/fonts/string-layouter.ts +0 -617
  87. package/dist/ts/implementation/graphics/fonts/string-tokenizer.ts +0 -275
  88. package/dist/ts/implementation/graphics/fonts/ttf-OS2-Table.ts +0 -206
  89. package/dist/ts/implementation/graphics/fonts/ttf-apple-cmap-sub-table.ts +0 -18
  90. package/dist/ts/implementation/graphics/fonts/ttf-cmap-sub-table.ts +0 -18
  91. package/dist/ts/implementation/graphics/fonts/ttf-cmap-table.ts +0 -14
  92. package/dist/ts/implementation/graphics/fonts/ttf-glyph-header.ts +0 -26
  93. package/dist/ts/implementation/graphics/fonts/ttf-glyph-info.ts +0 -35
  94. package/dist/ts/implementation/graphics/fonts/ttf-head-table.ts +0 -94
  95. package/dist/ts/implementation/graphics/fonts/ttf-horizontal-header-table.ts +0 -56
  96. package/dist/ts/implementation/graphics/fonts/ttf-loca-table.ts +0 -10
  97. package/dist/ts/implementation/graphics/fonts/ttf-long-hor-metric.ts +0 -14
  98. package/dist/ts/implementation/graphics/fonts/ttf-metrics.ts +0 -106
  99. package/dist/ts/implementation/graphics/fonts/ttf-microsoft-cmap-sub-table.ts +0 -58
  100. package/dist/ts/implementation/graphics/fonts/ttf-name-record.ts +0 -33
  101. package/dist/ts/implementation/graphics/fonts/ttf-name-table.ts +0 -22
  102. package/dist/ts/implementation/graphics/fonts/ttf-post-table.ts +0 -42
  103. package/dist/ts/implementation/graphics/fonts/ttf-reader.ts +0 -1254
  104. package/dist/ts/implementation/graphics/fonts/ttf-table-info.ts +0 -26
  105. package/dist/ts/implementation/graphics/fonts/ttf-trimmed-cmap-sub-table.ts +0 -26
  106. package/dist/ts/implementation/graphics/fonts/unicode-true-type-font.ts +0 -577
  107. package/dist/ts/implementation/graphics/images/byte-array.ts +0 -137
  108. package/dist/ts/implementation/graphics/images/image-decoder.ts +0 -439
  109. package/dist/ts/implementation/graphics/images/pdf-bitmap.ts +0 -110
  110. package/dist/ts/implementation/graphics/images/pdf-image.ts +0 -132
  111. package/dist/ts/implementation/graphics/pdf-color.ts +0 -478
  112. package/dist/ts/implementation/graphics/pdf-graphics.ts +0 -2429
  113. package/dist/ts/implementation/graphics/pdf-margins.ts +0 -124
  114. package/dist/ts/implementation/graphics/pdf-pen.ts +0 -370
  115. package/dist/ts/implementation/graphics/pdf-resources.ts +0 -300
  116. package/dist/ts/implementation/graphics/pdf-transformation-matrix.ts +0 -246
  117. package/dist/ts/implementation/graphics/pdf-transparency.ts +0 -93
  118. package/dist/ts/implementation/graphics/unit-convertor.ts +0 -96
  119. package/dist/ts/implementation/input-output/big-endian-writer.ts +0 -121
  120. package/dist/ts/implementation/input-output/cross-table.ts +0 -21
  121. package/dist/ts/implementation/input-output/enum.ts +0 -16
  122. package/dist/ts/implementation/input-output/pdf-cross-table.ts +0 -524
  123. package/dist/ts/implementation/input-output/pdf-dictionary-properties.ts +0 -571
  124. package/dist/ts/implementation/input-output/pdf-main-object-collection.ts +0 -194
  125. package/dist/ts/implementation/input-output/pdf-operators.ts +0 -363
  126. package/dist/ts/implementation/input-output/pdf-stream-writer.ts +0 -681
  127. package/dist/ts/implementation/input-output/pdf-writer.ts +0 -88
  128. package/dist/ts/implementation/pages/enum.ts +0 -201
  129. package/dist/ts/implementation/pages/page-added-event-arguments.ts +0 -39
  130. package/dist/ts/implementation/pages/pdf-document-page-collection.ts +0 -180
  131. package/dist/ts/implementation/pages/pdf-page-base.ts +0 -181
  132. package/dist/ts/implementation/pages/pdf-page-layer-collection.ts +0 -348
  133. package/dist/ts/implementation/pages/pdf-page-layer.ts +0 -271
  134. package/dist/ts/implementation/pages/pdf-page-settings.ts +0 -192
  135. package/dist/ts/implementation/pages/pdf-page-size.ts +0 -162
  136. package/dist/ts/implementation/pages/pdf-page-template-element.ts +0 -663
  137. package/dist/ts/implementation/pages/pdf-page.ts +0 -235
  138. package/dist/ts/implementation/pages/pdf-section-collection.ts +0 -187
  139. package/dist/ts/implementation/pages/pdf-section-page-collection.ts +0 -61
  140. package/dist/ts/implementation/pages/pdf-section-templates.ts +0 -96
  141. package/dist/ts/implementation/pages/pdf-section.ts +0 -644
  142. package/dist/ts/implementation/primitives/pdf-array.ts +0 -386
  143. package/dist/ts/implementation/primitives/pdf-boolean.ts +0 -119
  144. package/dist/ts/implementation/primitives/pdf-dictionary.ts +0 -513
  145. package/dist/ts/implementation/primitives/pdf-name.ts +0 -218
  146. package/dist/ts/implementation/primitives/pdf-number.ts +0 -165
  147. package/dist/ts/implementation/primitives/pdf-reference.ts +0 -430
  148. package/dist/ts/implementation/primitives/pdf-stream.ts +0 -306
  149. package/dist/ts/implementation/primitives/pdf-string.ts +0 -397
  150. package/dist/ts/implementation/structured-elements/grid/layout/grid-layouter.ts +0 -2027
  151. package/dist/ts/implementation/structured-elements/grid/pdf-grid-cell.ts +0 -1193
  152. package/dist/ts/implementation/structured-elements/grid/pdf-grid-column.ts +0 -206
  153. package/dist/ts/implementation/structured-elements/grid/pdf-grid-row.ts +0 -470
  154. package/dist/ts/implementation/structured-elements/grid/pdf-grid.ts +0 -853
  155. package/dist/ts/implementation/structured-elements/grid/styles/pdf-borders.ts +0 -240
  156. package/dist/ts/implementation/structured-elements/grid/styles/style.ts +0 -424
  157. package/dist/ts/implementation/structured-elements/tables/light-tables/enum.ts +0 -16
  158. package/dist/ts/interfaces/i-pdf-cache.ts +0 -23
  159. package/dist/ts/interfaces/i-pdf-changable.ts +0 -17
  160. package/dist/ts/interfaces/i-pdf-clonable.ts +0 -12
  161. package/dist/ts/interfaces/i-pdf-primitives.ts +0 -45
  162. package/dist/ts/interfaces/i-pdf-true-type-font.ts +0 -48
  163. package/dist/ts/interfaces/i-pdf-wrapper.ts +0 -13
  164. package/dist/ts/interfaces/i-pdf-writer.ts +0 -29
@@ -1,96 +0,0 @@
1
- /**
2
- * PdfUnitConverter.ts class for EJ2-PDF
3
- */
4
- import { PdfGraphicsUnit } from './../graphics/enum';
5
- /**
6
- * Used to perform `convertion between pixels and points`.
7
- * @private
8
- */
9
- export class PdfUnitConverter {
10
- //Fields
11
- /**
12
- * Indicates default `horizontal resolution`.
13
- * @default 96
14
- * @private
15
- */
16
- public static readonly horizontalResolution : number = 96;
17
- /**
18
- * Indicates default `vertical resolution`.
19
- * @default 96
20
- * @private
21
- */
22
- public static readonly verticalResolution: number = 96;
23
- /**
24
- * `Width, in millimeters`, of the physical screen.
25
- * @private
26
- */
27
- public static readonly horizontalSize: number;
28
- /**
29
- * `Height, in millimeters`, of the physical screen.
30
- * @private
31
- */
32
- public static readonly verticalSize: number;
33
- /**
34
- * `Width, in pixels`, of the screen.
35
- * @private
36
- */
37
- public static readonly pxHorizontalResolution: number;
38
- /**
39
- * `Height, in pixels`, of the screen.
40
- * @private
41
- */
42
- public static readonly pxVerticalResolution: number;
43
- /**
44
- * `Matrix` for conversations between different numeric systems.
45
- * @private
46
- */
47
- private proportions : number[];
48
- //constructors
49
- /**
50
- * Initializes a new instance of the `UnitConvertor` class with DPI value.
51
- * @private
52
- */
53
- public constructor( dpi : number) {
54
- this.updateProportionsHelper(dpi);
55
- }
56
- /**
57
- * `Converts` the value, from one graphics unit to another graphics unit.
58
- * @private
59
- */
60
- public convertUnits(value : number, from : PdfGraphicsUnit, to : PdfGraphicsUnit) : number {
61
- return this.convertFromPixels(this.convertToPixels(value, from), to);
62
- }
63
- /**
64
- * Converts the value `to pixel` from specified graphics unit.
65
- * @private
66
- */
67
- public convertToPixels(value : number, from : PdfGraphicsUnit) : number {
68
- let index : number = (from as number);
69
- let result : number = (value * this.proportions[index]) as number;
70
- return result;
71
- }
72
- /**
73
- * Converts value, to specified graphics unit `from Pixel`.
74
- * @private
75
- */
76
- public convertFromPixels(value : number, to : PdfGraphicsUnit) : number {
77
- let index : number = to as number;
78
- let result : number = (value / this.proportions[index]) as number;
79
- return result;
80
- }
81
- /**
82
- * `Update proportions` matrix according to Graphics settings.
83
- * @private
84
- */
85
- private updateProportionsHelper(pixelPerInch : number) : void {
86
- this.proportions = [
87
- pixelPerInch / 2.54, // Centimeter
88
- pixelPerInch / 6.0, // Pica
89
- 1, // Pixel
90
- pixelPerInch / 72.0, // Point
91
- pixelPerInch, // Inch
92
- pixelPerInch / 300.0, // Document
93
- pixelPerInch / 25.4 // Millimeter
94
- ];
95
- }
96
- }
@@ -1,121 +0,0 @@
1
- /**
2
- * Writes data in BigEndian order.
3
- */
4
- export class BigEndianWriter {
5
- //Constants
6
- /**
7
- * Size of Int32 type.
8
- */
9
- public readonly int32Size : number = 4;
10
- /**
11
- * Size of Int16 type.
12
- */
13
- public readonly int16Size : number = 2;
14
- /**
15
- * Size of long type.
16
- */
17
- public readonly int64Size : number = 8;
18
- //Fields
19
- /**
20
- * Internal buffer.
21
- */
22
- private buffer : number[];
23
- /**
24
- * Internal buffer capacity.
25
- */
26
- private bufferLength : number;
27
- /**
28
- * Current position.
29
- */
30
- private internalPosition : number;
31
- //Properties
32
- /**
33
- * Gets data written to the writer.
34
- */
35
- public get data() : number[] {
36
- if (this.buffer.length < this.bufferLength) {
37
- let length : number = this.bufferLength - this.buffer.length;
38
- for (let i : number = 0; i < length; i++) {
39
- this.buffer.push(0);
40
- }
41
- }
42
- return this.buffer;
43
- }
44
- /// <summary>
45
- /// Gets position of the internal buffer.
46
- /// </summary>
47
- public get position() : number {
48
- if (this.internalPosition === undefined || this.internalPosition === null) {
49
- this.internalPosition = 0;
50
- }
51
- return this.internalPosition;
52
- }
53
- //Constructors
54
- /**
55
- * Creates a new writer.
56
- */
57
- public constructor(capacity : number) {
58
- this.bufferLength = capacity;
59
- this.buffer = [];
60
- }
61
- /**
62
- * Writes short value.
63
- */
64
- public writeShort(value : number) : void {
65
- let bytes : number[] = [((value & 0x0000ff00) >> 8), value & 0x000000ff];
66
- this.flush(bytes);
67
- }
68
- /**
69
- * Writes int value.
70
- */
71
- public writeInt(value : number) : void {
72
- let i1 : number = (value & 0xff000000) >> 24;
73
- i1 = i1 < 0 ? 256 + i1 : i1;
74
- let i2 : number = (value & 0x00ff0000) >> 16;
75
- i2 = i2 < 0 ? 256 + i2 : i2;
76
- let i3 : number = (value & 0x0000ff00) >> 8;
77
- i3 = i3 < 0 ? 256 + i3 : i3;
78
- let i4 : number = value & 0x000000ff;
79
- i4 = i4 < 0 ? 256 + i4 : i4;
80
- let bytes : number[] = [(value & 0xff000000) >> 24, (value & 0x00ff0000) >> 16, (value & 0x0000ff00) >> 8, value & 0x000000ff ];
81
- this.flush(bytes);
82
- }
83
- /**
84
- * Writes u int value.
85
- */
86
- public writeUInt(value : number) : void {
87
- let buff : number[] = [(value & 0xff000000) >> 24, (value & 0x00ff0000) >> 16, (value & 0x0000ff00) >> 8, value & 0x000000ff ];
88
- this.flush(buff);
89
- }
90
- /**
91
- * Writes string value.
92
- */
93
- public writeString(value : string) : void {
94
- if (value == null) {
95
- throw new Error('Argument Null Exception : value');
96
- }
97
- let bytes : number[] = [];
98
- for (let i : number = 0; i < value.length; i++) {
99
- bytes.push(value.charCodeAt(i));
100
- }
101
- this.flush(bytes);
102
- }
103
- /**
104
- * Writes byte[] value.
105
- */
106
- public writeBytes(value : number[]) : void {
107
- this.flush(value);
108
- }
109
- // //Implementation
110
- private flush(buff : number[]) : void {
111
- if (buff === null) {
112
- throw new Error('Argument Null Exception : buff');
113
- }
114
- let position : number = this.position;
115
- for (let i : number = 0; i < buff.length; i++) {
116
- this.buffer[position] = buff[i];
117
- position++;
118
- }
119
- this.internalPosition += buff.length;
120
- }
121
- }
@@ -1,21 +0,0 @@
1
- /**
2
- * public Enum for `ObjectType`.
3
- * @private
4
- */
5
- export enum ObjectType {
6
- /**
7
- * Specifies the type of `Free`.
8
- * @private
9
- */
10
- Free = 0,
11
- /**
12
- * Specifies the type of `Normal`.
13
- * @private
14
- */
15
- Normal = 1,
16
- /**
17
- * Specifies the type of `Packed`.
18
- * @private
19
- */
20
- Packed = 2
21
- }
@@ -1,16 +0,0 @@
1
- /**
2
- * public Enum for `CompositeFontType`.
3
- * @private
4
- */
5
- export enum ObjectStatus {
6
- /**
7
- * Specifies the type of `None`.
8
- * @private
9
- */
10
- None,
11
- /**
12
- * Specifies the type of `Registered`.
13
- * @private
14
- */
15
- Registered
16
- }