Those fancy pants with the short legs that you see people wearing? Those are fencing pants, or knickers as they are properly called.
These are required for USFA tournaments.
Knickers are protective equipment for the legs and pelvis, extending to approximately the natural waist (belly button), to be sure that they are covered entirely by the jacket, even when reaching up with the arms, and extending to just below the knees. They, almost entirely, will have suspenders, a zipper front, and some sort of waist closure, velcro being the most common.
Like the other protective gear, the material is specifically puncture resistant, made to stop penetration and stop any hits from harming the fencer. They won't stop bruising, and getting slapped by a blade will still sting, but they will provide much more protection than normal workout clothes.
When buying knickers, you will be asked which hand you fence with. This is because the zipper opening on the pants must face AWAY from your opponent so that a wayward attack cannot go through the zipper area.
There are a broad variety of styles and materials used, the same as for jackets. Heavy duck canvas and nylons in all kinds of stretchiness, thickness, and weights. Almost all manufacturers make their uniforms with "models or styles" and they will have matching types for the jackets and knickers. Most fencers find the material type they like and then just buy the two matching pieces from the line of production. It is by no means necessary to go with matching equipment, however, and mix and match is perfectly acceptible.
When wearing knickers, it is a very good idea to wear knee height socks as well, and in tournaments they are required safety gear. As long as they don't have anything vulgar or offensive, there are no restrictions on color or pattern for socks. You can purchase "fencing socks" from all the vendors, they are generally a very heavy weight sock that does provide a little more protection. You may also use any sport sock, such as soccer socks, which work just as well, so long as they cover all the way to the knee, extending high enough to be fully covered at the knee by the knicker pant leg so that no skin is visible while fencing.