fix position of diagram