Which of the following can be directly measured using a ruler?

A. Distance between the earth and the moon
B. Distance between two cities
C. Width of a window frame
D. Height of a mountain