Geometric tools and methods in the study of switching systems