toThemeData method
Projects this theme onto a Material ThemeData.
Implementation
ThemeData toThemeData() {
final IconThemeData icons = resolvedIconTheme;
return ThemeData(
useMaterial3: useMaterial3,
colorScheme: colorScheme.toColorScheme(),
textTheme: textTheme,
iconTheme: icons,
primaryIconTheme: icons.copyWith(color: colorScheme.onPrimary),
visualDensity: VisualDensity(
horizontal: visualDensity,
vertical: visualDensity,
),
platform: platform,
splashColor: splashColor,
highlightColor: highlightColor,
);
}