14.18: Export As for PNG, JPEG and PDF, sized, over a checkerboard

This commit is contained in:
ZacharyZhang-NY committed 2026-10-11 09:10:51 -04:00
1 parent e6b7f043bb
commit 9be01073df
26 files changed
+1352 -688

No files matched your search

+3 -3
View File
@@ -2,7 +2,7 @@
#include "Rendering/AdjustmentSurface.h"
#include "Rendering/EditorCanvas.h"
#include "RenderFixtures.h"
#include "UI/JPEGExportSheet.h"
#include "UI/ExportAsSheet.h"
#include "UI/LevelsSheet.h"
#include <QScrollBar>
#include <QtTest>
@@ -178,8 +178,8 @@ void HighDpiCanvasTests::theJPEGPreviewCountsDevicePixels()
for (int y = 0; y < 800; ++y)
for (int x = 0; x < 1200; ++x)
image.setPixelColor(x, y, QColor((x * 7 + y) % 256, (x + y * 3) % 256, (x * y) % 256));
JPEGPreview preview(QSize(1200, 800), [] {}, nullptr);
preview.setImage(image, false);
JPEGPreview preview([] {}, nullptr);
preview.setImage(image, QSize(1200, 800), false);
preview.show();
QVERIFY(QTest::qWaitForWindowExposed(&preview));
// 600 by 400 points: Fit 0.825, averaged per device pixel.