Left and right padding for the last line in CompetitorInfo are equals now

This commit is contained in:
Stsiapan_Tsybulski committed 2016-10-18 10:17:40 +03:00
1 parent 4ac8f18fa4
commit 214ed92a3e
1 file changed
+2 -1
@@ -81,7 +81,8 @@ public class CompetitorInfoOverlay extends CanvasOverlayV3 {
ctx.beginPath();
ctx.moveTo(1.0,1.0);
ctx.lineTo(canvasWidth,1.0);
int bottomLineWidth = X_TEXT_COORDINATE + textLines[textLines.length - 1].length() * 5 + 10;
double lenghtOfTheLastLine = ctx.measureText(textLines[textLines.length - 1]).getWidth();
int bottomLineWidth = 2 * X_TEXT_COORDINATE + (int) lenghtOfTheLastLine;
ctx.lineTo(bottomLineWidth, infoBoxHeight);
ctx.lineTo(1.0,infoBoxHeight);
ctx.closePath();