Description of the bug
after upgrade to PyMuPDF 1.24.2, the following code will print one paragraph for each page, not split lines.
Downgrade to PyMuPDF 1.22.5, doc.xref_stream(xref).decode().splitlines() works again, and it will print "line", not "paragraph" for one page.
How to reproduce the bug
for page in doc:
page.clean_contents() # cleanup page painting commands
xref = page.get_contents()[0] # get xref of the resulting source
cont0 = doc.xref_stream(xref).decode("utf8").splitlines() # and read it as lines of strings
for line in cont0:
print(line)
PyMuPDF version
1.24.2
Operating system
Windows
Python version
3.10