Cut vertical lines first, than horizontal ones

This recent topic seems closely related: