Skip to content
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

[foot terminal] [vifm] image blinks 2 times and then disappears #4

Open
akhiljalagam opened this issue Nov 17, 2022 · 4 comments
Open

Comments

@akhiljalagam
Copy link

On the first preview, the image blinks 2 times and then disappears. It shows up from the second time.

terminal: foot
TERM: foot
shell: zsh
vifm: Version: 0.12
@akhiljalagam akhiljalagam changed the title image blinks 2 times and disappears on first preview image blinks 2 times and then disappears Nov 17, 2022
@eylles
Copy link
Owner

eylles commented Nov 18, 2022

ah sorry, i have not updated this in quite a long time and i use xterm, rn i'm back to using ueberzug and been tweaking my own fork of vifmimg.

anyway the cause to your problem could be the sixel scrolling mode, DECSDM, there was quit the discussion about it some time ago about what the correct default was supposed to be, with xterm even changing it's historic default for a while, try to run echo '\e[?80l' before starting vifm, my bet is that will help.

as for this i'm considering combining it with vifmimg and have a "one size fits all" solution to display images on terminals inside vifm, wich will be a bash wrapper that will determine what image preview method can be used if any and then set up the environment for vifm, then a "dumb" img-prev script that will just use the avaible method to show something, be it the image or just text info of the file.

@akhiljalagam
Copy link
Author

akhiljalagam commented Nov 19, 2022

Tried echo '\e[?80l', no luck.

@akhiljalagam
Copy link
Author

akhiljalagam commented Aug 16, 2023

By modifying the vifm config, I can resolve the blinking problem. You should add %pu to successfully resolve the issue.

fileviewer <image/*>
\ vifm-sixel draw %pw %ph %c %pd %pu
\ %pc
\ vifm-sixel clear

from the vifm manpage:

   %pu       uncached preview.  Intended to be used for commands that just
            send file path somewhere for preview.

@akhiljalagam akhiljalagam changed the title image blinks 2 times and then disappears [foot terminal] [vifm] image blinks 2 times and then disappears Aug 16, 2023
@eylles
Copy link
Owner

eylles commented Aug 27, 2023

thanks, refactoring this is still on my todo list but haven't gotten to it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants