Character entities

Some characters are represented by character entities (which can be compared to Java escape sequences) either because the characters are reserved, or because of the matching key in the keyboard.

A character entity is represented either by its Unicode numeric value or by a verbal symbol. For instance, the character > (greater than) which is reserved for HTML tags is represented either by > (its Unicode value) or by > (gt is the symbol assigned to this character).

HTMLComponent translates any numeric value and displays the according character (of course depending on its availability in the font used). As for symbols, it supports all the standard ISO 8859-1 symbols (up until Unicode value of 255) and does not recognise symbols with Unicode value greater than 255, except 2 very common symbols — euro and bull (bullet).

If you need support for upper symbols, they can be added using the static methods addCharEntity and addCharEntitiesRange. For example:

HTMLComponent.addCharEntity("spades",9824);