ttf

package
v0.0.0-...-1caac2b Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 28, 2014 License: BSD-3-Clause Imports: 4 Imported by: 0

Documentation

Index

Constants

View Source
const (
	HINTING_NORMAL = int(C.TTF_HINTING_NORMAL)
	HINTING_LIGHT  = int(C.TTF_HINTING_LIGHT)
	HINTING_MONO   = int(C.TTF_HINTING_MONO)
	HINTING_NONE   = int(C.TTF_HINTING_NONE)
)

Font Hinting Types

View Source
const (
	STYLE_NORMAL        = 0
	STYLE_BOLD          = 0x01
	STYLE_ITALIC        = 0x02
	STYLE_UNDERLINE     = 0x04
	STYLE_STRIKETHROUGH = 0x08
)

Font Style Types

Variables

This section is empty.

Functions

func ByteSwappedUnicode

func ByteSwappedUnicode(swap bool)

func GetError

func GetError() error

func Init

func Init() int

func Quit

func Quit()

func SetError

func SetError(err string)

func WasInit

func WasInit() bool

Types

type Font

type Font struct {
	// contains filtered or unexported fields
}

func OpenFont

func OpenFont(file string, size int) (*Font, error)

func OpenFontIndex

func OpenFontIndex(file string, size int, index int) (*Font, error)

func (*Font) Ascent

func (f *Font) Ascent() int

func (*Font) Close

func (f *Font) Close()

func (*Font) Descent

func (f *Font) Descent() int

func (*Font) FaceFamilyName

func (f *Font) FaceFamilyName() string

func (*Font) FaceIsFixedWidth

func (f *Font) FaceIsFixedWidth() bool

func (*Font) Faces

func (f *Font) Faces() int

func (*Font) GetHinting

func (f *Font) GetHinting() int

func (*Font) GetKerning

func (f *Font) GetKerning() bool

func (*Font) GetOutline

func (f *Font) GetOutline() int

func (*Font) GetStyle

func (f *Font) GetStyle() int

func (*Font) Height

func (f *Font) Height() int

func (*Font) LineSkip

func (f *Font) LineSkip() int

func (*Font) RenderText_Blended

func (f *Font) RenderText_Blended(text string, color sdl.Color) *sdl.Surface

func (*Font) RenderText_Shaded

func (f *Font) RenderText_Shaded(text string, fg, bg sdl.Color) *sdl.Surface

func (*Font) RenderText_Solid

func (f *Font) RenderText_Solid(text string, color sdl.Color) *sdl.Surface

func (*Font) SetHinting

func (f *Font) SetHinting(hinting int)

func (*Font) SetKerning

func (f *Font) SetKerning(allowed bool)

func (*Font) SetOutline

func (f *Font) SetOutline(outline int)

func (*Font) SetStyle

func (f *Font) SetStyle(style int)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL