@@ -86,7 +86,7 @@ public static function hasSourceText(string $pdfPath): bool
8686 *
8787 * @param string $pdfPath Path to the PDF file.
8888 * @return array<integer, string> A page-indexed array of text elements.
89- * Each text element includes text content, position, font, size, and color.
89+ * Each text element includes text content, position, font, size, and color.
9090 * @throws MindeePDFException Throws if the PDF can't be parsed or text elements can't be extracted.
9191 */
9292 public static function extractPagesTextElements (string $ pdfPath ): array
@@ -153,7 +153,7 @@ public static function downgradePDFVersion(string $inputPath): string
153153 *
154154 * @param Page $page Page object.
155155 * @return array<array<string, string|float|Font|null>> An array of text elements, each containing text content,
156- * position, font, size, and color.
156+ * position, font, size, and color.
157157 * @throws MindeePDFException Throws if the text elements can't be extracted.
158158 */
159159 public static function extractTextElements (Page $ page ): array
@@ -169,11 +169,11 @@ public static function extractTextElements(Page $page): array
169169 if (isset ($ text [1 ])) {
170170 $ textElements [] = [
171171 'text ' => $ text [1 ],
172- 'rotation ' => rad2deg ((float )($ text [0 ][2 ])),
173- 'x ' => (float )($ text [0 ][4 ]),
174- 'y ' => (float )($ text [0 ][5 ]),
172+ 'rotation ' => rad2deg ((float ) ($ text [0 ][2 ])),
173+ 'x ' => (float ) ($ text [0 ][4 ]),
174+ 'y ' => (float ) ($ text [0 ][5 ]),
175175 'font ' => $ page ->getFont ($ text [2 ]),
176- 'size ' => (float )($ text [3 ]),
176+ 'size ' => (float ) ($ text [3 ]),
177177 ];
178178 }
179179 }
0 commit comments