qimgv icon indicating copy to clipboard operation
qimgv copied to clipboard

Images do not take up entire screen when in fullscreen using Fit to Window

Open HelmicNewciv opened this issue 1 year ago • 6 comments

When in windowed mode, images will initially open and properly fit in window, assuming they're of sufficient resolution. But as soon as I go to the next image in a folder, or if I switch to or start in fullscreen, there's instead very large margins on all sides of the image. This occurs even when the image is above 4k on a 4k monitor.

On a similar note, I would like a way to force images to always fit in the screen regardless of size, or to otherwise set a size under which they no longer stretch to fit the window. The current option seems to just limit the screen space an image will take up to x4, regardless of starting resolution, which is annoying on high resolution displays.

HelmicNewciv avatar Oct 01 '24 03:10 HelmicNewciv

Screenshot 2024-10-06 081127

Those 2 options will solve your issues. First red circle, for fitting image to window. Second red circle is what is causing your margins. It expands smaller images to fit window but can be adjusted to have a limit of how much. Which is what is causing your margins. Move it all the way to the left to have no margins.

soul4kills avatar Oct 06 '24 15:10 soul4kills

Those are my settings, yes. I've experimented with different values to see what the problem might be. I tried other fit modes as well - stretching to width still has margins on the sides of the image, even for very large images, but it won't have the vertical margins. Videos are not impacted and will fit to screen correctly. I'm using the qimgv-qt6-kde-git package from the AUR. Here's a copy of qimgv.conf:

[General]
JPEGSaveQuality=95
autoResizeLimit=100
autoResizeWindow=false
backgroundOpacity=1
blurBackground=true
confirmDelete=true
confirmTrash=true
cursorAutohiding=true
defaultCropAction=0
defaultFitMode=0
defaultViewMode=0
drawTransparencyGrid=false
enableSmoothScroll=true
expandImage=true
expandLimit=0
firstRun=false
fixedZoomLevels="0.05,0.1,0.125,0.166,0.25,0.333,0.5,0.66,1,1.5,2,3,4,5,6,7,8"
focusPointIn1to1Mode=0
folderEndAction=0
folderViewIconSize=120
imageScrolling=2
infoBarFullscreen=false
infoBarWindowed=false
jxlAnimation=false
keepFitMode=false
language=en_US
lastVerMajor=1
lastVerMicro=3
lastVerMinor=0
loopSlideshow=false
memoryAllocationLimit=1024
mpvBinary=/usr/bin/mpv
openInFullscreen=false
panelCenterSelection=false
panelEnabled=false
panelFullscreenOnly=true
panelPinned=false
panelPosition=top
panelPreviewsSize=140
playVideoSounds=true
scalingFilter=3
showSaveOverlay=true
slideshowInterval=3000
smoothAnimatedImages=true
smoothUpscaling=true
sortFolders=true
sortingMode=0
squareThumbnails=false
thumbPanelStyle=1
thumbnailCache=true
thumbnailerThreads=4
trackpadDetection=true
unloadThumbs=true
unlockMinZoom=true
useFixedZoomLevels=false
usePreloader=true
useSystemColorScheme=true
videoPlayback=true
windowTitleExtendedInfo=true
zoomIndicatorMode=0
zoomStep=0.20000000298023224

[Controls]
shortcuts="zoomIn=+", "frameStepBack=,", "zoomOut=-", "frameStep=.", "fitWindow=1", "fitWidth=2", "fitNormal=3", "zoomIn=eq", "exit=Alt+X", "folderView=Backspace", "copyFile=C", "zoomIn=Ctrl++", "zoomOut=Ctrl+-", "zoomIn=Ctrl+eq", "copyFileClipboard=Ctrl+C", "showInDirectory=Ctrl+D", "zoomOut=Ctrl+Down", "rotateLeft=Ctrl+L", "seekVideoBackward=Ctrl+Left", "open=Ctrl+O", "print=Ctrl+P", "exit=Ctrl+Q", "rotateRight=Ctrl+R", "seekVideoForward=Ctrl+Right", "save=Ctrl+S", "copyPathClipboard=Ctrl+Shift+C", "saveAs=Ctrl+Shift+S", "zoomIn=Ctrl+Up", "pasteFile=Ctrl+V", "setWallpaper=Ctrl+W", "zoomOutCursor=Ctrl+WheelDown", "zoomInCursor=Ctrl+WheelUp", "discardEdits=Ctrl+Z", "toggleShuffle=Ctrl+`", "moveToTrash=Del", "scrollDown=Down", "jumpToLast=End", "folderView=Enter", "closeFullScreenOrExit=Esc", "toggleFullscreen=F", "toggleFullscreen=F11", "renameFile=F2", "reloadImage=F5", "flipH=H", "jumpToFirst=Home", "toggleImageInfo=I", "toggleFullscreen=LMB_DoubleClick", "prevImage=Left", "moveFile=M", "contextMenu=Menu", "exit=MiddleButton", "openSettings=P", "resize=R", "contextMenu=RMB", "nextImage=Right", "removeFile=Shift+Del", "toggleFullscreenInfoBar=Shift+F", "prevDirectory=Shift+Left", "nextDirectory=Shift+Right", "toggleFitMode=Space", "scrollUp=Up", "flipV=V", "nextImage=WheelDown", "prevImage=WheelUp", "crop=X", "prevImage=XButton1", "nextImage=XButton2", "toggleSlideshow=`"

[Scripts]
script\size=0

HelmicNewciv avatar Oct 08 '24 23:10 HelmicNewciv

Okay. Now I'm confused at what option you are looking for. I'm only a user, so the scope my help is limited. Maybe a screenshot will help. Send screenshot of what you expect to happen maybe in another app and what is happening in the qimgv app.

And I'm on windows. So maybe the apps behaviors are a bit different since you're on KDE.

If you're looking for "Stretch to Fit". Which distorts and stretches the image to fit the window regardless of dimension. Which is usually undesired because it distorts the aspect ratio of the image. The app doesn't have it. Maybe using the right terminology would help. There's a few that exist.

Fill = Fills out window using shortest dimension of the image, preserves aspect ratio, crops image, no margins Stretch = Stretches image to window, distorts aspect ratio, no crop, no margins Fit = Fits image into window from longest dimension of image, preserves aspect ratio, no crop, has margins on shortest dimension Fit to Width = Fits using the width of image to sides of window, preserves aspect ratio, can crop and can still have margins depending on Fit to Height = Same as width but on the alternative dimension. 1:1 = actual size of image regardless of window size or anything. can crop can have margins, preserves aspect ratio

So which one of those are you looking for. Can only be 1. qimgv only has 3 of them.

soul4kills avatar Oct 10 '24 12:10 soul4kills

Ok I've just built the qimgv-qt6-kde-git from aur, and I just can't reproduce this... Fit window mode is working as expected, provided you set no limit for image expansion

Very strange. I'll also try on an external 2k monitor cause maybe the bug is resolution-dependant, but I doubt it

Could you post a screenshot of the issue?

easymodo avatar Oct 10 '24 17:10 easymodo

This is the image as pulled from https://github.com/linuxdotexe/nordic-wallpapers/blob/4451bb432fc855159ab77a2ee41a0d4b8f60555a/wallpapers/ign_highTechGlobe.png which is a native 4k image on my 4k screen.

image

This is the image as pulled from https://www.reddit.com/media?url=https%3A%2F%2Fi.redd.it%2Fp2nkmgo6p3ud1.png which is an ultrawide wallpaper.

image

No matter the dimensions of the original image, it always opens with these margins. I'm able to then zoom as normal, but switching to "fit to screen" or just opening an image normally will have these margins.

Sometimes, but not consistently, an image that I just open as a window but not in fullscreen won't have the margins. But sometimes it does open with the margins. If I use the arrow keys to change to another image in the folder, it goes back to having the margins again.

image

image

HelmicNewciv avatar Oct 12 '24 06:10 HelmicNewciv

After a recent update, qimv seems to no longer have the margins. I'm not sure what updated that might have changed this - maybe Krohnkite or Plasma? Nothing was changed in the configuration file, I updated my system yesterday and now today there's no issue.

HelmicNewciv avatar Oct 31 '24 09:10 HelmicNewciv

I confirm an issue on 1.03 under Lubuntu 24.04 that is similar enough I'll add it here rather than make a separate feature req. I have a lower version of Qt but it is the highest in the repo. I have the relevant slider but it maxes out at 4, so I assume this in intentional, not a bug. But if so, it seems a poor choice. But whose choice was it? Maybe this is a QT issue rather than a qimgv issue? I'd probably set it around 8 - 10 if I had my druthers, but it seems odd to put an arbitrary limit on it. Added: I tried;

  1. using a QT scaling variable, but all it did was change the size of the text in the ui.
  2. installing qt6, compiling the qt6 version and running that. Didn't change the problem and added another problem (not loading files that the qt5 version did fine with).

I'll leave this here, since it is marginally related, but in essence, for me this is a feature req, not a bug report, since it IS honoring the the scale-up limit setting. So I'll add this as another thread.

Image

Lew-Rockwell-Fan avatar Oct 01 '25 04:10 Lew-Rockwell-Fan