Raphael.js SVG maps with DropShadow

StackOverflow https://stackoverflow.com/questions/20894954
  •  
  •  | 
  •   ( words)
 Checked

Question

I used Raphael.js but i have problem with SHADOW EFECT.

I try some Raphael plugins (like this https://github.com/dahoo/raphael.dropshadow.js/) for Shadow but i can't do it to work

Please sugest me some. THX

Solution

Try glow

<div id="map"></div>

var map = new Raphael(document.getElementById('map'),400,400);

var path = map.path('m 142.85647,60.432582 -5.84044,9.684235 c 0,0 -5.30949,5.533849 -11.68088,11.759429 -6.37139,6.225579 -9.55709,-2.075194 -9.55709,-2.075194 l -12.74278,-15.909815 -6.902336,1.383463 5.309496,26.285781 -6.902343,1.383462 -2.123796,13.142887 -6.902339,2.76693 c 0,0 -6.350152,1.27278 -10.618983,1.99218 -0.191141,0.0277 -0.361045,0.0553 -0.530949,0.083 -4.247593,0.69173 -13.273728,5.53385 -13.273728,5.53385 l -21.768914,0.69173 -2.123796,-4.84212 9.026135,-6.91731 c 0,0 -13.804677,-13.834619 -19.645118,-17.985006 -5.84044,-4.150386 -15.397524,-4.842117 -15.397524,-4.842117 L 3.8752252,73.049757 C 6.7635885,67.654255 9.6307137,62.507775 11.627082,58.966112 l 0.08495,0.08301 14.335626,8.992504 c 0,0 4.778542,0.691731 7.433288,4.150386 2.654746,3.458656 4.778542,11.067698 4.778542,11.067698 l 6.902339,8.992504 11.149931,-2.766925 4.778542,-8.300773 -5.84044,-9.684235 3.185695,-12.451159 9.557084,-10.375966 7.008528,3.043616 15.291335,6.640619 8.495186,-7.609042 -2.123797,-5.533849 4.778549,-11.067697 h 4.77854 l 11.68088,-8.300773 14.33562,14.526353 -2.12379,10.375966 12.74278,9.684235 z');

path.attr({ fill: 'blue' });

var shadow = path.glow({ color: '#000000', offsety: 5, fill: 'red' });

DEMO http://jsfiddle.net/gkayG/150/

enter image description here

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow