Iterator cIt = row.cellIterator();
while(cIt.hasNext()) {
HSSFCell cell = (HSSFCell)cIt.next();
if(cell.getCellType() == HSSFCell.CELL_TYPE_STRING) {
HSSFRichTextString rtr = cell.getRichStringCellValue();
UnicodeString u = rtr.getRawUnicodeString();
// Have we done this string already?
if(! doneUnicodeStrings.contains(u)) {
// Update for each new position
for(short i=5; i<newPos.length; i++) {
if(i != newPos[i]) {
u.swapFontUse(i, newPos[i]);
}
}
// Mark as done
doneUnicodeStrings.add(u);