Skip to main content


I had trouble getting a VerticalDivider to show up in a #flutter toolbar. It's because the Row didn't have any explicit height. There are two solutions: wrap it in a SizedBox, or wrap the row in an IntrinsicHeight. The latter can have performance penalties deep in the widget tree.
in reply to Hank G ☑️

Hmm... @Hank G ☑️ perhaps my read of this is failing... it looks like the code under "Fix 1" and "Fix 2" is identical. Was that intentional? Or am I just not reading it closely enough? Cheers, -Randy
in reply to Hank G ☑️

The third example should read:
IntrinsicHeight(
  child: Row(children: [
    IconButton(onPressed: () {}, icon: Icon(Icons.save)),
    VerticalDivider(),
    IconButton(onPressed: () {}, icon: Icon(Icons.cut)),
  ]),
);