Qwerasd
04ec859925
terminal/kitty_graphics: update tests
...
Kitty Graphics command structures have been changed to hold decoded payloads not base64 strings.
2024-03-31 22:28:53 -04:00
Qwerasd
ca4b55b486
terminal/kitty_graphics: ignore base64 padding
...
Also move all base64 decoding to inside of the command parser.
2024-03-31 21:09:37 -04:00
Qwerasd
5dee7e1430
terminal/kitty_graphics: update outdated comments
2024-03-31 19:29:56 -04:00
Mitchell Hashimoto
d7ee705a7a
terminal/kitty: calculate cell height more efficiently
2024-03-22 20:28:01 -07:00
Mitchell Hashimoto
49e8acbcd2
core: configurable scrollback limit
2024-03-22 20:27:59 -07:00
Mitchell Hashimoto
9c2a5bccc1
terminal: page size should be accounted every creation
2024-03-22 20:27:52 -07:00
Mitchell Hashimoto
4c4d5f5a89
terminal/kitty: graphics exec ported
2024-03-22 20:27:44 -07:00
Mitchell Hashimoto
25d84d697a
termio/exec: get compiler errors gone
2024-03-22 20:27:44 -07:00
Mitchell Hashimoto
9b4ab0e209
zig build test with renamed terminal package
2024-03-22 20:27:44 -07:00
Mitchell Hashimoto
b7bf59d772
update zig
2024-03-22 11:15:26 -07:00
Krzysztof Wolicki
4add6889d8
Update to new compress.zlib API
2024-02-20 16:43:02 -08:00
Mitchell Hashimoto
793b657ca8
kitty-gfx: deletion should mark image state dirty to force redraw
...
Fixes #1537
2024-02-18 19:45:18 -08:00
Mitchell Hashimoto
6acf2b40af
terminal/kitty-gfx: mistaken logic
2024-02-12 19:35:02 -08:00
Mitchell Hashimoto
9193cfa6d2
style nit
2024-02-12 19:31:58 -08:00
Nameless
28ff9f7310
bug: std.os.realpath on non-windows asserts no nulls, make an error
2024-02-12 19:31:17 -08:00
Jonathan Marler
e1996ad1e5
os: remove UB, tmpDir is returning stack memory on Windows
...
On Windows, the tmpDir function is currently using a buffer on the stack
to convert the WTF16-encoded environment variable value "TMP" to utf8
and then returns it as a slice...but that stack buffer is no longer valid
when the function returns. This was causing the "image load...temporary
file" test to fail on Windows.
I've updated the function to take an allocator but it only uses
the allocator on Windows. No allocation is needed on other platforms
because they return environment variables that are already utf8 (ascii)
encoded, and the OS pre-allocates all environment variables in the process.
To keep the conditional that determines when allocation is required, I
added the `freeTmpDir` function.
2024-02-10 21:09:05 -07:00
Mitchell Hashimoto
238361698b
kitty graphics: use internal ID for placements with ID 0
...
Fixes #1356 correctly.
This was previously fixed by #1360 which just assigned a random
placement ID. I asked the Kitty maintainer about this and this is not
the correct logic and the spec has been updated.
When a placement ID of zero is sent, we allow multiple placements but
use an internal, non-addressable placement ID. The issue with my
previous approach was someone with knowledge of internals (or luck)
could technically address the placement. This isn't allowed.
2024-01-24 22:17:13 -08:00
Mitchell Hashimoto
46dd6e6caf
kitty graphics: assign automatic placement ID if p==0
...
Fixes #1356
As stated in the code, the specification itself doesn't explicitly
specify this behavior (as far as I can tell), but testing in Kitty
results in this working and I believe this is how they do it.
2024-01-22 15:51:51 -08:00
Mitchell Hashimoto
7c8b156960
kitty images: support pngs with greyscale/alpha (bpp=2)
...
Fixes #1355
2024-01-22 14:32:27 -08:00
Mitchell Hashimoto
553d81afd1
terminal: enable kitty graphics commands on OpenGL
2023-11-19 21:39:30 -08:00
Krzysztof Wolicki
44a48f62f1
change unmodified var
s to const
s in anticipation of zig changes
2023-11-17 15:46:46 +01:00
Mitchell Hashimoto
ad23a7a2c9
terminal/kitty-gfx: erase all should preserve storage limit size
2023-09-17 09:27:01 -07:00
Mitchell Hashimoto
708d6a4323
terminal/kitty-gfx: todo notes
2023-08-24 08:48:45 -07:00
Mitchell Hashimoto
f2f2b1eaf1
termio/exec: initial subprocess screen size should be sub padding
2023-08-24 08:45:32 -07:00
Mitchell Hashimoto
c962bd0abf
terminal/kitty-gfx: add error if both image id and num is set
2023-08-24 08:33:58 -07:00
Mitchell Hashimoto
ec5dcf0850
terminal/kitty-gfx: do not send response on transmit/display unless I
2023-08-23 22:37:01 -07:00
Mitchell Hashimoto
35f1a9a478
terminal/kitty-gfx: transmission only sends response when no more chunks
2023-08-23 22:01:21 -07:00
Mitchell Hashimoto
bf7054eeb6
terminal/kitty-gfx: ignore extra base64 padding
2023-08-23 21:52:50 -07:00
Mitchell Hashimoto
21ce787cff
terminal/kitty-gfx: data chunk can be zero size
2023-08-23 19:31:46 -07:00
Mitchell Hashimoto
53452bab78
terminal/kitty-gfx: chunked transmit and display
2023-08-23 17:55:41 -07:00
Mitchell Hashimoto
23c7d95ee1
terminal/kitty-gfx: only enable on Metal for now
2023-08-23 17:07:50 -07:00
Mitchell Hashimoto
46ba3189f6
config: image-storage-limit to set maximum image memory per terminal
2023-08-23 16:58:16 -07:00
Mitchell Hashimoto
79ea2ff2db
terminal/kitty-gfx: update todo
2023-08-23 16:45:23 -07:00
Mitchell Hashimoto
83e396044b
terminal/kitty-gfx: add per-screen storage limit
2023-08-23 14:14:31 -07:00
Mitchell Hashimoto
91a4be4ca1
terminal/kitty-gfx: add file loading safety checks from Kitty
2023-08-23 11:52:31 -07:00
Mitchell Hashimoto
135250018e
terminal/kitty-gfx: get rid of selection
2023-08-23 11:41:49 -07:00
Mitchell Hashimoto
de3ef0f78c
terminal/kitty-gfx: hook up delete
2023-08-23 11:37:14 -07:00
Mitchell Hashimoto
81498fe9be
terminal/kitty-gfx: delete newest
2023-08-23 11:35:14 -07:00
Mitchell Hashimoto
c0b58802ba
terminal/kitty-gfx: images store transmit time
2023-08-23 11:17:58 -07:00
Mitchell Hashimoto
73976824a1
terminal/kitty-gfx: delete by column, row, z
2023-08-23 11:12:51 -07:00
Mitchell Hashimoto
6f7a9c4523
terminal/kitty-gfx: we need to use rect, not sel
2023-08-23 11:07:48 -07:00
Mitchell Hashimoto
98f1b55ea4
terminal/kitty-gfx: delete intersection
2023-08-23 11:00:13 -07:00
Mitchell Hashimoto
9ab25ef350
terminal/kitty-gfx: delete intersecting cursor
2023-08-23 10:53:38 -07:00
Mitchell Hashimoto
6244cc38cc
terminal/kitty-gfx: delete by id
2023-08-23 10:38:40 -07:00
Mitchell Hashimoto
4b38fb96db
terminal/kitty-gfx: honor "z" setting
2023-08-23 09:55:13 -07:00
Mitchell Hashimoto
7ff76ca00d
terminal/kitty-gfx: respect display c/r params
2023-08-22 14:43:50 -07:00
Mitchell Hashimoto
3bbfee676b
terminal/kitty-gfx: process source rectangle display params
2023-08-22 14:33:41 -07:00
Mitchell Hashimoto
84c72bbe46
renderer/metal: honor cell offset graphics command
2023-08-22 13:28:40 -07:00
Mitchell Hashimoto
e6155b7f19
terminal/kitty-gfx: add placement function get selection
2023-08-22 13:15:00 -07:00
Mitchell Hashimoto
65df9f4618
terminal/kitty-gfx: down movement off by one
2023-08-22 12:23:27 -07:00