Flutter修改返回按钮图标

return Scaffold(
   appBar: AppBar(
      leading: IconButton(
        onPressed: () {
          Navigator.of(context).pop();
        },
        // icon: Image.asset(
        //   'images/ic_back_black.png',
        //   width: 25,
        //   height: 25,
        //   color: Colors.white,
        // ),
        icon: const Icon(
          Icons.arrow_back,
          color: Colors.white,
          size: 30,
        ),
      ),
      title: Text(widget.title),
   ),
);

在这里插入图片描述

猜你喜欢

转载自blog.csdn.net/xiaopihair123/article/details/125336418