为什么我不能增加 flutter buttonbar 中的按钮宽度?

Why can't I increase my button width inside flutter buttonbar?

我想增加按钮的宽度以便它们占据整个屏幕,但是 buttonMinWidth 不起作用,

这是我的代码:

ButtonBar(
  children: [
    TextButton.icon(
      onPressed: null,
      icon: const Icon(
        Icons.replay,
        color: Colors.red,
      ),
      label: const Text(
        "Retry",
        style: TextStyle(color: Colors.red),
      ),
    ),
    TextButton.icon(
      onPressed: null,
      icon: const Icon(
        Icons.replay,
        color: Colors.green,
      ),
      label: const Text(
        "Continue",
        style: TextStyle(color: Colors.green),
      ),
    ),
  ],
  buttonMinWidth: 100,
),

我之前尝试过使用 sized box 来增加按钮栏的宽度,但是没有成功。

您好,请检查以下代码希望它对您有用如果您有任何疑问,请告诉我

ButtonBar(
      alignment: MainAxisAlignment.spaceBetween,
      children: [
        TextButton.icon(
          onPressed: null,
          icon: const Icon(
            Icons.replay,
            color: Colors.red,
          ),
          label: const Text(
            "Retry",
            style: TextStyle(color: Colors.red),
          ),
        ),
        TextButton.icon(
          onPressed: null,
          icon: const Icon(
            Icons.replay,
            color: Colors.green,
          ),
          label: const Text(
            "Continue",
            style: TextStyle(color: Colors.green),
          ),
        ),
      ],
    ),