fixing the handling of locations ofor external pictures