With the `insertPos` in pixel coordinates, the grid-snapping code below no longer works.