dashed_line 0.1.0+1 copy "dashed_line: ^0.1.0+1" to clipboard
dashed_line: ^0.1.0+1 copied to clipboard

outdated

Draw dashed lines with any shape and style you want. Just like that.

example/lib/main.dart

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

void main() => runApp(const MaterialApp(home: HomeScreen()));

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

  @override
  Widget build(BuildContext context) {
    final path = Path()..cubicTo(-40, 53, 14, 86, 61, 102);

    return Scaffold(
      appBar: AppBar(
        title: const Text('dashed_line example'),
      ),
      floatingActionButton: FloatingActionButton(
        onPressed: () {},
        child: const Icon(Icons.celebration),
      ),
      body: Column(
        crossAxisAlignment: CrossAxisAlignment.stretch,
        children: [
          const Spacer(),
          Text(
            'Click me!',
            textAlign: TextAlign.center,
            style: Theme.of(context).textTheme.headline4,
          ),
          Expanded(
            child: Padding(
              padding: const EdgeInsets.fromLTRB(72, 0, 72, 64),
              child: DashedLine(
                path: path,
                color: Theme.of(context).textTheme.headline4!.color!,
              ),
            ),
          ),
        ],
      ),
    );
  }
}
74
likes
0
pub points
85%
popularity

Publisher

verified publisherleancode.co

Draw dashed lines with any shape and style you want. Just like that.

Repository (GitHub)
View/report issues

License

unknown (license)

Dependencies

flutter, svg_path_parser

More

Packages that depend on dashed_line