render api for displaying formatted text