Add callback to scale the background properly on resize.

Fixes #1.