在 Flutter 中更改 AppBar 后退图标大小

Far*_*rwa 4 android dart flutter flutter-appbar

这是当前的AppBar代码:

AppBar(
  iconTheme: IconThemeData(
    color: Colors.black,
    size: 100 // This isn't performing any changes
  ),
  centerTitle: false,
  backgroundColor: Colors.white,
  title: Text(
    title,
    style: TextStyle(color: Colors.black87,

  ),
  elevation: 1.0,
);
Run Code Online (Sandbox Code Playgroud)

当前尺寸属性不做IconThemeData任何改变。

Nil*_*hod 6

尝试一下你需要使用的leading

  • 显示在标题之前的小部件。

示例代码

 AppBar(
      title: new Text("Your Title"),
      leading: new IconButton(
        icon: new Icon(Icons.arrow_back,size: 50.0,),
        onPressed: () => {
          // Perform Your action here
        },
      ),
    );
Run Code Online (Sandbox Code Playgroud)

输出

在此输入图像描述