Help/litehtml: Fix litehtml build on Windows and with GCC 5.3

GCC 5.3 doesn't want to convert char* literals to QString sometimes, and
for MSVC conversions litehtml::tstring/tchar_t <->
QString::fromStdString/QString fails because the former was wstring and
wchar
Also position independent code is needed on Linux

Change-Id: Iec8dd0d9d38a07cd1c4db49c9edf10e3d1d5b156
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
This commit is contained in:
Eike Ziller
2019-09-20 11:14:05 +02:00
parent 1273081224
commit fe6ba084c4
3 changed files with 18 additions and 8 deletions

View File

@@ -1232,19 +1232,19 @@ QPixmap DocumentContainer::getPixmap(const QString &imageUrl, const QString &bas
QString DocumentContainer::serifFont() const
{
// TODO make configurable
return "Times New Roman";
return {"Times New Roman"};
}
QString DocumentContainer::sansSerifFont() const
{
// TODO make configurable
return "Arial";
return {"Arial"};
}
QString DocumentContainer::monospaceFont() const
{
// TODO make configurable
return "Courier";
return {"Courier"};
}
QUrl DocumentContainer::resolveUrl(const QString &url, const QString &baseUrl) const