With Shimano (except for older Dura-Ace and 2010 MTB derailleurs) the cable pull is the same across the line. So you can use say a 9sp rear derailleur with 10sp shifters and it will index correctly. You can also use a "triple" rear derailleur, or a mountain bike one, on your 10sp road bike. They'll all index the same. That's handy for running extremely low gearing.
The newer 10sp road stuff (7900/6700) has slightly different cages so it can handle a bit more chain wrap. But it indexes the same as the other modern road derailleurs.
Front derailleurs also use the same cable pull, but the cage width varies with the chain width. 10sp chains are narrower across the side plates than 9sp, so a 10sp front derailleur is slightly narrower than a 9sp one. It'll work on a 9sp system, you'll just be trimming more often.
9sp and 10sp chain rollers are the same width, it's just the side plates that are narrower on the 10sp. 7 and 8 speed chains are wider. They might not fit in the cage of a 10sp derailleur.