separate grid drawing functions