ElevatedButton添加背景圆角 设置宽高

SizedBox(
                               height: 50.0,
                                child: ElevatedButton(
                                    style: ButtonStyle(
                                      textStyle:
                                      MaterialStateProperty.all(TextStyle(
                                        fontSize: 17.0,
                                      )),
                                      backgroundColor:
                                      MaterialStateProperty.all(    ///这里
                                          '#F38D3B'.color),
                                      shape: MaterialStateProperty.all(
                                          RoundedRectangleBorder(
                                              borderRadius:
                                              BorderRadius.circular(10.0))),
                                    ),
                                    onPressed: () {}, child: Text('      预览      ')),
                              )

发表回复

您的邮箱地址不会被公开。 必填项已用 * 标注