Now fit the selection with a 1.4x margin (matching 3d view). Also move border fitting into own function.