From 16d00819899260085ee10949012b07bf1c203db6 Mon Sep 17 00:00:00 2001 From: Russ Cox Date: Thu, 15 Nov 2018 23:52:05 -0500 Subject: libdraw: redo default font construction to be hidpi-safe If $font is not set, the default font is constructed from font data linked into every libdraw binary. That process was different from the usual openfont code, and so it was not hidpi-aware, resulting in very tiny fonts out of the box on hidpi systems, until users set $font. Fix this by using openfont to construct the default font, by recognizing the name *default* when looking for font and subfont file contents. Then all the hidpi scaling applies automatically. As a side effect, the concept of a 'default subfont' is gone, as are display->defaultsubfont, getdefont, and memgetdefont. --- include/memdraw.h | 1 - 1 file changed, 1 deletion(-) (limited to 'include/memdraw.h') diff --git a/include/memdraw.h b/include/memdraw.h index b1495ed8..a22dbe2b 100644 --- a/include/memdraw.h +++ b/include/memdraw.h @@ -178,7 +178,6 @@ extern Memsubfont* allocmemsubfont(char*, int, int, int, Fontchar*, Memimage*); extern Memsubfont* openmemsubfont(char*); extern void freememsubfont(Memsubfont*); extern Point memsubfontwidth(Memsubfont*, char*); -extern Memsubfont* getmemdefont(void); /* * Predefined -- cgit v1.2.3