34 lines
1.0 KiB
Diff
34 lines
1.0 KiB
Diff
From a898824a1555208b921fc4b185eea8c2999b15ae Mon Sep 17 00:00:00 2001
|
|
From: tanyulong <tanyulong@kylinos.cn>
|
|
Date: Thu, 28 Oct 2021 14:36:24 +0800
|
|
Subject: [PATCH] Avoid the problem of writing Chinese garbled characters in
|
|
qsettings
|
|
|
|
---
|
|
ukui-greeter/greeter/greeterwrapper.cpp | 2 ++
|
|
1 file changed, 2 insertions(+)
|
|
|
|
diff --git a/ukui-greeter/greeter/greeterwrapper.cpp b/ukui-greeter/greeter/greeterwrapper.cpp
|
|
index d155618..e1eb363 100755
|
|
--- a/ukui-greeter/greeter/greeterwrapper.cpp
|
|
+++ b/ukui-greeter/greeter/greeterwrapper.cpp
|
|
@@ -21,6 +21,7 @@
|
|
#include <QDesktopWidget>
|
|
#include <QDebug>
|
|
#include <QBitArray>
|
|
+#include <QTextCodec>
|
|
#include "globalv.h"
|
|
#include "common/configuration.h"
|
|
|
|
@@ -85,6 +86,7 @@ void GreeterWrapper::setrootWindow()
|
|
|
|
QString configPath = "/tmp/greeter-background.conf";
|
|
QSettings settings1(configPath, QSettings::IniFormat);
|
|
+ settings1.setIniCodec(QTextCodec::codecForName("UTF-8"));
|
|
settings1.setValue("Greeter",m_rootWindowBackground);
|
|
settings1.sync();
|
|
}
|
|
--
|
|
2.30.0
|
|
|