Hot answers tagged

6

More a guide than a definitive answer. It's a structured compilation of comments from the post. Try to find out why it's slow by using a plugin called "Plugin Load Times" to see plugins loading consumption. Be careful as stated in the plugin description It does not give you information about the speed of plugins when they are used. try to ...


6

Use Filter Current Selection:


5

In the case of the Select by location tool, you can define a spatial criteria to select features only within the already selected features.


4

You should try the following legend.rstyle(QgsLegendStyle.Symbol).setMargin( QgsLegendStyle.Top , 0) This variable above is the value I change in following animation


4

Just hit the rectangle with the two triangles attached to it to the right of the point count or density field. This allows you to choose data defined override - e.g. by choosing a column which holds valid values. So no, there hasn't be any renaming, the GUI simply has been made more sleek.


4

CAD-like digitizing tools are activated via View > Panels > Advanced Digitizing panel > Enable advanced digitizing tools Angles for the cursor to stick are selected by clicking the 'gear button' on the Advanced digitizing panel. Cursor position indication is activated by the 'Toggle floater' button of the same panel. Not sure, if this is proper use ...


4

I had the same issue and I solved it when I changed the download site to ftp.osuosl.org. It looked funny to me because after trying this one I decided to try the previous two again (osgeo4w-oslandia and OSGeo), that I unsuccessfully tested before osuosl... And it worked! QGIS 3.14 Pi was there in the Desktop installation options, contrarily to my first test. ...


3

In QGIS 3.10 it's possible to dynamically create a Revision Cloud Style with the help of the indispensable "geometry generator" and a custom Python expression function. Hat tip to @christoph and his answer here https://gis.stackexchange.com/a/354873/94350 about wavy lines that I am used as the basis for this answer. In the style properties of the ...


3

There is a setting to choose in witch units the coordinate are displayed. Go to Project>Properties... then go to the "general" tab, here the "Coordinate and Bearing display" section lets you choose between map unit and degrees (decimal, DM or DMS) That being said if your shapefile is indeed in EPSG:4326 the map unit should be degree ...


2

So after taking into account what ThomasG77 told me to fix my QGIS, I've found that indeed creating a new profile fixes the slowdown, but I didn't want to have to create a new profile everytime it got this slow, then reinstall my plugins,etc. The problem does seem to lie with the QGIS3.ini which kept getting bigger and bigger (After creating a new profile I ...


2

I had the same issue and I had to proceed to some deleting tests in the profile's QGIS3.ini file*, I figured out that the FastVersion plugin was at the origin of the issue. I uninstalled it and it works like a charm. We talk here about QGIS Profiles (Settings > User profiles) and the file is "C:\Users\PaCha\AppData\Roaming\QGIS\QGIS3\profiles\...


2

In the Value Relation widget, the Key Column option is the column with the values that will be stored in the table, and the Value Column option is the column with the values that QGIS will show (instead of the key) in the attribute. A Key Column must have unique values to avoid your behaviour, but the child table has not a key column. The only column with ...


2

I was able to parse the expression in your code by removing the outer enclosing quotes (initialising the qry object as an empty string like qry = '') and removing the backslashes before the double quotes around the field names in the formatted string. Try with the adjusted code snippet below: InputFeatureLayer = QgsVectorLayer(r'D:\Temp\Qgis\shp\qgis.shp',&...


2

Try from .PrograssDialog import PrograssDialog


2

I found this explanation for the scale_exp function which states what the exponent does. Exponent - A positive value (greater than 0), which dictates the way input values are mapped to the output range. Large exponents will cause the output values to ‘ease in’, starting slowly before accelerating as the input values approach the domain maximum. Smaller ...


1

Here's a solution that makes use of the fact that in PostGIS running ST_Difference on two intersecting LineStrings (or MultiLineStrings) has the effect of noding the first line. So it's possible to loop over every line in the table, and difference it with the collection of lines that intersect it, to effectively node it. The noded line is computed as a ...


1

I'm still on 3.12 and Data Source Manager is working for me - but its probably because im not connecting to the same data sources as you. The 'Getting Tiles' message at the bottom suggests that you have a connection to 'something' - a Tile service? in your project... Your problem is more than likely related to a service that you previously had connected in ...


1

Try the following vectorLayers = [layer.id() for layer in QgsProject.instance().mapLayers().values() if isinstance(layer, QgsVectorLayer)] QgsProject.instance().writeEntry( "WFSLayers" , "/", vectorLayers); QgsProject.instance().write() Adapted from my previous answer Publishing a layer as WFS with PyQGIS


1

"Dissolve" is the tool you're looking for. You can also use the plugin "Dissolve with stats" if you want to calculate the sum of subspecies within a main basin for example. EDIT: you have also the "Agregate" tool


1

To change the behaviour of Identify feature tool just go in the Identify Results Tab and turn off the option "Auto open form for single feature results" as shown in the image.


1

Here is an of an example of how you could achieve your goal of allowing the user to select any number of available fields. This is how I would approach it anyway! Since you want to get user input, I am assuming you want some kind of simple GUI. You could use a few simple widgets like a QgsMapLayerComboBox, a QListWidget, a QTableWidget and a couple of ...


1

Try saving this script as "save_log.py", and then: Connect to your device via the QGIS GPS Information Panel Drag and drop the script over the qgis window Pick a destination file for the GPS log Leave it to record some points, and then disconnect the GPS from the QGIS GPS Information Panel Attach some of the lines from the saved log file. It's ...


1

Surprisingly, after @BERA's comment, this was not a computationally taxing as I thought it would have been. I used the Generate points (Pixel Centroids) inside polygons as you suggested; though it only made a list of points and with no values. I then used the Sample Raster Values to sample the DEM, using the points generated from the previous step. Made the ...


1

QGIS uses GDAL behind the scene and only exposes infos as HTML e.g iface.activeLayer().htmlMetadata(). So to get the infos, I would use the following: from osgeo import gdal layer = iface.activeLayer() dataset = gdal.Open(layer.dataProvider().dataSourceUri(), gdal.GA_ReadOnly) print(dataset.GetDriver().ShortName) print(dataset.GetDriver().LongName)


1

After some playing around, here are 2 issues that might be getting in the way. While display of an image inside QGIS using the form File widget respects relative paths (if Relative Paths is checked), I don't think an Open action does. So there instead of [%filepath%] try [%concat(@project_home || '\\', "filepath" )%]. This will prepend the project ...


1

You can achieve it using the following expression in the Field Calculator array_find( array_sort( array_agg( line_locate_point( aggregate('line','collect',$geometry), line_interpolate_point( $geometry,0.001)))), line_locate_point( aggregate('line','collect',$geometry), line_interpolate_point( $geometry,0....


1

You can do this by installing plugins. With the Deactivate Active Labels plugin, you can deactivate and activate the labels for all layers in the project or do it for a specific layer. Also, there is another plugin, Layer Tree Toggle Labels Widget, that adds a widget to activate and deactivate the labels for a specific layer. To use it, right click the layer,...


1

If you are using osgeo4w-setup-x86_64 try advanced install, from the web, it will show this in the desktop section:


1

First, create the entire process within the modeler, and include the input "File/Folder". Then open it with the inbuilt Python editor in QGIS, then edit any code with the file path to the name of the input. In my example, I have defined the folder as "folderlocation", given it a path. This is the only place you will need to change the ...


1

you need to use sub_vlayer.saveStyleToDatabase(name="name_style",description="example", useAsDefault=True, uiFileContent="")


Only top voted, non community-wiki answers of a minimum length are eligible