Exemple #1
0
        protected static ITextRange CompareRegions(
            OutlineRegionCollection newRegions,
            OutlineRegionCollection oldRegions, int upperBound)
        {
            TextRangeCollection <OutlineRegion> oldClone = null;
            TextRangeCollection <OutlineRegion> newClone = null;

            if (oldRegions != null)
            {
                oldClone = oldRegions.Clone() as OutlineRegionCollection;
                oldClone.Sort();
            }

            newClone = newRegions.Clone() as OutlineRegionCollection;
            newClone.Sort();

            return(newClone.RangeDifference(oldClone, 0, upperBound));
        }