gauge_chart 1.0.4 copy "gauge_chart: ^1.0.4" to clipboard
gauge_chart: ^1.0.4 copied to clipboard

This Flutter package provides a customizable circular, gauge-style pie chart that can be displayed as a full circle or half circle

example/lib/main.dart

import 'package:flutter/material.dart';
import 'package:gauge_chart/gauge_chart.dart';

void main() {
  runApp(const App());
}

class App extends StatelessWidget {
  const App({
    Key? key,
  }) : super(key: key);

  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      home: Scaffold(
        body: Center(
          child: GaugeChart(
            children: [
              PieData(
                value: 10,
                color: Colors.blue.shade800,
                description: "Taken",
              ),
              PieData(
                value: 4,
                color: Colors.blue.shade300,
                description: "Planned",
              ),
              PieData(
                value: 14,
                color: Colors.grey.shade300,
                description: "To plan",
              ),
            ],
            gap: 3.5,
            animateDuration: const Duration(seconds: 1),
            start: 180,
            displayIndex: 2,
            shouldAnimate: true,
            animateFromEnd: false,
            isHalfChart: true,
            size: 200,
            showValue: false,
            borderWidth: 25,
          ),
        ),
      ),
    );
  }
}
6
likes
160
points
4.07k
downloads

Publisher

verified publishergmihai.com

Weekly Downloads

This Flutter package provides a customizable circular, gauge-style pie chart that can be displayed as a full circle or half circle

Repository (GitHub)

Documentation

API reference

License

BSD-3-Clause (license)

Dependencies

flutter

More

Packages that depend on gauge_chart