From 8e79b72279cda5bc71c83417dcec5139f9285b44 Mon Sep 17 00:00:00 2001 From: Loic Coyle Date: Sat, 21 Sep 2024 17:15:03 +0200 Subject: [PATCH] Revert "fix: round floats to ints" This reverts commit cf9918904f9a87a1f14ace250af2f652c18e0dc6. --- tinyticker/layouts/big_logo.py | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/tinyticker/layouts/big_logo.py b/tinyticker/layouts/big_logo.py index d47e302..623a76c 100644 --- a/tinyticker/layouts/big_logo.py +++ b/tinyticker/layouts/big_logo.py @@ -58,10 +58,7 @@ def big_logo( ), ), ) - plot_size = ( - plot_width, - logo_height - int(round(range_text_font.getbbox(range_text)[3])), - ) + plot_size = (plot_width, logo_height - range_text_font.getbbox(range_text)[3]) fig, axes = historical_plot(plot_size, ticker, resp) apply_layout_config(axes[0], ticker.config.layout, resp) @@ -83,7 +80,7 @@ def big_logo( font=range_text_font, fill=0, ) - available_space = int(round(size[1] - (plot_size[1] + (range_text_bbox[3])))) + available_space = size[1] - (plot_size[1] + (range_text_bbox[3])) price_text = f"{CURRENCY_SYMBOLS.get(ticker.currency, '$')}{resp.current_price:.2f}" price_text_bbox = regular_font.getbbox(price_text)