Fix warning in read_from_stdin
Add version limit to libnsgif for now
Use utf8 in window titles
fix failed assertions when running from TTY
When running imv from a TTY, assertions in imv_window_create are hit.
This patch replaces these assertions with propogating the error upward
to setup_window.
It is necessary to change the return value of connect_to_wayland from
void to bool to indicate success, since the operation is fallible.
Signed-off-by: Nissa <and-nissa@protonmail.com>
GIFs with 0ms duration are treated as still images
Some GIFs specify 0 as each frame's duration but are still meant to be animated. Every other player I've tested (Firefox, mpv, ffplay)
will play the GIF with a default delay of 100 ms, but imv will treat the GIF as a still image and only display the first frame until
next_frame is explicitly requested, at which point the animation proceeds as expected.
Here's an example such file (contents: anime girl) <https://f.monade.li/oOSSvJ.gif>.
I've patched my imv as below, however I think that patch also causes non-animated GIFs to be treated as animations, which is a waste of CPU.
Something cleverer might be needed.
Sync mime-types from imv.desktop to imv-dir.desktop
Add image/avif to desktop file
imv can open this file type without any issues. This change makes other
applications (mainly: file managesr) use imv when opening an avif image
file.
Add arguments for initial width and height
imv: set FD_CLOEXEC for the write part of stdin pipes
Correct spelling mistakes
Replace old GitHub links for sourcehut ones
Remove trailing whitespace from wordexp-ed strings
Previous implementation was always leaving a trailing whitespace at the
end of the expanded string (used in window title, description text,
etc.). Now it doesn't happen.
Make sure imv and imv-dir have different names in .desktop
It might be different in other file managers, but in Thunar both imv and
imv-dir are currently displayed as "imv" in the "open with" menu. This
makes them indisutinguishable and impossible to choose the one user
wants. This commit ensures that they have different names in the desktop
files.