This reverts commit 6ed59187 which is no longer needed as the style context now has the state flags updated when going into draw.