ransome1 / sleek

todo.txt manager for Linux, Windows and MacOS, free and open-source (FOSS)
https://github.com/ransome1/sleek/wiki
MIT License
1.28k stars 99 forks source link

Full display height on 4k monitor is not used #639

Closed mdbdb closed 4 months ago

mdbdb commented 5 months ago

Bug Report

App Version: 2.0.6

Platform: Linux

Installation Method: App Store (Flatpak)

Bug Description: If the program window is opened to its full height (2160p) on a 4k display, only the top 80% of the window is filled with list entries. The lower 20% remain empty - scrolling with the mouse is also not possible.

If the window is reduced to half height, all entries are available and it is possible to scroll through the list. (The list would be long enough to scroll even at full height).

Steps to Reproduce:

  1. Start Sleek
  2. Maximize program window to full display height

Expected Behavior: Entries should be displayed right to the bottom of the window, the list should be scrollable.

Actual Behavior: See above: The bottom 20% of the window remains empty, even though there are enough entries. If an entry is marked as completed at the top and disappears from the list, a new entry will appear at the bottom. Scrolling is not possible.

Screenshots:

Screenshot 1: Full height (2160p)

Screenshot 2: Half height (1080p)

ransome1 commented 5 months ago

@mdbdb @thekryz I have literally no way of reproducing it since I only have access to a 13 inch laptop ;)

Could you please check this pre-release and tell me if this changes anything for you on the big screen? https://github.com/ransome1/sleek/releases/tag/v2.0.9-rc.3

thekryz commented 5 months ago

@mdbdb @thekryz I have literally no way of reproducing it since I only have access to a 13 inch laptop ;)

Could you please check this pre-release and tell me if this changes anything for you on the big screen? https://github.com/ransome1/sleek/releases/tag/v2.0.9-rc.3

Unfortunately it doesn't seem to fix the issue. For me, items are (still) cut off after the 30th item. I have rearranged my todos, so now some of the B category are invisible as well - until I bring the scrollbar back by reducing the window size.

ransome1 commented 5 months ago

@thekryz is it exactly the 30th item?

thekryz commented 5 months ago

@thekryz is it exactly the 30th item?

In this case yes, but I can't say for certain that it always is. It seems that in my previous Screenshots it wasn't.

mdbdb commented 4 months ago

Could you please check this pre-release and tell me if this changes anything for you on the big screen? https://github.com/ransome1/sleek/releases/tag/v2.0.9-rc.3

I downloaded the AppImage package from version 2.0.9.rc.3 and tested it with the same settings and a copy of the same todo.txt file.

As soon as the window is enlarged to the full display height, not all entries are displayed. No scrollbar available. However, there is one change: As @thekryz already stated, exactly 30 entries are displayed, the rest are not.

(I have just counted, in version 2.0.8. there are 26 entries that are displayed. In my screenshot in the original post there were 25...)

Screenshot v2.0.8 (left) / v.2.0.9.rc.3 (right):

sleek-screenshot

And, one more change: I just closed v2.0.9.rc.3 and opened it again, whereupon the window opened to full display height. All entries were there! However, as soon as I change the window (half display width, full display height, right display side), only 30 entries are displayed without a scrollbar. So everything is fine the first time I start the program, only when I change the window size or position is something wrong. (This is a change to v.2.0.8 - if I start here with full display height, the entries are still not displayed completely).

ransome1 commented 4 months ago

@mdbdb can I ask you if you have Snap installed on your Linux system? Since this will be a bit trial and error on my side, I wouldn't want to create countless pre-release, but instead rather push updates to the Edge channel of sleek's Snap.

You would install it with sudo snap install sleek --edge. If you could make this work I can start building another release, which cloud include the fix.

ransome1 commented 4 months ago

@thekryz @mdbdb it's a long shot again, but there is another attempt to solve this included in this latest pre-release: https://github.com/ransome1/sleek/releases/tag/v2.0.9-rc.4

Let me know if it changes anything.

thekryz commented 4 months ago

@ransome1 This one seems to do the trick for me. In my first experiments, I couldn't find any more cutting off the list. Everything displayed fine. I tried switching to sorting by due date and back, tried playing with window height / scrollbar - it all seemed to work well so far.

mdbdb commented 4 months ago

@thekryz @mdbdb it's a long shot again, but there is another attempt to solve this included in this latest pre-release: https://github.com/ransome1/sleek/releases/tag/v2.0.9-rc.4

Let me know if it changes anything.

This version actually seems to have fixed the error.

I started and stopped the app several times, changed the window size, set the sorting criteria differently -> the scrollbar was always present, all entries that should be displayed were displayed.

And sorry, Snap is not installed on my system, so that would not have been an option.

ransome1 commented 4 months ago

Thanks for reporting back, this is good news. sleek had a default value of how many rows will be rendered on app start. The scrolling event would then reload more rows. In your cases the default amount of rows did not fill the screen and therefor did not create a scroll bar. Without it, sleek was not able to lazy load more rows.

The new behavior measures your apps height and calculates how many rows fit into it. Plus it adds a buffer just in case and in theory this should have solved the issue. I hope it doesn't have any other effects I did not think about yet.