handle rare case when graphics object is null
Merge branch 'master' into zipmodule