[orca-list] I would like do builtin current date and time spokening and braille writing feature with Orca, but I have some language dependent question before I begin working this feature



Hy List,

Sorry, my letter possible is longer now, but I would like ask hint
before I working a new now not doed feature request in Bugzilla:
Oldest time I think have a community request need doing Orca a builtin
date and time spokening and braille writing feature.
For example default date spokening shortcut is possible Orca+d, default
time spokening feature is Orca+t key combination, similar with Storm
already doed orca-customizations.py keybinding map, because this two
keybinding is popular.
I welcome doing this feature in future, but I have few language specific
questions before I begin working:
1. The date spokening question I think clear, possible need do
translated form, because language to language uses different order to
spokening date format (year month, month day, week day or another format
order), so, optimal translators are possible toggle custom order with
this feature if this is possible. But possible this is not need, because
if I switch english language, hungarian used orca-customizations date
script resulting following output:
2010. April 28, wednesday. I using following code to request date and
outputting final message, sorry the code part, of course braille message
writing method sintax is changed in master branch, my code based Storm
date spokening script with little modification for hungarian users.
Following part is code, if anybody not interesting this part, please jump:
year=time.strftime("%Y", time.localtime())
month=time.strftime("%B", time.localtime())
monthday=time.strftime("%d", time.localtime())
weekday=time.strftime("%A", time.localtime())
#If monthday[0] containing 0 (for example 01 the month day), need cut
#the first 0 number
if monthday[0]=="0":
    orca.speech.speak(year+". "+month+" "+monthday[1]+", "+weekday+".")
    orca.braille.displayMessage(year+". "+month+" "+monthday[1]+",
"+weekday+".")
else:
    orca.speech.speak(year+". "+month+" "+monthday+", "+weekday+".")
    orca.braille.displayMessage(year+". "+month+" "+monthday+",
"+weekday+".")

So, good the community the year, month, monthday, week day format (for
example 2010. April 28, Wednesday date string) without marking
translation? When I switch language back to hungarian language, date
string is of course changed automaticaly with hungarian form:
2010. április 28, szerda (April replaced with április hungarian month
name, and Wednesday replaced with Szerda hungarian week day name).

2. The difficulter question with time spokening and braille writing
feature part:
I think we need use 24 hour format, and don't need using hour and minute
suffix word. But, for example in hungarian language we spokening 12:25
string with 12 óra 25 perc (óra means hour, perc means minute) with
normal speak. Of
course I known english timezone this time form is wrong spokened,
12 óra 25 am perc, this is incorrect. Enough to spokening time spokening
script with 12 25 AM for example in english language?
Of course, have several ways to do this feature part:
Original time request code resulting this output for english users, but
not disturb for example hungarian language output, hungarian users hear
only hour and minute numbers, but english users hear AM or PM suffix
after the time values spokening:
message = time.strftime("%H %M%p.", time.localtime())
Or, have another format to get time, this is resulting only hour and
minute values without AM or PM suffix:
message = time.strftime("%H %M.", time.localtime())
Another way to we use this second form, and mark translation the hour
and minute word, so, translators translate correct own language this
words, for example english spokened and braille wroted time value looks
following if this is happening:
12 hour 25 minute
Hungarian language time value looks following:
12 óra 25 perc.
What method form would like the community?

I have a question with braille users:
In master branch, the braille.displayMessage write method is changed
with following, need use following parameters, I copyed with default.py
parameter comment:
- message: the string to display
- cursor: the 0-based cursor position, where -1 (default) means no
          cursor
- flashTime:  if non-0, the number of milliseconds to display the
          regions before reverting back to what was there before. A 0
means to not do any flashing.  A negative number means to display the
message until some other message comes along or the user presses
 a cursor routing key.

What the best with braille users with this feature purpose?
Unfortunately I haven't got a braille display, so, I would like ask
braille users hints.
For example good if this feature using settings.brailleFlashTime value
with flash time parameter? This settings mean following with
src/orca/settings.py, the default value this settings is 5000:
# The timeout (in milliseconds) to use for messages flashed in braille.
#
brailleFlashTime        = 5000

Attila



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