From 2e27da552c409675fc429775b95954b64f6c4f3a Mon Sep 17 00:00:00 2001 From: collecting Date: Sat, 4 Oct 2025 12:05:16 +0000 Subject: [PATCH] Edit configure_system.h --- src/citron/configuration/configure_system.h | 21 ++++++++++++++++++--- 1 file changed, 18 insertions(+), 3 deletions(-) diff --git a/src/citron/configuration/configure_system.h b/src/citron/configuration/configure_system.h index a1a3a799d..e795a9d1b 100644 --- a/src/citron/configuration/configure_system.h +++ b/src/citron/configuration/configure_system.h @@ -1,4 +1,5 @@ // SPDX-FileCopyrightText: 2016 Citra Emulator Project +// SPDX-FileCopyrightText: Copyright 2025 citron Emulator Project // SPDX-License-Identifier: GPL-2.0-or-later #pragma once @@ -7,6 +8,7 @@ #include #include +#include // Added for stylesheet property #include #include "citron/configuration/configuration_shared.h" @@ -15,20 +17,23 @@ class QLineEdit; class QComboBox; class QDateTimeEdit; namespace Core { -class System; + class System; } namespace Ui { -class ConfigureSystem; + class ConfigureSystem; } namespace ConfigurationShared { -class Builder; + class Builder; } class ConfigureSystem : public ConfigurationShared::Tab { Q_OBJECT + // This property allows the main UI file to pass its stylesheet to this widget + Q_PROPERTY(QString templateStyleSheet READ GetTemplateStyleSheet WRITE SetTemplateStyleSheet NOTIFY TemplateStyleSheetChanged) + public: explicit ConfigureSystem(Core::System& system_, std::shared_ptr> group, @@ -39,6 +44,13 @@ public: void ApplyConfiguration() override; void SetConfiguration() override; + // These functions get and set the stylesheet property + QString GetTemplateStyleSheet() const; + void SetTemplateStyleSheet(const QString& sheet); + +signals: + void TemplateStyleSheetChanged(); + private: void changeEvent(QEvent* event) override; void RetranslateUI(); @@ -60,4 +72,7 @@ private: QDateTimeEdit* date_rtc; QSpinBox* date_rtc_offset; u64 previous_time; + + // This variable will hold the raw stylesheet string + QString m_template_style_sheet; };