Xorg and DPI

So I decided, because reasons, that I wanted the PDF display application evince to display at actual size on my screen. This should be straightforward, as my monitor is correctly telling Xorg, when asked during EDID, its physical height and width in millimeters when displaying in maximal resolution mode. Thus, it would seem to be a simple matter to for Xorg to take this default physical size and resolution and use it to calculate a DPI value for applications such as evince to use. For my display, that would be about 88.67 DPI, as it turns out. Unfortunately, things are not so nice… First of all, evince is supposed to get physical size information from the XRandR extension information. XrandR keeps physical size up to date with respect to the current mode, as physical displayed size can vary between modes because of shadowboxing and stuff. However, evince ignores XRandR. Instead, it (and by it I probably mean Gnome here, rather than just evince; haven't checked) uses the DPI passed by X at connection startup. Since I'm running my display in its default resolution, you'd think this bug wouldn't matter to me normally, but there's more…

For reasons again, Xorg chooses to just force the DPI passed on startup to 96dpi, regardless of what it knows. I could find no xorg.conf setting to override this decision—not that I want an xorg.conf anyway. So, rather than deal with things properly, I went and found the spot in lightdm where it is starting X and gave the "-dpi 88.67" flag. Now my screen is sized properly…as long as I don't change monitors or graphic cards or resolution.

I will have a long talk with Keithp when he returns from Australia. In the meantime, at least I can now see things at actual size. Go me. (B)