Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions docs/user_guide/raster_layers/wms_tile_layer.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,11 @@ import folium

# WmsTileLayer

`transparent=True` requests a transparent background from the WMS server.
It does not make black (or other colored) pixels in the returned imagery transparent.
Use an image format that supports transparency, such as `image/png`, and check
that the server supports transparency for the requested layer.

```{code-cell} ipython3
m = folium.Map(location=[41, -70], zoom_start=5, tiles="cartodb positron")

Expand Down
3 changes: 3 additions & 0 deletions tests/test_raster_layers.py
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,9 @@ def test_wms():
w.add_to(m)
html = m.get_root().render()

assert '"transparent": true' in html
assert '"format": "image/png"' in html

# verify this special case wasn't converted to lowerCamelCase
assert '"cql_filter": "something",' in html
assert "cqlFilter" not in html
Expand Down