adding concept of RenderState trait