|
4 | 4 | # See the file COPYING for more details. |
5 | 5 | # Copyright (C) 2006-2021 NV Access Limited, Peter Vágner, Aleksey Sadovoy, Rui Batista, Joseph Lee, |
6 | 6 | # Leonard de Ruijter, Derek Riemer, Babbage B.V., Davy Kager, Ethan Holliger, Łukasz Golonka, Accessolutions, |
7 | | -# Julien Cochuyt |
| 7 | +# Julien Cochuyt, Jakub Lukowicz |
8 | 8 |
|
9 | 9 | import time |
10 | 10 | import itertools |
@@ -385,13 +385,13 @@ def script_toggleSpeakCommandKeys(self,gesture): |
385 | 385 |
|
386 | 386 | @script( |
387 | 387 | # Translators: Input help mode message for toggle report font name command. |
388 | | - description=_("Toggles on and off the reporting of font changes"), |
389 | | - category=SCRCAT_DOCUMENTFORMATTING |
| 388 | + description=_("Toggles on and off the reporting of font name changes"), |
| 389 | + category=SCRCAT_DOCUMENTFORMATTING, |
390 | 390 | ) |
391 | 391 | def script_toggleReportFontName(self,gesture): |
392 | 392 | if config.conf["documentFormatting"]["reportFontName"]: |
393 | | - # Translators: The message announced when toggling the report font name document formatting setting. |
394 | 393 | state = _("report font name off") |
| 394 | + # Translators: The message announced when toggling the report font name document formatting setting. |
395 | 395 | config.conf["documentFormatting"]["reportFontName"]=False |
396 | 396 | else: |
397 | 397 | # Translators: The message announced when toggling the report font name document formatting setting. |
@@ -702,6 +702,32 @@ def script_toggleReportTableCellCoords(self,gesture): |
702 | 702 | config.conf["documentFormatting"]["reportTableCellCoords"]=True |
703 | 703 | ui.message(state) |
704 | 704 |
|
| 705 | + @script( |
| 706 | + # Translators: Input help mode message for toggle report cell borders command. |
| 707 | + description=_("Cycles through the cell border reporting settings"), |
| 708 | + category=SCRCAT_DOCUMENTFORMATTING, |
| 709 | + ) |
| 710 | + def script_toggleReportCellBorders(self, gesture): |
| 711 | + if ( |
| 712 | + not config.conf["documentFormatting"]["reportBorderStyle"] and not |
| 713 | + config.conf["documentFormatting"]["reportBorderColor"] |
| 714 | + ): |
| 715 | + # Translators: A message reported when cycling through cell borders settings. |
| 716 | + ui.message(_("Report styles of cell borders")) |
| 717 | + config.conf["documentFormatting"]["reportBorderStyle"] = True |
| 718 | + elif ( |
| 719 | + config.conf["documentFormatting"]["reportBorderStyle"] and not |
| 720 | + config.conf["documentFormatting"]["reportBorderColor"] |
| 721 | + ): |
| 722 | + # Translators: A message reported when cycling through cell borders settings. |
| 723 | + ui.message(_("Report colors and styles of cell borders")) |
| 724 | + config.conf["documentFormatting"]["reportBorderColor"] = True |
| 725 | + else: |
| 726 | + # Translators: A message reported when cycling through cell borders settings. |
| 727 | + ui.message(_("Report cell borders off.")) |
| 728 | + config.conf["documentFormatting"]["reportBorderStyle"] = False |
| 729 | + config.conf["documentFormatting"]["reportBorderColor"] = False |
| 730 | + |
705 | 731 | @script( |
706 | 732 | # Translators: Input help mode message for toggle report links command. |
707 | 733 | description=_("Toggles on and off the reporting of links"), |
|
0 commit comments