text

package
v0.0.0-...-b298911 Latest Latest
Warning

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

Go to latest
Published: Nov 27, 2020 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Text

type Text struct {
	*transformer.Rect
	// contains filtered or unexported fields
}

Text is a ebiten's Text

func NewText

func NewText(t string, f font.Face) *Text

NewText returns a new Text

func (*Text) Center

func (d *Text) Center(x, y int) *Text

Center move the center of the rect to the position

func (*Text) Clone

func (d *Text) Clone() *Text

Clone returns a cloned Text

func (*Text) Draw

func (d *Text) Draw(dst *ebiten.Image)

Draw draws a given text on a given destination image dst.

func (*Text) From

func (d *Text) From(x, y int, mode transformer.PositionMode) *Text

From move the rect to the position in the mode

func (*Text) WithColor

func (d *Text) WithColor(col color.Color) *Text

WithColor sets a text color

Jump to

Keyboard shortcuts

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