class_editorselection.rst 3.1 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485
  1. :github_url: hide
  2. .. Generated automatically by doc/tools/makerst.py in Godot's source tree.
  3. .. DO NOT EDIT THIS FILE, but the EditorSelection.xml source instead.
  4. .. The source is found in doc/classes or modules/<name>/doc_classes.
  5. .. _class_EditorSelection:
  6. EditorSelection
  7. ===============
  8. **Inherits:** :ref:`Object<class_Object>`
  9. Manages the SceneTree selection in the editor.
  10. Description
  11. -----------
  12. This object manages the SceneTree selection in the editor.
  13. Methods
  14. -------
  15. +---------------------------+--------------------------------------------------------------------------------------------------------------------+
  16. | void | :ref:`add_node<class_EditorSelection_method_add_node>` **(** :ref:`Node<class_Node>` node **)** |
  17. +---------------------------+--------------------------------------------------------------------------------------------------------------------+
  18. | void | :ref:`clear<class_EditorSelection_method_clear>` **(** **)** |
  19. +---------------------------+--------------------------------------------------------------------------------------------------------------------+
  20. | :ref:`Array<class_Array>` | :ref:`get_selected_nodes<class_EditorSelection_method_get_selected_nodes>` **(** **)** |
  21. +---------------------------+--------------------------------------------------------------------------------------------------------------------+
  22. | :ref:`Array<class_Array>` | :ref:`get_transformable_selected_nodes<class_EditorSelection_method_get_transformable_selected_nodes>` **(** **)** |
  23. +---------------------------+--------------------------------------------------------------------------------------------------------------------+
  24. | void | :ref:`remove_node<class_EditorSelection_method_remove_node>` **(** :ref:`Node<class_Node>` node **)** |
  25. +---------------------------+--------------------------------------------------------------------------------------------------------------------+
  26. Signals
  27. -------
  28. .. _class_EditorSelection_signal_selection_changed:
  29. - **selection_changed** **(** **)**
  30. Emitted when the selection changes.
  31. Method Descriptions
  32. -------------------
  33. .. _class_EditorSelection_method_add_node:
  34. - void **add_node** **(** :ref:`Node<class_Node>` node **)**
  35. Adds a node to the selection.
  36. ----
  37. .. _class_EditorSelection_method_clear:
  38. - void **clear** **(** **)**
  39. Clear the selection.
  40. ----
  41. .. _class_EditorSelection_method_get_selected_nodes:
  42. - :ref:`Array<class_Array>` **get_selected_nodes** **(** **)**
  43. Gets the list of selected nodes.
  44. ----
  45. .. _class_EditorSelection_method_get_transformable_selected_nodes:
  46. - :ref:`Array<class_Array>` **get_transformable_selected_nodes** **(** **)**
  47. Gets the list of selected nodes, optimized for transform operations (i.e. moving them, rotating, etc). This list avoids situations where a node is selected and also child/grandchild.
  48. ----
  49. .. _class_EditorSelection_method_remove_node:
  50. - void **remove_node** **(** :ref:`Node<class_Node>` node **)**
  51. Removes a node from the selection.