2
0
mirror of https://github.com/telegramdesktop/tdesktop synced 2025-09-05 17:06:03 +00:00

Add a cheat code to enable freetype on Windows and macOS

This commit is contained in:
Ilya Fedin
2020-05-09 02:37:43 +04:00
committed by John Preston
parent c9553c2d4c
commit 7409d615a3
6 changed files with 69 additions and 6 deletions

View File

@@ -518,6 +518,21 @@ void Application::switchTestMode() {
App::restart();
}
void Application::switchFreeType() {
if (cUseFreeType()) {
QFile(cWorkingDir() + qsl("tdata/withfreetype")).remove();
cSetUseFreeType(false);
} else {
QFile f(cWorkingDir() + qsl("tdata/withfreetype"));
if (f.open(QIODevice::WriteOnly)) {
f.write("1");
f.close();
}
cSetUseFreeType(true);
}
App::restart();
}
void Application::writeInstallBetaVersionsSetting() {
_launcher->writeInstallBetaVersionsSetting();
}