Text

sfml.graphics.Text
See theText companion trait
object Text

Attributes

Companion
trait
Graph
Supertypes
class Object
trait Matchable
class Any
Self type
Text.type

Members list

Type members

Classlikes

object ctor

Attributes

Supertypes
class Object
trait Matchable
class Any
Self type
ctor.type

Value members

Concrete methods

def apply(): Text

Default constructor.

Default constructor.

Creates an empty text.

Attributes

def apply(string: String, font: Font, characterSize: Int): Text

Construct the text from a string, font and size.

Construct the text from a string, font and size.

Note that if the used font is a bitmap font, it is not scalable, thus not all requested sizes will be available to use. This needs to be taken into consideration when setting the character size. If you need to display text of a certain size, make sure the corresponding bitmap font that supports that size is used.

Value parameters

characterSize

Base size of characters, in pixels

font

Font used to draw the string

string

Text assigned to the string

Attributes

Extensions

Extensions

extension (text: Immutable[Text])
def characterSize: Int
def color: Color
def globalBounds: Rect[Float]
def letterSpacing: Float
def lineSpacing: Float
def localBounds: Rect[Float]
def outlineThickness: Float