Skip to content

Commit

Permalink
Merge pull request #590 from awwaawwa/fix_colorspace
Browse files Browse the repository at this point in the history
fix(pdfinterp): Keep the color space effective after processing xobject.
  • Loading branch information
Byaidu authored Feb 11, 2025
2 parents a7e6b81 + 55fd6c6 commit fece247
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions pdf2zh/pdfinterp.py
Original file line number Diff line number Diff line change
Expand Up @@ -224,6 +224,8 @@ def do_Do(self, xobjid_arg: PDFStackT) -> None:
[xobj],
ctm=ctm,
)
self.ncs = interpreter.ncs
self.scs = interpreter.scs
try: # 有的时候 form 字体加不上这里会烂掉
self.device.fontid = interpreter.fontid
self.device.fontmap = interpreter.fontmap
Expand Down

0 comments on commit fece247

Please sign in to comment.