Over a million developers have joined DZone.
{{announcement.body}}
{{announcement.title}}

AnimatedCluster Demo Site Updated to Work with OpenLayers 2.12

DZone's Guide to

AnimatedCluster Demo Site Updated to Work with OpenLayers 2.12

· Web Dev Zone ·
Free Resource

Deploy code to production now. Release to users when ready. Learn how to separate code deployment from user-facing feature releases with LaunchDarkly.

Not an awesome post but for any interested in the AnimatedCluster strategy I have updated the demo site to work properly with OpenLayers 2.12.

In version 2.12 symbolizer are richest than in 2.11 and required to set the labelOutlineWidth property to some low value to show the labels fine:

var lowRule = new OpenLayers.Rule({
    filter: new OpenLayers.Filter.Comparison({
        type: OpenLayers.Filter.Comparison.LESS_THAN,
        property: "count",
        value: 15
    }),
    symbolizer: {
        fillColor: colors.low,
        fillOpacity: 0.9, 
        strokeColor: colors.low,
        strokeOpacity: 0.5,
        strokeWidth: 12,
        pointRadius: 10,
        label: "${count}",
        labelOutlineWidth: 1,
        fontColor: "#ffffff",
        fontOpacity: 0.8,
        fontSize: "12px"
    }
});

See in action:

Deploy code to production now. Release to users when ready. Learn how to separate code deployment from user-facing feature releases with LaunchDarkly.

Topics:

Published at DZone with permission of

Opinions expressed by DZone contributors are their own.

{{ parent.title || parent.header.title}}

{{ parent.tldr }}

{{ parent.urlSource.name }}