Module: LiteRGSS::Text::Util Deprecated

Defined in:
docs/00700_Ajout_PSDK.rb

Overview

Deprecated.

DO NOT FUCKING USE THIS. Use SpriteStack instead.

Utility module to manage text easly in user interfaces.

Constant Summary collapse

DEFAULT_OUTLINE_SIZE =

Default outlinesize, nil gives a 0 and keep shadow processing, 0 or more disable shadow processing

nil
FOY =

Offset induced by the Font

2

Instance Method Summary collapse

Instance Method Details

#add_text(x, y, width, height, str, align = 0, outlinesize = DEFAULT_OUTLINE_SIZE, type: Text) ⇒ Text

Add a text inside the window, the offset x/y will be adjusted

Parameters:

  • x (Integer)

    the x coordinate of the text surface

  • y (Integer)

    the y coordinate of the text surface

  • width (Integer)

    the width of the text surface

  • height (Integer)

    the height of the text surface

  • str (String)

    the text shown by this object

  • align (0, 1, 2) (defaults to: 0)

    the align of the text in its surface (best effort => no resize), 0 = left, 1 = center, 2 = right

  • outlinesize (Integer, nil) (defaults to: DEFAULT_OUTLINE_SIZE)

    the size of the text outline

  • type (Class) (defaults to: Text)

    the type of text

Returns:

  • (Text)

    the text object



445
446
# File 'docs/00700_Ajout_PSDK.rb', line 445

def add_text(x, y, width, height, str, align = 0, outlinesize = DEFAULT_OUTLINE_SIZE, type: Text)
end

#init_text(font_id = 0, viewport = nil, z = 1000)

Initialize the texts

Parameters:

  • font_id (Integer) (defaults to: 0)

    the default font id of the texts

  • viewport (Viewport, nil) (defaults to: nil)

    the viewport



433
434
# File 'docs/00700_Ajout_PSDK.rb', line 433

def init_text(font_id = 0, viewport = nil, z = 1000)
end

#text_dispose

Dispose the texts



448
449
# File 'docs/00700_Ajout_PSDK.rb', line 448

def text_dispose
end

#text_each

Yield a block on each undisposed text



451
452
# File 'docs/00700_Ajout_PSDK.rb', line 451

def text_each
end

#text_viewportViewport

4 Returns the text viewport

Returns:



425
426
# File 'docs/00700_Ajout_PSDK.rb', line 425

def text_viewport
end

#text_viewport=(v)

Change the text viewport



428
429
# File 'docs/00700_Ajout_PSDK.rb', line 428

def text_viewport=(v)
end