FontProtocol
public protocol FontProtocol
PangoCairoFont is an interface exported by fonts for
use with Cairo.
The actual type of the font will depend on the particular font technology Cairo was compiled to use.
The FontProtocol protocol exposes the methods and properties of an underlying PangoCairoFont instance.
The default implementation of these can be found in the protocol extension below.
For a concrete class that implements these methods and properties, see Font.
Alternatively, use FontRef as a lighweight, unowned reference if you already have an instance you just want to use.
-
Untyped pointer to the underlying
PangoCairoFontinstance.Declaration
Swift
var ptr: UnsafeMutableRawPointer! { get } -
font_ptrDefault implementationTyped pointer to the underlying
PangoCairoFontinstance.Default Implementation
Return the stored, untyped pointer as a typed pointer to the
PangoCairoFontinstance.Declaration
Swift
var font_ptr: UnsafeMutablePointer<PangoCairoFont>! { get } -
Required Initialiser for types conforming to
FontProtocolDeclaration
Swift
init(raw: UnsafeMutableRawPointer)
-
getScaledFont()Extension methodGets the
cairo_scaled_font_tused byfont. The scaled font can be referenced and kept usingcairo_scaled_font_reference().Declaration
Swift
@inlinable func getScaledFont() -> Cairo.ScaledFontRef! -
scaledFontExtension methodGets the
cairo_scaled_font_tused byfont. The scaled font can be referenced and kept usingcairo_scaled_font_reference().Declaration
Swift
@inlinable var scaledFont: Cairo.ScaledFontRef! { get }
View on GitHub
Install in Dash
FontProtocol Protocol Reference