Re: [orca-list] question with laptop battery status saying



Dear list!

I would like thank help with Chris Normann.
I make a short script for battery status saying and writing with braille display. I looked the sayweather example script with Orca Faq section, and after is easy make the battery script. This script saying and I hope writing braille display correct my laptop battery capacity using acpi command.

The script:
"import orca.input_event
import orca.keybindings
import orca.orca
import orca.speech

myKeyBindings = orca.keybindings.KeyBindings()



def sayBatteryState(script, inputEvent=None):
    import commands
    message = commands.getoutput("acpi")
    orca.speech.speak(message)
    orca.braille.displaymessage(message)
    return True

sayBatteryStateHandler = orca.input_event.InputEventHandler(
    sayBatteryState,
    "Prints battery status information.")

myKeyBindings.add(orca.keybindings.KeyBinding(
    "b",
    1 << orca.settings.MODIFIER_ORCA,
    1 << orca.settings.MODIFIER_ORCA,
    sayBatteryStateHandler))"

Possible build this script native with Orca?

Now, I define this command with Orca+b keybinding, but I would like doing Orca+shift+b keybinding.

But, I have a new question:
How can translate the battery script saying and braille message with acpi command with hungarian users or any language users (Orca.speech.speak and orca.braille.displaymessage)?

Thanks,

Attila




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