mirror of
https://github.com/zen-browser/pdf.js.git
synced 2025-07-10 02:05:37 +02:00
Replace css color rgb(...) by #...
* it's faster to generate the color code in using a table for components * it's very likely a way faster to parse (when setting the color in the canvas)
This commit is contained in:
parent
bf870bd2ac
commit
9d11b51a3e
6 changed files with 15 additions and 18 deletions
|
@ -571,7 +571,7 @@ const TilingPattern = (function TilingPatternClosure() {
|
|||
current.strokeColor = ctx.strokeStyle;
|
||||
break;
|
||||
case PaintType.UNCOLORED:
|
||||
const cssColor = Util.makeCssRgb(color[0], color[1], color[2]);
|
||||
const cssColor = Util.makeHexColor(color[0], color[1], color[2]);
|
||||
context.fillStyle = cssColor;
|
||||
context.strokeStyle = cssColor;
|
||||
// Set color needed by image masks (fixes issues 3226 and 8741).
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue