Twips-conversion fixes in Transform and MouseEvent

Fixes #681