Use Xft.dpi for DPI if available.

fixes #2465
This commit is contained in:
Ingo Bürk
2016-09-23 15:09:49 +02:00
parent 1437271e65
commit cb1fcfed6a
8 changed files with 75 additions and 14 deletions

View File

@ -470,6 +470,13 @@ char *get_process_filename(const char *prefix);
*/
char *get_exe_path(const char *argv0);
/**
* Initialize the DPI setting.
* This will use the 'Xft.dpi' X resource if available and fall back to
* guessing the correct value otherwise.
*/
void init_dpi(void);
/**
* Convert a logical amount of pixels (e.g. 2 pixels on a “standard” 96 DPI
* screen) to a corresponding amount of physical pixels on a standard or retina