From 2cbe610b956975571b59509d83f80faafd13dac0 Mon Sep 17 00:00:00 2001 From: = <=> Date: Wed, 21 Jul 2021 20:48:41 +0100 Subject: [PATCH] Correct FORCE_TEXT --- src/calc.c | 18 +++++++++++------- 1 file changed, 11 insertions(+), 7 deletions(-) diff --git a/src/calc.c b/src/calc.c index cd4a741..8b1ed7b 100644 --- a/src/calc.c +++ b/src/calc.c @@ -258,16 +258,20 @@ static void code_click_subscribe(void *context) } #ifdef LOW_MEM - #define DISPLAY_LINE " (hrt) \":\" (mnt))\n" + #define TIME_FUNC \ + "(def time (fn ()(utl tt \n"\ + " (cat \"Hey, it's \" \n"\ + " (hrt) \":\" (mnt)\n" \ + "))))\n" #else - #define DISPLAY_LINE " (hrt) \":\" (if (> 10 (mnt)) \"0\" \"\") (mnt))\n" + #define TIME_FUNC \ + "(def time (fn () ((def m (mnt)) (utl tt \n"\ + " (cat \"Hey, it's \"\n"\ + " (hrt) \":\" (if (< m 10) \"0\" \"\") m)\n"\ + "))))\n" #endif -#define FORCE_TEXT \ - "(def time (fn () (utl tt \n"\ - " (cat \"Hey, it's \" \n"\ - DISPLAY_LINE \ - ")))\n" \ +#define FORCE_TEXT TIME_FUNC \ "(def ww (cw))\n" \ "(def tt (atl ww \":\"))\n" \ "(pw ww)\n" \