Rework oriented containers
This commit is contained in:
parent
8c7be63588
commit
73929bef73
16 changed files with 170 additions and 15 deletions
|
|
@ -54,9 +54,12 @@ private:
|
|||
void _resort();
|
||||
|
||||
protected:
|
||||
bool is_fixed = false;
|
||||
|
||||
virtual void _update_theme_item_cache() override;
|
||||
|
||||
void _notification(int p_what);
|
||||
void _validate_property(PropertyInfo &p_property) const;
|
||||
static void _bind_methods();
|
||||
|
||||
public:
|
||||
|
|
@ -65,6 +68,9 @@ public:
|
|||
void set_alignment(AlignmentMode p_alignment);
|
||||
AlignmentMode get_alignment() const;
|
||||
|
||||
void set_vertical(bool p_vertical);
|
||||
bool is_vertical() const;
|
||||
|
||||
virtual Size2 get_minimum_size() const override;
|
||||
|
||||
virtual Vector<int> get_allowed_size_flags_horizontal() const override;
|
||||
|
|
@ -78,7 +84,7 @@ class HBoxContainer : public BoxContainer {
|
|||
|
||||
public:
|
||||
HBoxContainer() :
|
||||
BoxContainer(false) {}
|
||||
BoxContainer(false) { is_fixed = true; }
|
||||
};
|
||||
|
||||
class MarginContainer;
|
||||
|
|
@ -89,7 +95,7 @@ public:
|
|||
MarginContainer *add_margin_child(const String &p_label, Control *p_control, bool p_expand = false);
|
||||
|
||||
VBoxContainer() :
|
||||
BoxContainer(true) {}
|
||||
BoxContainer(true) { is_fixed = true; }
|
||||
};
|
||||
|
||||
VARIANT_ENUM_CAST(BoxContainer::AlignmentMode);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue