Add a new symbol to alphabet

  • 637 Views
  • Last Post 14 January 2016
Andrei posted this 05 January 2016

I am trying to add a new symbol to punctuation

ILanguageDatabase languageDB = engine.CreateLanguageDatabase();
ITextLanguage textLanguage = languageDB.CreateCompoundTextLanguage("English");
String punctuation = textLanguage.getLetterSet(TextLanguageLetterSetEnum.TLLS_InterwordPunctuators);
log.info("Original punctuation = " + punctuation);
String newPunctuation = punctuation + "₡";
textLanguage.setLetterSet(TextLanguageLetterSetEnum.TLLS_InterwordPunctuators, newPunctuation);
log.info("New  punctuation = " + punctuation);

Output

Original punctuation = !"#$%&'()*+,-./:;<=>?[]_{}£¥§©«°»—’“”„•€■□▲△►▻▼▽◄◅◊◎◦★☆♦✓❖
New punctuation = !"#$%&'()*+,-./:;<=>?[]_{}£¥§©«°»—’“”„•

Why last symbols was deleted after update? And how can I set a custom symbol correctly?

The same issue if I am trying to set a new character to BaseLanguage

String alphabet = language.getLetterSet(BaseLanguageLetterSetEnum.BLLS_Alphabet);
log.debug("Original Alphabet: {}", alphabet);
String newAlphabet = alphabet + "₡");
language.setLetterSet(BaseLanguageLetterSetEnum.BLLS_Alphabet, newAlphabet);
log.debug("New alphabet : {}", language.getLetterSet(BaseLanguageLetterSetEnum.BLLS_Alphabet));

Output

Original Alphabet: '-.ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz’
New Alphabet: '-.ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz

Andrei posted this 14 January 2016

The problem was fixed by updating to FRE11.1.9

Close