[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Speech-enabling mud.el



For the past several days, I have been attempting to speech-enable the
Emacs MUD client which I obtained from
ftp://ftp.cold.org/cold/contrib/clients/mud-telnet-Sleeper-1.11.tar.gz. Basically,
I would like all incoming text to be spoken by the client, unless
(point) is not at the end of the buffer, to allow reviewing long bits
of text. I would also like newly-arrived speech to not interrupt
current speech, but I would like the user to be able to interrupt
speech by moving to a new buffer position or typing a command. I'll
show what I've done so far, which is an entire 3 lines of code, and
then point out deficiencies and ask for assistance. Note that while
there are certainly elisp mailing lists/news groups, I thought it
would be best to post this here, since my enhancements are more likely
to be understood by people who are familiar with Emacspeak. Anyhow,
code snippet follows:

(defun emacspeak-mud-hook ()
"Adds speech to mud.el"
(emacspeak-speak-region (point-min) (point-max)))

This code is added to one of the hooks in the client, moo-filter-hook
to be exact. There are numerous problems with this code however, and
I'm not sure how to implement certain things.

1. Apparently, the filter function is called by mud-telnet-sleeper.el
   on each line. I was hoping that something like the following would
   work, but I'm thinking something happens to mark, because I receive
   no spoken output with this version:

(defun emacspeak-mud-hook ()
"Adds speech to mud.el"
(if (> (mark) (point-min))
(emacspeak-speak-region (point-min) (point-max))))

2.  The first version of this function does provide basic spoken
    feedback. One or two-line messages speak nicely, and as long as
    the speech flow remains uninterrupted, it works well except in
    certain situations (see below). But, if a long room description is
    being spoken, and someone enters the room, speech is
    interrupted. Is it somehow possible to say, "I don't want speech
    to be stopped by incoming text, but any input from the user should
    halt speech and act accordingly?"

3.  Long portions of text result in only the last few lines being
    spoken. I'm thinking that this is related to 2, since it seems
    logical that the lines which reach the Dectalk last would flush
    the lines which arrive first, thus gaining priority and creating
    only partial speech.

Thanks for any assistance.

-- 

                                           Nolan Darilek
                                        nolan_d@bigfoot.com
                                           nolan@cold.org
                                      nolan_d@mail.utexas.edu
                                         ICQ UIN: 15709478

-------------------------------------------------------------------------------
             "We are not without accomplishment. We have managed to
                          distribute poverty equally."
                 -Nguyen Co Thatch, Vietnamese foreign minister

-----------------------------------------------------------------------------
       To unsubscribe or change your address send mail to
"emacspeak-request@cs.vassar.edu" with a subject of "unsubscribe" or "help"


Emacspeak Files | Subscribe | Unsubscribe