Set the proper size limits

This commit is contained in:
hunbernd 2017-10-23 17:04:20 +02:00
parent f434e6559b
commit 64481de74b
8 changed files with 54 additions and 36 deletions

View file

@ -11,7 +11,7 @@ public:
ImageUtil();
static void extractImage(QWidget *window, QTextCursor cursor);
static void optimizeSize(QString &html, const QImage& original, QImage &optimized, int maxPixels = -1, int maxBytes = -1);
static bool optimizeSize(QString &html, const QImage& original, QImage &optimized, int maxPixels = -1, int maxBytes = -1);
private:
static int checkSize(QString& embeddedImage, const QImage& img, int maxBytes = -1);