From 5d380107e41fff100d027fd279514fd7b0db4165 Mon Sep 17 00:00:00 2001 From: neauoire Date: Thu, 30 Nov 2023 17:21:58 -0800 Subject: [PATCH] (notepad) Use flag for collapsed state --- gui/notepad/notepad.tal | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/gui/notepad/notepad.tal b/gui/notepad/notepad.tal index 4a67178..a20745d 100644 --- a/gui/notepad/notepad.tal +++ b/gui/notepad/notepad.tal @@ -7,6 +7,7 @@ |0000 @page $1 + @collapsed $1 @selection &a $2 &b $2 &length $2 |0100 @@ -92,13 +93,13 @@ BRK &toggle-collapse ( -> ) - #00e0 .Screen/width DEO2 - #00f8 #0011 - DUP2 .Screen/height DEI2 EQU2 [ JMP SWP2 POP2 ] - .Screen/height DEO2 + .collapsed LDZ ?{ SWP2 } + POP2 .Screen/height DEO2 + .collapsed LDZ #00 EQU .collapsed STZ draw-header redraw + [ LIT2 00 -Mouse/state ] DEO BRK