linebender/druid

Add missing layout widgets

Open

#659 ouverte le 14 mars 2020

Voir sur GitHub
 (3 commentaires) (0 réactions) (0 assignés)Rust (567 forks)batch import
enhancementhelp wanted

Métriques du dépôt

Stars
 (9 091 stars)
Métriques de merge PR
 (Aucune PR mergée en 30 j)

Description

There are a number of basic layout widgets in flutter that we don't have.

  • LimitedBox: A widget that checks if incoming constraints are infinite, and constraints them.
  • FittedBox: A widget that fits a child within itself, in a number of ways (fill, fit, fillHeight, etc).
  • FractionallySizedBox: use a fraction of available space
  • AspectRatio: maintain an aspect ratio (this should report if it is passed tight constraints) #1645
  • OverflowBox: allow a child to overflow
  • ConstrainedBox: impose arbitrary(?) constraints on child? I think this should probably be represented as Fn(BoxConstraints) -> BoxConstraints or something.

In any case: none of these are super-duper-urgent, but I think we would like to have all of them eventually.

Guide contributeur