rssguard icon indicating copy to clipboard operation
rssguard copied to clipboard

[FR]: Lock position of article previewer window (verticle layout)

Open RetroAbstract opened this issue 2 years ago • 26 comments

Brief description of the feature request

This feature would allow the user to lock the position of the article previewer window.

Reason: The positioning of the article previewer gets automatically adjusted when moving RSS Guard from one monitor to another with a different resolution, resulting in having to always re-adjust it's positioning.

Would be located in: Right click in article previewer window > Lock window position.

RetroAbstract avatar Jul 11 '22 13:07 RetroAbstract

You mean position of the "separator" between article previewer and article list? Can you perhaps make a video of the problem?

martinrotter avatar Jul 15 '22 04:07 martinrotter

You mean position of the "separator" between article previewer and article list?

@martinrotter, That's how I understand it too.

Here:

article previewer gets automatically adjusted when moving RSS Guard from one monitor to another with a different resolution

Most likely cause is that RSS Guard sets article previewer size in pixels, not proportional to the total window size (e.g. in percents).

If you can confirm it then that where the problem is.

I can't test it myself unfortunately, so it's just a speculation.

Would be located in: Right click in article previewer window > Lock window position.

I don't think it needs to have a separate option, it should work properly by default.

That is, unless I misunderstand something, and this is a duplicate of https://github.com/martinrotter/rssguard/issues/424, about persistent article previewer.

akinokonomi avatar Jul 16 '22 20:07 akinokonomi

  1. Yes, value for "splitter" between article list and article viewer is set in pixels.
  2. I do not really do anything manual when window is moved between screens, all recalculations are done in upstream Qt libraries.

FOR ME: https://lists.qt-project.org/pipermail/interest/2016-October/024823.html

martinrotter avatar Jul 17 '22 06:07 martinrotter

all recalculations are done in upstream Qt libraries.

@martinrotter Indeed, it can be the upstream issue, and its integration of QtWebengine into UI. Qt6 supposed to have fixed their UI issues with screen scaling since Qt5, though. (No idea about Webengine.)

So you are saying pixels is the only way to keep coordinates of the article browser splitter? Does the feed list has it the same?

To clarify it for me, you just keep the position of splitter, not the size of the article viewer?


previewer gets automatically adjusted when moving RSS Guard from one monitor to another with a different resolution

@RetroAbstract, Do you experience it with nowebengine version of RSS Guard too? Could you test it please.

Also, just to confirm, do you have different scaling on those screens? And, you are on Windows, right?

akinokonomi avatar Jul 17 '22 18:07 akinokonomi

To clarify it for me, you just keep the position of splitter, not the size of the article viewer?

It is not straightforward. I remember "list of sizes" separated by the splitter/separator.

So I in fact remember heights (or widths) of those GUI components separated and those are in pixels. All recalculations of ratios etc. when transferring window to another screen are somehow done automatically.

Another thing is that I do not really have any chance to test some fix.

I have one fix on mind (but again no way to test):

  1. Detect when windows gets moved from screen to screen.
  2. Let's say that old values of splitter are 400/300 (heights of article list and article previewer).
  3. Get total height of available space on new screen and move splitter to 400/x position.

https://doc.qt.io/qt-6/qsplitter.html#sizes

martinrotter avatar Jul 20 '22 08:07 martinrotter

All recalculations of ratios etc. when transferring window to another screen are somehow done automatically.

Also notice that OP's having problems only with article viewer and not with feed list.

akinokonomi avatar Jul 20 '22 19:07 akinokonomi

You mean position of the "separator" between article previewer and article list? Can you perhaps make a video of the problem?

Yes the separator position, which determines the width of the article previewer window. I will have to note when the problem that originally made me submit this FR happens exactly & update this issue with more info.

@RetroAbstract, Do you experience it with nowebengine version of RSS Guard too? Could you test it please.

I use the nowebengine version by default.

Also, just to confirm, do you have different scaling on those screens? And, you are on Windows, right?

Yes I have different scaling percentages & resolutions on the 2 monitors, and yes I'm on Windows.

RetroAbstract avatar Aug 27 '22 13:08 RetroAbstract

@RetroAbstract Can you re-test this with latest Qt6-based 4,.2.4 build?

martinrotter avatar Sep 06 '22 06:09 martinrotter

@RetroAbstract Can you re-test this with latest Qt6-based 4,.2.4 build?

Tested with 4.2.4, the position of of the article previewer window remains the same when manually moving RSS Guard from one monitor to the other.

Will report back if the window position changes again without my input.

RetroAbstract avatar Sep 06 '22 13:09 RetroAbstract

So the problem is now de-facto solved?

martinrotter avatar Sep 12 '22 06:09 martinrotter

So the problem is now de-facto solved?

I have noticed the issue does not happen when manually moving RSS Guard from one monitor to the other, but rather when RSS Guard is launched after being closed for a while / when monitors are turned on again after being off for a while - then RSS Guard seems to forget what the previously set position of the article previewer was.

