Skip to content

Commit

Permalink
Incubates #6110. Re issues #6109, #4194, #6220, #6140.
Browse files Browse the repository at this point in the history
  • Loading branch information
jcsteh committed Sep 27, 2016
2 parents ce6fb14 + 123b08d commit 6191725
Show file tree
Hide file tree
Showing 4 changed files with 25 additions and 7 deletions.
2 changes: 1 addition & 1 deletion include/liblouis
Submodule liblouis updated 63 files
+9 −0 .gitignore
+1 −1 HACKING
+36 −11 NEWS
+2 −2 configure.ac
+63 −47 doc/liblouis.texi
+83 −37 liblouis/compileTranslationTable.c
+19 −10 liblouis/liblouis.h.in
+1 −1 liblouis/logging.c
+28 −3 liblouis/lou_backTranslateString.c
+149 −451 liblouis/lou_translateString.c
+6 −4 liblouis/louis.h
+42 −2 liblouis/pattern.c
+0 −2 liblouis/wrappers.c
+13 −0 python/louis/__init__.py.in
+7 −13 tables/Makefile.am
+1 −2 tables/da-dk-common6.uti
+313 −0 tables/da-dk-g08.ctb
+2 −2 tables/da-dk-g16.ctb
+49 −14 tables/da-dk-g18.ctb
+0 −57 tables/da-dk-g18.utb
+3 −3 tables/da-dk-g26.ctb
+159 −0 tables/da-dk-g26l.ctb
+0 −591 tables/da-dk-g28-patches.cti
+1,693 −189 tables/da-dk-g28.ctb
+0 −524 tables/da-dk-g28caps.cti
+742 −0 tables/da-dk-g28l.ctb
+2 −2 tables/da-dk-octobraille.dis
+3 −6 tables/en-ueb-g1.ctb
+1,854 −0 tables/en-ueb-g2.ctb
+12,537 −0 tables/hyph_brl_da_dk.dic
+0 −324 tables/nl-BE-chardefs.cti
+1 −0 tables/nl-BE-g0.utb
+0 −162 tables/nl-BE-g1.ctb
+0 −435 tables/nl-NL-chardefs.cti
+1 −0 tables/nl-NL-g0.utb
+0 −196 tables/nl-NL-g1.ctb
+0 −145 tables/nl-NL-old-g0.utb
+1 −0 tables/nl-chardefs.uti
+1 −0 tables/nl-g0.utb
+0 −183 tables/nl-old-g0.utb
+9 −1 tests/Makefile.am
+1 −1 tests/logging.c
+1 −1 tests/tables/emphclass/emphclass_valid.utb
+43 −0 tests/typeform_for_emphclass.c
+1 −1 tests/ueb_test_data.pl
+0 −1 tests/yaml/Makefile.am
+1 −1 tests/yaml/da-dk-g16-dictionary_harness.yaml
+1 −1 tests/yaml/da-dk-g18-dictionary_harness.yaml
+93 −93 tests/yaml/da-dk-g26-dictionary_harness.yaml
+95 −95 tests/yaml/da-dk-g28-dictionary_harness.yaml
+0 −5 tests/yaml/en-ueb-03-symbols.yaml
+0 −6 tests/yaml/en-ueb-05-grade_1_mode.yaml
+1 −21 tests/yaml/en-ueb-06-numeric_mode.yaml
+1 −1 tests/yaml/en-ueb-08-capitalization.yaml
+2 −5 tests/yaml/en-ueb-09-typeforms.yaml
+1 −1 tests/yaml/example_test.yaml
+0 −128 tests/yaml/nl-BE-g1_harness.yaml
+11 −11 tools/brl_checks.c
+5 −5 tools/lou_allround.c
+18 −18 tools/lou_checkyaml.c
+2 −2 tools/lou_translate.c
+203 −152 windows/include/liblouis.h
+1 −0 windows/liblouis.def
1 change: 1 addition & 0 deletions nvdaHelper/liblouis/liblouis.def
Expand Up @@ -18,5 +18,6 @@ EXPORTS
lou_setDataPath
lou_getTable
lou_checkTable
lou_getTypeformForEmphClass
lou_getDataPath
lou_free
2 changes: 1 addition & 1 deletion readme.md
Expand Up @@ -54,7 +54,7 @@ For reference, the following dependencies are included in Git submodules:
* [Sonic](https://github.com/waywardgeek/sonic), commit 4f8c1d11
* [IAccessible2](http://www.linuxfoundation.org/collaborate/workgroups/accessibility/iaccessible2), version 1.3
* [ConfigObj](http://www.voidspace.org.uk/python/configobj.html), version 4.6.0
* [liblouis](http://www.liblouis.org/), version 2.6.5
* [liblouis](http://www.liblouis.org/), version 3.0.0
* NVDA images and sounds
* System dlls not present on many systems: mfc90.dll, msvcp90.dll, msvcr90.dll, Microsoft.VC90.CRT.manifest
* [Adobe Acrobat accessibility interface, version XI](http://download.macromedia.com/pub/developer/acrobat/AcrobatAccess.zip)
Expand Down
27 changes: 22 additions & 5 deletions source/braille.py
Expand Up @@ -55,10 +55,10 @@
("cz-cz-g1.utb", _("Czech grade 1"), False),
# Translators: The name of a braille table displayed in the
# braille settings dialog.
("da-dk-g16.utb", _("Danish 6 dot grade 1"), False),
("da-dk-g16.ctb", _("Danish 6 dot grade 1"), False),
# Translators: The name of a braille table displayed in the
# braille settings dialog.
("da-dk-g18.utb", _("Danish 8 dot grade 1"), False),
("da-dk-g18.ctb", _("Danish 8 dot grade 1"), False),
# Translators: The name of a braille table displayed in the
# braille settings dialog.
("da-dk-g26.ctb", _("Danish 6 dot grade 2"), False),
Expand Down Expand Up @@ -205,10 +205,10 @@
("mr-in-g1.utb", _("Marathi grade 1"), False),
# Translators: The name of a braille table displayed in the
# braille settings dialog.
("nl-BE-g1.ctb", _("Dutch (Belgium)"), False),
("nl-BE-g0.utb", _("Dutch (Belgium)"), False),
# Translators: The name of a braille table displayed in the
# braille settings dialog.
("nl-NL-g1.ctb", _("Dutch (Netherlands)"), False),
("nl-NL-g0.utb", _("Dutch (Netherlands)"), False),
# Translators: The name of a braille table displayed in the
# braille settings dialog.
("no-no-comp8.ctb", _("Norwegian 8 dot computer braille"), True),
Expand Down Expand Up @@ -262,7 +262,7 @@
("Se-Se-g1.utb", _("Swedish grade 1"), False),
# Translators: The name of a braille table displayed in the
# braille settings dialog.
("sk-sk-g1.utb", _("Slovak grade 1"), False),
("sk-g1.ctb", _("Slovak grade 1"), False),
# Translators: The name of a braille table displayed in the
# braille settings dialog.
("sl-si-g1.utb", _("Slovene grade 1"), False),
Expand Down Expand Up @@ -295,6 +295,18 @@
#: Braille tables that support input (only computer braille tables yet).
INPUT_TABLES = tuple(t for t in TABLES if t[2])

#: Maps old table names to new table names for tables renamed in newer versions of liblouis.
RENAMED_TABLES = {
"da-dk-g16.utb":"da-dk-g16.ctb",
"da-dk-g18.utb":"da-dk-g18.ctb",
"nl-BE-g1.ctb":"nl-BE-g0.utb",
"nl-NL-g1.ctb":"nl-NL-g0.utb",
"no-no.ctb":"no-no-comp8.ctb",
"sk-sk-g1.utb":"sk-g1.ctb",
"UEBC-g1.ctb":"en-ueb-g1.ctb",
"UEBC-g2.ctb":"en-ueb-g2.ctb",
}

roleLabels = {
# Translators: Displayed in braille for an object which is an
# editable text field.
Expand Down Expand Up @@ -1764,6 +1776,11 @@ def initialize():
global handler
config.addConfigDirsToPythonPackagePath(brailleDisplayDrivers)
log.info("Using liblouis version %s" % louis.version())
# #6140: Migrate to new table names as smoothly as possible.
oldTableName = config.conf["braille"]["translationTable"]
newTableName = RENAMED_TABLES.get(oldTableName)
if newTableName:
config.conf["braille"]["translationTable"] = newTableName
handler = BrailleHandler()
handler.setDisplayByName(config.conf["braille"]["display"])

Expand Down

0 comments on commit 6191725

Please sign in to comment.