[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[BUG] speechd-up fails to detect one-character messages
From: |
Alexander E . Patrakov |
Subject: |
[BUG] speechd-up fails to detect one-character messages |
Date: |
Fri, 28 Dec 2007 21:47:37 +0500 |
Hello,
speechd-up contains the following code to detect whether the message
from the kernel (speakup) contains one non-space character and thus
should be treated as a character, not as general text:
/* Find the first non-whitespace non-controll character,
make pointer _c_ point to it. If it is the only character
in the string, _characters_ is 1, otherwise different. */
for (i=0; i<=bytes-1; i++){
if (buf[i] != ' '){
c=buf+i;
characters++;
if (characters>1) break;
}
if ((unsigned) buf[i] < 32){
characters = -1; break;
}
}
if (characters == 1){
say_single_character(c, bytes-i, cd);
iconv_close(cd);
return 0;
} /* else continue parsing the buffer*/
Gowever, git versions of speakup (at least since August, 2007) supply
this when the user presses "2" on the numpad (in order to examine the
current character):
<stop talking (0x18)><space (0x20)><the needed character><space (0x20)>
The "stop talking" special character confuses the code above, and thus
the system fails to pronounce punctuation characters such as "[" when
the user examines them.
And BTW, with the current choice of espeak as the default output
module, sending the KEY command in the say_single_character() doens't
work (produces silence for some characters), while the CHAR command
does work.
Please fix the two issues above.
--
Alexander E. Patrakov
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [BUG] speechd-up fails to detect one-character messages,
Alexander E . Patrakov <=