[orca-list] Help Required



Dear all,

Please help me out. I was exploring orca on my laptop and i was adding
the say time functionality to the orca using orca_customizations.py
file. After type the script, i saved the file and i restarted the
orca. But, now the problem is, orca is not getting started. When i
type orca in run, it just gets loaded and says, "Starting orca
preferences" and then gets shut again. What could be the problem? Is
there any solution to reset my orca? For your convenience, i'll
mention the code which i used for adding the say time functionality.

import orca.input_event # watches for input that Orca recognizes
import orca.keybindings # Handles binding keystrokes for Orca to use.
import orca.orca # Imports the main screen reader
import orca.speech # Handles Orca's speaking abilities
import orca.braille # Displays information in Braille format

myKeyBindings = orca.keybindings.KeyBindings()

#Define the sayTime function
def sayTime(script, inputEvent=None):
  import time # imports the Python time library
  message = time.strftime("%I:%M%p", time.localtime())
  orca.speech.speak(message)
  orca.braille.displayMessage(message)
  return True
#end sayTime function

sayTimeHandler = orca.input_event.InputEventHandler(
    sayTime,
    "Speaks and/or Brailles the time.") # Shows the function of the
key press in learn mode

myKeyBindings.add(orca.keybindings.KeyBinding(
    "t",
    1 << orca.settings.MODIFIER_ORCA,
    1 << orca.settings.MODIFIER_ORCA,
    sayTimeHandler)) # Sets Orca-t as the say time key

orca.settings.keyBindingsMap["default"] = myKeyBindings
#end time code

Even i had restarted my laptop, but the result was the same. Please help me out.

Regards
Tejas



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