看板 Python 關於我們 聯絡資訊
不好意思,想請教透過folium / geojson加圖層後 要怎麼更改線條顏色 google發現是透過stlye函數 但是只能改layer裡面的顏色 layer線條的顏色好像無法~ 是否有哪裡做錯了 謝謝~~ style1 = {'fillColor': '#228B22', 'lineColor': '#228B22'} style2 = {'fillColor': '#00FFFFFF', 'lineColor': '#00FFFFFF'} test1=gpd.read_file('file2.geojson') folium.GeoJson(test1,name='test1',style_function=lambda x: style).add_to(mainmap) test2=gpd.read_file('file1.geojson') folium.GeoJson(test2,name='test2', style_function=lambda x: style2).add_to(mainmap) https://imgur.com/4awkXVi 感謝~~ -- ※ 發信站: 批踢踢實業坊(ptt.cc), 來自: 36.230.242.102 (臺灣) ※ 文章網址: https://www.ptt.cc/bbs/Python/M.1571328534.A.E8C.html ※ 編輯: fattyfox (36.230.242.102 臺灣), 10/18/2019 00:11:14
fattyfox: https://imgur.com/a/4awkXVi 10/18 00:14
※ 編輯: fattyfox (36.230.242.102 臺灣), 10/18/2019 00:14:41