Module text_box

A text box

Functions

set_background_color (t_box, color) Fill all the widget with this color (default is transparent).
set_text_background_color (t_box, color) Fill the text area (text height/width + padding) background with this color (default is none)
set_text_background_border (color) Set a border on the text area background (default is none )
set_v_margin (t_box, margin) Define the top and bottom margin for the text background
set_h_margin (t_box, margin) Define the left and right margin for the text background
set_rounded_size (t_box, rounded_size) Set rounded corners for background and text background
set_text_color (t_box, color) Define the color of the text
set_font_size (t_box, size) Define the text font size
text_box:set_height (height) Set the t_box height.
text_box:set_width (width) Set the t_box width.
new (args) Create a t_box widget.


Functions

set_background_color (t_box, color)
Fill all the widget with this color (default is transparent).

Parameters:

  • t_box the value text box
  • color a string "#rrggbbaa" or "#rrggbb"

Usage:

    myt_box:set_background_color(string) -->"#rrggbbaa"
set_text_background_color (t_box, color)
Fill the text area (text height/width + padding) background with this color (default is none)

Parameters:

  • t_box the t_box
  • color a string "#rrggbbaa" or "#rrggbb"

Usage:

    myt_box:set_text_background_color(string) -->"#rrggbbaa"
set_text_background_border (color)
Set a border on the text area background (default is none )

Parameters:

  • color a string "#rrggbbaa" or "#rrggbb"

Usage:

    myt_box:set_text_background_border(string) -->"#rrggbbaa"
set_v_margin (t_box, margin)
Define the top and bottom margin for the text background

Parameters:

  • t_box the value text box
  • margin an integer for top and bottom margin

Usage:

    myt_box:set_v_margin(integer)
set_h_margin (t_box, margin)
Define the left and right margin for the text background

Parameters:

  • t_box the value text box
  • margin an integer for left and right margin

Usage:

    myt_box:set_h_margin(integer)
set_rounded_size (t_box, rounded_size)
Set rounded corners for background and text background

Parameters:

  • t_box the value text box
  • rounded_size float in [0,1]

Usage:

    myt_box:set_rounded_size(a) -> a in [0,1]
set_text_color (t_box, color)
Define the color of the text

Parameters:

  • t_box the value text box
  • color a string "#rrggbb"

Usage:

    myt_box:set_text_color(string)
set_font_size (t_box, size)
Define the text font size

Parameters:

  • t_box the value text box
  • size the font size

Usage:

    myt_box:set_font_size(integer)
text_box:set_height (height)
Set the t_box height.

Parameters:

  • height The height to set.
text_box:set_width (width)
Set the t_box width.

Parameters:

  • width The width to set.
new (args)
Create a t_box widget.

Parameters:

  • args Standard widget() arguments. You should add width and height key to set t_box geometry.

Returns:

    A t_box widget.
generated by LDoc 1.3.12