[Kde-accessibility] KTTS News
Gary Cramblitt
garycramblitt at comcast.net
Sun Jan 30 03:03:45 CET 2005
On Friday 28 January 2005 01:18 pm, Mikolaj Machowski wrote:
> > > Added to english string replacer 'Word' BTW 'by the way' and voice
> > > still reads it as 'bee tee dabl:u'.
You added BTW to the String Replacer (English) filter but your default
(topmost) Talker is Polish Festival, so unless you are somehow telling KTTSD
that your text is English, KTTS is assuming the text is Polish. Therefore
the String Replacer (English) filter doesn't apply itself. Either remove the
"Language is" from the String Replacer (English) filter, or add BTW to the
String Replacer (Polish) filter.
> > > 'Polish replacements' also doesn't work.
<?xml version="1.0" encoding="UTF-8"?>
<wordlist>
...
<word>
<type>Word</type>
<match><![CDATA[(]]></match>
<subst><![CDATA[ ]]></subst>
</word>
<word>
<type>Word</type>
<match><![CDATA[)]]></match>
<subst><![CDATA[ ]]></subst>
</word>
</wordlist>
These should be Regular Expressions, i.e. check the Regular Expression radio
button in the config dialog for each word.
<?xml version="1.0" encoding="UTF-8"?>
<wordlist>
...
<name>String Replacer (Polish)</name>
<language-code>pl</language-code>
<word>
<type>RegExp</type>
<match><![CDATA[\(]]></match>
<subst><![CDATA[ ]]></subst>
</word>
<word>
<type>RegExp</type>
<match><![CDATA[\)]]></match>
<subst><![CDATA[ ]]></subst>
</word>
</wordlist>
"Word" type filters are internally implemented as regular expressions of the
form \bword\b, which means that the left and right parens would have to have
word boundaries (spaces) on either side for them to be matched. Also note
the backslashes I added.
You didn't include { and }. Was that on purpose?
Hopefully, once I've documented the use of filters in the Handbook, this will
be less confusing.
--
Gary Cramblitt (aka PhantomsDad)
KDE Text-to-Speech Maintainer
http://accessibility.kde.org/developer/kttsd/index.php
More information about the kde-accessibility
mailing list