| 
 
Subject: character substitution. From: "Pawson, David" <DPawson@xxxxxxxxxxx> Date: Tue, 11 Aug 1998 14:13:23 +0100  | 
In looking at text->audio preparation using Jade.
I need to 'clean up' some of the text, such that a 
text to speech engine  will speak the element content more clearly.
e.g. <tel>(44) 1733-378-777 </tel>
becomes <tel>44, 1733,378,777 </tel>
I'm looking to examine an element content (CDATA)
and map a function over  the output of the data (current-node).
However.
What I can't get my tiny mind around is the 
sosofo->character->sosofo transformation needed.
I note that Norm, in dbcommon, does a simple (sosofo-append (data
(current-node)) #\.)
which implies I can treat the output of the data function as a char.
Am I looking for a function which does something like
(process-node-list (fnA (fnB  (data (current-node))))
such that fnB does the actual character substitution on the output of the
data function
	           [Input a character sosofo, output a sequence of chars]
              fnA restores the character sequence to a sosofo, given the
character output of fnB
                       [Input a sequenc of chars, output a character sosofo]
then (process-node-list ...) finally produces the output.
Question: Am I vaguely in the right domain?
Do I need to fnA transformation?
Is there a char->sosofo function.
Any help appreciated.
TIA DaveP
(define subst
  (lambda (stringin)
    (list->string (subst1 (string->list stringin)))))
(define subst1
  (lambda (str)
    (if (null? str) '()
        (cons
          (if (equal? (car str) #\-) #\,
              (car str))
          (subst1 (cdr str))))))
 DSSSList info and archive:  http://www.mulberrytech.com/dsssl/dssslist
| Current Thread | 
|---|
  | 
| <- Previous | Index | Next -> | 
|---|---|---|
| Re: Generating procedure arguments, James Clark | Thread | Re: character substitution., Sebastian Rahtz | 
| Re: not a character number in the d, David Carlisle | Date | Re: character substitution., Sebastian Rahtz | 
| Month |