Re: [Qgis-user] Looking for QGIS Python code for a three-level menu?

2024-05-12 Thread Raymond Nijssen via QGIS-User

Wow, this is so much more logical!

If this works, then why do we (still) have the addPluginToMenu() available?

Raymond



On 12-05-2024 22:26, Jürgen E. Fischer via QGIS-User wrote:

Hi Mike,

On Sun, 12. May 2024 at 17:35:14 +, Elstermann, Mike via QGIS-User wrote:

I'm looking for a piece of QGIS Python code for a three-level menu, something 
like this:

Plugins
|
|
MyMenu > -+-- Submenu 1 >  SubSubMenu 1.1
|  |   +--- SubSubMenu 1.2
|  |   +--- SubSubMenu 1.3
Other...  |
   +-- Submenu 2 >  SubSubMenu 2.1
   |   +--- SubSubMenu 2.2
   |   +--- SubSubMenu 2.3
   |   +--- SubSubMenu 2.4
   |
   +-- Submenu 3 >  SubSubMenu 3.1
   +--- SubSubMenu 3.2


m0 = iface.pluginMenu().addMenu("MyMenu")
m1 = m0.addMenu("SubMenu 1")
m1.addMenu("SubSubMenu 1.1")
m1.addMenu("SubSubMenu 1.2")
m1.addMenu("SubSubMenu 1.3")
m1 = m0.addMenu("SubMenu 2")
m1.addMenu("SubSubMenu 2.1")
m1.addMenu("SubSubMenu 2.2")
m1.addMenu("SubSubMenu 2.3")
m1 = m0.addMenu("SubMenu 3")
m1.addMenu("SubSubMenu 3.1")
m1.addMenu("SubSubMenu 3.2")

Jürgen


___
QGIS-User mailing list
QGIS-User@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user

___
QGIS-User mailing list
QGIS-User@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] Looking for QGIS Python code for a three-level menu?

2024-05-12 Thread Raymond Nijssen via QGIS-User

Hi Mike,

I'm afraid you cannot add submenus to the plugin menu.


The addPluginToMenu function only takes actions as an argument:


action_1 = QAction('Action 1')
iface.addPluginToMenu('Plugin 1', action_1)

menu_1 = QMenu('Menu 1')
iface.addPluginToMenu('Plugin 1', menu_1)




The last line causes this error:

TypeError: QgisInterface.addPluginToMenu(): argument 2 has unexpected 
type 'QMenu'





Also see the docs:

https://qgis.org/pyqgis/master/gui/QgisInterface.html#qgis.gui.QgisInterface.addPluginToMenu



There might be a tricky way to get the QMenu of the main QGIS window and 
somehow add things in a Qt way.



Kind regards,
Raymond



On 12-05-2024 19:35, Elstermann, Mike via QGIS-User wrote:

Hello everyone,

I'm looking for a piece of QGIS Python code for a three-level menu, 
something like this:


Plugins
    |
    |
MyMenu > -+-- Submenu 1 >  SubSubMenu 1.1
    |      |               +--- SubSubMenu 1.2
    |      |               +--- SubSubMenu 1.3
Other...  |
           +-- Submenu 2 >  SubSubMenu 2.1
           |               +--- SubSubMenu 2.2
           |               +--- SubSubMenu 2.3
           |               +--- SubSubMenu 2.4
           |
           +-- Submenu 3 >  SubSubMenu 3.1
                           +--- SubSubMenu 3.2
  Can anyone help with a code snippet?
  Thanks & best regards, mikeE.

___
QGIS-User mailing list
QGIS-User@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user

___
QGIS-User mailing list
QGIS-User@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] web based spatial MIS/Dashboard

2024-04-22 Thread Raymond Nijssen via QGIS-User

Hi Janneke,

Recently, I've been playing around with Apache Superset which I think 
can do what you are looking for and looks very promising!


https://superset.apache.org/

Kind regards,
Raymond


On 22-04-2024 12:33, Janneke van Dijk via QGIS-User wrote:

Dear QGIS developers and users,

