QIcon MainWindow::qiconFromSvg(QString svg_path, QString color) { QPixmap img(svg_path); QPainter qp(&img); qp.setCompositionMode(QPainter::CompositionMode_SourceIn); qp.fillRect( img.rect(), QColor(color) ); qp.end(); return QIcon(img); } 1. 2. 3. 4. 5. 6. 7. 8. 9...