Documentation
¶
Overview ¶
Package fcfonts is an implementation of the font tooling required by Pango, using textlayout/fontconfig and textlayout/fonts.
Index ¶
- Constants
- type Decoder
- type Font
- func (font *Font) Describe(absolute bool) pango.FontDescription
- func (font *Font) GetCoverage(_ pango.Language) pango.Coverage
- func (font *Font) GetFeatures() []harfbuzz.Feature
- func (font *Font) GetFontMap() pango.FontMap
- func (font *Font) GetHBFont() *harfbuzz.Font
- func (font *Font) GetMetrics(lang pango.Language) pango.FontMetrics
- func (font *Font) GlyphExtents(glyph pango.Glyph, inkRect, logicalRect *pango.Rectangle)
- type FontMap
- type Fontset
- type FontsetHash
- type PangoFcFontKey
- type PangoFcMetricsInfo
- type PangoFontsetKey
- type PatternHash
- type Patterns
Constants ¶
View Source
const Fontset_CACHE_SIZE = 256
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Decoder ¶
type Decoder interface {
// GetCharset returns a charset given a font that
// includes a list of supported characters in the font.
// The implementation must be fast because the method is called
// separately for each character to determine Unicode coverage.
GetCharset(font *fcFont) fc.Charset
// GetGlyph returns a single glyph for a given Unicode code point.
GetGlyph(font *fcFont, r rune) pango.Glyph
}
Decoder represents a decoder that an application provides for handling a font that is encoded in a custom way.
type Font ¶
type Font struct {
// contains filtered or unexported fields
}
func (*Font) Describe ¶
func (font *Font) Describe(absolute bool) pango.FontDescription
func (*Font) GetFeatures ¶
func (*Font) GetFontMap ¶
func (*Font) GetMetrics ¶
func (font *Font) GetMetrics(lang pango.Language) pango.FontMetrics
type FontMap ¶
type FontMap struct {
Fontset_key_substitute func(*PangoFontsetKey, fc.Pattern)
// contains filtered or unexported fields
}
FontMap implements pango.FontMap using 'fontconfig' and 'fonts'.
func NewFontMap ¶
func NewFontMap() *FontMap
NewFontMap creates a new font map, used to cache information about available fonts, and holds certain global parameters such as the resolution and the default substitute function.
type Fontset ¶
type Fontset struct {
// contains filtered or unexported fields
}
func (*Fontset) Foreach ¶
func (Fontset *Fontset) Foreach(fn pango.FontsetForeachFunc)
func (*Fontset) GetLanguage ¶
type FontsetHash ¶
type FontsetHash map[PangoFontsetKey]*Fontset
type PangoFcFontKey ¶
type PangoFcFontKey struct {
// contains filtered or unexported fields
}
type PangoFcMetricsInfo ¶
type PangoFcMetricsInfo struct {
// contains filtered or unexported fields
}
type PangoFontsetKey ¶
type PangoFontsetKey struct {
// contains filtered or unexported fields
}
type PatternHash ¶
Click to show internal directories.
Click to hide internal directories.