Package: cairo

CEnum cairo:font-type-t

Declaration

(cffi:defcenum font-type-t
  :toy
  :ft
  :win32
  :quartz
  :user
  :dwrite)  

Values

:toy
The font was created using Cairo's toy font API.
:ft
The font is of type FreeType.
:win32
The font is of type Win32.
:quartz
The font is of type Quartz.
:user
The font was created using Cairo's user font API.
:dwrite
The font is of type Win32 DWrite. Since 1.18

Details

The cairo:font-type-t enumeration is used to describe the type of a given font face or scaled font. The font types are also known as "font backends" within Cairo.

The type of a font face is determined by the function used to create it, which will generally be of the form type-font-face-create. The font face type can be queried with the cairo:font-face-type function.

The various cairo:font-face-t functions can be used with a font face of any type.

The type of a scaled font is determined by the type of the font face passed to the cairo:scaled-font-create function. The scaled font type can be queried with the cairo:scaled-font-type function.

The various cairo:scaled-font-t functions can be used with scaled fonts of any type, but some font backends also provide type-specific functions that must only be called with a scaled font of the appropriate type. These functions have names that begin with type-scaled-font such as the cairo:ft-scaled-font-lock-face function.

The behavior of calling a type-specific function with a scaled font of the wrong type is undefined.
 

See also

2025-1-29