You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This image viewer is amazing: Extremely fast and very nice to use from the command line!
However, it doesn't seem to let one control the image zoom, except by resizing the containing window, as it seems to always scale the image to fit the window. For very large images (lmuch arger than the screen resolution), this is very inconvenient. For images of other sizes, it would still be nice to have.
Following the spirit of meh, the way to go is probably to keep this functionality out of meh itself and doing something like
meh *| xargs -I___ mogrify -scale -10% ___
# Note that this code doesn't work, it's just to show the idea: Hitting # enter should scale down the image.# Note also that this, provided it worked like intended, would # permanently scale the actual image file, instead of just zooming # the display. This shouldn't be hard to work around, though.
However, this way we only get one-way zoom, and as there is just one STDOUT, I don't see an obvious way to trigger two (or more) different commands for zooming in and out. Maybe if meh hat an option to write to one of several (named) pipes, depending on keystroke? Not sure about that, but then I don't know much about pipes.
Another idea: Hitting a number key could output the image filename (like with enter) plus the respective number (after a whitespace). Then the command behind the pipe could decide on what to do depending on which number it received along with the filename.
Or maybe Ctrl plus any symbol key could act like that? Then this wouldn't be restricted to just the number keys (but to always holding the Ctrl key...).
The text was updated successfully, but these errors were encountered:
This image viewer is amazing: Extremely fast and very nice to use from the command line!
However, it doesn't seem to let one control the image zoom, except by resizing the containing window, as it seems to always scale the image to fit the window. For very large images (lmuch arger than the screen resolution), this is very inconvenient. For images of other sizes, it would still be nice to have.
Following the spirit of meh, the way to go is probably to keep this functionality out of meh itself and doing something like
However, this way we only get one-way zoom, and as there is just one STDOUT, I don't see an obvious way to trigger two (or more) different commands for zooming in and out. Maybe if meh hat an option to write to one of several (named) pipes, depending on keystroke? Not sure about that, but then I don't know much about pipes.
Another idea: Hitting a number key could output the image filename (like with enter) plus the respective number (after a whitespace). Then the command behind the pipe could decide on what to do depending on which number it received along with the filename.
Or maybe Ctrl plus any symbol key could act like that? Then this wouldn't be restricted to just the number keys (but to always holding the Ctrl key...).
The text was updated successfully, but these errors were encountered: