private LineBreaking.IUnjustifiedLine<Printing.IPrintableLine> CreateLine(LineBreaking.ILineConstraint constraint, StartOfParagraph from, IInterletter to, InlineStyle style, out InlineStyle newStyle) { var toIndex = Array.IndexOf(_objectList, to); if (toIndex == -1) throw new ArgumentException("to"); return InlineLayoutEngine.Solve(constraint, from.Glue, _objectList.Take(toIndex), to.GlueBeforeBreak, PenaltyValue(to), _heading, style, out newStyle); }
private LineBreaking.IUnjustifiedLine<Printing.IPrintableLine> CreateLine(LineBreaking.ILineConstraint constraint, StartOfParagraph from, EndOfParagraph to, InlineStyle style, out InlineStyle newStyle) { return InlineLayoutEngine.Solve(constraint, from.Glue, _objectList, to.Glue, PenaltyValue(to), _heading, style, out newStyle); }