class_linkbutton.rst 3.3 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677
  1. .. Generated automatically by doc/tools/makerst.py in Godot's source tree.
  2. .. DO NOT EDIT THIS FILE, but the LinkButton.xml source instead.
  3. .. The source is found in doc/classes or modules/<name>/doc_classes.
  4. .. _class_LinkButton:
  5. LinkButton
  6. ==========
  7. **Inherits:** :ref:`BaseButton<class_basebutton>` **<** :ref:`Control<class_control>` **<** :ref:`CanvasItem<class_canvasitem>` **<** :ref:`Node<class_node>` **<** :ref:`Object<class_object>`
  8. **Category:** Core
  9. Brief Description
  10. -----------------
  11. Simple button used to represent a link to some resource
  12. Member Functions
  13. ----------------
  14. +------------------------------+-------------------------------------------------------------------------------------------------------------------+
  15. | :ref:`String<class_string>` | :ref:`get_text<class_LinkButton_get_text>` **(** **)** const |
  16. +------------------------------+-------------------------------------------------------------------------------------------------------------------+
  17. | :ref:`int<class_int>` | :ref:`get_underline_mode<class_LinkButton_get_underline_mode>` **(** **)** const |
  18. +------------------------------+-------------------------------------------------------------------------------------------------------------------+
  19. | void | :ref:`set_text<class_LinkButton_set_text>` **(** :ref:`String<class_string>` text **)** |
  20. +------------------------------+-------------------------------------------------------------------------------------------------------------------+
  21. | void | :ref:`set_underline_mode<class_LinkButton_set_underline_mode>` **(** :ref:`int<class_int>` underline_mode **)** |
  22. +------------------------------+-------------------------------------------------------------------------------------------------------------------+
  23. Member Variables
  24. ----------------
  25. - :ref:`String<class_string>` **text**
  26. - :ref:`int<class_int>` **underline**
  27. Numeric Constants
  28. -----------------
  29. - **UNDERLINE_MODE_ALWAYS** = **0** --- The LinkButton will always show an underline at the bottom of its text
  30. - **UNDERLINE_MODE_ON_HOVER** = **1** --- The LinkButton will show an underline at the bottom of its text when the mouse cursor is over it.
  31. - **UNDERLINE_MODE_NEVER** = **2** --- The LinkButton will never show an underline at the bottom of its text.
  32. Description
  33. -----------
  34. This kind of buttons are primarily used when the interaction with the button causes a context change (like linking to a web page).
  35. Member Function Description
  36. ---------------------------
  37. .. _class_LinkButton_get_text:
  38. - :ref:`String<class_string>` **get_text** **(** **)** const
  39. Returns the text of the button.
  40. .. _class_LinkButton_get_underline_mode:
  41. - :ref:`int<class_int>` **get_underline_mode** **(** **)** const
  42. Returns the underline mode for this button.
  43. .. _class_LinkButton_set_text:
  44. - void **set_text** **(** :ref:`String<class_string>` text **)**
  45. Sets the text of the button.
  46. .. _class_LinkButton_set_underline_mode:
  47. - void **set_underline_mode** **(** :ref:`int<class_int>` underline_mode **)**
  48. Sets the underline mode for this button, the argument must be one of the :ref:`LinkButton<class_linkbutton>` constants (see constants section).