Config class

A model representing the flutter_launcher_icons configuration

Annotations
  • @JsonSerializable(anyMap: true, checked: true)

Constructors

Config({String? imagePath, dynamic android = false, dynamic ios = false, String? imagePathAndroid, String? imagePathIOS, String? imagePathIOSDarkTransparent, String? imagePathIOSTintedGrayscale, String? adaptiveIconForeground, int adaptiveIconForegroundInset = 16, String? adaptiveIconBackground, String? adaptiveIconMonochrome, int minSdkAndroid = constants.androidDefaultAndroidMinSDK, bool removeAlphaIOS = false, bool desaturateTintedToGrayscaleIOS = false, String backgroundColorIOS = '#ffffff', WebConfig? webConfig, WindowsConfig? windowsConfig, MacOSConfig? macOSConfig})
Creates an instance of Config
const
Config.fromJson(Map json)
Creates Config icons from json
factory

Properties

adaptiveIconBackground String?
android adaptive_icon_background image
final
adaptiveIconForeground String?
android adaptive_icon_foreground image
final
adaptiveIconForegroundInset int
android adaptive_icon_foreground inset
final
adaptiveIconMonochrome String?
android adaptive_icon_background image
final
android → dynamic
Returns true or path if android config is enabled
final
backgroundColorIOS String
IOS background_color_ios
final
desaturateTintedToGrayscaleIOS bool
IOS desaturate_tinted_to_grayscale
final
hasAndroidAdaptiveConfig bool
whether or not there is configuration for adaptive icons for android
no setter
hasAndroidAdaptiveMonochromeConfig bool
whether or not there is configuration for monochrome icons for android
no setter
hashCode int
The hash code for this object.
no setterinherited
hasMacOSConfig bool
Whether or not configuration for generating MacOS icons exists
no setter
hasPlatformConfig bool
Checks if contains any platform config
no setter
hasWebConfig bool
Whether or not configuration for generating Web icons exist
no setter
hasWindowsConfig bool
Whether or not configuration for generating Windows icons exist
no setter
imagePath String?
Generic image_path
final
imagePathAndroid String?
Image path specific to android
final
imagePathIOS String?
Image path specific to ios
final
imagePathIOSDarkTransparent String?
IOS image_path_ios_dark_transparent
final
imagePathIOSTintedGrayscale String?
IOS image_path_ios_tinted_grayscale
final
ios → dynamic
Returns true or path if ios config is enabled
final
isCustomAndroidFile bool
Check to see if specified Android config is a string or bool String - Generate new launcher icon with the string specified bool - override the default flutter project icon
no setter
isNeedingNewAndroidIcon bool
if we are needing a new Android icon
no setter
isNeedingNewIOSIcon bool
if we are needing a new iOS icon
no setter
macOSConfig MacOSConfig?
MacOS platform config
final
minSdkAndroid int
Android min_sdk_android
final
removeAlphaIOS bool
IOS remove_alpha_ios
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
webConfig WebConfig?
Web platform config
final
windowsConfig WindowsConfig?
Windows platform config
final

Methods

getImagePathAndroid() String?
Method for the retrieval of the Android icon path If image_path_android is found, this will be prioritised over the image_path value.
getImagePathIOS() String?
get the image path for IOS
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toJson() Map<String, dynamic>
Converts config to Map
toString() String
A string representation of this object.
override

Operators

operator ==(Object other) bool
The equality operator.
inherited

Static Methods

loadConfigFromFlavor(String flavor, String prefixPath) Config?
Creates Config for given flavor and prefixPath
loadConfigFromPath(String filePath, String prefixPath) Config?
Loads flutter launcher icons configs from given filePath
loadConfigFromPubSpec(String prefix) Config?
Loads flutter launcher icons config from pubspec.yaml file