Commit Graph

8 Commits

Author SHA1 Message Date
Kartik K. Agaram 2ff2692bb4 bugfix: use border color in scrollbars 2023-12-01 20:19:27 -08:00
Kartik K. Agaram 809a980213 implement second, 'output' editor
Also its scrollbar.
2023-11-18 21:18:09 -08:00
Kartik K. Agaram 8958100df1 make scrollbar opaque
This is another way to clarify foreground and background.
2023-11-18 16:24:06 -08:00
Kartik K. Agaram d0531fdd37 round scrollbar slightly 2023-11-18 14:39:27 -08:00
Kartik K. Agaram 62ea920dd4 slightly inset the scrollbar within its area
Mike Stein made the good point that when the buffer is empty it wasn't
clear if the blue area was the positive scrollbar or the negative space
within the scrollbar area.
2023-11-18 14:37:06 -08:00
Kartik K. Agaram 5444db930f no, make the scrollbar easier to acquire 2023-11-18 05:44:39 -08:00
Kartik K. Agaram fe8a21bea3 mouse events for scrollbar
You can either drag the scrollbar or click anywhere in the scrollbar
area.

It has this weird funkiness that the scrollbar shrinks as you get near
the bottom. But it feels.. weirdly satisfying?
2023-11-18 05:29:07 -08:00
Kartik K. Agaram 3717d7868a start sketching out a scrollbar
Not quite ideal: the scrollbar computation only considers
screen_bottom1.line and not screen_bottom1.pos, and so it always assumes
the final line is at the bottom of the screen.

I'm making a deeper change here that I might come to regret. I want to
avoid creating new book-keeping for editor mutations, so I'm putting the
work of computing scrollbar data into clear_screen_line_cache. But that
implies the editor should never clear before updating data, and I caught
one place that wasn't true before. A better name helps avoid this in
future. Let's see how much toil this causes in resolving conflicts.
2023-11-18 04:25:31 -08:00