Permit modes to enhance the text editor by adding its own typographical effects to the Painter.

This permits Python mode to draw an indentation indicator, which is common in Python editors.