|
|
@ -591,6 +591,7 @@ Edge.prototype._label = function (ctx, text, x, y) { |
|
|
|
x = 0; |
|
|
|
yLine = 0; |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
this._drawLabelRect(ctx); |
|
|
|
this._drawLabelText(ctx,x,yLine, lines, lineCount, fontSize); |
|
|
@ -639,7 +640,6 @@ Edge.prototype._drawLabelRect = function(ctx) { |
|
|
|
ctx.fillRect(-this.labelDimensions.width * 0.5, lineMargin, this.labelDimensions.width, this.labelDimensions.height); |
|
|
|
} |
|
|
|
else { |
|
|
|
ctx.fillStyle = this.options.fontFill; |
|
|
|
ctx.fillRect(this.labelDimensions.left, this.labelDimensions.top, this.labelDimensions.width, this.labelDimensions.height); |
|
|
|
} |
|
|
|
} |
|
|
@ -675,6 +675,9 @@ Edge.prototype._drawLabelText = function(ctx, x, yLine, lines, lineCount, fontSi |
|
|
|
ctx.textBaseline = "middle"; |
|
|
|
} |
|
|
|
} |
|
|
|
else { |
|
|
|
ctx.textBaseline = "middle"; |
|
|
|
} |
|
|
|
|
|
|
|
// check for strokeWidth
|
|
|
|
if (this.options.fontStrokeWidth > 0){ |
|
|
|