4

I would like to know if it's possible to do ArcMap style clip with QGIS. The operation I'd like to do is to clip overlapping polygon(s) in the same layer with the selected polygon.

For example: I have 2 polygons which overlap each other on the same layer. I want to clip all overlapping (unselected) polygons with the polygon I have selected in QGIS, just like in ArcMap. I also don't want the result of the clip to be written in a new shapefile but would like to edit the original shapefile (just like ArcMap). I can't seem to find this function in QGIS. There are many other ways to go around this problem, but is there any plugin etc. which would be able to perform this task with two clicks--> select polygon --> clip all other polygons with selected polygon?

Example images from ArcMap:

before

after

4

There is the Clipper plugin which I think does what you are looking for. You can download and install this from the toolbar (Plugins > Manage and Install Plugins...):

Once installed and enabled, select your polygon (yellow polygon is selected):

Polygons to be clipped

Then hit the plugin icon (highlighted by the red circle):

Polygons clipped

The polygons should be clipped and you also get a helpful reminder to save the edits in your shapefile, no new shapefiles are made.

Hope this helps!

  • Hi, thanks for the reply! This is just what I'm looking for and solves alot of my problems. Tested it and it worked on shapefiles / polygons just like I hoped. I also tested it on polygons in PostGIS DB where it did not seem to work. For some reason when I select overlapping polygon that's in PostGIS DB, click "Clipper" button --> nothing happens. I usually work with shapefiles, but this current project I'm working on has everything stored in PostGIS DB.. (and by the way, my QGIS 2.10 keeps crashing randomly when I try to save my edits to the DB) – Sisuaski Oct 22 '15 at 10:22
  • @Gifupack - Glad it works...to some extent! I haven't tested this for shapefiles stored in PostGIS but perhaps a possible workaround could be to export the shapefile from PostGIS -> load into QGIS -> do your clippings -> import back into PostGIS? – Joseph Oct 22 '15 at 10:29
  • Yep, that's propably the easiest sollution. I hope they add PostGIS support to Clipper plugin in the future.. – Sisuaski Oct 22 '15 at 10:33
  • @Gifupack - I have tested this on a polygon shapefile from PostGIS (DB Manager -> Added shapefile to canvas), used the plugin to clip over a dozen polygons at once and it seems fine. Strange, perhaps it has something to do with the size and amount of polygons being clipped...? – Joseph Oct 22 '15 at 10:45
  • I tried to create 5 new overlapping polygons in PostGIS DB and clip them after selecting one. Nothing happens.... If it works for you, then I think I need to ask our PostGIS-guy for his opinion on the matter... Maybe some PostGIS configurations are incorrect.... – Sisuaski Oct 22 '15 at 11:16
4

Is Cut Shapes Layer the tool you're looking for?. It will not edit the original shapefile but rather create a new one.

  • Hi, thanks for your reply. I'm looking for a tool that edits the original shapefile. I have file that has more than 5000 polygons, and about 200 of them overlaps just abit. These overlaps need to be looked through manually and clipped by one of the overlapping polygons, depending on which is correct. I'd like to be able to select a polygon and click "clip all polygons that overlap". Clip function would need to edit the shape of overlapping polygons to be in line with the selected polygon. I do not want a new shape to be created. – Sisuaski Oct 22 '15 at 8:28
  • Furthermore it would be great, if there was a popup warning, if a feature would be entirely deleted while clipping. If at least a part of the original feature remained after clipping, no warning would be nessessary. But this is just a thought of functionality I'd like to have, not required. – Sisuaski Oct 22 '15 at 8:29

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.