如何在表格内部使用TableRowInkWell颤振? [英] How to use TableRowInkWell inside Table in flutter?

查看:57
本文介绍了如何在表格内部使用TableRowInkWell颤振?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

有人用TableRowInkWell创建表吗?

我想要一个表,该表的左侧为可点击行,右侧为不可点击行.

有没有创建漂亮桌子的例子?

解决方案

您只能在 TableRow TableCell 中使用 TableRowInkWell >

例如:

  Table(边框:TableBorder.all(),孩子们: [表格行(孩子:[///像这个*******TableRowInkWell(onTap:(){},孩子:专栏(孩子:[图标(Icons.account_box,大小:iconSize,),文字(我的帐户"),]),),栏目(儿童:[图标(Icons.settings,大小:iconSize,),文字(设置")]),]),],) 

Does anyone create a table with TableRowInkWell?

I wanted a table with clickable row on the left and unclickable row on the right.

Are there any example for creating a nice table?

解决方案

You can only use TableRowInkWell inside the TableRow or TableCell

for example:

Table(
  border: TableBorder.all(),
  children: [
    TableRow(children: [
    ///Like this one*******
      TableRowInkWell(
          onTap: (){},
        child: Column(children: [
          Icon(
            Icons.account_box,
            size: iconSize,
          ),
          Text('My Account'),
        ]),
      ),
      Column(children: [
        Icon(
          Icons.settings,
          size: iconSize,
        ),
        Text('Settings')
      ]),
    ]),
  ],
)

这篇关于如何在表格内部使用TableRowInkWell颤振?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