[#78] fix a bug when matplotlib qt4 backend is not available