Added Qt5 support, contributed by John Buonagurio <jbuonagurio@exponent.com>.