In my work as a freelance GIS consultant I work with QGIS as much as 
possible and try to convince clients that it will address all their GIS 
needs despite not having to pay a license fee for it (and no, it is not 
user unfriendly).


More and more, in addition to wanting 'a GIS system', there are requests 
for a web based management information system which shows both maps and 
a dashboard with selected KPIs, and where selecting a feature on the map 
will update the graphs and charts in the dashboard. So far, I have not 
been able to find out if this is possible using Open Source software, 
what it would require in terms of setting it up/configuring/additional 
development. I assume it is technically possible to develop it.


Does anyone have experience with this? How did you set it up? Any 
examples I could have a look at? I guess strictly speaking it is not a 
QGIS question, but seeing that some other proprietary GIS software 
vendors are offering web dashboard functionality 'out of the box' it 
does get associated with the GIS software procured.


Is there a demand for it (from my limited view - yes)? Are there 
thoughts about developing such functionality more 'out of the box' 
within the QGIS community? What would such development require? My 
impression is that there is more (very tentative) willingness from 
donors to consider contributing to Open Source software development as 
part of development projects, but it may mean that it would need to be 
written into tender proposals with indicative figures for the required 
funding.


I have a limited understanding of what is out there (I've just dabbled 
(so far unsuccesfully) with chartbrew and grafana the past few days to 
see how dashboard creation works) so I am not sure what are the right 
questions to ask. I realise my questions are still rather broad. I have 
some time at hand so I would be available to do more research and become 
more specific if there is an interest in this topic.


Looking forward to your ideas!
Janneke

___
QGIS-User mailing list
QGIS-User@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user

___
QGIS-User mailing list
QGIS-User@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] Determining the Name of the Current Style File of a QGIS layer

2024-04-12 Thread Raymond Nijssen via QGIS-User

Hi Bill,

Didn't do any inverstigation, but I'm pretty sure that only the layer 
style gets set by the .qml, but the .qml file name doesn't get stored 
anywhere on the layer. So the QGIS project or layer is not aware of the 
.qml anymore. If you change the .qml you will not see anything changing 
in your layer style when reopening your project.


Kind regards,
Raymond

On 12-04-2024 08:23, Bill Casey via QGIS-User wrote:
After I have applied style elements such as colour, label font and 
placement to a QGIS layer, I can of course save the style to a .qml 
file.  I ofter have different .qml files with different style elements 
for displaying the same layer data in different projects.  Subsequently 
I might wish to know the name of the .qml file which I had applied to 
that layer. in that project


I know I can copy and paste the style, but I want to know the actual 
name of the .qml file which currently defines the style.


Where should I look?


___
QGIS-User mailing list
QGIS-User@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user

___
QGIS-User mailing list
QGIS-User@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] QGIS Open Day 28 March 2024

2024-03-27 Thread Raymond Nijssen via QGIS-User

Hi Amy,

Will this be Thursday 28 or Friday 29 ?
(Friday 28 will not happen this month.)

Kind regards,
Raymond


On 27-03-2024 11:06, Amy Ternent via QGIS-User wrote:


Dear QGIS Users

On Friday, 28 March 2024 we will be holding our year-eand festive QGIS 
Open Day! What is a QGIS Open Day you may be wondering to yourself? It 
is an initiative to replace the wonderful community meetups we used to 
hold every six months when times were different. Like our in-person 
meetings, the event is organised on the principle of self-organisation 
and community participation.


*Programme*

  * Session 1: WAPlugin: Optimizing FAO WaPOR Data for Land and Water
Productivity Monitoring in QGIS, YouTube Link
, Jitsi link

  * Session 2: How to visualize Digital Surface Model using QGIS and
Blender,YouTube Link
, Jitsi link

  * Session 3: Building QGIS Plugins,YouTube Link
, Jitsi link


*Where to watch*

Please see the event wiki page at QOD-March-2024 Wiki 
 for all the details 
of times and links for participation.



  Recordings

