The tightest part of shorts legs is the bottom edges, where the elastic is. Elastic seeks the place of least resistance.
Most of our thighs are thickest and hardest muscle in the middle section of them, getting smaller circumference again towards the knee and towards the crotch.
If you wear shorts that end BELOW where your widest thigh part is, they will not ride up to the wider harder thigh muscle area. If the shorts end at the thickest hardest part of your thigh, the elastic will be tight and seek a smaller or softer circumf.- your crotch area.
So, if you have trouble with shorts riding up your leg to your crotch, try longer shorts. Needless to say, capris will NOT ride up into your crotch!
Terry makes longer shorts that I really like- they land about 3" above my knees and they stay put. They also are not TIGHT at the legband.