From 51654fb62f09ff5a32b8c4133f3ee40337ae2e76 Mon Sep 17 00:00:00 2001 From: Axel Spoerl Date: Fri, 20 May 2022 22:35:59 +0200 Subject: Prepare boundary hint in QTextToSpeech Add enum class BoundaryHint in QTextToSpeech. Add respective parameters in stop() and pause(). Update documentation, and implement support on macOS and iOS engines. Change-Id: I616a8763520e197c3bf16118c111c3e114079b38 Reviewed-by: Qt CI Bot Reviewed-by: Volker Hilsheimer --- examples/speech/hello_speak/mainwindow.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'examples') diff --git a/examples/speech/hello_speak/mainwindow.cpp b/examples/speech/hello_speak/mainwindow.cpp index 04c7a7f..5c15b1a 100644 --- a/examples/speech/hello_speak/mainwindow.cpp +++ b/examples/speech/hello_speak/mainwindow.cpp @@ -140,8 +140,8 @@ void MainWindow::engineSelected(int index) setRate(ui.rate->value()); setPitch(ui.pitch->value()); setVolume(ui.volume->value()); - connect(ui.stopButton, &QPushButton::clicked, m_speech, &QTextToSpeech::stop); - connect(ui.pauseButton, &QPushButton::clicked, m_speech, &QTextToSpeech::pause); + connect(ui.stopButton, &QPushButton::clicked, m_speech, [this]{ m_speech->stop(); }); + connect(ui.pauseButton, &QPushButton::clicked, m_speech, [this]{ m_speech->pause(); }); connect(ui.resumeButton, &QPushButton::clicked, m_speech, &QTextToSpeech::resume); connect(m_speech, &QTextToSpeech::stateChanged, this, &MainWindow::stateChanged); -- cgit v1.2.3