Skip to content

View's minHeight not respected #562

Open
@golddove

Description

@golddove

Issues and steps to reproduce

Create any viewgroup (for example, a LinearLayout), and place a FlexboxLayout inside it.

Set the FlexboxLayout's height to WRAP_CONTENT. Assign a large min height (either using setMinimumHeight or android:minHeight inherited from View) to the FlexboxLayout.

Notice how the FlexboxLayout height does not expand to the min height.

(There is an unresolved, but closed duplicate here: #536)

Expected behavior

The flexbox should take up at least minHeight, even if the flex items don't need that much height.

Version of the flexbox library

2.0.1

Link to code

flexboxLayout.setLayoutParams(new ViewGroup.LayoutParams(WRAP_CONTENT, WRAP_CONTENT));
flexboxLayout.setMinimumHeight(1000);
viewGroup.addView(flexboxLayout);

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions