ensure width and height settings are respected