ProgressModel constructor
ProgressModel({
- int width = _defaultWidth,
- String full = defaultFullCharHalfBlock,
- String fullColor = '#7571F9',
- String empty = defaultEmptyCharBlock,
- String emptyColor = '#606060',
- bool showPercentage = true,
- String percentFormat = ' %3.0f%%',
- Style? percentageStyle,
- double frequency = _defaultFrequency,
- double damping = _defaultDamping,
- bool useGradient = false,
- String gradientColorA = '#5A56E0',
- String gradientColorB = '#EE6FF8',
- List<
String> blend = const [], - ColorFunc? colorFunc,
- bool scaleGradient = false,
- bool scaleBlend = false,
- bool indeterminate = false,
- double pulseWidth = 0.2,
- DateTime? startTime,
- double percentShown = 0,
- double targetPercent = 0,
- double velocity = 0,
- double pulseOffset = 0,
- int? id,
- int tag = 0,
Creates a new progress bar model.
Implementation
ProgressModel({
this.width = _defaultWidth,
this.full = defaultFullCharHalfBlock,
this.fullColor = '#7571F9',
this.empty = defaultEmptyCharBlock,
this.emptyColor = '#606060',
this.showPercentage = true,
this.percentFormat = ' %3.0f%%',
Style? percentageStyle,
this.frequency = _defaultFrequency,
this.damping = _defaultDamping,
this.useGradient = false,
this.gradientColorA = '#5A56E0',
this.gradientColorB = '#EE6FF8',
this.blend = const [],
this.colorFunc,
this.scaleGradient = false,
this.scaleBlend = false,
this.indeterminate = false,
this.pulseWidth = 0.2,
this.startTime,
double percentShown = 0,
double targetPercent = 0,
double velocity = 0,
double pulseOffset = 0,
int? id,
int tag = 0,
}) : percentageStyle = percentageStyle ?? Style(),
_spring = _Spring(frequency: frequency, damping: damping),
_percentShown = percentShown,
_targetPercent = targetPercent,
_velocity = velocity,
_pulseOffset = pulseOffset,
_id = id ?? _nextProgressId(),
_tag = tag;