Japanese girls gym shorts are called Buruma. They are worn by girls at school and they allow a great deal of freedom of movement because they don't cover the legs at all. They look a lot like panties. The word comes from bloomers which were worn by American and European women in the 19th century in a few athletic activities — such as bicycle-riding and gymnastics. The bloomers of the 19th century were more baggy and knee length. Considering what they are guy's really like them, girls generally don't.
In the Ranma manga, Happosai often steals Buruma from the girl's locker room. Most of the girls in the manga are seen wearing them at one point. In the above picture Kodachi and Shampoo are seen wearing Buruma.