pqiv icon indicating copy to clipboard operation
pqiv copied to clipboard

with fullscreen=1 in the options, pqiv will sometimes open the wrong picture.

Open magnetophon opened this issue 7 years ago • 6 comments

When ~/config/pqiv contains

[options]
fullscreen=1

and you open a picture in a folder containing multiple pictures, pqiv will sometimes open another one.

I'm using pqiv 2.10.1.

magnetophon avatar Dec 11 '17 22:12 magnetophon

I'm not sure I can follow. You mean you run pqiv some_file.jpg and it opens another file from that directory? And your pqivrc is exactly as you've written, and there are no other options you're omitting here? (Like --sort or --browse?)

phillipberndt avatar Dec 11 '17 22:12 phillipberndt

Sorry, I didn't test properly. From the cli, it works as intended, but from ranger, it doesn't. This is with an otherwise empty pqivrc.

When I comment out fullscreen=1, it works again.

magnetophon avatar Dec 12 '17 00:12 magnetophon

Ah, and ranger uses --browse. Ok, that explains how other files can get into the play. I'll investigate. (Could you check if adding sort=1 changes anything?)

phillipberndt avatar Dec 12 '17 07:12 phillipberndt

sort=1 doesn't change anything. Where does ranger add --browse?

magnetophon avatar Dec 12 '17 09:12 magnetophon

Ah, it doesn't have --browse, but it still opens all images. See core/fm.py, function sxiv_workaround_hook. The configuration option is open_all_images. It's a pretty cool feature, but of course only if it works as intended :) I haven't managed to reproduce this yet, but will keep trying. In the meantime, if you don't use it, disable the option and the correct image should pop up at all times.

phillipberndt avatar Dec 12 '17 18:12 phillipberndt

Great workaround, especially when combined with browse=1 in pqivrc! Thanks.

magnetophon avatar Dec 12 '17 18:12 magnetophon