Re: [orca-list] Changing Pronunciation for punctuation?



I'm not sure it can be done through the pronunciation page.  This behavior used to be controlled through an orca scrypt file.
 
Check if you have a file ~/.local/share/orca/orca-customizations.py if it doesn't exist you can creat it.
There used to be some information on the orca wiki about the orca-customization.py file.  You'd probably want to try something like the following:
 
 
try:
  import orca.speech # contains speech routines for orca.
except ImportError:
  print "sorry, speech could not be loaded."
try:
  import orca.braille # contains orca routines for braille.
except ImportError:
  print "sorry, braille could not be loaded."
# attempt to add customized speach.
try:
  import orca.chnames # contains the structure linking symbols to their names.
except ImportError:
  print "sorry, chnames could not be loaded."
else:
  try:
# redefine ! to "bang."
    orca.chnames.chnames['!'] = "bang"
  except:
    message = "sorry.  could not set custom speach for the bang symbol (!)."
    try:
      orca.speech.speak(message)
      orca.braille.displayMessage(message)
    except:
      print message
  try:
# define # as "hash."
    orca.chnames.chnames['#'] = "hash"
  except:
    message = "sorry.  could not set custom speach for the hash symbol (#)."
    try:
      orca.speech.speak(message)
      orca.braille.displayMessage(message)
    except:
      print message
 
 
 
 
I coppied the relevent sections from my own orca-customizations.py file and swapped in a couple of the examples you wanted.  If you get syntax errors,  
double check the chnames.py file (I can't remember the exact path right now; if you can't find it on your own, post back and I, or someone else can take  
a gander for the path.).  If chnames doesn't work, I'm not sure what the new procedure is, but I'd be interested.
 
Hope this helps:-)
 
>Message: 3
>Date: Sat, 13 Aug 2011 22:45:00 +0100
>From: "C. M. Blake" <cmb1589 gmail com>
>To: orca-list gnome org
>Subject: [orca-list] Changing Pronunciation for punctuation?
>Message-ID: <4E46F05C 5090009 gmail com>
>Content-Type: text/plain; charset="iso-8859-1"; Format="flowed"
>  
>Hello,
>  
>I'm a fairly new Orca user.
>  
>I'm running VInux 3.2.1, with Orca 3.1.2-xdesktop.
>  
>I'm looking to change the way some punctuation is spoken so that it  
>helps my efficiency using Orca with web development and programming.
>  
>For example.
>For full stop to be read as 'dot' which I think it does already,
>! to be read as 'bang'
># to be read as hash only and not number
>< to be read as 'less'
>and > to be read as 'greater'.
>  
>Is there any special characters I need to denote in the pronunciation  
>table to define I wish to change the way a symbol is spoken?


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