[1.31.18]

Indicate unrecognized letters within a word by clicks.
lang-tr: Non-standard lower case conversion for "I".
Tone languages: indicate emphasis by increasing the pitch range.


git-svn-id: https://espeak.svn.sourceforge.net/svnroot/espeak/trunk@151 d46cf337-b52f-0410-862d-fd96e6ae7743
This commit is contained in:
jonsd
2008-02-25 21:59:24 +00:00
parent bf8ee6362e
commit 16fba5a1c1
20 changed files with 179 additions and 54 deletions
+13 -5
View File
@@ -71,9 +71,10 @@ int Translator_English::Unpronouncable(char *word)
This function is language specific.
*/
unsigned char c;
int c;
int vowel_posn=9;
int index;
int count;
int ix;
int apostrophe=0;
@@ -92,19 +93,26 @@ int Translator_English::Unpronouncable(char *word)
}
index=0;
while(((c = word[index++]) != 0) && !isspace(c))
count=0;
for(;;)
{
index += utf8_in(&c,&word[index],0);
count++;
if((c==0) || (c==' '))
break;
if(IsVowel(c) || (c == 'y'))
{
vowel_posn = index;
vowel_posn = count;
break;
}
if(c == '\'')
apostrophe = 1;
else
if((c < 'a') || (c > 'z'))
return(0); // letter (not vowel) outside a-z range or apostrophe, abort test
if((c < 'a') || (c > 0x241))
return(0); // letter (not vowel) outside Latin character range or apostrophe, abort test
}
if((vowel_posn > 5) || ((word[0]!='s') && (vowel_posn > 4)))
return(1); // no vowel, or no vowel in first four letters