Sample codes for QT