# Module `RichInput`

Druid Rich Input custom component.

It's wrapper on Input component with cursor and placeholder text

## Functions

get_text(self) | Set input field text
init(self, template, nodes) | The RichInput constructor
select(self) | Select input field
set_allowed_characters(self, characters) | Set allowed charaters for input field.
set_font(self, font) | Set input field font
set_placeholder(self, placeholder_text) | Set placeholder text
set_text(self, text) | Set input field text

## Fields

cursor | On input field text change to empty string callback(self, input_text)
cursor_position | On input field text change to empty string callback(self, input_text)
cursor_text | On input field text change to empty string callback(self, input_text)
drag | On input field text change to empty string callback(self, input_text)
druid | The component druid instance
input | On input field text change callback(self, input_text)
input_text | On input field text change to empty string callback(self, input_text)
placeholder | On input field text change to empty string callback(self, input_text)
root | Root node
text_position | On input field text change to empty string callback(self, input_text)

## Functions

get_text(self)
  Set input field text

  ### Parameters:

  - self RichInput RichInput
init(self, template, nodes)
  The RichInput constructor

  ### Parameters:

  - self RichInput RichInput
  - template string The template string name
  - nodes table Nodes table from gui.clone_tree
select(self)
  Select input field

  ### Parameters:

  - self RichInput RichInput
set_allowed_characters(self, characters)
  Set allowed charaters for input field. See: https://defold.com/ref/stable/string/ ex: [%a%d] for alpha and numeric

  ### Parameters:

  - self RichInput RichInput
  - characters string Regulax exp. for validate user input

  ### Returns:

  RichInput Current instance
set_font(self, font)
  Set input field font

  ### Parameters:

  - self RichInput RichInput
  - font hash The font hash

  ### Returns:

  druid.input Current input instance
set_placeholder(self, placeholder_text)
  Set placeholder text

  ### Parameters:

  - self RichInput RichInput
  - placeholder_text string The placeholder text
set_text(self, text)
  Set input field text

  ### Parameters:

  - self RichInput RichInput
  - text string The input text

  ### Returns:

  druid.input Current input instance

## Fields

cursor
  On input field text change to empty string callback(self, input_text)
  - cursor node
cursor_position
  On input field text change to empty string callback(self, input_text)
  - cursor_position vector3
cursor_text
  On input field text change to empty string callback(self, input_text)
  - cursor_text node
drag
  On input field text change to empty string callback(self, input_text)
  - drag druid.drag
druid
  The component druid instance
  - druid DruidInstance DruidInstance
input
  On input field text change callback(self, input_text)
  - input Input Input
input_text
  On input field text change to empty string callback(self, input_text)
  - input_text druid.text
placeholder
  On input field text change to empty string callback(self, input_text)
  - placeholder druid.text
root
  Root node
  - root node
text_position
  On input field text change to empty string callback(self, input_text)
  - text_position vector3

generated by LDoc TESTING Last updated 2015-01-01 12:00:00