Skip site navigation (1)Skip section navigation (2)

FreeBSD Manual Pages

  
 
  

home | help
system_defaultfont(3)		 Arcan Lua API		 system_defaultfont(3)

NAME
       system_defaultfont - Set	/ Replace the current default font

SYNOPSIS
       boolres,	height,	baseline,
       system_defaultfont( fontres, fontsz, fonth, fallback )

DESCRIPTION
       For  text rendering functions, some kind	of font	is needed. The default
       font is set either by using this	function, or  indirectly  through  the
       first  render_text    call  with	an explicit font ( arg.	 fontres  is a
       string reference	to a valid file	in the SYS_FONT_RESOURCE    namespace,
       fontsz	 is the	size argument as used in render_text and fonth	speci-
       fies anti-aliasing strength (0: disabled, 1: light,  ...)  It  is  also
       possible	 to specify an additional fallback  font that will cover miss-
       ing glyphs not found in fontres . The downside is that the glyphs might
       not visually blend with the primary ones	in a visually  appealing  way,
       but may still be	better than invisible characters.

NOTES
       1      This  is	also implicitly	updated	in LWA	arcan builds if	it re-
	      ceives a FONTHINT	 event from the	display	server connection, and
	      there is no event-trigger	to detect if that occurs.

EXAMPLE
       function	system_defaultfont0()
	     system_defaultfont("default.ttf", 12, 0);
       end

SEE ALSO:
system				  April	2025		 system_defaultfont(3)

Want to link to this manual page? Use this URL:
<https://man.freebsd.org/cgi/man.cgi?query=system_defaultfont&sektion=3&manpath=FreeBSD+Ports+14.3.quarterly>

home | help