MCPcopy
hub / github.com/g3n/engine / SetAttributes

Method SetAttributes

text/font.go:149–155  ·  view source on GitHub ↗

SetAttributes sets the font attributes.

(fa *FontAttributes)

Source from the content-addressed store, hash-verified

147
148// SetAttributes sets the font attributes.
149func (f *Font) SetAttributes(fa *FontAttributes) {
150
151 f.SetPointSize(fa.PointSize)
152 f.SetDPI(fa.DPI)
153 f.SetLineSpacing(fa.LineSpacing)
154 f.SetHinting(fa.Hinting)
155}
156
157// updateFace updates the font face if parameters have changed.
158func (f *Font) updateFace() {

Callers 2

SetTextMethod · 0.80
setTextCaretMethod · 0.80

Calls 4

SetPointSizeMethod · 0.95
SetDPIMethod · 0.95
SetLineSpacingMethod · 0.95
SetHintingMethod · 0.95

Tested by

no test coverage detected