FColorScheme constructor

const FColorScheme({
  1. required Brightness brightness,
  2. required Color background,
  3. required Color foreground,
  4. required Color primary,
  5. required Color primaryForeground,
  6. required Color secondary,
  7. required Color secondaryForeground,
  8. required Color muted,
  9. required Color mutedForeground,
  10. required Color destructive,
  11. required Color destructiveForeground,
  12. required Color error,
  13. required Color errorForeground,
  14. required Color border,
  15. double enabledHoveredOpacity = 0.9,
  16. double disabledOpacity = 0.5,
})

Creates a FColorScheme.

Note: Unless you are creating a completely new color scheme, modifying FThemes' predefined color schemes is preferred.

Implementation

const FColorScheme({
  required this.brightness,
  required this.background,
  required this.foreground,
  required this.primary,
  required this.primaryForeground,
  required this.secondary,
  required this.secondaryForeground,
  required this.muted,
  required this.mutedForeground,
  required this.destructive,
  required this.destructiveForeground,
  required this.error,
  required this.errorForeground,
  required this.border,
  this.enabledHoveredOpacity = 0.9,
  this.disabledOpacity = 0.5,
})  : assert(
        0 <= enabledHoveredOpacity && enabledHoveredOpacity <= 1,
        'The enabledHoveredOpacity must be between 0 and 1.',
      ),
      assert(0 <= disabledOpacity && disabledOpacity <= 1, 'The disabledOpacity must be between 0 and 1.');