Fix rendering of text layers