All the events are recorded and made available to users who couldn't 
make the live events. Youtube live streams are automatically available 
for catch-up viewing. Reviewing video links for individual events should 
work without a hitch, but you can also catch up on recordings from the 
QGIS Youtube channel:


  * https://www.youtube.com/@qgishome 


  Code of Conduct

Participants are kindly reminded to please read and observe our QGIS 
Code of Conduct and Diversity Statement to make these events a great 
experience for everyone!


  * Code of Conduct


  * Diversity Statement



Please contact the Lead QOD Event Organiser, Amy by email 
a...@kartoza.com , or via the Telegram Channel 
 username @Amz if you have 
any queries or need help setting up events.


We look forward to seeing you there! 



--

Amy Ternent
GIS Technician
Visit http://kartoza.com  to find out about open source:
* Desktop GIS programming services
* Geospatial web development
* GIS Training
* Consulting Services
Office: +27(0)71 225 0039

___
QGIS-User mailing list
QGIS-User@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user

___
QGIS-User mailing list
QGIS-User@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] Hillshade default direction

2024-01-23 Thread Raymond Nijssen via QGIS-User



Hi David,

On 23-01-2024 06:39, David Strip via QGIS-User wrote:
After a lifetime of NW hillshades, my eye reverses hills and valleys 
when I shift the sun.


This is not caused by looking at NW hillshades, but by looking at real 
life objects where light normally comes from above. This is what your 
brain is expecting and therefore it generates a 3D "bump map" for you 
that way.


And that's why a GIS uses a sun position from the top of the map, often 
north.


(Turning your SW map upside down should fix the problem.)

Raymond
___
QGIS-User mailing list
QGIS-User@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] Cannot save

2023-11-30 Thread Raymond Nijssen via QGIS-User
Just guessing.. You're trying to export your layer and when you chose a 
file name you just typed it into the edit widget and did not choose the 
[...] button next to it to open file browser. Now QGIS will attempt to 
save your gpkg file in the installation folder or some other directory 
where you don't have write access.


Could that be?


On 30-11-2023 08:00, Pekka Sarkola via QGIS-User wrote:

Hi!

It seems that you are trying to convert vector data to geopackage. What 
tool are you using?


Rgs,

Pekka

Pekka Sarkola
Gispo Oy
pekka.sark...@gispo.fi    - GSM +358 
40 725 2042
www.gispo.fi – www.paikkatieto.com 





ke 29. marrask. 2023 klo 12.22 Ilkka Haapalinna via QGIS-User 
(qgis-user@lists.osgeo.org ) kirjoitti:


Hi
What is the problem as I cannot save.
I have version 3.28.13 Firenze.
When trying to save this is what I get in the attachment.
Please advice
Ilkka
___
QGIS-User mailing list
QGIS-User@lists.osgeo.org 
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user

Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user



___
QGIS-User mailing list
QGIS-User@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user

___
QGIS-User mailing list
QGIS-User@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] Readonly geometries

2023-10-27 Thread Raymond Nijssen via QGIS-User
Haven't tried, but maybe 1:1 joining a second table to your layer and 
editing that table might work?


Raymond

On 23-10-2023 20:58, Simon Gröchenig via QGIS-User wrote:

Hi list,
is it possible to set geometries to readonly while attributes are editable?
Simon

___
QGIS-User mailing list
QGIS-User@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user

___
QGIS-User mailing list
QGIS-User@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] How to permanently enable a plugin?

2023-04-07 Thread Raymond Nijssen via QGIS-User

Hi Adam,

Normally it should work as you wish for.

Once I had a customer with this problem. They were using Citrix and the 
user home directory (where plugins are stored) was either cleared at 
every startup, or the server where QGIS was running was a different 
every time. Could that be the problem?


Hope this helps,
Raymond


On 07-04-2023 13:36, Adam Nielsen via QGIS-User wrote:

Hi all,

Every time I load QGIS, I have to go to the Plugins menu, choose
"Manage and Install Plugins", then go to the "Installed" section and
tick the plugins that I want to use, in order for them to become
available in the menu and on the toolbar.

Is there a way to permanently have them ticked, like the system plugins
are, so that I don't have to go in and re-enable them every time I load
QGIS?

