- fix --stretch mode, we need to make sure the background texture matches the screen size, so when we composite the foreground in the drawForeground() we fil the screen
This commit is contained in:
@@ -191,7 +191,10 @@ void MainWindow::setAspect(char aspectIn)
|
||||
|
||||
QPixmap MainWindow::getBlurredBackground(const QPixmap& originalSize, const QPixmap& scaled)
|
||||
{
|
||||
if (scaled.width() < width()) {
|
||||
if (fitAspectAxisToWindow) {
|
||||
// our scaled version will just fill the whole screen, us it directly
|
||||
return scaled.copy();
|
||||
} else if (scaled.width() < width()) {
|
||||
QPixmap background = blur(originalSize.scaledToWidth(width(), Qt::SmoothTransformation));
|
||||
QRect rect(0, (background.height() - height())/2, width(), height());
|
||||
return background.copy(rect);
|
||||
|
||||
Reference in New Issue
Block a user