简体   繁体   中英

Leaflet printing does not show pins and map is shifted

I don't exactly why but whenever I try to print my leaflet map with layers, it shows the map a little shifted to the left as well as the pins are not quite ok. I tried using easyPrint() and window.print() , same result. It used to work well. Any ideas? Here is the difference

它应该看起来如何

when it opens up to print the map 看起来如何

Using easyprint, (I am importing easyprint's css)

jQuery.print.js:125 
 GET http://127.0.0.1:8001/proj/easyPrint.css  
 $.print.$.fn.print @ jQuery.print.js:125
 (anonymous function) @ VM4317:1

You need to edit the Easyprint.css .

Remove this line:

.leaflet-control-easyPrint-button{display: none!important;}

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM