}
// found the end of a text chunck
int chunkEndIndex = aci.getIndex();
AttributedCharacterIterator chunkACI =
new AttributedCharacterSpanIterator
(aci, chunkStartIndex, chunkEndIndex);
// need to setIndex because creating the new ACI,
// looses the current index.
aci.setIndex(chunkEndIndex);
aciVector.add(chunkACI);