目录
一、时间类QTime
1、QTime 的创建和初始化
QTime time1(23, 59, 59);
qDebug() << time1; //QTime("23:59:59.000")
QTime time2 = QTime::currentTime();
qDebug() << time2; //QTime("00:34:39.752")
2、QTime 的计算
QTime time1 = QTime::currentTime();
int h = time1.hour();
int m = time1.minute();
int s = time1.second();
int ms = time1.msec();
qDebug() << h <<":" << m << ":" << s << "." <<