title: Android TextView's Lines equivalent in flutter
body: <p>So, I need to make a <code>Text</code> widget to have an exact number of lines. In android studio, I only need to add property <code>android:Lines = 2</code> and then the <code>TextView</code> will be 2 lines, regardless of how long the text is (if less than 2 lines, then fill the second line with an empty space) and regardless of what's the user's device font size.</p>
  
  <p>The problem is, I have difficulty in replicating such behavior in flutter dynamically. The screenshot below works only on a particular user device's fontSize, since it uses an exact height (<code>32.0</code>).</p>
  
  <pre><code>new Container(
       height: 32.0,
       child: new Column(
            crossAxisAlignment: CrossAxisAlignment.stretch,
            children: &lt;Widget&gt;[
                 new Expanded(
                      child: new Text('Curry Rice'), maxLines: 2, overflow: TextOverflow.ellipsis))
            ])
   )
  </code></pre>
  
  <p><a href="https://i.stack.imgur.com/sH5s2.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/sH5s2.png" alt="enter image description here"></a></p>
  
  <p>The problem arise when user is increasing / decreasing their device's font size, it will make the fixed-height container's doesn't work anymore.</p>
  
  <p><a href="https://i.stack.imgur.com/fNXTx.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/fNXTx.png" alt="enter image description here"></a></p>
  
  <p>So, any idea how to replicate <code>android:Lines</code> behavior in flutter <code>Text</code> widget regardless of the user's device text size?</p>
  
  <p>UPDATE: Added comprehensive code for better context</p>
  
  <pre><code>class MyApp extends StatelessWidget {
    @override
    Widget build(BuildContext context) {
      // final wordPair = new WordPair.random();
      return new MaterialApp(
          title: 'App Title',
          theme:
              new ThemeData(primaryColor: Colors.white, accentColor: Colors.blue),
          home: new Scaffold(
              appBar: new AppBar(
                title: new Text('App Title'),
                actions: &lt;Widget&gt;[
                  new IconButton(icon: new Icon(Icons.list), onPressed: null),
                ],
              ),
              body: new Center(
                  child: new Padding(
                      padding: new EdgeInsets.all(16.0),
                      child: new TestWidget()))));
    }
  }
  
  class TestWidget extends StatelessWidget {
    @override
    Widget build(BuildContext context) {
      return new SizedBox(
          width: 150.0,
          child: new Card(
            child: new Column(
              mainAxisSize: MainAxisSize.min,
              children: &lt;Widget&gt;[
                new Image.asset(
                  'assets/thumb2.jpg',
                  color: Colors.red,
                ),
                new InkWell(
                    onTap: () {
                      // _showMenuDescription(context);
                    },
                    child: new Padding(
                        padding: new EdgeInsets.all(8.0),
                        child: new Column(
                          children: &lt;Widget&gt;[
                            new Container(
                              height: 32.0,
                              child: new Column(
                                  crossAxisAlignment: CrossAxisAlignment.stretch,
                                  children: &lt;Widget&gt;[
                                    new Expanded(
                                      child: new Text(
                                          'Curry Rice With Tandoori Chicken and Sunny Side Fried Egg',
                                          maxLines: 2,
                                          overflow: TextOverflow.ellipsis),
                                    )
                                  ]),
                            ),
                            new Container(height: 8.0),
                            new Row(
                              children: &lt;Widget&gt;[
                                new Expanded(
                                  child: new Text(
                                    'BBQ Sauce',
                                    maxLines: 1,
                                    overflow: TextOverflow.ellipsis,
                                    style: new TextStyle(color: Colors.black45),
                                  ),
                                ),
                                new Padding(
                                    padding: new EdgeInsets.only(left: 8.0),
                                    child: new Text(
                                      '20,000',
                                      maxLines: 1,
                                      overflow: TextOverflow.ellipsis,
                                      textAlign: TextAlign.end,
                                      style: new TextStyle(
                                          color: const Color(0xffffa000)),
                                    ))
                              ],
                            ),
                          ],
                        ))),
              ],
            ),
          ));
    }
  }
  </code></pre>