Modify 'zoom in' behavior when close to an edge

If zooming in when the mouse is close to an edge ('close' meaning within
10% of the total width) then keep that same edge after zoom (as opposed
to ending up slightly inset from that edge).