Thanks,
Adam.

QGIS version: 3.30.0-'s-Hertogenbosch
Qt version: 5.15.8
Python version: 3.10.10
___
QGIS-User mailing list
QGIS-User@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user

___
QGIS-User mailing list
QGIS-User@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


[Qgis-user] International QGIS User Conference & Contributor Meeting 2023

2023-02-02 Thread Raymond Nijssen via QGIS-User

Dear users and developers,

After waiting for 3 years we are happy to announce that the conference 
website is live:


https://uc2023.qgis.nl/

More details will follow soon, but for now please register and propose 
your talks and/or workshops.


And especially for those who'd like to attend the Contributor Meeting, 
please book your stay early cause hotels are mentioning not having too 
many free rooms.


We hope to see you all in The Netherlands soon!

Kind regards,
Raymond
___
QGIS-User mailing list
QGIS-User@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] CSV layer, Time column null expressie to test for NULL/empty?

2023-01-19 Thread Raymond Nijssen via QGIS-User

Or:

coalesce(field, '') in ('', ' ', 'NULL')

Raymond


On 19-01-2023 09:53, kirk via QGIS-User wrote:

You can also use
CASE
When field is null then 123
else 321
end

Kirk Schmidt



Sent from my Galaxy


 Original message 
From: Richard Duivenvoorde via QGIS-User 
Date: 2023-01-18 1:44 p.m. (GMT-04:00)
To: qgis-user@lists.osgeo.org
Subject: Re: [Qgis-user] CSV layer, Time column null expressie to test 
for NULL/empty?


Pff, ok found a solution:

"bezoek.begintijd" IS NULL

works

So if I want to test for empty strings, or NULL (like strings), AND real 
NULLS, I use now:


( "bezoek.begintijd" IS NULL   OR   "bezoek.begintijd"  in ('', ' ', 
'NULL') )


Regards,

Richard Duivenvoorde

On 1/18/23 18:31, Richard Duivenvoorde via QGIS-User wrote:
 > We have csv data, which is loaded as layer via the Delimited Text 
Layer provider.

 >
 > The data contains both a date and a time column, which we have to 
format as isodatetime using an QGIS Expression.

 >
 > BUT sometimes time column is empty/no value (in which case we have to 
format it as isoTIME only).

 >
 > So we have to check IF the time column is empty, then only format the 
Date, else use Date AND Time.

 >
 > My problem is that I fail to create an expression for the test IF the 
column (see screenshot) is empty.

 >
 > I thought to use (our column is called "bezoek.begintijd"):
 >
 > "bezoek.begintijd"  in ('', ' ', NULL)
 >
 > BUT this does NOT return True or False, but NULL !!
 >
 > But:
 >
 >
 > ("bezoek.begintijd"  in ('', ' ', NULL)) = NULL
 > does ALSO NOT resolve to True... (also NULL)
 >
 > When the record has no data (the csv holds no data for that record), 
it shows

 > 
 > if it has data:
 > 
 >
 > Anybody an idea what test I can use to test if the time column (which 
is typed as Time) is empty/null/none?

 >
 > Thanks for any pointers.
 >
 > Regards,
 >
 > Richard Duivenvoorde
 >
 > ___
 > QGIS-User mailing list
 > QGIS-User@lists.osgeo.org
 > List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
 > Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user

___
QGIS-User mailing list
QGIS-User@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user

___
QGIS-User mailing list
QGIS-User@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user

___
QGIS-User mailing list
QGIS-User@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] The license agreement of QGIS

2022-12-07 Thread Raymond Nijssen via QGIS-User

Yes, all free! Use as much QGIS as you like!

However, if you are happy QGIS users and your organization is relying on 
the software, consider becoming a sustaining member. That way you can 
support the project, software development, bug fixing, upgrades and so on.


More info over here:

https://qgis.org/en/site/getinvolved/governance/sustaining_members/sustaining_members.html#sustaining-membership

No necessity, but very much appreciated!

Kind regards and enjoy using QGIS,
Raymond

