Relative Content

Tag Archive for javakotlintextpdfboxbounding-box

PDFBox get bounding box of text results in incorrect size

I want to use PDFBox to get the texts from the pdf with their bounding boxes. I’ve managed to get together a code from here that does almost this, but as you can see the bounding boxes I get (drawn with blue) are not the correct size as if I were to select the texts. Where could the calculation go wrong in my code?