Clean commands

Implement command for cleaning polygroups/polygons (doc/folder/imagedata in rightclick context menu)