On 08-12-2022 04:28, Brent Wood via QGIS-User wrote:

The full licence is described here:
https://docs.qgis.org/3.22/en/docs/user_manual/appendices/GNU_GPL.html 



Essentially it means you can install and use QGIS anywhere you want for 
whatever the cost of downloading it might be (usually free). You can be 
an individual, government agency, commercial business, etc., that 
doesn't matter.


Note that if you do change the source code to provide some functionality 
that you require, the licence requires you to make your enhancements 
available under the same licence.


Cheers,

Brent Wood


*From:* QGIS-User  on behalf of Paco 
Lui via QGIS-User 

*Sent:* Thursday, December 8, 2022 16:01
*To:* qgis-user@lists.osgeo.org 
*Subject:* [Qgis-user] The license agreement of QGIS
Dear sir/madam,

I , on behalf of, Hong Kong Government, to ask some question about the 
license agreement for QGIS, our Division want to install the QGIS 
software for work purpose and I want to ask that need our division buys 
a license or it is free? thanks.


Best Regards,
Mr. Paco Lui
System Analyst1/TECH
Survey Division, Highways Department, Hong Kong Government
  Brent Wood
Principal Technician - GIS and Spatial Data Management
Programme Leader - Environmental Information Delivery
+64-4-386-0529

National Institute of Water & Atmospheric Research Ltd (NIWA)
301 Evans Bay Parade Hataitai Wellington New Zealand
*Connect with NIWA:* niwa.co.nz  Facebook 
 LinkedIn 
 Twitter 
 Instagram 



To ensure compliance with legal requirements and to maintain cyber 
security standards, NIWA's IT systems are subject to ongoing monitoring, 
activity logging and auditing. This monitoring and auditing service may 
be provided by third parties. Such third parties can access information 
transmitted to, processed by and stored on NIWA's IT systems


___
QGIS-User mailing list
QGIS-User@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user

___
QGIS-User mailing list
QGIS-User@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] Faster Intersects

2022-09-09 Thread Raymond Nijssen via Qgis-user

Great! \o/


On 09-09-2022 19:25, Dennis Burgess wrote:
That did it!!!  I was unware that GeoPackage’s are SUPER fast and that I 
could SAVE a CSV as a GeoPackage file. . There is no metho to create 
indexes though once I do this, but now it runs in about 2 min!  lol


*LTI-Full_175px*

*Dennis Burgess*

*
*Author of "Learn RouterOS- Second Edition”

*Link Technologies, Inc*-- Mikrotik & WISP Support Services

*Office*: 314-735-0270  Website: http://www.linktechs.net 
<http://www.linktechs.net/>


Create Wireless Coverage’s with www.towercoverage.com 



Need MikroTik Cloud Management: https://cloud.linktechs.net 
<https://cloud.linktechs.net>


*From:* Alexandre Neto 
*Sent:* Friday, September 9, 2022 12:20 PM
*To:* Dennis Burgess 
*Cc:* Raymond Nijssen ; QGIS User 


*Subject:* Re: [Qgis-user] Faster Intersects

Following raymond advice,

Move the CSV to a shapefile or geopackage and run the create spatial 
index on it.


If you have very complex polygons, use suvdivide to create smaller ones 
save it in shapefile or geopackage and run create spatial index on it.


https://docs.qgis.org/3.22/en/docs/user_manual/processing_algs/qgis/vectorgeometry.html#subdivide 
<https://docs.qgis.org/3.22/en/docs/user_manual/processing_algs/qgis/vectorgeometry.html#subdivide>


I would try with a smaller subset of points to test the improvement 
speed before trying to run on the full dataset again.


Answering your question, yes I am pretty sure postgis is much faster 
than mssql, and yes I think most recent versions of PostgreSQL PostGIS 
make use of more than one core.


Good luck

A sexta, 9/09/2022, 17:59, Dennis Burgess via Qgis-user 
mailto:qgis-user@lists.osgeo.org>> escreveu:


In the format, are you talking about the shape or the CSV with
2million lines?



Dennis Burgess

