1. Anuncie Aqui ! Entre em contato fdantas@4each.com.br

[Flutter] Flutter (Dart): Exceptions caused by rendering / A RenderFlex overflowed

Discussão em 'Mobile' iniciado por Stack, Outubro 3, 2024 às 13:12.

  1. Stack

    Stack Membro Participativo

    I have a problem with Flutter (Dart) RenderFlex overflowed pixels. An exception of rendering library.

    How can I manage or apply scrolling ability to my app page view and avoid Flutter's rendering exceptions with messages like:


    A RenderFlex overflowed by 28 pixels on the bottom.

    if you by any chance need the full log to help me is here:

    [​IMG]

    on the hot-reload it comes up with the yellow/black stripes at the bottom as per the message.

    Is this something I can manage with a scrollable widget? Or I can declare otherwise my widgets in order to control it?

    full code if needed (i changed the Text data but assume the texts appearing are longer than the screen size, and thus the error comes up):

    @override
    Widget build(BuildContext context) {
    return new DefaultTabController(
    length: 3,
    child: new Scaffold(
    appBar: new AppBar(
    bottom: new TabBar(
    tabs: [
    new Tab(text: "xxx",),
    new Tab(text: "xxx",),
    new Tab(text: "xxx",),
    ],
    ),
    title: new Text(data["xxx"]),
    ),
    body: new TabBarView(
    children: [
    new Column(
    children: <Widget>[
    new Text(data["xxx"],
    style: new TextStyle(
    fontStyle: FontStyle.italic,
    color: Colors.blue,
    fontSize: 16.0
    ),),
    new Text(data["xxx"],
    style: new TextStyle(
    fontStyle: FontStyle.italic,
    color: Colors.blue,
    fontSize: 10.0
    ),),
    new Text(data["xxx"],
    style: new TextStyle(
    fontStyle: FontStyle.italic,
    color: Colors.blue,
    fontSize: 16.0
    ),),
    new Text(data["xxx"],
    style: new TextStyle(
    fontStyle: FontStyle.italic,
    color: Colors.blue,
    fontSize: 8.0
    ),
    ),
    new Text(data["xxx"],
    style: new TextStyle(
    fontStyle: FontStyle.italic,
    color: Colors.blue,
    fontSize: 8.0
    ),),

    new Row(
    children: <Widget>[
    new Expanded(
    child: new Text("xxx"),
    ),
    new Expanded(
    child: new Icon(Icons.file_download, color: Colors.green, size: 30.0,),
    ),
    ],
    ),

    new Divider(),
    new Text("xxx",
    style: new TextStyle(
    fontStyle: FontStyle.italic,
    color: Colors.red,
    fontSize: 16.0
    ),
    ),
    ],
    ),

    new ListView.builder(
    itemBuilder: (BuildContext context, int index) => new EntryItem(_lstTiles[index]),
    itemCount: _lstTiles.length,
    ),

    new Column(
    children: <Widget>[
    new Text(data["xxx"],
    style: new TextStyle(
    fontStyle: FontStyle.italic,
    color: Colors.green[900],
    fontSize: 16.0
    ),
    ),
    new Text(data["xxx"],
    style: new TextStyle(
    fontStyle: FontStyle.italic,
    color: Colors.green[900],
    fontSize: 16.0
    ),),
    new Text(data["xxx"]),
    new ListTile(title: new Text("xxx")),
    new Text(data["xxx"]),
    new ListTile(title: new Text("xxx")),
    new Divider(),
    new Text("xxx",
    style: new TextStyle(
    fontStyle: FontStyle.italic,
    color: Colors.red,
    fontSize: 16.0
    ),
    ),
    ],
    ),
    ],
    ),
    ),
    );
    }

    Continue reading...

Compartilhe esta Página