Preview: fix glitchy PlantUML preview when no background is specified

This commit is contained in:
Le Tan 2018-11-25 11:19:41 +08:00
parent 313a8647a8
commit f9e9735d5f

View File

@ -1748,7 +1748,10 @@ QPixmap VUtils::svgToPixmap(const QByteArray &p_content,
}
QPixmap pm(deSz);
if (!p_background.isEmpty()) {
if (p_background.isEmpty()) {
// Fill a transparent background to avoid glitchy preview.
pm.fill(QColor(255, 255, 255, 0));
} else {
pm.fill(p_background);
}