From 61bda71c6d7228a4504803a6f51784d2a6004be9 Mon Sep 17 00:00:00 2001 From: Aaron Parecki Date: Mon, 2 Jan 2017 14:26:58 -0800 Subject: [PATCH] fix centering for any icon with "dot" in the name --- p3k/geo/StaticMap.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/p3k/geo/StaticMap.php b/p3k/geo/StaticMap.php index 6e27e5b..e1093c0 100644 --- a/p3k/geo/StaticMap.php +++ b/p3k/geo/StaticMap.php @@ -478,8 +478,8 @@ function generate($params, $filename, $assetPath) { // Add markers foreach($markers as $marker) { - // Icons that start with 'dot-' do not have a shadow - $shadow = !preg_match('/^dot-/', $marker['icon']); + // Icons that have 'dot' in the name do not have a shadow and center vertically and horizontally + $shadow = !preg_match('/dot/', $marker['icon']); if($width < 120 || $height < 120) { $shrinkFactor = 1.5;