Skip to content

Commit

Permalink
Add Galician and Euskera locales along with 2 license unicode symbols
Browse files Browse the repository at this point in the history
  • Loading branch information
mondeja committed Sep 1, 2021
1 parent cb29828 commit 1fdc498
Show file tree
Hide file tree
Showing 4 changed files with 23 additions and 11 deletions.
12 changes: 12 additions & 0 deletions NOTES.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,4 +12,16 @@ Implementation of [CBE guide][cbe-guide] for uniformed Spanish Braille.
must be preceded by a numeric prefix `` in the first number only. But
this implementation currently precede the numerical prefix before any number.

## Galician - Braille español (Grado 1)

Uses same implementation as Spanish.

## Basque - Braille español (Grado 1)

Uses same implementation as Spanish.

# Other useful resources

- [World Braille Usage][world-braille-usage]

[cbe-guide]: https://sid.usal.es/idocs/F8/FDO12069/signografiabasica.pdf
12 changes: 4 additions & 8 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,18 +25,14 @@ text-to-Braille converter.
Select a text that you want to convert in Braille, open this extension,
choose a locale and press `Apply`.

## Useful resources

- [World Braille Usage][world-braille-usage]

## TODO

- [x] ~~Spanish Braille conversion for texts not prepared for Braille
translation. Add prefixes before numbers and before uppercased letters.~~
- [ ] Catalán/valenciano ([link](https://www.once.es/servicios-sociales/braille))
- [ ] Gallego ([link](https://www.once.es/servicios-sociales/braille))
- [ ] Euskera ([link](https://www.once.es/servicios-sociales/braille))
- [x] ~~Spanish combinations ([link](https://sid.usal.es/idocs/F8/FDO12069/signografiabasica.pdf))~~
- [ ] Catalán/valenciano
- [x] ~~Gallego~~
- [x] ~~Euskera~~
- [x] ~~Spanish combinations~~

[notes]: https://github.com/mondeja/inkscape-braille-l18n-ext/blob/master/NOTES.md
[download-repo]: https://github.com/mondeja/inkscape-braille-l18n-ext/archive/refs/heads/master.zip
Expand Down
4 changes: 3 additions & 1 deletion text_braille_l18n.inx
Original file line number Diff line number Diff line change
@@ -1,13 +1,15 @@
<?xml version="1.0" encoding="UTF-8"?>
<inkscape-extension xmlns="http://www.inkscape.org/namespace/inkscape/extension">
<_name>Convert to localized Braille</_name>

<id>org.inkscape.TextBrailleL18n</id>

<dependency type="executable" location="extensions">text_braille_l18n.py</dependency>

<param name="locale" gui-text="Alphabet:" type="optiongroup" appearance="combo">
<option value="en">English (ASCII)</option>
<option value="es">Spanish</option>
<option value="gl">Galician</option>
<option value="eu">Basque</option>
</param>

<effect>
Expand Down
6 changes: 4 additions & 2 deletions text_braille_l18n.py
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
#!/usr/bin/env python
# coding=utf-8

__version__ = "0.0.1"

import inkex

def en_char_map(char):
Expand Down Expand Up @@ -105,6 +103,8 @@ def es_char_map(char):
"‰": chr(0x2838) + chr(0x2834) + chr(0x2834), # per mile
"©": chr(0x2823) + chr(0x2828) + chr(0x2809) + chr(0x281c),
"®": chr(0x2823) + chr(0x2828) + chr(0x2817) + chr(0x281c),
"℗": chr(0x2823) + chr(0x2828) + chr(0x280f) + chr(0x281c),
"🄯": chr(0x2823) + chr(0x2828) + chr(0x2807) + chr(0x281c),
"/": chr(0x2820) + chr(0x2802),
"\\": chr(0x2810) + chr(0x2804),
"<": chr(0x2810) + chr(0x2805),
Expand All @@ -131,6 +131,8 @@ def es_char_map(char):
LOCALE_CHARMAPS = {
"en": en_char_map,
"es": es_char_map,
"gl": es_char_map, # Galician uses Spanish alphabet
"eu": es_char_map, # Euskera hasn't accent marks, so use Spanish alphabet
}

class BrailleL18n(inkex.TextExtension):
Expand Down

0 comments on commit 1fdc498

Please sign in to comment.