~akkartik/carousel.love

e848a890 — Kartik K. Agaram 25 days ago main
shield script from touch events when showing editor
a7fb9449 — Kartik K. Agaram 30 days ago
use an available constant
1f42711d — Kartik K. Agaram 30 days ago
indicate unsaved changes
6c596c0b — Kartik K. Agaram 30 days ago
hoist next_save to all saves

Now we can rely on its state even when we don't rely on autosave.
fff4dc19 — Kartik K. Agaram 30 days ago
explicitly state stance on autosave
ff27ad6a — Kartik K. Agaram 30 days ago
swap copy and paste menu buttons

Scenario: every once in a while I try to paste on my phone (in the
overflow menu) and fat finger and tap 'clear' next to it instead.

I could try adding space between the buttons in the overflow menu, but
that creates cascading issues of how it should look. Swapping these two
buttons is a hacky way to ensure that buttons that mutate the buffer
are never side by side.
c413f281 — Kartik K. Agaram a month ago
add to list of forks
bfc1f80b — Kartik K. Agaram a month ago
no, go back to drawing the menu after the editor

I originally made this change to keep the next/prev buttons from
overwriting the search bar. But now the dropdown menu up top gets
overwritten by the scrollbars! You can only see it if the window width
is just right, as happens on my phone.

I could fix this perfectly, but at the cost of some code complexity.
Just take that slight visual ugliness for now, it doesn't seem to impede
anything.
08f3b08f — Kartik K. Agaram a month ago
draw code editor after menu and output

scenario:
* run Carousel on a computer
* press ctrl+f

Before this commit, the search dialog that came up was occluded by the
output editor's scrollbar.
b7104398 — Kartik K. Agaram a month ago
Merge template-live-editor-mobile
7fab028c — Kartik K. Agaram a month ago
Merge template-live-editor
8d3bfa6b — Kartik K. Agaram a month ago
stop recommending the terminal

Freewheeling apps have been stable for many months now.
960380b8 — Kartik K. Agaram a month ago
Merge template-live-editor-mobile
5de5cdaf — Kartik K. Agaram a month ago
Merge template-live-editor
01efe059 — Kartik K. Agaram a month ago
Merge text0
b281b3dd — Kartik K. Agaram a month ago
Merge text.love
732ae693 — Kartik K. Agaram a month ago
Merge lines.love
093da1e7 — Kartik K. Agaram a month ago
add a mirror and reorg mirrors
c7a81906 — Kartik K. Agaram a month ago
slightly shrink the clickable area for a button

The reason is tooltips for buttons that lie along the left or bottom
edge of the app window. Since adding tooltips I noticed that the tooltip
on the 'next' button (which lies all down the right margin of the
window) would continue to be visible after the mouse moves off the
window. It turns out that LÖVE doesn't disable the mouse position
somehow after it goes off screen. It just remains at 0 or width-1 or
height-1.

Why was I not seeing the same issue with the 'previous' button? Kinda by
happy accident. The checks in button.lua were comparing using < and >,
not <= or >=. And the x coordinate when the mouse goes off window is 0.

So the quick solution is to remove one px of clickable area from the
bottom and right. It doesn't seem too hacky; the icon switches to
resizing the window anyway when you're _right_ at the border.

I'm also focusing now on the fact that pixel values in LÖVE go from 0 to
width-1 in spite of Lua's 1-based indexing in most places.
3293f3e1 — Kartik K. Agaram a month ago
some keyboard shortcuts on non-mobile devices

Hopefully this is easy to remember from left to right:
- run is F1
- stop is F2
- hide/show is F3
- save is F4
- load is F5

There are also tooltips to introduce these shortcuts to newcomers.

Most of the shortcuts are only enabled when code is visible. In keeping
with existing conventions for mouse events, we leave most event handlers
for the script when code is hidden. The only exception is 'F3' to show
code. So if you want to use a shortcut 'k' when code is hidden, you have
to instead use 'F3 k F3'.

This is all tentative and open to change. But I'll probably grow more
reluctant to change the shortcuts in a few weeks or months.
Next