void getRows(ref FlowRowElement parentElement, IHaveChild block) { FlowRow currentRow = new FlowRow(); foreach (PrintElementBase current in block.Childs) { FlowRowElement currentRowElement = new FlowRowElement(current); if (current is LineBreak) { parentElement.ChildsRows.Add(currentRow); currentRow = new FlowRow(); currentRow.Elements.Add(currentRowElement); parentElement.ChildsRows.Add(currentRow); currentRow = new FlowRow(); } else { currentRow.Elements.Add(currentRowElement); if (current is IHaveChild) { getRows(ref currentRowElement, (IHaveChild)current); } } } }
private Rect getRowBounds(FlowRow row) { foreach (FlowRowElement element in row.Elements) { Rect rectElement = GetRect(element.Element); foreach (FlowRow childRow in element.ChildsRows) { Rect rect = getRowBounds(childRow); rectElement.Extend(rectElement); } } return(Rect.Empty); }
private Rect getRowBounds(FlowRow row) { foreach (FlowRowElement element in row.Elements) { Rect rectElement = GetRect(element.Element); foreach (FlowRow childRow in element.ChildsRows) { Rect rect = getRowBounds(childRow); rectElement.Extend(rectElement); } } return Rect.Empty; }
internal void SetOwnerRow(FlowRow owner) { _OwnerRow = owner; }