- i = 1;
- detectedContraction = TRUE;
- while(spacePointer != NULL) {
- sscanf(spacePointer+1, "%4x", &theValue);
- element->cPoints[i++] = (UChar)theValue;
- spacePointer = strchr(spacePointer+1, ' ');
+ dashPointer = strchr(buffer, '|');
+ if (dashPointer != NULL) {
+ // prefix characters
+ element->prefixChars[0] = (UChar)theValue;
+ element->prefixSize = 1;
+ element->prefix = element->prefixChars;
+ sscanf(dashPointer+1, "%4x", &theValue);
+ element->cPoints[0] = (UChar)theValue;
+ element->cSize = 1;
+ }
+ else {
+ // Contractions or surrogate characters.
+ i = 1;
+ detectedContraction = TRUE;
+ while(spacePointer != NULL) {
+ sscanf(spacePointer+1, "%4x", &theValue);
+ element->cPoints[i++] = (UChar)theValue;
+ spacePointer = strchr(spacePointer+1, ' ');
+ }
+ element->cSize = i;