Author of "Learn RouterOS- Second Edition”
Link Technologies, Inc -- Mikrotik & WISP Support Services
Office: 314-735-0270  Website: http://www.linktechs.net
<http://www.linktechs.net>
Create Wireless Coverage’s with www.towercoverage.com
<http://www.towercoverage.com>
Need MikroTik Cloud Management: https://cloud.linktechs.net
<https://cloud.linktechs.net>

-Original Message-
From: Qgis-user mailto:qgis-user-boun...@lists.osgeo.org>> On Behalf Of Raymond
Nijssen via Qgis-user
Sent: Friday, September 9, 2022 11:11 AM
To: qgis-user@lists.osgeo.org <mailto:qgis-user@lists.osgeo.org>
Subject: Re: [Qgis-user] Faster Intersects

Some things to check:

* Is your data local?
* Is it in a fast file format? (for example .gpkg or .shp and not
.csv or .geojson)
* Does the data have a spatial index?
* Is the geometry very complicated, like a huge multi polygon with
thousands of vertices and islands? In that case, split it up in
several polygons.

Hope this helps. Anyway, it should not need to take this long.

Raymond



On 09-09-2022 16:28, Dennis Burgess via Qgis-user wrote:
 > How can I speed up Intersects?  Right now I have a single geometry
 > file, but then have about 2 million points that I need to understand
 > what intersects that geometry.  Right now its taking 3 days?
 > QGIS-bin.exe is only using 11% CPU.. ☹
 >
 > Dennis
 >
 >
 > ___
 > Qgis-user mailing list
 > Qgis-user@lists.osgeo.org <mailto:Qgis-user@lists.osgeo.org>
 > List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
<https://lists.osgeo.org/mailman/listinfo/qgis-user>
 > Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user
<https://lists.osgeo.org/mailman/listinfo/qgis-user>
___
Qgis-user mailing list
Qgis-user@lists.osgeo.org <mailto:Qgis-user@lists.osgeo.org>
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
<https://lists.osgeo.org/mailman/listinfo/qgis-user>
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user
<https://lists.osgeo.org/mailman/listinfo/qgis-user>
___
Qgis-user mailing list
Qgis-user@lists.osgeo.org <mailto:Qgis-user@lists.osgeo.org>
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
<https://lists.osgeo.org/mailman/listinfo/qgis-user>
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user
<https://lists.osgeo.org/mailman/listinfo/qgis-user>


___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] Faster Intersects

2022-09-09 Thread Raymond Nijssen via Qgis-user

Some things to check:

* Is your data local?
* Is it in a fast file format? (for example .gpkg or .shp and not .csv 
or .geojson)

* Does the data have a spatial index?
* Is the geometry very complicated, like a huge multi polygon with 
thousands of vertices and islands? In that case, split it up in several 
polygons.


Hope this helps. Anyway, it should not need to take this long.

Raymond



On 09-09-2022 16:28, Dennis Burgess via Qgis-user wrote:
How can I speed up Intersects?  Right now I have a single geometry file, 
but then have about 2 million points that I need to understand what 
intersects that geometry.  Right now its taking 3 days?  QGIS-bin.exe is 
only using 11% CPU.. ☹


Dennis


___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user

___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] NULL in attribute table

2022-07-06 Thread Raymond Nijssen via Qgis-user

Hi Dario,

In an expression you can use the coalesce() function:

coalesce("field", 'alternative value')

Raymond

On 06-07-2022 18:15, Dario C via Qgis-user wrote:

Hi there,
I'm using an attribute table on my layout. For all the field without any 
value I have NULL. Is there any way to add an expression like (when 
FIELD is NULL Then ' ') ?

Thank you

regards,
Dario

___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user

___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] shp file vs vector laag

2022-05-25 Thread Raymond Nijssen via Qgis-user

Hoi Theo,

Dit is een internationaal kanaal waar in het Engels wordt gecommuniceerd.

Groet,
Raymond

On 25-05-2022 13:40, Theo Stevens via Qgis-user wrote:


Beste,

