class_boxcontainer.rst 2.4 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576
  1. .. Generated automatically by doc/tools/makerst.py in Godot's source tree.
  2. .. DO NOT EDIT THIS FILE, but the BoxContainer.xml source instead.
  3. .. The source is found in doc/classes or modules/<name>/doc_classes.
  4. .. _class_BoxContainer:
  5. BoxContainer
  6. ============
  7. **Inherits:** :ref:`Container<class_Container>` **<** :ref:`Control<class_Control>` **<** :ref:`CanvasItem<class_CanvasItem>` **<** :ref:`Node<class_Node>` **<** :ref:`Object<class_Object>`
  8. **Inherited By:** :ref:`VBoxContainer<class_VBoxContainer>`, :ref:`HBoxContainer<class_HBoxContainer>`, :ref:`ColorPicker<class_ColorPicker>`
  9. **Category:** Core
  10. Brief Description
  11. -----------------
  12. Base class for box containers.
  13. Properties
  14. ----------
  15. +-----------------------------------------------+------------------------------------------------+
  16. | :ref:`AlignMode<enum_BoxContainer_AlignMode>` | :ref:`alignment<class_BoxContainer_alignment>` |
  17. +-----------------------------------------------+------------------------------------------------+
  18. Methods
  19. -------
  20. +-------+--------------------------------------------------------------------------------------------+
  21. | void | :ref:`add_spacer<class_BoxContainer_add_spacer>` **(** :ref:`bool<class_bool>` begin **)** |
  22. +-------+--------------------------------------------------------------------------------------------+
  23. Enumerations
  24. ------------
  25. .. _enum_BoxContainer_AlignMode:
  26. enum **AlignMode**:
  27. - **ALIGN_BEGIN** = **0** --- Aligns children with the beginning of the container.
  28. - **ALIGN_CENTER** = **1** --- Aligns children with the center of the container.
  29. - **ALIGN_END** = **2** --- Aligns children with the end of the container.
  30. Description
  31. -----------
  32. Arranges child controls vertically or horizontally, and rearranges the controls automatically when their minimum size changes.
  33. Property Descriptions
  34. ---------------------
  35. .. _class_BoxContainer_alignment:
  36. - :ref:`AlignMode<enum_BoxContainer_AlignMode>` **alignment**
  37. +----------+----------------------+
  38. | *Setter* | set_alignment(value) |
  39. +----------+----------------------+
  40. | *Getter* | get_alignment() |
  41. +----------+----------------------+
  42. The alignment of the container's children (must be one of ALIGN_BEGIN, ALIGN_CENTER, or ALIGN_END).
  43. Method Descriptions
  44. -------------------
  45. .. _class_BoxContainer_add_spacer:
  46. - void **add_spacer** **(** :ref:`bool<class_bool>` begin **)**
  47. Adds a control to the box as a spacer. If ``true``, *begin* will insert the spacer control in front of other children.