Moved hit Tolerance parameter to own example.

This commit is contained in:
simonseyock
2016-12-27 14:53:58 +01:00
parent ca0b74c8fd
commit bd459fde34
4 changed files with 105 additions and 41 deletions

View File

@@ -0,0 +1,21 @@
---
layout: example.html
title: Hit Tolerance
shortdesc: Example of using the hitTolerance parameter.
docs: >
Choose the hit tolerance parameter in pixels and try to click on or near the line feature. If the feature gets hit, it is colored green.
tags: "hitTolerance"
---
<div id="map" class="map"></div>
<form class="form-inline">
<span id="status">&nbsp;No feature got hit.</span>
<br />
<label>Hit tolerance for selecting features </label>
<select id="hitTolerance" class="form-control">
<option value="0" selected>0 Pixels</option>
<option value="5">5 Pixels</option>
<option value="10">10 Pixels</option>
</select>
<br />
Area: &nbsp;<canvas id="circle" style="vertical-align: middle"/>
</form>