Improved custom block renderer.

Minor tweaks of color helpers.