Zoom Slider Control#

The Zoom Slider Control in ipyopenlayers provides a convenient slider interface for users to control the zoom level of the map. This control enhances the user experience by allowing a more intuitive and precise adjustment of the zoom level.

Example#

from ipyopenlayers import Map, ZoomSlider, RasterTileLayer


# Create a map with initial zoom level and center coordinates
m = Map(center=[0, 0], zoom=2)

# Add layer
layer=RasterTileLayer()
m.add_layer(layer)


# Add a ZoomSlider control to the map
zoom_slider = ZoomSlider()
m.add_control(zoom_slider)


# Display the map
m

Attributes#

class ipyopenlayers.openlayers.ZoomSlider(*args: t.Any, **kwargs: t.Any)[source]#

ZoomSlider class for adding a zoom slider control to the map.