mirror of
https://gitlab.com/mbunkus/mkvtoolnix.git
synced 2024-12-24 11:54:01 +00:00
GUI: system information: include more environment variables
This commit is contained in:
parent
039533e756
commit
5dfa723d15
@ -114,6 +114,18 @@ gatherScreenInfo(QStringList &info) {
|
||||
#endif
|
||||
}
|
||||
|
||||
void
|
||||
gatherEnvironmentVariables(QStringList &info) {
|
||||
info << Q("") << Q("## Environment variables") << Q("");
|
||||
|
||||
auto keys = QStringList{} << Q("QT_AUTO_SCREEN_SCALE_FACTOR") << Q("QT_SCALE_FACTOR") << Q("QT_SCREEN_SCALE_FACTORS") << Q("QT_DEVICE_PIXEL_RATIO")
|
||||
<< Q("MTX_LOGGER") << Q("MTX_DEBUG") << Q("MKVTOOLNIX_DEBUG") << Q("MKVMERGE_DEBUG");
|
||||
keys.sort();
|
||||
|
||||
for (auto const &name : keys)
|
||||
info << Q("* `%1=%2`").arg(name).arg(Q(mtx::sys::get_environment_variable(to_utf8(name))));
|
||||
}
|
||||
|
||||
void
|
||||
gatherQtInfo(QStringList &info) {
|
||||
info << Q("") << Q("# Qt") << Q("");
|
||||
@ -129,11 +141,6 @@ gatherQtInfo(QStringList &info) {
|
||||
info << Q("* Compiler: unknown");
|
||||
#endif
|
||||
|
||||
info << Q("") << Q("## Environment variables") << Q("");
|
||||
|
||||
auto keys = QStringList{} << Q("QT_AUTO_SCREEN_SCALE_FACTOR") << Q("QT_SCALE_FACTOR") << Q("QT_SCREEN_SCALE_FACTORS") << Q("QT_DEVICE_PIXEL_RATIO");
|
||||
for (auto const &name : keys)
|
||||
info << Q("* `%1=%2`").arg(name).arg(Q(mtx::sys::get_environment_variable(to_utf8(name))));
|
||||
}
|
||||
|
||||
} // anonymous namespace
|
||||
@ -148,6 +155,8 @@ gatherSystemInformation() {
|
||||
|
||||
gatherOperatingSystemInfo(info);
|
||||
gatherScreenInfo(info);
|
||||
gatherEnvironmentVariables(info);
|
||||
|
||||
gatherQtInfo(info);
|
||||
|
||||
return info.join(Q("\n"));
|
||||
|
Loading…
Reference in New Issue
Block a user