all repos — taro @ df6e8dd49ba08550d36ddaaaa2a3bc2166815a61

mblaze frontend in uxn + crystal

taro-ls: add indicator for pending operations; update readme
Iris Lightshard nilix@nilfm.cc
PGP Signature
-----BEGIN PGP SIGNATURE-----

iQIzBAABCAAdFiEEkFh6dA+k/6CXFXU4O3+8IhROY5gFAmQqRYMACgkQO3+8IhRO
Y5jgqQ/6Ai4ZcHR7P+12GPDcnrPTI8lP2cAkgkbsOwwgNLX9z3iJVbhuB5sb3Zgy
eVonvTpOkNXvew1fPLhrFqi/ghRT8v/xIIjjSFAo+dbSA98q2kxkeBLC/M3B9R8M
t8JZ0AhPcK89Py/RoUqg89IQzJtM+wR9S3TP9E32+xqmYK8vXS4gmSS+211i0Qn9
4uEifsz1egNDR+dQWvJNFnt+y1WPQ4jq0YSLBj1VJpeKAlEpsgyf8q8KyprY8O32
yleDreaNjBmXScE+xJDOXHN/s2kmMZm6n3uD1AvQ0oQvQn75Yy5m29ln0ENHD+Mg
E4FLeiQPxbLNod6mVyk2PoT0MzyRg3yc1qZEI6pX+hpf7V6eZfwavu//nOZwrz3C
65npjuqDoDPTxpd0PUq44dOi0YpPx4bymFjQKVDhXzUwtRsEQlWtvbGj6t5nFbJE
hkH47e6iDVr9/6D6NTzrwxFys/gvqHpGo8MXFZ8qSW0gsYz0f28Crh6mOKUoxMzB
9Z2cVx/blMGzB1f9idtqN6WKMCqh2/8+hXV2++C4T33TP9x6i/0lj2LMLw112ht9
lUL5cKJm+aU4bZGfNphdB4/EH9vQvIfQ8n85k/fdv5qKj5P4PchOuNkjR8TTQPBx
ojLpQzgZuXbm50B3rSeX7piMQVQ+fRlxc0ONrj/TPL9VYSJ7mVA=
=jTnb
-----END PGP SIGNATURE-----
commit

df6e8dd49ba08550d36ddaaaa2a3bc2166815a61

parent

43c528652721519dc3f429a264d39059ad816311

2 files changed, 68 insertions(+), 12 deletions(-)

jump to
M README.mdREADME.md

@@ -35,7 +35,7 @@ 2. Hilight, scrollbar, button hover color (turquoise)

3. Soft fg color eg. resize handle, textbox help (medium gray) 4. Foreground/text color (whitish gray) -Any 8x8 1bpp ASCII font in [icn](https://wiki.xxiivv.com/site/icn_format.html) format can be used. They can be created/edited in [nasu](https://git.sr.ht/~rabbits/nasu) and located at `TARO_LIB/font.icn`. +Any 8x8 1bpp ASCII font in [icn](https://wiki.xxiivv.com/site/icn_format.html) format can be used. They can be created/edited in [nasu](https://git.sr.ht/~rabbits/nasu) and should located at `TARO_LIB/font.icn`. ## usage

@@ -66,6 +66,11 @@ - search [`/`]: search mail with a regex (only headers, case insensitive)

- refile [`m`]: move mail to the given folder - trash [`Del`]: move mail to the Trash folder, unless it's already in the Trash, in which case it's deleted +In the bottom-left of the window is an indicator area with in which the following symbols may appear: + +- `$`: search query is active - refresh or switch mailboxes to deactivate +- `*`: an operation is pending (ie, more messages have been sent than received) + There is a resize handle in the bottom right - clicking and dragging it resizes the window. Additional keybindings:

@@ -74,8 +79,6 @@ - `[shift+]tab`: change mailboxes

- `up/down`: navigate through mail - `shift+<up|down>`: naive multiselect - `alt+<up|down|left|right>`: resize - -At the bottom-left, a small indicator will appear if you have a search query active. Performing the refresh action or switching mailboxes will make it disappear. ### reading mail

@@ -97,6 +100,12 @@ ### crypto

If you try to decrypt/sign with either `pinenetry-tty` or `pinentry-curses`, GPG will attach it to the stdio of `taro-ctl`, not the terminal window where you are viewing/composing mail. Use a graphical pinentry program instead. +### what it doesn't do + +- manage your contacts (there are other programs for this) +- manage your calendar (and that) +- add/remove mailboxes (how many times a year do you do this?) + ## TODO - Add options to search (case-sensitive, search mail body, etc)

@@ -130,4 +139,4 @@ - `15`: push view update (keeps search query, for after replying/writing mail or when new mail comes in); no payload

## socket (other IPC) -`taro-ctl` creates a socket at `TARO_LIB/taro.sock` and listens for bytes on it. Every time a byte is written to the socket, `taro-ctl` will use message `15` to update the inbox. Whatever method you use to sync your maildirs to your mailserver, it can write a byte to this socket when you receive mail!+`taro-ctl` creates a socket at `TARO_LIB/taro.sock` and listens for bytes on it. Every time a byte is written to the socket, `taro-ctl` will use message `15` to update the inbox. Whatever method you use to sync your maildirs to your mailserver, it can write a byte to this socket when you receive mail!
M taro-ls.taltaro-ls.tal

@@ -68,6 +68,7 @@ &top $2 &height $1 &select_index $2 &select_len $2

&sb_len $1 &sb_pos $2 &sb_step $2 ] @btn_colors [ &compose $1 &refresh $1 &read_all $1 &search $1 &refile $1 &trash $1 ] @btn_fns [ &compose $2 &refresh $2 &read_all $2 &search $2 &refile $2 &trash $2 ] +@pending_ops [ $1 ] ( program )

