pix-image-viewer icon indicating copy to clipboard operation
pix-image-viewer copied to clipboard

skip non-image files when rendering

Open katexochen opened this issue 2 years ago • 0 comments

When passing a directory with images and other files, currently the thumbnailer will print many errors:

[2024-01-06T21:38:22Z ERROR pix::group] make_thumb: image error: 0
[2024-01-06T21:38:22Z ERROR pix::group] make_thumb: image error: 0
[2024-01-06T21:38:22Z ERROR pix::group] make_thumb: image error: 0
[2024-01-06T21:38:22Z ERROR pix::group] make_thumb: image error: 0
[2024-01-06T21:38:22Z ERROR pix::group] make_thumb: image error: 0
[2024-01-06T21:38:22Z ERROR pix::group] make_thumb: image error: 0
[2024-01-06T21:38:22Z ERROR pix::group] make_thumb: image error: 0
[2024-01-06T21:38:22Z ERROR pix::group] make_thumb: image error: 0
[2024-01-06T21:38:22Z ERROR pix::group] make_thumb: image error: 0
[2024-01-06T21:38:22Z ERROR pix::group] make_thumb: image error: 0
[2024-01-06T21:38:22Z ERROR pix::group] make_thumb: image error: 0
[2024-01-06T21:38:22Z ERROR pix::group] make_thumb: image error: 0
[2024-01-06T21:38:22Z ERROR pix::group] make_thumb: image error: 0

In the rendered grid, there are spaces left empty where these files are in the directory list. I think it would be nice to skip files that aren't renderable instead and throw a warning at most.

Also there is a warning thrown when exiting the program and I'm not sure why:

warning: queue 0x55d63d40b9d0 destroyed while proxies still attached:
  wl_shm_pool@34 still attached
  xdg_wm_base@24 still attached
  wl_output@15 still attached
  wl_output@14 still attached
  wl_seat@13 still attached
  xdg_activation_v1@12 still attached
  wp_viewporter@11 still attached
  zwp_text_input_manager_v3@10 still attached
  zwp_pointer_constraints_v1@9 still attached
  zwp_relative_pointer_manager_v1@8 still attached
  zxdg_decoration_manager_v1@7 still attached
  wl_subcompositor@6 still attached
  wl_compositor@5 still attached
  wl_shm@4 still attached
  wl_registry@2 still attached

katexochen avatar Jan 06 '24 21:01 katexochen