Browse Source

shading-pattern: While drawing patterns, transform to the baseTransform first

Daan Sprenkels 10 years ago
parent
commit
a9081653fc
  1. 3
      src/display/canvas.js
  2. 1
      test/pdfs/.gitignore
  3. BIN
      test/pdfs/issue6296.pdf
  4. 6
      test/test_manifest.json

3
src/display/canvas.js

@ -1089,6 +1089,9 @@ var CanvasGraphics = (function CanvasGraphicsClosure() {
if (isPatternFill) { if (isPatternFill) {
ctx.save(); ctx.save();
if (this.baseTransform) {
ctx.setTransform.apply(ctx, this.baseTransform);
}
ctx.fillStyle = fillColor.getPattern(ctx, this); ctx.fillStyle = fillColor.getPattern(ctx, this);
needRestore = true; needRestore = true;
} }

1
test/pdfs/.gitignore vendored

@ -181,6 +181,7 @@
!issue6081.pdf !issue6081.pdf
!issue6069.pdf !issue6069.pdf
!issue6106.pdf !issue6106.pdf
!issue6296.pdf
!bug1001080.pdf !bug1001080.pdf
!issue6108.pdf !issue6108.pdf
!issue6113.pdf !issue6113.pdf

BIN
test/pdfs/issue6296.pdf

Binary file not shown.

6
test/test_manifest.json

@ -2510,6 +2510,12 @@
"link": true, "link": true,
"type": "eq" "type": "eq"
}, },
{ "id": "issue6296.pdf",
"file": "pdfs/issue6296.pdf",
"md5": "734e191aab1372e6fd7523ca7751fcf0",
"rounds": 1,
"type": "eq"
},
{ "id": "issue5549.pdf", { "id": "issue5549.pdf",
"file": "pdfs/issue5549.pdf", "file": "pdfs/issue5549.pdf",
"md5": "6c36df6ebc583c9e18aad0ad00d257b8", "md5": "6c36df6ebc583c9e18aad0ad00d257b8",

Loading…
Cancel
Save