widget py3k compatibility