textStyle property

TextStyle textStyle
final

Customizes the tooltip text's style.

This snippet shows how to customize the tooltip text style in SfMaps.

 @override
 Widget build(BuildContext context) {
   return SfMaps(
     layers: [
       MapShapeLayer(
         enableShapeTooltip: true,
         tooltipSettings: MapTooltipSettings(
             textStyle: TextStyle(color: Colors.red)
         ),
         delegate: MapShapeLayerDelegate(
             shapeFile: "assets/world_map.json",
             shapeDataField: "continent",
             dataCount: bubbleData.length,
             primaryValueMapper: (index) {
               return bubbleData[index].country;
             }),
       )
     ],
   );
 }

Implementation

final TextStyle textStyle