int end= fRememberedPosition == null ? -1 : fRememberedPosition.getOffset() + fRememberedPosition.getLength();
if (endOffset < end && end < d.getLength())
partition= getPartition(d, end);
//if there is not damager for the partition then use the endOffset of the partition
IPresentationDamager damager= getDamager(partition.getType());
if (damager != null) {
IRegion r= damager.getDamageRegion(partition, e, fDocumentPartitioningChanged);
endOffset = r.getOffset() + r.getLength();
}
return endOffset;
}