STR 2658: documentation fixes on Fl::set_fonts

This commit is contained in:
Matthias Melcher 2023-01-20 12:35:56 +01:00
parent 0eeb6fe33e
commit 18aaa32e45

17
FL/Fl.H
View File

@ -1155,15 +1155,24 @@ public:
that the normal one is first, followed by bold, italic, and bold
italic.
The optional argument is a string to describe the set of fonts to
The only argument to this function is somehat obsolete since FLTK and most
underlying operating systems move to support Unicode. For completeness,
following is the original documentation and a few updates:
On X11, the optional argument is a string to describe the set of fonts to
add. Passing NULL will select only fonts that have the
ISO8859-1 character set (and are thus usable by normal text). Passing
"-*" will select all fonts with any encoding as long as they have
normal X font names with dashes in them. Passing "*" will list every
font that exists (on X this may produce some strange output). Other
values may be useful but are system dependent. With Windows NULL
selects fonts with ISO8859-1 encoding and non-NULL selects
all fonts.
values may be useful but are system dependent.
With the Xft option on Linux, this parameter is ignored.
With Windows, `NULL` selects fonts with ANSI_CHARSET encoding and non-NULL
selects all fonts.
On macOS, this parameter is ignored.
The return value is how many faces are in the table after this is done.
*/