BOX Grammar
[1] BOX ::= Encoding Node*
[2] Encoding ::= 'A' | 'U'
'A' for ASCII, 'U' for UTF-8
[3] Node ::= (TypeCode TextSpec) | (TypeCodePlus Index)
1st option if first time the text is encountered; 2nd option otherwise
[4] TypeCode ::= 0 | 10 | ... | 90
See this for meaning of the values.
[5] TypeCodePlus ::= TypeCode plus IndexLength
[6] IndexLength ::= 1 | 2 | 4
[7] TextSpec ::= Length Text
[8] Length ::= a two byte integer
[9] Text ::= ASCII or UTF-8 text
[10] Index ::= a one, two or four-byte integer