News for hackers. Stuff that matters.
Re:Linux touchpad like a MacBook: April 2020 update by alias_neo on Friday May 01, 2020 @05:14AM (#23040361)
Nice to know, thanks. You say X, does that mean not Wayland/X-Wayland?
Re:Linux touchpad like a MacBook: April 2020 update by Nursie on Friday May 01, 2020 @06:46AM (#23040797)
Pretty sure xrandr is just for X. Am on debian with Xfce, so not using wayland at present. AFAICT Wayland is the default option for Gnome sessions on debian, but I fell out with gnome around the 2->3 transition and have never looked back.

My xrandr line is not that easy to read but effectively, after I've set xfce hidpi support to double the size of screen elements, I increase the view window of the smaller screen by a factor of 1.8, and of the larger screen by a factor of 1.2, and put them next to each other -

xrandr --output HDMI-0 --mode 1920x1200 --pos 0x100 --scale 1.8x1.8 --output DP-2 --mode 3840x2160 --primary --scale 1.2x1.2 --pos 3456x-180

If Wayland can do that without so much messing around, great :)

Re:Linux touchpad like a MacBook: April 2020 update by vetinari on Friday May 01, 2020 @05:24AM (#23040412)
Wayland does that out of the box; unfortunately most people do not run Wayland, either because they prefer WM/DE that is X11 only (xfce, etc), or just because.

On X11, scaling of entire framebuffer (i.e. scaling macOS style) is a standard xrandr functionality, but it was never exposed to UI. It has some drawbacks that macOS never had to solve (how it behaves over remote x11/vnc/etc, or memory requirements for framebuffer, for example), that make it unsuitable as a general solution. It is basically one of the hacks complained in this threads.

Re:Linux touchpad like a MacBook: April 2020 update by alias_neo on Friday May 01, 2020 @06:15AM (#23040653)
I'm not sure what "Wayland does that out of the box" means; I ran 18.04 with Wayland since launch, it never gave me different scaling per monitor (not in the Gnome UI anyway).

Are you saying it would have worked had I used xrandr?

Re:Linux touchpad like a MacBook: April 2020 update by vetinari on Friday May 01, 2020 @06:27AM (#23040718)
xrandr is X11 only; it is X11 extension, after all.

Are you sure you were running Wayland? In Fedora under Wayland, you could pick a monitor and choose scaling for it in the setting applet.

Re:Linux touchpad like a MacBook: April 2020 update by alias_neo on Friday May 01, 2020 @09:03AM (#23041563)
I'm sure so far as when I login I select "Ubuntu on Wayland" and when I search through the output of top for "wayland" it's there. I'm not sure how else I prove I'm running Wayland. The machine I'm sending this from now is still running 18.04 on "Wayland" and I cannot set the DPI independently for each monitor, if I select my external monitor and set 200% and click "Done", I get 200% on all displays.
Re:Linux touchpad like a MacBook: April 2020 update by vetinari on Friday May 01, 2020 @02:55PM (#23045309)
You don't have to prove anything (but informatively, the way to detect wayland session is to check for XDG_SESSION_TYPE env variable). Also, just for curiosity, what GPU are you using?

It is quite possible that 18.04 has some bugs. I don't have 18.04 machine with hidpi monitor at hand, so I can't have a look myself, so I chalk it up that there is something weird happening.

Re:Linux touchpad like a MacBook: April 2020 update by alias_neo on Saturday May 02, 2020 @03:29AM (#23050070)
Thanks for the tip. The XPS 15 that I've tested this most on has a 1050.

I'm using the proprietary Nvidia driver.

My XPS 13 is using Intel from an 8th gen i7.