XListFonts



XListFonts

NAME
SYNTAX
ARGUMENTS
DESCRIPTION
SEE ALSO

NAME

XListFonts, XFreeFontNames, XListFontsWithInfo, XFreeFontInfo − obtain or free font names and information

SYNTAX

char **XListFonts(Display *display, char *pattern, int maxnames, int *actual_count_return);

int XFreeFontNames(char *list[]);

char **XListFontsWithInfo(Display *display, char *pattern, int maxnames, int *count_return, XFontStruct **info_return);

int XFreeFontInfo(char **names, XFontStruct *free_info, int actual_count);

ARGUMENTS

actual_count

Specifies the actual number of font names.

actual_count_return

Returns the actual number of font names.

count_return

Returns the actual number of matched font names.

display

Specifies the connection to the X server.

info_return

Returns the font information.

free_info

Specifies the font information.

list

Specifies the array of strings you want to free.

maxnames

Specifies the maximum number of names to be returned.

names

Specifies the list of font names.

pattern

Specifies the null-terminated pattern string that can contain wildcard characters.

DESCRIPTION

The XListFonts function returns an array of available font names (as controlled by the font search path; see XSetFontPath) that match the string you passed to the pattern argument. The pattern string can contain any characters, but each asterisk (*) is a wildcard for any number of characters, and each question mark (?) is a wildcard for a single character. If the pattern string is not in the Host Portable Character Encoding, the result is implementation-dependent. Use of uppercase or lowercase does not matter. Each returned string is null-terminated. If the data returned by the server is in the Latin Portable Character Encoding, then the returned strings are in the Host Portable Character Encoding. Otherwise, the result is implementation-dependent. If there are no matching font names, XListFonts returns NULL. The client should call XFreeFontNames when finished with the result to free the memory.

The XFreeFontNames function frees the array and strings returned by XListFonts or XListFontsWithInfo.

The XListFontsWithInfo function returns a list of font names that match the specified pattern and their associated font information. The list of names is limited to size specified by maxnames. The information returned for each font is identical to what XLoadQueryFont would return except that the per-character metrics are not returned. The pattern string can contain any characters, but each asterisk (*) is a wildcard for any number of characters, and each question mark (?) is a wildcard for a single character. If the pattern string is not in the Host Portable Character Encoding, the result is implementation-dependent. Use of uppercase or lowercase does not matter. Each returned string is null-terminated. If the data returned by the server is in the Latin Portable Character Encoding, then the returned strings are in the Host Portable Character Encoding. Otherwise, the result is implementation-dependent. If there are no matching font names, XListFontsWithInfo returns NULL.

To free only the allocated name array, the client should call XFreeFontNames. To free both the name array and the font information array or to free just the font information array, the client should call XFreeFontInfo.

The XFreeFontInfo function frees a font structure or an array of font structures and optionally an array of font names. If NULL is passed for names, no font names are freed. If a font structure for an open font (returned by XLoadQueryFont) is passed, the structure is freed, but the font is not closed; use XUnloadFont to close the font.

Note that XListFontsWithInfo is not thread-safe. If other threads make X requests on the same Display, then this function’s behavior is undefined.

SEE ALSO

XLoadFont(3), XSetFontPath(3)
Xlib − C Language X Interface






Opportunity


Personal Opportunity - Free software gives you access to billions of dollars of software at no cost. Use this software for your business, personal use or to develop a profitable skill. Access to source code provides access to a level of capabilities/information that companies protect though copyrights. Open source is a core component of the Internet and it is available to you. Leverage the billions of dollars in resources and capabilities to build a career, establish a business or change the world. The potential is endless for those who understand the opportunity.

Business Opportunity - Goldman Sachs, IBM and countless large corporations are leveraging open source to reduce costs, develop products and increase their bottom lines. Learn what these companies know about open source and how open source can give you the advantage.





Free Software


Free Software provides computer programs and capabilities at no cost but more importantly, it provides the freedom to run, edit, contribute to, and share the software. The importance of free software is a matter of access, not price. Software at no cost is a benefit but ownership rights to the software and source code is far more significant.


Free Office Software - The Libre Office suite provides top desktop productivity tools for free. This includes, a word processor, spreadsheet, presentation engine, drawing and flowcharting, database and math applications. Libre Office is available for Linux or Windows.





Free Books


The Free Books Library is a collection of thousands of the most popular public domain books in an online readable format. The collection includes great classical literature and more recent works where the U.S. copyright has expired. These books are yours to read and use without restrictions.


Source Code - Want to change a program or know how it works? Open Source provides the source code for its programs so that anyone can use, modify or learn how to write those programs themselves. Visit the GNU source code repositories to download the source.





Education


Study at Harvard, Stanford or MIT - Open edX provides free online courses from Harvard, MIT, Columbia, UC Berkeley and other top Universities. Hundreds of courses for almost all major subjects and course levels. Open edx also offers some paid courses and selected certifications.


Linux Manual Pages - A man or manual page is a form of software documentation found on Linux/Unix operating systems. Topics covered include computer programs (including library and system calls), formal standards and conventions, and even abstract concepts.