@@ -196,6 +197,12 @@ .decoding/processed LDZ2 .decoding/count LDZ2 EQU2 DUP ,&refresh_ui JCN

JMP2r &refresh_ui + ( we may erroneously decrement if we have a pending operation + AND we close a reader/compose window but this is rare ) + .pending_ops LDZ #00 EQU ,&no_dec_pending JCN + .pending_ops LDZ #01 SUB .pending_ops STZ + #01 .refresh/etc STZ + &no_dec_pending .list/bytes LDZ2 .decoding/count LDZ2 NEQ2 ,&no_list JCN #01 .refresh/list STZ &no_list

@@ -218,7 +225,8 @@ #0001 .list/select_len STZ2

#0000 .list/top STZ2 .list update_sb_pos - + + pending_ops++ #00 .textbox/searching STZ #01 .refresh/etc STZ

@@ -229,6 +237,9 @@

MARK_ALL_READ .Console/write DEO #00 .Console/write DEOk DEO ( message size is 0, no payload ) + + pending_ops++ + #01 .refresh/etc STZ JMP2r

@@ -237,6 +248,14 @@

SEARCH_MAIL .Console/write DEO ;textbox_text strlen SWP .Console/write DEO .Console/write DEO ;textbox_text send_str + + #0000 .list/select_index STZ2 + #0001 .list/select_len STZ2 + #0000 .list/top STZ2 + + .list update_sb_pos + + pending_ops++ #01 .textbox/searching STZ #01 .refresh/etc STZ

@@ -251,6 +270,9 @@ SWP .Console/write DEO .Console/write DEO

SWP .Console/write DEO .Console/write DEO ;textbox_text send_str + pending_ops++ + #01 .refresh/etc STZ + JMP2r @send_trash ( -- )

@@ -260,6 +282,9 @@ #0004 SWP .Console/write DEO .Console/write DEO

.list selection_to_range SWP .Console/write DEO .Console/write DEO SWP .Console/write DEO .Console/write DEO + + pending_ops++ + #01 .refresh/etc STZ JMP2r

@@ -304,6 +329,12 @@ STH2r

JMP2r +@pending_ops++ ( -- ) + + .pending_ops LDZk INC SWP STZ + +JMP2r + ( -== input ==- ) @on_key ( -> )

@@ -875,6 +906,7 @@ &no_textbox

.refresh/etc LDZ #00 EQU ,&no_etc JCN draw_search_indicator + draw_pending_indicator draw_resize_handle #00 .refresh/etc STZ &no_etc

@@ -890,13 +922,27 @@

@draw_search_indicator ( -- ) .textbox/searching LDZ #00 EQU ,&nothing JCN - ;search_indicator #0000 .Screen/height DEI2 #0008 SUB2 #01 draw_str - JMP2r + ;search_indicator #0000 .Screen/height DEI2 #0008 SUB2 #01 draw_str + JMP2r + &nothing + #0000 .Screen/x DEO2 + .Screen/height DEI2 #0008 SUB2 .Screen/y DEO2 + ;blank .Screen/addr DEO2 + #01 .Screen/sprite DEO + +JMP2r + +@draw_pending_indicator ( -- ) + + .pending_ops LDZ #00 EQU ,&nothing JCN + ;pending_indicator #0008 .Screen/height DEI2 #0008 SUB2 #01 draw_str + JMP2r &nothing - #0000 .Screen/x DEO2 - .Screen/height DEI2 #0008 SUB2 .Screen/y DEO2 - ;blank .Screen/addr DEO2 - #01 .Screen/sprite DEO + #0008 .Screen/x DEO2 + .Screen/height DEI2 #0008 SUB2 .Screen/y DEO2 + ;blank .Screen/addr DEO2 + #01 .Screen/sprite DEO + JMP2r @draw_bone ( -- )

@@ -1218,6 +1264,7 @@

( -== data ==- ) @search_indicator "$ 00 +@pending_indicator "* 00 @theme_file ".theme 00 @font_file "font.icn 00

@@ -1261,7 +1308,7 @@ 0408 191e 1d00 0000 4080 00a8 5000 0000

] @metadata [ 00 "taro 0a - "v0.2.1 0a + "v0.2.2 0a "GUI 20 "for 20 "mblaze 0a "Derek 20 "Stevens 20 "<nilix@nilfm.cc> 0a 00 ]