Fix nice rounding quality in two cases.

This commit is contained in:
John Preston
2026-04-24 11:38:05 +07:00
parent 3cd2246a51
commit d9649bc8d9
2 changed files with 6 additions and 1 deletions
@@ -348,6 +348,7 @@ auto GenerateNewBotThread(
const auto x = (outerWidth - icon.width()) / 2; const auto x = (outerWidth - icon.width()) / 2;
const auto y = (size - icon.height()) / 2 const auto y = (size - icon.height()) / 2
+ st::newThreadAboutIconSkip; + st::newThreadAboutIconSkip;
auto hq = PainterHighQualityEnabler(p);
p.setPen(Qt::NoPen); p.setPen(Qt::NoPen);
p.setBrush(context.st->msgServiceBgSelected()); p.setBrush(context.st->msgServiceBgSelected());
p.drawEllipse( p.drawEllipse(
@@ -1774,6 +1774,7 @@ void TopBar::paintUserpic(QPainter &p, const QRect &geometry) {
const auto size = st::infoProfileTopBarPhotoSize; const auto size = st::infoProfileTopBarPhotoSize;
const auto frame = _videoUserpicPlayer->frame(Size(size), _peer); const auto frame = _videoUserpicPlayer->frame(Size(size), _peer);
if (!frame.isNull()) { if (!frame.isNull()) {
auto hq = PainterHighQualityEnabler(p);
p.drawImage(geometry, frame); p.drawImage(geometry, frame);
update(); update();
return; return;
@@ -1818,7 +1819,10 @@ void TopBar::paintUserpic(QPainter &p, const QRect &geometry) {
_cachedUserpic = std::move(image); _cachedUserpic = std::move(image);
_cachedUserpic.setDevicePixelRatio(style::DevicePixelRatio()); _cachedUserpic.setDevicePixelRatio(style::DevicePixelRatio());
} }
{
auto hq = PainterHighQualityEnabler(p);
p.drawImage(geometry, _cachedUserpic); p.drawImage(geometry, _cachedUserpic);
}
if (_uploadOverlay && _uploadOverlay->shown()) { if (_uploadOverlay && _uploadOverlay->shown()) {
_uploadOverlay->paint(p, geometry, { _uploadOverlay->paint(p, geometry, {
.lineWidth = st::defaultUserpicButton.uploadProgressLine, .lineWidth = st::defaultUserpicButton.uploadProgressLine,