QML获取随机颜色时间:2023-03-09 15:32:33 rect.color = Qt.rgba(Math.random(), Math.random(), Math.random(), );//random返回0~1的随机数