title: How to remove or manage space in Flutter ListView Builder?
body: <p>I am new to flutter and this question may be duplicate as well. If someone can assist me finding answer my query please? Your kind kind help will be highly appreciated.</p>
  <p>Question:
  How to remove or manage space in Flutter ListView Builder? Attached is the photo of Side menu / Navigation Drawer. what I require is to reduce the height of navigation items. in other words reduce the top and bottom spacing in each item.</p>
  <p><img src="https://i.stack.imgur.com/Cdo53.png" alt="" /></p>
  <p>Code as Follows:</p>
  <pre><code>import 'package:flutter/material.dart';
  import '../pages/home_screen.dart';
  import '../pages/list_page.dart';
  import '../pages/item_page.dart';
  
  final List&lt;MenuItem&gt; menuItems = &lt;MenuItem&gt;[
    MenuItem(0,'Home',Icon(Icons.home),Icon(Icons.chevron_right), HomeScreen()),
    MenuItem(1,'List',Icon(Icons.home),Icon(Icons.chevron_right), ListPage()),
    MenuItem(2,'Item',Icon(Icons.home),Icon(Icons.chevron_right), ItemPage()),
    MenuItem(1,'Home',Icon(Icons.home),Icon(Icons.chevron_right), HomeScreen()),
    MenuItem(1,'List',Icon(Icons.home),Icon(Icons.chevron_right), ListPage()),
    MenuItem(2,'Item',Icon(Icons.home),Icon(Icons.chevron_right), ItemPage()),
    MenuItem(1,'Home',Icon(Icons.home),Icon(Icons.chevron_right), HomeScreen()),
    MenuItem(1,'List',Icon(Icons.home),Icon(Icons.chevron_right), ListPage()),
    MenuItem(2,'Item',Icon(Icons.home),Icon(Icons.chevron_right), ItemPage()),
    MenuItem(2,'Item',Icon(Icons.home),Icon(Icons.chevron_right), ItemPage()),
    MenuItem(1,'Home',Icon(Icons.home),Icon(Icons.chevron_right), HomeScreen()),
    MenuItem(1,'List',Icon(Icons.home),Icon(Icons.chevron_right), ListPage()),
    MenuItem(2,'Item',Icon(Icons.home),Icon(Icons.chevron_right), ItemPage()),
  ];
  
  class XmobeMenu extends StatelessWidget {
    int indexNumber;
    XmobeMenu(int menuIndex)
    {
      indexNumber =menuIndex;
    }
    @override
    Widget build(BuildContext context) {
      return Drawer(
        child: ListView.builder(
          itemBuilder: (BuildContext context, int index) {
            return MenuItemWidget(menuItems[index],indexNumber);
          },
          itemCount: menuItems.length,
        ),
      );
    }
  }
  
  class MenuItem {
    MenuItem(this.itemNumber,this.title, this.leadIcon, this.trailIcon, this.page);
    final int itemNumber;
    final Icon leadIcon;
    final Icon trailIcon;
    final String title;
    final StatelessWidget page;
  }
  
  class MenuItemWidget extends StatelessWidget {
    final MenuItem item;
    final int indexNumber;
    const MenuItemWidget(this.item, this.indexNumber);
  
    Widget _buildMenu(MenuItem menuItem, context) {
      return
        new Container(
          color: const Color.fromARGB(0, 245,245,245),
          child: new Column(
            children: &lt;Widget&gt;[
              new Column( children: &lt;Widget&gt;[
                Container(
                   padding: new EdgeInsets.all(0.0),
                   child: ListTile(
                      leading: menuItem.leadIcon,
                      title: Text(menuItem.title,),
                      trailing: menuItem.trailIcon,
                      selected: _checkEnabled(menuItem.itemNumber,indexNumber),
                      onTap: () {
                        Navigator.of(context).push(
                          new MaterialPageRoute(
                            builder: (BuildContext context) =&gt; menuItem.page,
                          ),
                        );
                      },
                    ),
                ),
                Divider(height: 1.0,color: Colors.grey,),
              ],)
            ],
          ),
  
        );
    }
    bool _checkEnabled(int itemNumber, int index)
    {
      if(itemNumber==index) {
          return true;
        }
        else
          {
        return false;
      }
    }
    @override
    Widget build(BuildContext context) {
      return _buildMenu(this.item, context);
    }
  
  
  }
  </code></pre>