Note that it doesn't happen every time.

RetroAbstract avatar Sep 12 '22 14:09 RetroAbstract

but rather when RSS Guard is launched after being closed for a while

That's what I'm experiencing too, even with 4.2.4. The preview pane is completely shrunk and I have to manually resize it every time. Occurs with both vertical and horizontal view.

xfzv avatar Sep 12 '22 16:09 xfzv

What's the status of this? just curious.

xfzv avatar Nov 11 '22 12:11 xfzv

What's the status of this? just curious.

Same as when I opened this issue

RetroAbstract avatar Nov 13 '22 15:11 RetroAbstract

Well i planned to report this as a BUG as even on single screen the vertical article pane separator gets reset now and there, but im not sure its is still an issue with the newest version, need to check.

andrewpros avatar Dec 08 '22 16:12 andrewpros

Well i planned to report this as a BUG as even on single screen the vertical article pane separator gets reset now and there, but im not sure its is still an issue with the newest version, need to check.

Still occurs here with a build I compiled today (c51b6089-nowebengine)

xfzv avatar Dec 08 '22 21:12 xfzv

it would be really nice to have exact! steps to reproduce the problem as i was unable to reproduce really in the past

martinrotter avatar Dec 09 '22 04:12 martinrotter

Well i verified it and it is still the case with win 4.2.5 828697bd-nowebengine.

For me, i just need to exit, either by closing Windows or just closing the app by Quit option, its not every time so i dont know the trigger factor, but it happens after a max of couple of tries. After win restart its almost always.

andrewpros avatar Dec 09 '22 10:12 andrewpros

Well i verified it and it is still the case with win 4.2.5 828697b-nowebengine.

For me, i just need to exit, either by closing Windows or just closing the app by Quit option, its not every time so i dont know the trigger factor, but it happens after a max of couple of tries. After win restart its almost always.

Same experience as Andrew. Difficult to reproduce at will as even when Windows is restarted it might not happen.

RetroAbstract avatar Dec 09 '22 13:12 RetroAbstract

Just close the app from the tray, it will very quickly reset.

Splitter name is m_messageSplitter Saved only when changing app window size or moving the splitter In my case, it resets splitter_messages_horizontal config.ini value to 100, 0

It happens after the app is loaded so its not saving it with wrong value, i dont even need to click any feed, just restart, app window shows, boom, splitter_messages_horizontal is reset, u dont even see the splitter yet

If i had to guess, thats why, u dont see it so it "does not exists" but the save event is triggered for some reason which is a common issue with resize events, but if it does not exists it puts a default size there...

andrewpros avatar Dec 09 '22 17:12 andrewpros

Just close the app from the tray, it will very quickly reset.

Splitter name is m_messageSplitter Saved only when changing app window size or moving the splitter In my case, it resets splitter_messages_horizontal config.ini value to 100, 0

It happens after the app is loaded so its not saving it with wrong value, i dont even need to click any feed, just restart, app window shows, boom, splitter_messages_horizontal is reset, u dont even see the splitter yet

If i had to guess, thats why, u dont see it so it "does not exists" but the save event is triggered for some reason which is a common issue with resize events, but if it does not exists it puts a default size there...

Indeed.

Closing & restarting RSS Guard from tray icon resets the article previewer window position but in the following pattern:

  1. User-set position
  2. Reset/Close from tray
  3. User-set position untouched
  4. Reset/Close from tray again (second time)
  5. User-set position changed back to default.

RetroAbstract avatar Dec 09 '22 19:12 RetroAbstract

Yeah, but that was before i checked some things, now seems tray or not, it does not matter, as it resets when the app window shows, not when exiting. Funny thing is, it can also happen by using the app for longer time, just showing/hiding the window multiple times in a day, and on top of that, its possible u will not even see it in the UI until u restart, but it will save immediately and it wont save the proper size when u exit as this value is only saved then u resize. So it seems this is only one way issue, when the window shows and there is some kind of initialization that resets the size.

andrewpros avatar Dec 09 '22 19:12 andrewpros

I noticed that a system reboot is very likely to trigger the issue (I'm using Linux). I'm not using the tray icon.

xfzv avatar Dec 09 '22 19:12 xfzv

The thing is, it could be not the reboot, its what happened already when u run the app that day, and if it is what i suspect, the resize event, its qt based and system independent issue, normally u put some safe checks when it is needed for situations like this.

andrewpros avatar Dec 10 '22 00:12 andrewpros

Using 4.3.1 nowebengine in Windows and the "bug" persists. Splitter gets down when I click on an article (the first you click, obviously, when you get opened RSS guard).

image

It's happening the exact same behaviour in kubuntu 22.10 which is 4.0.x I think, and it comes with the webengine by default.

ghost avatar Jan 27 '23 08:01 ghost

It will persist as i dont think it was fixed.

andrewpros avatar Jan 27 '23 12:01 andrewpros