Why isn't my <select> "font-family" property inheriting from <body>?

Sabya picture Sabya · Jan 5, 2009 · Viewed 44k times · Source

My code:

Why is the first <select> element not inheriting the font-family property from the specification for <body>?

If I have to change the font for a <select> why do I have to copy the style?

Answer

James B picture James B · Jan 5, 2009

If you use:

select {
  font-family: inherit;
}

It'll work fine. CSS is a little quirky when it comes to form controls.