Search in sources :

Example 1 with LScale

use of org.vaadin.addon.leaflet.control.LScale in project v-leaflet by mstahv.

the class HasControlTest method getTestComponent.

@Override
public Component getTestComponent() {
    map = new LMap();
    map.setCenter(40, -105.2);
    map.setZoomLevel(11);
    map.addControl(new LScale());
    return map;
}
Also used : LMap(org.vaadin.addon.leaflet.LMap) LScale(org.vaadin.addon.leaflet.control.LScale)

Example 2 with LScale

use of org.vaadin.addon.leaflet.control.LScale in project v-leaflet by mstahv.

the class MapInWindowIssue19 method createMap.

private LMap createMap() {
    final LMap map = new LMap();
    map.setCenter(41.920833176630296, 1.853337480434182);
    map.setZoomLevel(5);
    map.addControl(new LScale());
    map.addControl(new LZoom());
    AbstractLeafletLayer[] layers = new AbstractLeafletLayer[] { createTileLayer("OSM", "https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png", "a", "b", "c") };
    addLayers(map, layers);
    return map;
}
Also used : LMap(org.vaadin.addon.leaflet.LMap) LZoom(org.vaadin.addon.leaflet.control.LZoom) AbstractLeafletLayer(org.vaadin.addon.leaflet.AbstractLeafletLayer) LScale(org.vaadin.addon.leaflet.control.LScale)

Aggregations

LMap (org.vaadin.addon.leaflet.LMap)2 LScale (org.vaadin.addon.leaflet.control.LScale)2 AbstractLeafletLayer (org.vaadin.addon.leaflet.AbstractLeafletLayer)1 LZoom (org.vaadin.addon.leaflet.control.LZoom)1