void LineBreaker::skipLeadingWhitespace(InlineBidiResolver& resolver, LineInfo& lineInfo, FloatingObject* lastFloatFromPreviousLine, LineWidth& width) { while (!resolver.position().atEnd() && !requiresLineBox(resolver.position(), lineInfo, LeadingWhitespace)) { RenderObject* object = resolver.position().object(); if (object->isOutOfFlowPositioned() && object->style()->isOriginalDisplayInlineType()) { resolver.runs().addRun(createRun(0, 1, object, resolver)); lineInfo.incrementRunsFromLeadingWhitespace(); } resolver.position().increment(&resolver); } resolver.commitExplicitEmbedding(resolver.runs()); }
void LineBreaker::skipLeadingWhitespace(InlineBidiResolver& resolver, LineInfo& lineInfo, LineWidth& width) { while (!resolver.position().atEnd() && !requiresLineBox(resolver.position(), lineInfo, LeadingWhitespace)) { LineLayoutItem lineLayoutItem = resolver.position().getLineLayoutItem(); if (lineLayoutItem.isOutOfFlowPositioned()) { setStaticPositions(m_block, LineLayoutBox(lineLayoutItem), width.indentText()); if (lineLayoutItem.style()->isOriginalDisplayInlineType()) { resolver.runs().addRun(createRun(0, 1, LineLayoutItem(lineLayoutItem), resolver)); lineInfo.incrementRunsFromLeadingWhitespace(); } } else if (lineLayoutItem.isFloating()) { m_block.insertFloatingObject(LineLayoutBox(lineLayoutItem)); m_block.positionNewFloats(&width); } resolver.position().increment(&resolver); } resolver.commitExplicitEmbedding(resolver.runs()); }
void LineBreaker::skipLeadingWhitespace(InlineBidiResolver& resolver, LineInfo& lineInfo, FloatingObject* lastFloatFromPreviousLine, LineWidth& width) { while (!resolver.position().atEnd() && !requiresLineBox(resolver.position(), lineInfo, LeadingWhitespace)) { RenderObject& object = *resolver.position().renderer(); if (object.isOutOfFlowPositioned()) { setStaticPositions(m_block, downcast<RenderBox>(object)); if (object.style().isOriginalDisplayInlineType()) { resolver.runs().addRun(new BidiRun(0, 1, object, resolver.context(), resolver.dir())); lineInfo.incrementRunsFromLeadingWhitespace(); } } else if (object.isFloating()) m_block.positionNewFloatOnLine(m_block.insertFloatingObject(downcast<RenderBox>(object)), lastFloatFromPreviousLine, lineInfo, width); else if (is<RenderCombineText>(object) && object.style().hasTextCombine() && !downcast<RenderCombineText>(object).isCombined()) { downcast<RenderCombineText>(object).combineText(); if (downcast<RenderCombineText>(object).isCombined()) continue; } resolver.increment(); } resolver.commitExplicitEmbedding(); }
void LineBreaker::skipLeadingWhitespace(InlineBidiResolver& resolver, LineInfo& lineInfo, FloatingObject* lastFloatFromPreviousLine, LineWidth& width) { while (!resolver.position().atEnd() && !requiresLineBox(resolver.position(), lineInfo, LeadingWhitespace)) { RenderObject* object = resolver.position().object(); if (object->isOutOfFlowPositioned()) { setStaticPositions(m_block, toRenderBox(object)); if (object->style()->isOriginalDisplayInlineType()) { resolver.runs().addRun(createRun(0, 1, object, resolver)); lineInfo.incrementRunsFromLeadingWhitespace(); } } else if (object->isFloating()) { m_block->positionNewFloatOnLine(m_block->insertFloatingObject(*toRenderBox(object)), lastFloatFromPreviousLine, lineInfo, width); } else if (object->isText() && object->style()->hasTextCombine() && object->isCombineText() && !toRenderCombineText(object)->isCombined()) { toRenderCombineText(object)->combineText(); if (toRenderCombineText(object)->isCombined()) continue; } resolver.position().increment(&resolver); } resolver.commitExplicitEmbedding(resolver.runs()); }