Browse Source

scale line width; set min font size to 8

notmasteryet 13 years ago
parent
commit
99d71cc713
  1. 4
      src/canvas.js

4
src/canvas.js

@ -18,7 +18,7 @@ var TextRenderingMode = {
}; };
// Minimal font size that would be used during canvas fillText operations. // Minimal font size that would be used during canvas fillText operations.
var MIN_FONT_SIZE = 5; var MIN_FONT_SIZE = 8;
var CanvasExtraState = (function CanvasExtraStateClosure() { var CanvasExtraState = (function CanvasExtraStateClosure() {
function CanvasExtraState(old) { function CanvasExtraState(old) {
@ -721,7 +721,7 @@ var CanvasGraphics = (function CanvasGraphicsClosure() {
if (scale == 0 || lineWidth == 0) if (scale == 0 || lineWidth == 0)
lineWidth = this.getSinglePixelWidth(); lineWidth = this.getSinglePixelWidth();
else else
lineWidth /= scale; lineWidth /= scale * fontSizeScale;
ctx.lineWidth = lineWidth; ctx.lineWidth = lineWidth;

Loading…
Cancel
Save