edit mirrors of aqt

This commit is contained in:
Martin Rotter 2023-12-07 15:13:28 +01:00
parent 8c4d9bdf1b
commit 828ac562cb
2 changed files with 10 additions and 5 deletions

View File

@ -5,12 +5,13 @@ baseurl: https://mirror.netcologne.de/qtproject
[mirrors]
trusted_mirrors:
https://download.qt.io
https://mirrors.ocf.berkeley.edu/qt
https://ftp.jaist.ac.jp/pub/qtproject
http://ftp1.nluug.nl/languages/qt
https://mirrors.dotsrc.org/qtproject
blacklist:
http://mirrors.ustc.edu.cn
http://mirrors.tuna.tsinghua.edu.cn
http://mirrors.geekpie.club
fallbacks:
https://mirrors.ocf.berkeley.edu/qt
https://ftp.jaist.ac.jp/pub/qtproject
http://ftp1.nluug.nl/languages/qt
https://mirrors.dotsrc.org/qtproject

View File

@ -328,7 +328,10 @@ QString WebFactory::limitSizeOfHtmlImages(const QString& html, int desired_width
}
}
else {
// No dimensions given or just height.
// No dimensions given.
// In this case we simply rely on original image dimensions
// if no specific limit is set.
// Too wide images will get downscaled.
if (desired_max_height > 0) {
attrs.insert("height", QString::number(desired_max_height));
}
@ -337,6 +340,7 @@ QString WebFactory::limitSizeOfHtmlImages(const QString& html, int desired_width
else {
attrs.remove("width");
attrs.remove("height");
if (desired_max_height > 0) {
attrs.insert("style", QSL("max-height: %1px !important;").arg(desired_max_height));
}