flutter-examples icon indicating copy to clipboard operation
flutter-examples copied to clipboard

Header Color is not working properly

Open Uvais-Mohammad opened this issue 3 years ago • 0 comments

I have given a header color headerColor:Colors.blue for a table. But the ouput color is nearly grey. I have tried with many colors, unfortunately it is not showing the exact color we write in the code. Please give a hand on this. code & Output is added below

child: SfDataGridTheme(
                                  data: SfDataGridThemeData(
                                    brightness: Brightness.light,
                                    headerHoverColor: Colors.white.withOpacity(0.3),
                                    headerColor:
                                        Colors.blue
                                  ),
                                  child: Expanded(
                                    child: SfDataGrid(
                                      columnWidthMode: ColumnWidthMode.fill,
                                      gridLinesVisibility:
                                          GridLinesVisibility.both,
                                      columns: [
                                        GridColumn(
                                          columnName: 'Name',
                                          label: Container(
                                            alignment: Alignment.centerLeft,
                                            padding: const EdgeInsets.all(16.0),
                                            child: const Text(
                                              'Name',
                                              style: textStyle,
                                              overflow: TextOverflow.ellipsis,
                                            ),
                                          ),
                                        ),
                                        GridColumn(
                                          columnName: 'Phone Code',
                                          label: Container(
                                            alignment: Alignment.center,
                                            padding: const EdgeInsets.all(8.0),
                                            child: const Text(
                                              'Phone Code',
                                              style: textStyle,
                                              overflow: TextOverflow.ellipsis,
                                            ),
                                          ),
                                        ),

image

Uvais-Mohammad avatar Aug 12 '22 06:08 Uvais-Mohammad