mirror of
https://github.com/mozilla/pdf.js.git
synced 2026-06-26 10:05:47 +02:00
Fix the annotation base transform before drawing it
It fixes #7821. We do something similar for before drawing XObjects.
This commit is contained in:
parent
f05bad9872
commit
9ed5eef6d7
@ -2858,8 +2858,10 @@ class CanvasGraphics {
|
|||||||
this.ctx.canvas.height
|
this.ctx.canvas.height
|
||||||
);
|
);
|
||||||
|
|
||||||
|
this.baseTransformStack.push(this.baseTransform);
|
||||||
this.transform(opIdx, ...transform);
|
this.transform(opIdx, ...transform);
|
||||||
this.transform(opIdx, ...matrix);
|
this.transform(opIdx, ...matrix);
|
||||||
|
this.baseTransform = getCurrentTransform(this.ctx);
|
||||||
}
|
}
|
||||||
|
|
||||||
endAnnotation(opIdx) {
|
endAnnotation(opIdx) {
|
||||||
@ -2871,6 +2873,7 @@ class CanvasGraphics {
|
|||||||
delete this.annotationCanvas.savedCtx;
|
delete this.annotationCanvas.savedCtx;
|
||||||
delete this.annotationCanvas;
|
delete this.annotationCanvas;
|
||||||
}
|
}
|
||||||
|
this.baseTransform = this.baseTransformStack.pop();
|
||||||
}
|
}
|
||||||
|
|
||||||
paintImageMaskXObject(opIdx, img) {
|
paintImageMaskXObject(opIdx, img) {
|
||||||
|
|||||||
1
test/pdfs/.gitignore
vendored
1
test/pdfs/.gitignore
vendored
@ -897,3 +897,4 @@
|
|||||||
!tiling_patterns_variations.pdf
|
!tiling_patterns_variations.pdf
|
||||||
!function_based_shading.pdf
|
!function_based_shading.pdf
|
||||||
!issue16091.pdf
|
!issue16091.pdf
|
||||||
|
!issue7821.pdf
|
||||||
|
|||||||
BIN
test/pdfs/issue7821.pdf
Executable file
BIN
test/pdfs/issue7821.pdf
Executable file
Binary file not shown.
@ -14059,5 +14059,12 @@
|
|||||||
"md5": "ac6b2b69d9b3675b317708ec00aaf56c",
|
"md5": "ac6b2b69d9b3675b317708ec00aaf56c",
|
||||||
"rounds": 1,
|
"rounds": 1,
|
||||||
"type": "eq"
|
"type": "eq"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"id": "issue7821",
|
||||||
|
"file": "pdfs/issue7821.pdf",
|
||||||
|
"md5": "7f0f390a70228fffe95835518ec266c5",
|
||||||
|
"rounds": 1,
|
||||||
|
"type": "eq"
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user