Questions tagged [flutter-constraint]

7 questions
3
votes
2 answers

Understanding the nature of Flutter constraints through a specific example

Prelude I'm familiar with the dictum "Constraints go down. Sizes go up. Parent sets position.' What I'd like to understand is how "constraints" are defined. Is it just a range ("height must be between 30 and infinity"), or is there something more…
Sam
  • 563
  • 5
  • 15
1
vote
3 answers

Flutter: Widget compression priority

I'm a beginner in Flutter, and now I try to understand how I can set for layouts of widget compression priority. What I want for example: I have Horizontal Stack like Row, it has inside: Some space like SizedBox, then some Text. And I want to reduce…
EvGeniy Ilyin
  • 1,817
  • 1
  • 21
  • 38
0
votes
0 answers

Trouble with widget size constraints on window resize

I'm new to Flutter development and have been following the tutorials and codelabs recommended on flutter.dev to get started. As a first exercise, I decided to recreate the Spotify Desktop welcome page, aiming for the most accurate representation…
MetaHG
  • 21
  • 3
0
votes
1 answer

How to tests the constraints of a specific widget?

I have a widget (MyWidget) in a screen (MyScreen) and I would like to write a test that verifies that specific constraints are applied to MyWidgets. How can I do that?
Valentin Vignal
  • 6,151
  • 2
  • 33
  • 73
0
votes
1 answer

How to have several Texts with overflow and maximize the size used?

I would like to have 2 texts on the same row, one aligned left, the other aligned right. Both texts are inside a Flexible widget and have overflow option in case the user resizes the screen (it is a flutter web project). This is my code so…
Valentin Vignal
  • 6,151
  • 2
  • 33
  • 73
0
votes
2 answers

Real height in flutter?

I am trying to retrieve the real height in Flutter. I tried different options: MediaQuery.of(context).size.height * MediaQuery.of(context).devicePixelRatio or WidgetsBinding.instance.window.physicalSize.height I add these 2 lines in a new Flutter…
kike
  • 658
  • 1
  • 8
  • 26
0
votes
2 answers

flutter how to make a container expand with result from text field search

I was trying to make a dropdown like custom search -result page but it failed with some errors like RenderFlex children have non-zero flex but incoming height constraints are unbounded. Is there is any way to solve with out package?? when i remove…