Blog

iPhone font-size adjustment

I realized that on the iPhone, fonts are sometimes rendered much bigger than on a desktop device. That concerns only some fonts or styles, so that sometimes you will end up with a broken layout. The reason for this is, that the iPhone webkit engine tries to make fonts bigger if it “thinks” the text is too small for your eyes. You can easily stop that by changing the webkit css property -webkit-text-size-adjust to none like this.

@media screen and (max-device-width: 480px){ body{ -webkit-text-size-adjust: none; } }