Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Inner shadow effect in flutter

According to the github issue there is no inset attribute in ShadowBox yet. Is there any workaround how to emulate inner shadow right now in flutter.

I like to achieve inner shadow effects like you can see on the following images

enter image description here

enter image description here

like image 588
Mac Avatar asked Jan 06 '19 13:01

Mac


People also ask

What is inner shadow?

Your inner shadow is composed of parts of you that you subconsciously reject. The psychologist Carl Jung popularized the idea of the shadow self, or inner shadow. He defined the collective unconscious with eight different Jungian archetypes: Self: The center of the personality or psyche — your conscious awareness.

What is BoxShadow flutter?

BoxShadow is a built-in widget in flutter, whose functionality is to cast shadow to a box. The BoxShadow widget is usually used with BoxDecoration. In BoxDecoration widget one of its parameters is boxShadow which takes a list of BoxShadow to cast a shadow around a box.


1 Answers

decoration: BoxDecoration(         boxShadow: [           const BoxShadow(             color: your_shadow_color,           ),           const BoxShadow(             color: your_bg_color,             spreadRadius: -12.0,             blurRadius: 12.0,           ),         ],       ), 
like image 149
james Avatar answered Sep 20 '22 04:09

james