ignore aspect ratio added
This commit is contained in:
parent
0ba7638e17
commit
3ac7f4c611
8 changed files with 119 additions and 74 deletions
|
@ -68,6 +68,7 @@ void ExportThread::run()
|
|||
cusExportSize.setHeight(1);
|
||||
}
|
||||
QString sizeMode = settings.value("ExportSizeMode", "Default").toString();
|
||||
Qt::AspectRatioMode aspectRatio = (Qt::AspectRatioMode)settings.value("AspectRatio", Qt::KeepAspectRatio).toInt();
|
||||
settings.endGroup();
|
||||
// End Picture Settings
|
||||
|
||||
|
@ -94,11 +95,11 @@ void ExportThread::run()
|
|||
if (sizeMode == "Desktop")
|
||||
{
|
||||
QRect desktopResolution = QApplication::desktop()->screenGeometry();
|
||||
exportPicture = exportPicture.scaled(desktopResolution.width(), desktopResolution.height(), Qt::IgnoreAspectRatio, Qt::SmoothTransformation);
|
||||
exportPicture = exportPicture.scaled(desktopResolution.width(), desktopResolution.height(), aspectRatio, Qt::SmoothTransformation);
|
||||
}
|
||||
else if (sizeMode == "Custom")
|
||||
{
|
||||
exportPicture = exportPicture.scaled(cusExportSize, Qt::IgnoreAspectRatio, Qt::SmoothTransformation);
|
||||
exportPicture = exportPicture.scaled(cusExportSize, aspectRatio, Qt::SmoothTransformation);
|
||||
}
|
||||
|
||||
bool isSaved;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue