private void _CombinePass() { if (_fixedSOMPage.SemanticBoxes.Count < 2) { //Nothing to do return; } int prevBoxCount; do { prevBoxCount = _fixedSOMPage.SemanticBoxes.Count; List <FixedSOMSemanticBox> boxes = _fixedSOMPage.SemanticBoxes; for (int i = 0; i < boxes.Count; i++) { FixedSOMTable table1 = boxes[i] as FixedSOMTable; if (table1 != null) { //Check for nested tables for (int j = i + 1; j < boxes.Count; j++) { FixedSOMTable table2 = boxes[j] as FixedSOMTable; if (table2 != null && table1.AddContainer(table2)) { boxes.Remove(table2); } } continue; } FixedSOMFixedBlock box1 = boxes[i] as FixedSOMFixedBlock; if (box1 == null || box1.IsFloatingImage) { continue; } for (int j = i + 1; j < boxes.Count; j++) { FixedSOMFixedBlock box2 = boxes[j] as FixedSOMFixedBlock; if (box2 != null && !box2.IsFloatingImage && box2.Matrix.Equals(box1.Matrix) && (_IsSpatiallyCombinable(box1, box2, 0, 0))) { { box1.CombineWith(box2); boxes.Remove(box2); } } } } } while (_fixedSOMPage.SemanticBoxes.Count > 1 && _fixedSOMPage.SemanticBoxes.Count != prevBoxCount); }
// Token: 0x06002E01 RID: 11777 RVA: 0x000CF564 File Offset: 0x000CD764 private void _CombinePass() { if (this._fixedSOMPage.SemanticBoxes.Count < 2) { return; } int count; do { count = this._fixedSOMPage.SemanticBoxes.Count; List <FixedSOMSemanticBox> semanticBoxes = this._fixedSOMPage.SemanticBoxes; for (int i = 0; i < semanticBoxes.Count; i++) { FixedSOMTable fixedSOMTable = semanticBoxes[i] as FixedSOMTable; if (fixedSOMTable != null) { for (int j = i + 1; j < semanticBoxes.Count; j++) { FixedSOMTable fixedSOMTable2 = semanticBoxes[j] as FixedSOMTable; if (fixedSOMTable2 != null && fixedSOMTable.AddContainer(fixedSOMTable2)) { semanticBoxes.Remove(fixedSOMTable2); } } } else { FixedSOMFixedBlock fixedSOMFixedBlock = semanticBoxes[i] as FixedSOMFixedBlock; if (fixedSOMFixedBlock != null && !fixedSOMFixedBlock.IsFloatingImage) { for (int k = i + 1; k < semanticBoxes.Count; k++) { FixedSOMFixedBlock fixedSOMFixedBlock2 = semanticBoxes[k] as FixedSOMFixedBlock; if (fixedSOMFixedBlock2 != null && !fixedSOMFixedBlock2.IsFloatingImage && fixedSOMFixedBlock2.Matrix.Equals(fixedSOMFixedBlock.Matrix) && this._IsSpatiallyCombinable(fixedSOMFixedBlock, fixedSOMFixedBlock2, 0.0, 0.0)) { fixedSOMFixedBlock.CombineWith(fixedSOMFixedBlock2); semanticBoxes.Remove(fixedSOMFixedBlock2); } } } } } }while (this._fixedSOMPage.SemanticBoxes.Count > 1 && this._fixedSOMPage.SemanticBoxes.Count != count); }