Skip to content

Releases: JaWeilBaum/pyqtlet2

Version 0.9.3

02 Feb 15:36
0.9.3
0e9fdd8
Compare
Choose a tag to compare

At multiple places in the library the multiple map feature was not yet implemented. This should hopefully be resolved with this release.

What's Changed

  • Fix popup and tooltip binding by @Baljak in #50
  • Adjust structure to work with multiple maps by @Baljak in #54

New Contributors

Full Changelog: 0.9.1...0.9.3

Version 0.9.1

28 Dec 20:30
0.9.1
c5ee20f
Compare
Choose a tag to compare

What's Changed

  • Bug fix when Draw is created and Control added to Map by @ericj974 in #49
  • Adjusted the event body which is sent from _onMove and _onMoveend to have the same body structure. Thanks for pointing that out @ericj974

New Contributors

Full Changelog: 0.9.0...0.9.1

Version 0.9.0

04 Dec 14:52
0.9.0
bf73968
Compare
Choose a tag to compare

Changes

pyqtlet2 in version 0.9.0 now supports multiple maps in one application!

Closed issues:

Sample Code:

import sys
from PyQt5.QtWidgets import QApplication, QHBoxLayout, QWidget
from pyqtlet2 import L, MapWidget
import pyqtlet2.leaflet.core


class MapWindow(QWidget):
    def __init__(self):
        # Setting up the widgets and layout
        super().__init__()
        self.mapWidget1 = MapWidget()
        self.mapWidget2 = MapWidget()
        self.layout = QHBoxLayout()
        self.layout.addWidget(self.mapWidget1)
        self.layout.addWidget(self.mapWidget2)
        self.setLayout(self.layout)

        # Working with the maps with pyqtlet
        self.map1 = L.map(self.mapWidget1)
        self.map1.setView([12.97, 77.59], 10)
        L.tileLayer('http://{s}.tile.osm.org/{z}/{x}/{y}.png').addTo(self.map1)

        self.map2 = L.map(self.mapWidget2)
        self.map2.setView([12.97, 77.59], 10)
        L.tileLayer('http://{s}.tile.osm.org/{z}/{x}/{y}.png').addTo(self.map2)

        self.marker1 = L.marker([12.934056, 77.610029], options={'draggable': True}).addTo(self.map1)
        self.marker1.bindPopup('Maps are a treasure.')
        self.marker1.moveend.connect(print)

        self.marker2 = L.marker([12.934056, 77.610029]).addTo(self.map2)
        self.marker2.setDragging(True)
        self.marker2.bindPopup('Maps are a treasure.')
        self.marker2.moveend.connect(print)

        self.show()

if __name__ == '__main__':
    app = QApplication(sys.argv)
    widget = MapWindow()
    sys.exit(app.exec_())

Download via PyPi

Version 0.8.3

04 Dec 12:53
0.8.3
49d74af
Compare
Choose a tag to compare

In the realese the version was leaflet version was updated from 1.7.1 to 1.9.3

Version 0.8.1

30 Sep 10:07
0.8.1
e6c14b2
Compare
Choose a tag to compare

Minor changes

Version 0.8.0

06 Mar 21:53
0.8.0
9c1482f
Compare
Choose a tag to compare

What's Changed

What's New

You can now use QtPy as general interface to work with all kind of python Qt bindings. Have a look into the README.md to findout how to use it.

During the install you can pass the Qt binding framework of your choice

pip3 install "pyqtlet2[PyQt5]"
# or
pip3 install "pyqtlet2[PySide6]"

After the install you need to specify the framework to use by an environment variable.

import os
os.environ['QT_API'] = 'pyqt5'
from qtpy import QtGui

Full Changelog: 0.7.0...0.8.0

Version 0.7.0

27 Feb 16:02
0.7.0
064d91f
Compare
Choose a tag to compare

What's Changed

  • add PySide6 support by @danielhrisca in #25
  • Added install_requires to setup.py to install required packages on the fly
  • Added long_description to setup.py to show description on pypi.org

New Contributors

Full Changelog: 0.6.0...0.7.0

Version 0.6.0

15 Feb 20:14
0.6.0
b5433a9
Compare
Choose a tag to compare

What's Changed

You are now able to install pyqtlet2 via pypi and have full support of all map components. Earlier there had been issues where html or js files where missing. Thanks again to @JuanPotato !

New Contributors

Full Changelog: 0.5.0...0.6.0

Version 0.5.0

15 Nov 07:49
0.5.0
60709e1
Compare
Choose a tag to compare

Version 0.5.0

What's Changed

Code snipets

Chained calls

Before:

arrow = L.polygon([c, a], {'color': color})
arrow.addTo(self.map)
tag = arrow._ayerName

After:

tag = L.polygon([c, a], {'color': color}).addTo(self.map).layerName

L.Icon

icon_url_website = "https://leafletjs.com/examples/custom-icons/leaf-red.png"
self.red_icon = L.icon(iconUrl=icon_url_website, options={
    "iconSize": [38, 95],
    "iconAnchor": [22, 94],
})

self.marker1 = L.marker([12.934056, 77.610029], options={"draggable": "true"})
self.marker1.setIcon(self.red_icon)

New Contributors

Version 0.4.9

03 Nov 22:26
0.4.9
e11a0d9
Compare
Choose a tag to compare

Full Changelog: 0.4.8...0.4.9