figma-linux icon indicating copy to clipboard operation
figma-linux copied to clipboard

Tab bar using badly implemented CSDs

Open pontaoski opened this issue 3 years ago • 2 comments

After upgrading from 0.6.4 -> 0.7.1, I've noticed several regressions in regards to the tab bar, most caused by the usage of CSDs

The client side decorations are extremely poorly implemented, and they don't seem to work well in any desktop environment. Electron doesn't have the facilities to support these well; removing them and using the system titlebars where available would be the best course of operation. And no, making this an option doesn't count as a fix.

The issues caused by the CSDs are:

  • doesn't use system move gestures, which means snapping by dragging doesn't work, as well as other window effects applied to windows currently being driven. On Wayland sessions, this also comes with a slew of bugs of movement that means you cannot effectively move the window.
  • odd sizing. A maximized window seems to be larger than the bounds of the screen, which causes stuff that detects if something is on one screen to freak out in a way that it shouldn't.

pontaoski avatar Jan 30 '21 03:01 pontaoski

Look like this was introduced in the same commit that caused #172

git bisect start
# good: [a92b442ef23d9458702e3442cff42da424aa893a] Bump web binding api version
git bisect good a92b442ef23d9458702e3442cff42da424aa893a
# bad: [53b35f5403f91df0c9f7d1317bcec651ad78e0a5] Merge branch 'dev'
git bisect bad 53b35f5403f91df0c9f7d1317bcec651ad78e0a5
# good: [519f63304c4175e7f86f53af20be6b1ffc0d6caa] feat: implemented the openExtensionDirectory function
git bisect good 519f63304c4175e7f86f53af20be6b1ffc0d6caa
# bad: [8875f21b1d4648b521f644118c6fe5699df86961] feat: added a context menu for copy colors in the Theme Creator
git bisect bad 8875f21b1d4648b521f644118c6fe5699df86961
# bad: [cf6011660192f526cecc28c4153c874e4f7611ce] fix: updated styles of control window buttons
git bisect bad cf6011660192f526cecc28c4153c874e4f7611ce
# good: [b410ef16e205c24f0ac2b31ed9d07a9247d76e1d] fix: update the writeFiles function
git bisect good b410ef16e205c24f0ac2b31ed9d07a9247d76e1d
# bad: [9f7d1ccf7757ce51b48c3fb8c529846da50c000a] feat: add the new project button
git bisect bad 9f7d1ccf7757ce51b48c3fb8c529846da50c000a
# bad: [77c8ce6b833be302aa3af9a12e8acb443656a646] feat: add color profile settings
git bisect bad 77c8ce6b833be302aa3af9a12e8acb443656a646
# bad: [302518e1f8fcb6e2d206f90a2a0110577f5369e9] feat: update main menu
git bisect bad 302518e1f8fcb6e2d206f90a2a0110577f5369e9
# first bad commit: [302518e1f8fcb6e2d206f90a2a0110577f5369e9] feat: update main menu

pontaoski avatar Jan 30 '21 04:01 pontaoski

FWIW, 0.6.x CSD implementation didn't have the window snapping issue (#166) and was optional.

Electron really doesn't have a good and elegant way to do CSD (e.g. with respecting user theme and window button placement), so reverting to just the regular ugly titlebar in the meantime might be the right course of action.

jannuary avatar Jan 30 '21 14:01 jannuary