{"id":17603173,"url":"https://github.com/yjg30737/pyqt-folium-example","last_synced_at":"2025-10-18T20:12:53.477Z","repository":{"id":65620935,"uuid":"587587369","full_name":"yjg30737/pyqt-folium-example","owner":"yjg30737","description":"Showing folium(based on leaflet.js) map with PyQt desktop app","archived":false,"fork":false,"pushed_at":"2023-03-20T02:32:25.000Z","size":71,"stargazers_count":7,"open_issues_count":1,"forks_count":2,"subscribers_count":1,"default_branch":"main","last_synced_at":"2024-12-29T08:42:11.868Z","etag":null,"topics":["folium","folium-gui","pyqt-folium","pyqt-gui","pyqt-map","pyqt5-examples","pyqt5-folium","pyqt5-tutorial","python-folium","python-map"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/yjg30737.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2023-01-11T05:09:24.000Z","updated_at":"2024-08-20T18:43:14.000Z","dependencies_parsed_at":"2024-10-23T06:00:06.505Z","dependency_job_id":null,"html_url":"https://github.com/yjg30737/pyqt-folium-example","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/yjg30737%2Fpyqt-folium-example","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/yjg30737%2Fpyqt-folium-example/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/yjg30737%2Fpyqt-folium-example/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/yjg30737%2Fpyqt-folium-example/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/yjg30737","download_url":"https://codeload.github.com/yjg30737/pyqt-folium-example/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":232282809,"owners_count":18499325,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["folium","folium-gui","pyqt-folium","pyqt-gui","pyqt-map","pyqt5-examples","pyqt5-folium","pyqt5-tutorial","python-folium","python-map"],"created_at":"2024-10-22T13:41:53.821Z","updated_at":"2025-10-18T20:12:53.383Z","avatar_url":"https://github.com/yjg30737.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# pyqt-folium-example\nShowing folium(based on leaflet.js) map with PyQt desktop(+web) app\n\nThis is not the static map viewer, this is basic client-server side web app.\n\nServer side is using the 5000 port. Therefore, you should check whether the port 5000 is already in use or not.\n\n## Requirements\n* folium\n* QtWebEngineView\n* jinja2 - to use javascript in the Python source\n* flask (Python web framework, it needs to build the web app) - to save the information in DB\n* flask_cors - to fix the CORS error\n\n## How to Use\n1. git clone ~\n2. python -m pip install PyQt5-stubs - if this is not installed, QtWebEngineWidgets might not work\n3. python -m pip install PyQtWebEngine\n4. python -m pip install folium\n5. python main.py\n\n## How to check the error\nThis script doesn't support error log on its own(it is very hard), so we need to use the browser like Chrome, Edge, Firefox.\n\n1. Go to the root directory\n2. Open the script.py file and uncomment the code below\n```python\n# for test by browser\n# app.run()\n```\n3. python server.py\n4. open map.html\n5. Chrome, for example, you can see the log to figure it out it works well or not. It doesn't work for some reasons, you can fix the error on your own.\n\n![image](https://user-images.githubusercontent.com/55078043/226232439-00c79606-fa9a-4805-b99f-16455e93fa38.png)\n\n## Preview\n\n![image](https://user-images.githubusercontent.com/55078043/218347247-bd0ce881-e07d-46f7-8469-95eb702103b2.png)\n\nThis is very basic one. Zoom in and out and you can see the country's name and region or anything like that\n\nYou can switch between each tile by clicking on each radio button.\n\nEach time you click one of them, the Folium HTML file is saved and the QWebEngineView is reloaded.\n\n## Note\nmain.html will be generated for showing the folium map. main.html contains folium related scripts.\n\n## TODO\n* Toggle the sidebar\n* Connect one's route to the other\n* Stop the server when the web app is closed\n* Add feature to export it as DB\n* Get the location's name with tooltip\n\n## See Also\nNote: examples on the list are the static map viewer. It doesn't use the server-side at all.\n* \u003ca href=\"https://github.com/yjg30737/pyqt-googlemap-example\"\u003ePyQt Google Map Example\u003c/a\u003e\n* \u003ca href=\"https://github.com/yjg30737/pyqt-plotly-example.git\"\u003ePyQt Plotly Example\u003c/a\u003e\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fyjg30737%2Fpyqt-folium-example","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fyjg30737%2Fpyqt-folium-example","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fyjg30737%2Fpyqt-folium-example/lists"}