Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    text
    copied!<h1>Update</h1> <p>The <code>SVG2</code> renderer was introduced in v2.11, and then <strong>immediately deprecated</strong> in v2.12 for reliability reasons (See <a href="https://github.com/openlayers/openlayers/pull/306" rel="noreferrer">this pull request</a>). For OL >= 2.12, set the layer's <code>ratio</code> property to have it render all features within a wider area as a ratio of the screen size. The trade-off is performance, and if your user "throws" their map in some direction, they will fly past the features, but at that point they probably expect to have some rendering delays.</p> <pre><code>new OpenLayers.Layer.Vector("My Layer", { ratio: 2 }); </code></pre> <h1>Original Answer</h1> <p>From <a href="http://lists.osgeo.org/pipermail/openlayers-dev/2011-March/007345.html" rel="noreferrer">http://lists.osgeo.org/pipermail/openlayers-dev/2011-March/007345.html</a> :</p> <blockquote> <p>the new <code>OpenLayers.Renderer.SVG2</code> renderer does what you are requesting. It is available on trunk (and will be in 2.11). To use it, configure the renderers array for your <code>OpenLayers.Layer.Vector</code> like this:</p> <pre><code>new OpenLayers.Layer.Vector("My Layer", { renderers: ["SVG2", "VML", "Canvas"] }); </code></pre> <p>Or set it on the prototype:</p> <p><code>OpenLayers.Layer.Vector.renderers = ["SVG2", "VML", "Canvas"];</code></p> <p>Note that VML (used in IE6,7,8) and Canvas (used on Android devices) behave like <code>Renderer.SVG</code> and don't draw features while panning.</p> </blockquote>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload