diagram rotation correction