title: How to create a frame around custom marker icons without use of shadows
body: <p>How would you put a white frame behind a dynamically loaded marker icon, now, that the new Google Maps "VisualRefresh" doesn´t allow shadows anymore? <a href="https://developers.google.com/maps/documentation/javascript/basics" rel="nofollow">1</a></p>
  
  <p>Open <a href="http://jsfiddle.net/FSffv/3/" rel="nofollow">http://jsfiddle.net/FSffv/3/</a> with <i>google.maps.visualRefresh = false;</i> to see the white frame around the marker icon and <i>google.maps.visualRefresh = true;</i> to have it disappear. </p>
  
  <pre><code>var map;
  var m_NormalImageSize = 15;
  var m_NormalShadowSize = m_NormalImageSize+5;
  var elevator;
  var myOptions = {
    zoom: 6,
    center: new google.maps.LatLng(47, 8),
    mapTypeId: 'terrain'
  };
  
  // turn VisualRefresh on/off
  google.maps.visualRefresh = false;
  
  map = new google.maps.Map($('#map')[0], myOptions);
  var img = new Image();
  img.src = "http://t2.gstatic.com/images?q=tbn:ANd9GcQUnmYVY5sWfZtBlw_IELax3W8E7-jZcCXLd2HUZYtpk_AeuK4CRnJmMHj0";
  var img_ratio = img.height / img.width;
  if (isNaN(img_ratio)) 
    img_ratio = 1;
  var icon_size = new google.maps.Size(m_NormalImageSize, m_NormalImageSize * img_ratio);
  var shadow_size = new google.maps.Size(m_NormalShadowSize, m_NormalShadowSize * img_ratio);
  var image = new google.maps.MarkerImage(
    "http://t2.gstatic.com/images?q=tbn:ANd9GcQUnmYVY5sWfZtBlw_IELax3W8E7-jZcCXLd2HUZYtpk_AeuK4CRnJmMHj0",
    icon_size,
    new google.maps.Point(0, 0),
    new google.maps.Point(-3, m_NormalImageSize * img_ratio + 3 * img_ratio),
    icon_size
  );
  
  // the frame around the marker icon as a shadow
  var shadow = new google.maps.MarkerImage(
    "http://alsotoday.com/jpg/placemarkbackground_white.png",
    shadow_size,
    new google.maps.Point(0, 0),
    new google.maps.Point(0, m_NormalShadowSize * img_ratio),
    shadow_size
  );
  
  var marker = new google.maps.Marker({
    position: new google.maps.LatLng(47, 8),
    map: map,
    icon: image,
    shadow: shadow,
    title: "hallo"
   });
  </code></pre>