How to extract the color of a rectangle in a PDF, with iText

前端 未结 2 1512
甜味超标
甜味超标 2021-01-21 09:53

I\'m trying to extract the color of a rectangle in a PDF with iText. The following is all what the PDF page have:

And this is the page content extracted with iT

2条回答
  •  轮回少年
    2021-01-21 10:46

    To find the color of your rectangle, you may need to browse through the /Annots section of the PDF stream. Here, you are only exploring the /Contents, which doesn't include information such as color for the Rect entities.

    I hope it will help :)

提交回复
热议问题