How To Add Appbar Shadow Using Flutter Android App

admin_img Posted By Bajarangi soft , Posted On 30-10-2020

Add Appbar Shadow

How To Add Appbar Shadow Using Flutter Android App

 Add Appbar Shadow
Complete Code For  Add Appbar Shadow In Flutter
main.dart

import 'dart:async';
import 'package:flutter/material.dart';
void main() {
  runApp(new MyApp());
}

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

class MyHomePage extends StatefulWidget {
  @override
  _MyHomePageState createState() => _MyHomePageState();
}

class _MyHomePageState extends State<MyHomePage> {
  bool _isLoading = false;

  initApp() async {
    setState(() => _isLoading = true);
    Future.delayed(Duration(seconds: 6)).then((_) {
      setState(() => _isLoading = false);
    });
  }

  @override
  void initState() {
    super.initState();
    initApp();
  }

  @override
  Widget build(BuildContext context) {
    return Scaffold(
      appBar: AppBar(
        elevation: 20,
        backgroundColor: Colors.red[700],
          title: Text("Elevation Add In AppBar")),
      body: Center(
              child: Text("Future Completed!",
              style: TextStyle(fontSize: 20, fontWeight: FontWeight.bold,))),
    );
  }
}

Related Post