ui->tableSpot->horizontalHeader()->setStretchLastSection(true); 转载于:https://www.cnblogs.com/RootChu/p/9280757.html