SfGaugeThemeData class
Holds the color and typography values for a SfGaugeTheme. Use this class to configure a SfGaugeTheme widget
To obtain the current theme, use SfGaugeTheme.of.
Widget build(BuildContext context) {
return Scaffold(
body: SfGaugeTheme(
data: SfGaugeThemeData(
brightness: Brightness.dark,
backgroundColor: Colors.grey
),
child: SfRadialGauge()
),
);
}
See also:
- SfTheme and SfThemeData, for customizing the visual appearance of the radial gauges widgets.
- Mixed-in types
- Annotations
Constructors
- SfGaugeThemeData({Color backgroundColor = Colors.transparent, Color? titleColor, Color? axisLabelColor, Color? axisLineColor, Color? majorTickColor, Color? minorTickColor, Color? markerColor, Color markerBorderColor = Colors.transparent, Color? needleColor, Color? knobColor, Color knobBorderColor = Colors.transparent, Color? tailColor, Color tailBorderColor = Colors.transparent, Color? rangePointerColor, Color? rangeColor, Color titleBorderColor = Colors.transparent, Color titleBackgroundColor = Colors.transparent, TextStyle? titleTextStyle, TextStyle? axisLabelTextStyle, TextStyle? markerTextStyle})
-
Initialize the gauge theme data
const
- SfGaugeThemeData.raw({Brightness? brightness, Color backgroundColor = Colors.transparent, Color? titleColor, Color? axisLabelColor, Color? axisLineColor, Color? majorTickColor, Color? minorTickColor, Color? markerColor, Color markerBorderColor = Colors.transparent, Color? needleColor, Color? knobColor, Color knobBorderColor = Colors.transparent, Color? tailColor, Color tailBorderColor = Colors.transparent, Color? rangePointerColor, Color? rangeColor, Color titleBorderColor = Colors.transparent, Color titleBackgroundColor = Colors.transparent, TextStyle? titleTextStyle, TextStyle? axisLabelTextStyle, TextStyle? markerTextStyle})
-
Create a SfGaugeThemeData given a set of exact values.
factory
Properties
- axisLabelColor → Color?
-
Specifies the axis label color
final
- axisLabelTextStyle → TextStyle?
-
Specifies the text style for axis label.
final
- axisLineColor → Color?
-
Specifies the axis line color
final
- backgroundColor → Color
-
Create a SfGaugeThemeData given a set of exact values.
All the values must be specified.
final
- hashCode → int
-
The hash code for this object.
no setteroverride
- knobBorderColor → Color
-
Specifies the knob border color
final
- knobColor → Color?
-
Specifies the knob color
final
- majorTickColor → Color?
-
Specifies the major tick line color
final
- markerBorderColor → Color
-
Specifies the marker border color
final
- markerColor → Color?
-
Specifies the marker color
final
- markerTextStyle → TextStyle?
-
Specifies the text style for marker text.
final
- minorTickColor → Color?
-
Specifies the minor tick line color
final
- needleColor → Color?
-
Specifies the needle color
final
- rangeColor → Color?
-
Specifies the range color
final
- rangePointerColor → Color?
-
Specifies the range pointer color
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- tailBorderColor → Color
-
Specifies the tail border color
final
- tailColor → Color?
-
Specifies the tail color
final
- titleBackgroundColor → Color
-
Specifies the title background color
final
- titleBorderColor → Color
-
Specifies the title border color
final
- titleColor → Color?
-
Specifies the title color
final
- titleTextStyle → TextStyle?
-
Specifies the text style for gauges title.
final
Methods
-
copyWith(
{Brightness? brightness, Color? backgroundColor, Color? titleColor, Color? axisLabelColor, Color? axisLineColor, Color? majorTickColor, Color? minorTickColor, Color? markerColor, Color? markerBorderColor, Color? needleColor, Color? knobColor, Color? knobBorderColor, Color? tailColor, Color? tailBorderColor, Color? rangePointerColor, Color? rangeColor, Color? titleBorderColor, Color? titleBackgroundColor, TextStyle? titleTextStyle, TextStyle? axisLabelTextStyle, TextStyle? markerTextStyle}) → SfGaugeThemeData - Creates a copy of this gauge theme data object with the matching fields replaced with the non-null parameter values.
-
debugFillProperties(
DiagnosticPropertiesBuilder properties) → void -
Add additional properties associated with the node.
override
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toDiagnosticsNode(
{String? name, DiagnosticsTreeStyle? style}) → DiagnosticsNode -
Returns a debug representation of the object that is used by debugging
tools and by DiagnosticsNode.toStringDeep.
inherited
-
toString(
{DiagnosticLevel minLevel = DiagnosticLevel.info}) → String -
A string representation of this object.
inherited
-
toStringShort(
) → String -
A brief description of this object, usually just the runtimeType and the
hashCode.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
override
Static Methods
-
lerp(
SfGaugeThemeData? a, SfGaugeThemeData? b, double t) → SfGaugeThemeData? - Returns the gauge theme data