Use ye olde -lockFocus/-unlockFocus, the delayed drawing causes some issues particular with button images