# --- T2-COPYRIGHT-BEGIN --- # t2/package/*/kinfocenter/up-next-arch-entry.patch # Copyright (C) 2026 The T2 SDE Project # SPDX-License-Identifier: GPL-2.0 or patched project license # --- T2-COPYRIGHT-END --- Let's add a Arch entry, too. Signed-off-by: René Rebe --- kinfocenter-6.6.3/kcms/about-distro/src/main.cpp.vanilla 2026-03-17 19:14:29.046486359 +0100 +++ kinfocenter-6.6.3/kcms/about-distro/src/main.cpp 2026-03-17 19:15:37.855483728 +0100 @@ -26,6 +26,7 @@ #include #include +#include "ArchEntry.h" #include "CPUEntry.h" #include "GPUEntry.h" #include "GPUEntryFactory.h" @@ -271,7 +272,7 @@ } // hardware - addEntriesToGrid(m_hardwareEntries, {new CPUEntry, new MemoryEntry}); + addEntriesToGrid(m_hardwareEntries, {new ArchEntry, new CPUEntry, new MemoryEntry}); addEntriesToGrid(m_hardwareEntries, GPUEntryFactory::factorize()); KAuth::Action action(QStringLiteral("org.kde.kinfocenter.dmidecode.systeminformation")); --- kinfocenter-6.6.3/kcms/about-distro/src/CMakeLists.txt.vanilla 2026-03-17 19:11:11.252775776 +0100 +++ kinfocenter-6.6.3/kcms/about-distro/src/CMakeLists.txt 2026-03-17 19:16:14.180560624 +0100 @@ -5,6 +5,8 @@ add_subdirectory(vulkan-helper) set(kcm_SRCS + ArchEntry.cpp + ArchEntry.h CPUEntry.cpp CPUEntry.h Entry.cpp --- kinfocenter-6.6.3/kcms/about-distro/src/ArchEntry.h.vanilla 2026-03-17 18:57:52.058934247 +0100 +++ kinfocenter-6.6.3/kcms/about-distro/src/ArchEntry.h 2026-03-17 19:01:23.340026298 +0100 @@ -0,0 +1,20 @@ +/* + SPDX-FileCopyrightText: 2026 René Rebe + SPDX-License-Identifier: GPL-2.0-only OR GPL-3.0-only OR LicenseRef-KDE-Accepted-GPL +*/ + +#ifndef ARCHENTRY_H +#define ARCHENTRY_H + +#include + +#include "Entry.h" + +class ArchEntry : public Entry +{ +public: + ArchEntry(); + QString localizedValue(Language language = Language::System) const override; +}; + +#endif // CPUENTRY_H --- kinfocenter-6.6.3/kcms/about-distro/src/ArchEntry.cpp.vanilla 2026-03-17 18:57:47.722934699 +0100 +++ kinfocenter-6.6.3/kcms/about-distro/src/ArchEntry.cpp 2026-03-17 19:11:07.489117106 +0100 @@ -0,0 +1,27 @@ +/* + SPDX-FileCopyrightText: 2026 René Rebe + SPDX-License-Identifier: GPL-2.0-only OR GPL-3.0-only OR LicenseRef-KDE-Accepted-GPL +*/ + +#include "ArchEntry.h" +#include "FancyString.h" + +#include + +ArchEntry::ArchEntry() + : Entry(KLocalizedString(), QString()) +{ + m_label = ki18n("Architecture:"); +} + +QString ArchEntry::localizedValue(Language language) const +{ + struct utsname buf; + + if (uname(&buf) != 0) { + const KLocalizedString l10nUnknown = ki18nc("unknown CPU arch", "unknown"); + const QString unknownName = localize(l10nUnknown, language); + } + + return QString::fromLocal8Bit(buf.machine); +} --- ./po/de/kcm_about-distro.po.vanilla 2026-03-17 19:38:11.539381159 +0100 +++ ./po/de/kcm_about-distro.po 2026-03-17 19:40:48.561039975 +0100 @@ -17,6 +17,11 @@ "Plural-Forms: nplurals=2; plural=(n != 1);\n" "X-Generator: Lokalize 25.08.3\n" +#: ArchEntry.cpp:13 +#, kde-format +msgid "Architecture:" +msgstr "Architektur:" + #: CPUEntry.cpp:17 #, kde-format msgid "Processor:"