Ik ben pas sinds maart 2022 een gebruiker van Qgisp en probeer nu mijn 
gegevens via Qgis2web om te zetten om op het net te plaatsen.
Telkens lukt het niet shp-files blijven zichtbaar maar een 
vectorlaag: CartoWeb-TOPO 
en URLhttps://cartoweb.wms.ngi.be/service?version=1.3.0 
 komt niet zichtbaar 
in beeld.

Zie bijlage ham een oostham.

Wat doe ik fout of moet de vector laag een shp file worden.

Vriendelijke groeten

Theo Stevens

Heemkunde Ham


___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user

___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] quit() and exit()

2022-05-02 Thread Raymond Nijssen via Qgis-user

Put your code in a main() function and use return to leave the function?


On 02-05-2022 18:06, Stephen Sacks via Qgis-user wrote:
I would like to terminate a Python script gracefully.  Both quit() and 
exit() not only abort the script but end the entire QGIS app.  For 
example, if a file I want to read doesn't exist, the following four 
lines of code terminate QGIS:


filePath = Path(fName)
if not filePath.is_file():
     print ('Unable to find file  ', fName)
     exit()

Substituting  quit() for exit()  doesn't help.  I could omit both, and 
put all of the remaining code under an "else" but that seems rather clunky.

   Any suggestions would be welcome.



___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user

___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] Classify road network into dead-end links and links connected on both ends

2022-05-02 Thread Raymond Nijssen via Qgis-user

Hi Roland,

You could either go making SQL queries (using st_startpoint() and 
st_endpoint() et cetera) or have a look at the "Networks" plugin which 
has a lot of this kind of functionality.


https://plugins.qgis.org/plugins/networks/

And there are several other network and topology related plugins.

Hope this helps,
Raymond


On 02-05-2022 10:35, Roland Spielhofer via Qgis-user wrote:

Hi,
I have a road network (Shape linestring) where I would like to classify 
all links that are dead-end and compute the share of the dead-end links 
in relation to the total network length.
I am pretty sure this is possible in QGIS or a plugin - any pointers 
would be appreciated.

Regards,
Roland

___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user

___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] create PostGIS view from QGis layer

2022-04-28 Thread Raymond Nijssen via Qgis-user

Hi Gert-Jan,

Not sure how exactly you are filtering your data, but to create views 
you can run these queries on your PostgreSQL database using the tool you 
like (for example DB-manager in QGIS, or DBeaver or PGAdmin).



In case this is an SQL query filter:

CREATE VIEW blabla1 AS
[your sql select query goes here]


In case it's a 'provider object filter' (in the Source tab of your layer 
properties):


CREATE VIEW view_name AS
SELECT * FROM table_name WHERE
[your filter goes here]


Hope this helps,
Raymond



On 28-04-2022 14:09, gisnederland via Qgis-user wrote:

Hi all,

I've got a QGis (3.20) project with (amongst others) 15 layers that all 
point to 1 postgis table, but all have a different filter applied (in 
QGis).


I'm looking for a convenient way to convert these layers-with-filter to 
views in PostGIS, in which the SQL "select"-statement matches the QGis 
filter expression.

Any way to do this in QGis, or with other tooling?


Kind regards,

Gert-Jan
___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user

___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] Change properties of multiple layer at once

2022-04-01 Thread Raymond Nijssen via Qgis-user
Don't know how to do that using the GUI, but for the opacity you can use 
these 2 lines of python in the QGIS python console. It will set all your 
selected layers to 50% opacity.



for layer in iface.layerTreeView().selectedLayers():
layer.setOpacity(.5)


I think the stroke style is harder to change because all these layers 
can have different symbologies.


Hope it helps!
Raymond


On 01-04-2022 09:47, Roland Spielhofer via Qgis-user wrote:

Hi,
I have a set of similar layers where I would like to change certain 
properties for all layers in the same way.

* change opacity to 50%
* change stroke style to "no pen"
When I select multiple layers and open properties -> symbology, I just 
change the styling of the first layer, not for all.

Is there a way to do this?
Regards,
Roland

___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user

___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user