pilot51 / voicenotify

Android app that speaks notifications
https://voicenotify.app
Apache License 2.0
144 stars 55 forks source link

Process Require Text before TTS Text Replacement #110

Open pilot51 opened 10 months ago

pilot51 commented 10 months ago

Received via email:

Voice Notify is a great app. I use it to read selectable messages to my Telegram Bot. I only want to TTS messages which begins with the # character. I can set this up with the "Require Text" setting. And I want to strip this # character. At the moment I only can replace characters before the detection is triggered. It's very useful to replace (or in my case delete the first) character after the detection if the message must be handled. The "Require Text" setting.

So I want to TTS only Telegram messages which starts with # character. And I want to strip the # character. So only TTS the part after the # character.

Two ways to solve this:

  1. Move processing of Require Text to happen before TTS Text Replacement in code. This is the easiest to do, but not ideal since it could negatively impact other users who are happy with the current order.
  2. Add an option to change the order that Require Text and TTS Text Replacement are processed. This idea may be expanded into a list of processing steps that can be reordered.