Video-Hub-App icon indicating copy to clipboard operation
Video-Hub-App copied to clipboard

[BUG] app resizes to half size after close each time

Open whyboris opened this issue 6 months ago • 2 comments

Description

This bug happens for a user, it might happen because of this:

To Reproduce

  1. Have 2 monitors
  2. Have 2 different scaling ratios on them (150% and 200% for example)
  3. Close app, reopen, see it change size (maybe move from one screen to other first)

Expected behavior

App remembers its size

Actual behavior

Size reduced to 50% in width and to 50% original height

Additional context

We're using electron-window-state

Might be this bug: https://github.com/mawie81/electron-window-state/issues/80 and a potential solution is shared there.

whyboris avatar Jun 18 '25 19:06 whyboris

Maybe find another library; here's one:

  • https://github.com/xupea/stateful-electron-window/
  • https://www.npmjs.com/package/stateful-electron-window

whyboris avatar Jun 18 '25 19:06 whyboris

More details from user:

The issue seems to have been caused by the “Scale and layout” settings. Setting both monitors to the same scaling ratio resolved the problem. Also, when I moved VHA to the 4K monitor and restarted it, the bug did not appear.

I’ve found a temporary workaround for now. By going into the VHA properties, under the Compatibility tab, and adjusting the “High DPI settings” so that the DPI is controlled by the application, the shrinking window bug no longer occurs.

whyboris avatar Jun 27 '25 19:06 whyboris