File indexing completed on 2025-04-20 12:50:01
0001 /* 0002 SPDX-FileCopyrightText: 2022-2023 Laurent Montel <montel@kde.org> 0003 0004 SPDX-License-Identifier: LGPL-2.0-or-later 0005 */ 0006 0007 #pragma once 0008 #include "textedittexttospeech_private_export.h" 0009 #include <QWidget> 0010 class QLabel; 0011 class QSlider; 0012 namespace TextEditTextToSpeech 0013 { 0014 class TEXTEDITTEXTTOSPEECH_TESTS_EXPORT TextToSpeechSliderWidget : public QWidget 0015 { 0016 Q_OBJECT 0017 public: 0018 explicit TextToSpeechSliderWidget(const QString &labelInfo, QWidget *parent = nullptr); 0019 ~TextToSpeechSliderWidget() override; 0020 0021 void setValue(int value); 0022 void setRange(int min, int max); 0023 Q_REQUIRED_RESULT int value() const; 0024 0025 Q_SIGNALS: 0026 void valueChanged(int value); 0027 0028 private: 0029 void slotValueChanged(int value); 0030 QString mLabelInfo; 0031 QLabel *const mLabel; 0032 QSlider *const mSlider; 0033 }; 0034 }