Fixes for example qt programs for python 3