X logical font description
{{Short description|Legacy standard for specifying fonts and their properties in the X Windows System}}{{multiple|{{no footnotes|date=May 2017}}
{{cleanup-reorganize|date=April 2014}}}}
Image:Xfontsel.pngs of a font]]
X logical font description (XLFD) is a font standard used by the X Window System and first published in 1988.Jim Flowers; Stephen Gildea (1994). "X Logical Font Description Conventions" Modern X software typically relies on the newer Fontconfig system instead, but XLFDs are still supported in current X window implementations for compatibility with legacy software.
XLFD is intended to support:
- unique, descriptive font names that support simple pattern matching
- multiple font vendors, arbitrary character sets, and encodings
- naming and instancing of scalable and polymorphic fonts
- transformations and subsetting of fonts
- independence of X server and operating or file system implementations
- arbitrarily complex font matching or substitution
- extensibility
One prominent XLFD convention is to refer to individual fonts including any variations using their unique FontName. It comprises a sequence of fourteen hyphen-prefixed, X-registered fields:
- FOUNDRY: Type foundry - vendor or supplier of this font
- FAMILY_NAME: Typeface family
- WEIGHT_NAME: Weight of type
- SLANT: Slant (upright, italic, oblique, reverse italic, reverse oblique, or "other")
- SETWIDTH_NAME: Proportionate width (e.g. normal, condensed, narrow, expanded/double-wide)
- ADD_STYLE_NAME: Additional style (e.g. (Sans) Serif, Informal, Decorated)
- PIXEL_SIZE: Size of characters, in pixels; 0 (Zero) means a scalable font
- POINT_SIZE: Size of characters, in tenths of points
- RESOLUTION_X: Horizontal resolution in dots per inch (DPI), for which the font was designed
- RESOLUTION_Y: Vertical resolution, in DPI
- SPACING: monospaced, proportional, or "character cell"
- AVERAGE_WIDTH: Average width of characters of this font; 0 means scalable font
- CHARSET_REGISTRY: Registry defining this character set
- CHARSET_ENCODING: Registry's character encoding scheme for this set
The following sample is for a 75-dpi, 12-point, Charter font:
-bitstream-charter-medium-r-normal--12-120-75-75-p-68-iso8859-1[65 70 80_90]
(which also tells the font source that the client is interested only in characters 65, 70, and 80-90.)
References
- {{cite web |url=http://www.x.org/archive/X11R7.6/doc/xorg-docs/specs/XLFD/xlfd.pdf |title=X Logical Font Description Conventions |access-date=2015-11-22 |author=Jim Flowers |author2=Stephen Gildea |date=1994 |orig-date=1988 (first version, based on copyright) |work=Digital Equipment Corporation |publisher=X Consortium |ref=Flowers}}
- {{cite book |last=Mansfield |first=Niall |title=The Joy of X - An overview of the X Window System |publisher=Addison-Wesley |orig-year=1992 |year=1994 |location=Cambridge |pages=266–267 |chapter=System Administration |isbn=0-201-56512-9}}
{{reflist}}
{{free-software-stub}}