New answers tagged qgis-plugins
1
vote
PyQGIS: moving legend with changed reference point
From your screenshot, it is clear that your legend is being added to your layout, "except for being in the wrong place".
You haven't shown or explained how you calculated the layout point ...
1
vote
Adding a fixed table to layout in QGIS
Late to the party but an answer
composerTitle = 'Layout 1'
project = QgsProject.instance()
projectLayoutManager = project.layoutManager()
# Access to the layout by name
layout = projectLayoutManager....
1
vote
Creating Network Flow Diagram using QGIS
In my opinion, you should start with the telecom project you are working on. Next, for sure you will find the layers you need to include in your network flow schematic. You can follow the steps:
...
1
vote
Using PyQGIS to buffer the width different than the height of a rectangle
Here a PyQGIS solution for 1 feature :
from functools import lru_cache
@lru_cache(maxsize=6)
def orientation_choices(num_coords: int, axis: str = "x") -> list:
if axis == "x&...
0
votes
QGIS 3.24.1 - Problem Plugin NTv2 Datum Transformations - A failure in the SSL library occurred (_ssl.c:1129)
I was not able o find the reason, so I had to allow unverified ssl with the following code
import ssl ssl._create_default_https_context = ssl._create_unverified_context Afterwards the plugin was ...
0
votes
MMQGIS export shapefile to KML not working, error message: 'Unknown geometry type 0'. But Point data being used?
Before you will use the KML export by the MMQGIS plugin you should reproject your layer. The quickest way to do it is using the "Reproject layer" option in your processing toolbox.
As the ...
3
votes
Accepted
Conditional signals in QgsTask managing algorithm output
Try the example below. Sorry, your code was a bit of a mess, I basically tried to make it functional in the quickest way that I could. I suggest to now study the code and do your own research and self ...
0
votes
Accepted
How to create 3D polygon layer in QGIS 3 or convert 2D layer to 3D similar to PostGIS function ST_Force3d()
Ok I was able to solve this by using this code when saving to file:
QgsVectorFileWriter.writeAsVectorFormat(inputlayer, str(outputlayer), "utf-8", QgsCoordinateReferenceSystem("EPSG:...
1
vote
Accepted
pyqgis 3 zoom to selected polygon without zooming in so far
I created a quick script with the setCenter method from the QgsMapCanvas class.
It allows you to change the extent of the canvas without changing zoom level. It works with Polygons, Lines and Points.
...
4
votes
Accepted
Sharing class variables across thread (QgsTasks) with pyQGIS
Here is working example. I have modified your code a bit. Because both your tasks have much the same function (to run a processing algorithm and return a result layer) I would prefer to only create ...
2
votes
Accepted
Get M-value from shapefile by mouse click on canvas
There are two main issues with your code. First one is that QgsMapToolIdentify.identify() will return a list of identified features.
So you will need index your result variable before accessing any ...
1
vote
Accepted
Pyqgis 3 adding polygon vector layer in code and triggering iface.actionAddFeature().trigger() will give me polygons but they cannot be selected
Regarding your first problem I can only assume that you forgot to commit your changes to the underlying data provider.
This could be an issue if you iterate through each feature and zoom to it's ...
0
votes
How to Update Plugin Installed Manually (Zip File)
For those still looking for a way to create a proper QGIS repository you have this script that is just perfect:
https://gitlab.com/GIS-projects/phpQGISrepository/
2
votes
Tiles XYZ plugin for newer versions of QGIS
So I figured it out. The plugin is now already within the QGIS processing tool box and it is known as Generate XYZ Tiles (MbTiles)
1
vote
Adding missing python packages to QGIS Plugin?
The place were the blessed route to a solution will be, if it can be found, is PIP dependencies for Python plugins QGIS enhancement proposal. It's a hard problem to solve. That thread contains ...
Top 50 recent answers are included
Related Tags
qgis-plugins × 2727qgis × 1747
pyqgis × 898
qgis-3 × 345
python × 311
qgis-2 × 193
qgis-processing × 170
pyqt × 88
pyqgis-3 × 86
raster × 66
installation × 56
grass × 51
error × 51
postgis × 45
python-2.7 × 45
pyqt5 × 40
c++ × 38
plugins × 36
coordinate-system × 32
openstreetmap × 32
qt-designer × 32
gdal × 30
print-composer × 29
polygon × 28
georeferencing × 28