From 9010b3be5ae31d1347ecdd9f2c24ded9b5e0fe2c Mon Sep 17 00:00:00 2001 From: Luis Fernando Molina Date: Fri, 1 Jun 2018 21:14:36 +0200 Subject: [PATCH] Small Corrections in font size --- BottomSpace/BreakpointsBar.js | 16 ++++++++++++++++ ChartGrid.js | 1 - TimelineChart.js | 10 +++++----- 3 files changed, 21 insertions(+), 6 deletions(-) diff --git a/BottomSpace/BreakpointsBar.js b/BottomSpace/BreakpointsBar.js index 8ad01fc5b..6d122ca30 100644 --- a/BottomSpace/BreakpointsBar.js +++ b/BottomSpace/BreakpointsBar.js @@ -19,16 +19,32 @@ function newBreakpointsBar() { container.frame.position.y = 0; container.isDraggeable = false; + container.isClickeable = true; let logo; let canDrawLogo = false; + let datetime; + let timePeriod; + return thisObject; function initialize() { + viewPort.eventHandler.listenToEvent("Zoom Changed", onZoomChanged); + timePeriod = INITIAL_TIME_PERIOD; + } + function onZoomChanged(event) { + + timePeriod = recalculatePeriod(event.newLevel); + + } + + function setDatetime(pDatetime) { + + datetime = new Date(pDatetime); } function getContainer(point) { diff --git a/ChartGrid.js b/ChartGrid.js index d949592cc..4e24c2866 100644 --- a/ChartGrid.js +++ b/ChartGrid.js @@ -8,7 +8,6 @@ return chartGrid; - function draw(container, timeLineCoordinateSystem) { let periods = []; diff --git a/TimelineChart.js b/TimelineChart.js index a4eeadc14..5df6cad4a 100644 --- a/TimelineChart.js +++ b/TimelineChart.js @@ -918,9 +918,9 @@ if (INTENSIVE_LOG === true) { logger.write("[INFO] drawBackground -> Entering function."); } - let targetLabelFontSize = 150; - let fontSizeIncrement = 12.5; - let currentFontSize = 150; + let targetLabelFontSize = 120; + let fontSizeIncrement = 12; + let currentFontSize = 120; let market = markets.get(marketId); let label = market.assetA + " " + market.assetB; @@ -958,7 +958,7 @@ if (topPoint.y > viewPort.visibleArea.topLeft.y || bottomPoint.y < viewPort.visibleArea.bottomRight.y) { - targetLabelFontSize = 150 / 2; + targetLabelFontSize = 120 / 2; point = { x: 0, @@ -974,7 +974,7 @@ } else { - targetLabelFontSize = 150; + targetLabelFontSize = 120; point = { x: (viewPort.visibleArea.bottomRight.x - viewPort.visibleArea.bottomLeft.x) / 2 - label.length / 2 * currentFontSize * FONT_ASPECT_RATIO,