Struct amethyst_ui::UiText[][src]

pub struct UiText {
    pub text: String,
    pub font_size: f32,
    pub color: [f32; 4],
    pub font: FontHandle,
    pub password: bool,
    // some fields omitted
}

A component used to display text in this entity's UiTransform

Fields

The string rendered by this.

The height of a line of text in pixels.

The color of the rendered text, using a range of 0.0 to 1.0 per channel.

The font used for rendering.

If true this will be rendered as dots instead of the text.

Methods

impl UiText
[src]

Initializes a new UiText

Parameters

  • font: A handle to a Font asset
  • text: the glyphs to render
  • color: RGBA color with a maximum of 1.0 and a minimum of 0.0 for each channel
  • font_size: a uniform scale applied to the glyphs

Trait Implementations

impl Clone for UiText
[src]

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

impl Debug for UiText
[src]

Formats the value using the given formatter. Read more

impl Component for UiText
[src]

Associated storage type for this component.

Auto Trait Implementations

impl Send for UiText

impl Sync for UiText