How to support mixed DPI in Xwayland?

Joseph Burt caseorum at gmail.com
Sun Sep 10 15:01:29 UTC 2017


Hi Olivier,

On Thu, Sep 7, 2017 at 6:17 PM, Olivier Fourdan <ofourdan at redhat.com> wrote:
>
> The other solution would be to have the same screen, but have Xwayland to
> give different scaling conversions for root window size, screen size, events
> coordinates, etc. depending on the client, if it's HiDPI aware or not,
> some sort of a "hidden" screen.

I'm not aware of a facility for X clients to advertise DPI awareness
to the X server. What would the heuristic be? Or just user-specified
scaling for a specific X client?

On scaling: DPI awareness isn't really possible in Wayland at the
moment. The client needs to be told what DPI the compositor would like
it to render, and must be able to acknowledge that. Pretty close to
the current spec would be to have wl_output::scale and buffer_scale
non-integers with an explicitly defined pixel size corresponding with
1 (96, 72 or 75 DPI, 0.25mm/pixel, whatever), but there are so many
possibilities. Even just the client attaching a differently-sized
buffer than it's surface "size" in such normed pixels would be
acknowledgment enough.

What's the current state of that conversation?

Cheers,
Joseph


More information about the wayland-devel mailing list