From 5205df84002667b768df61d533fcddb1fba7fa8c Mon Sep 17 00:00:00 2001 From: Mohammad Shoaib Khan Date: Mon, 10 Oct 2022 15:56:35 +0530 Subject: [PATCH] Replaced ^ with \n when narrating texts --- stardew-access/ScreenReader/ScreenReaderLinux.cs | 2 ++ stardew-access/ScreenReader/ScreenReaderWindows.cs | 2 ++ 2 files changed, 4 insertions(+) diff --git a/stardew-access/ScreenReader/ScreenReaderLinux.cs b/stardew-access/ScreenReader/ScreenReaderLinux.cs index 0cbe1f3..7e58c69 100644 --- a/stardew-access/ScreenReader/ScreenReaderLinux.cs +++ b/stardew-access/ScreenReader/ScreenReaderLinux.cs @@ -68,6 +68,8 @@ namespace stardew_access.ScreenReader if (!MainClass.Config.TTS) return; + if (text.Contains('^')) text = text.Replace('^', '\n'); + GoString str = new GoString(text, text.Length); Speak(str, interrupt); } diff --git a/stardew-access/ScreenReader/ScreenReaderWindows.cs b/stardew-access/ScreenReader/ScreenReaderWindows.cs index a52d546..f2da4b5 100644 --- a/stardew-access/ScreenReader/ScreenReaderWindows.cs +++ b/stardew-access/ScreenReader/ScreenReaderWindows.cs @@ -65,6 +65,8 @@ namespace stardew_access.ScreenReader if (!MainClass.Config.TTS) return; + if (text.Contains('^')) text = text.Replace('^', '\n'); + screenReader.Speak(text, interrupt); }