image_in_text 1.0.0 copy "image_in_text: ^1.0.0" to clipboard
image_in_text: ^1.0.0 copied to clipboard

A new Flutter package that creates image in text effect. It works in all flutter platforms including web.

example/lib/main.dart

import 'package:flutter/cupertino.dart';
import 'package:flutter/material.dart';
import 'package:image_in_text/image_in_text.dart';

void main()async{
  WidgetsFlutterBinding.ensureInitialized();
  await init("assets/Roboto-Regular.ttf", isAsset: true);
  runApp(MyApp());
}

class MyApp extends StatelessWidget {
  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      debugShowCheckedModeBanner: false,
      home: MyHomePage(),
    );
  }
}

class MyHomePage extends StatelessWidget{
  @override
  Widget build(BuildContext context) {
    return Scaffold(
      backgroundColor: Colors.black,
      body: Container(
        width: MediaQuery.of(context).size.width-MediaQuery.of(context).padding.horizontal,
        height: MediaQuery.of(context).size.height,
        child: FittedBox(
          fit: BoxFit.cover,
          child: ImageInText(
            text: "LAZY",
            boxFit: BoxFit.contain,
            image:  AssetImage(
                "assets/bg.jpg"
            ),
          ),
        ),
      ),
    );
  }
}
5
likes
40
pub points
0%
popularity

Publisher

unverified uploader

A new Flutter package that creates image in text effect. It works in all flutter platforms including web.

Repository (GitHub)
View/report issues

License

Apache-2.0 (LICENSE)

Dependencies

flutter, text_to_path_maker

More

Packages that depend on image_in_text