flutter container elevation

body: Container(
    margin: EdgeInsets.all(8),
    decoration: BoxDecoration(
        borderRadius: BorderRadius.circular(8.0),
        color: Colors.white,
        boxShadow: [
            BoxShadow(
                color: Colors.black,
                blurRadius: 2.0,
                spreadRadius: 0.0,
                offset: Offset(2.0, 2.0), // shadow direction: bottom right
            )
        ],
    ),
    child: Container(width: 100, height: 50) // child widget, replace with your own
),

3.8
5
Jim G. 90 points

                                    return Material(
       elevation: 20,
       child Container(),
       );

3.8 (5 Votes)
0
4.13
8

                                    import "package:flutter/material.dart";

void main() => runApp(MyApp());

class MyApp extends StatelessWidget {
  Widget build(BuildContext context) {
    return MaterialApp(
      home: HomePage(),
    );
  }
}

class HomePage extends StatelessWidget {
  @override
  Widget build(BuildContext context) {
    return Scaffold(
      body: Center(
        child: Padding(
          padding: const EdgeInsets.all(30.0),
          child: ClipRRect(
            borderRadius: BorderRadius.circular(5.0),
            child: Container(
              height: 100.0,
              margin: const EdgeInsets.only(bottom: 6.0), //Same as `blurRadius` i guess
              decoration: BoxDecoration(
                borderRadius: BorderRadius.circular(5.0),
                color: Colors.white,
                boxShadow: [
                  BoxShadow(
                    color: Colors.grey,
                    offset: Offset(0.0, 1.0), //(x,y)
                    blurRadius: 6.0,
                  ),
                ],
              ),
            ),
          ),
        ),
      ),
    );
  }
}

4.13 (8 Votes)
0
Are there any code examples left?
Create a Free Account
Unlock the power of data and AI by diving into Python, ChatGPT, SQL, Power BI, and beyond.
Sign up
Develop soft skills on BrainApps
Complete the IQ Test
Relative searches
make elevation for container flutter left container elevation flutter how to give elevation to a cotiner in flutter how to give elevation in flutter add elevation to widget flutter flutter elevation to container give elevation to container in flutter how to changes the elevation of a container in flutter container border elevation in flutter give container elevation material -flutter make elevation flutter flutter material elevation in container flutter elevation any widget without container flutter elevation any widget give elevation to one side container flutter put elevation in container in flutter elevation of container flutter container shape flutter with elevation ciontainer elevation flutter Flutter How to set elevation to container giving a container elevation in flutter flutter elevation to widget flutter material elevation to container elevation flutter container elevation for container flutter how to give elevation to container flutter elevation in flutter container flutter add elevation on container flutter give container elevation container box elevation flutter container flutter elevation add elevation to container flutter from bottom container top elevation flutter flutter container with elevation flutter elevation container decoration flutter elevation adding elevation to container flutter put elevation on container flutter box shadow at right of the card in flutter how to make elevation in container flutter flutter elevate container elevation box decoration flutter flutter container elevetaion contianer elevate on side flutter flutter page shadow how to make a container raised flutter how to make drop shadow container flutter how to set container shadow in flutter elevation to container flutter how to show elevation effect in flutter how to put elevation on container in flutter container( decoration flutter) flutter hide appbar elevation elevation in container flutter flatbutton elevation flutter card elevation flutter add a custom shadow to a container in flutter flutter container box decoration shadow flutter container adde elvation flutter container boxdecoration how give an elevated look in flutter shadow outside container flutter how to give a container a background color and elevation in flutter make a container elevated flutter make container look elavated flutter make container look raised flutter flutter add elivation to container elevation container flutter elevation in flutter container shadow in flutter add elevation to container flutter container with elevation flutter how to add elevation in container flutter give elevation to container flutter elevation fo container in flutter flutter elevation container elevated container flutter flutter container elevation elevation container fluter elevation on container flutter container elevation flutter give container elevation flutter adding evaluation for a container flutter how to add elevation to container flutter Container flutter elevationo flutter elevation direction elevate container flutter set elevation to container flutter how to give elevation to container in flutter flutter add elevation to container
Made with love
This website uses cookies to make IQCode work for you. By using this site, you agree to our cookie policy

Welcome Back!

Sign up to unlock all of IQCode features:
  • Test your skills and track progress
  • Engage in comprehensive interactive courses
  • Commit to daily skill-enhancing challenges
  • Solve practical, real-world issues
  • Share your insights and learnings
Create an account
Sign in
Recover lost password
Or log in with

Create a Free Account

Sign up to unlock all of IQCode features:
  • Test your skills and track progress
  • Engage in comprehensive interactive courses
  • Commit to daily skill-enhancing challenges
  • Solve practical, real-world issues
  • Share your insights and learnings
Create an account
Sign up
Or sign up with
By signing up, you agree to the Terms and Conditions and Privacy Policy. You also agree to receive product-related marketing emails from IQCode, which you can unsubscribe from at any time.
Creating a new code example
Code snippet title
Source