-
-
Notifications
You must be signed in to change notification settings - Fork 674
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix kitty image protocol display parameters #4847
Conversation
Thanks for looking into this! The thing that caught my eye, although I haven't read your diff in detail yet, is that there were some changes around how the cursor position is handled, so it would be good to confirm that |
Here's what I get running Wezterm 05eadb7kitty-image branch (this pr) |
If you wouldn't mind, could you run through these issues and confirm whether this PR addresses them? Thanks!
|
Here are the results of the tests. All seem to be displayed correctly. #1156 (kitty on the left, this branch on the right) #3918 (kitty on the left, this branch on the right) #1663 did not provide a file/script with which to reproduce, but from the problem description and the other results I think we can consider it closed. |
So this PR will close all of those issues? Excellent work, thank you! |
Yeah, #2761 can also be closed, as its changes are already integrated here (the part about the id=0) |
Hi! I've made some changes into the way that images get displayed to properly handle the kitty image protocol. The changes should not affect the iterm2 and sixel implementations.
I've also added in
test-data/kitty-png.py
some functions with test cases (intended to be checked manually) that should cover all the changes. To run each of the test just uncomment the one to be run and comment the rest.Here is a list of changes:
Here are some screenshots comparing kitty, the current wezterm
master
branch, and this pr branch.display_parameters (x, y, w, h, c, r) test
Kitty
Wezterm 05eadb7
This PR
cell_offsets (X, Y parameters) test
Kitty
Wezterm 05eadb7
This PR
For these I've used this picture, although any image should generate similar results.
![ferris](https://private-user-images.githubusercontent.com/31407988/299429553-8e4d620a-356c-4003-ac26-b5249dae2ce2.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MjAzNzUzMDAsIm5iZiI6MTcyMDM3NTAwMCwicGF0aCI6Ii8zMTQwNzk4OC8yOTk0Mjk1NTMtOGU0ZDYyMGEtMzU2Yy00MDAzLWFjMjYtYjUyNDlkYWUyY2UyLnBuZz9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNDA3MDclMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjQwNzA3VDE3NTY0MFomWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPTIxZTU5ZTFhZjZmMTliNmVlZDI4NjE1ZmU5MDdmYzA5NzQzNTkxMDllMTZlNTY3ZjlkYWZkZGVmYzg5YmQ0NjQmWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0JmFjdG9yX2lkPTAma2V5X2lkPTAmcmVwb19pZD0wIn0.4irT2mAuxagDG9QqrU5QdWhDqU_w4BdiDcAIG9HVOi4)
This PR should solve most of the issues described in #986 (comment)
I'll be happy to make any modification if needed :)