Adjust the ending position of current EM and STRONG spans

@return void
774633
protected function adjustEndingPositions()
	{
		if ($this->closeEm && $this->closeStrong)
		{
			if ($this->emPos < $this->strongPos)
			{
				$this->emEndPos += 2;
			}
			else
			{
				++$this->strongEndPos;
			}
		}
	}
633468
function handleTag_br() {
    $this->out("  \n".$this->indent, true);
    $this->parser->html = ltrim($this->parser->html);
  }
891529
private function _closeStart()
    {
        if ($this->name === 'blank') {
            return;
        }

        if ($this->isSelfclosing()) {
            echo str_replace(':name', $this->realName, $this->brackets['close_short']);
            $this->_closed = true;
            $this->doCallback('closed');
            $this->destroy();
            if (!$this->hasOption('inline')) {
                Generator::lineBreak();
            }
            $this->_contentPrinted = true;
        } else {
            echo str_replace(':name', $this->realName, $this->brackets['close_start']);
            $this->doCallback('opened');
            if (!$this->inlineInner && !$this->hasOption('inline')) {
                Config::set('tabs', '++');
                Generator::lineBreak();
            }
        }
    }
948274
def end_span
      return unless (span = current_spans.pop)

      span.done

      enqueue.call span

      span
    end
40638
protected function closeSpans()
	{
		if ($this->closeEm)
		{
			--$this->remaining;
			$this->parser->addTagPair('EM', $this->emPos, 1, $this->emEndPos, 1);
			$this->emPos = null;
		}
		if ($this->closeStrong)
		{
			$this->remaining -= 2;
			$this->parser->addTagPair('STRONG', $this->strongPos, 2, $this->strongEndPos, 2);
			$this->strongPos = null;
		}
	}
397471
public function end()
    {
        $html = Html::endTag(ArrayHelper::keyExists('tag', $this->options) ? $this->options['tag'] : 'div');
        $this->form->afterFieldRender($this);

        return $html;
    }
19350
public function setLineEnd($value)
    {
        $this->_validateInt('LineEnd', $value);

        if ($this->data['line_end'] === $value) {
            return;
        }

        $this->data['line_end'] = $value;

        $this->_setModified('line_end');
    }
738506
public function endBodyToolbar()
    {
        $this->_setBeginning(false);
        $toolbar = trim(ob_get_clean());
        if (is_string($this->bodyToolbar)) {
            $this->bodyToolbar = [$this->bodyToolbar];
        }
        $this->bodyToolbar[] = [
            'body' => $toolbar,
            'options' => $this->_bodyToolbarLastOptions,
        ];
        $this->_bodyToolbarLastOptions = [];
    }
70130
protected function linkBlocks()
	{
		$ends = array();

		$elements = $this->elements;

		$result = array();
		while ($element = array_pop($elements)) {

			if ($element instanceof Abstraction\SupraMarkupBlockStart) {

				/* @var $end Abstraction\SupraMarkupBlockEnd */
				$end = array_pop($ends);


				// Check if we hava a matching end for this start and check if their signature match,
				// or skip this check if truncation of invalid blocks is disabled.
				if (
						( ! empty($end) && $end->getSignature() == $element->getSignature() ) ||
						$this->truncateInvalidBlocks == false
				) {
					
					$end->setStart($element);
					$element->setEnd($end);

					array_unshift($result, $element);
				}
			}
			else if ($element instanceof Abstraction\SupraMarkupBlockEnd) {

				array_unshift($result, $element);
				$ends[] = $element;
			}
			else {
				array_unshift($result, $element);
			}
		}

		$this->elements = $result;
	}
1183573
public function on_workshop_elements_end() {
        // give the strategy hanlders last chance to write what they need
        $handler = $this->get_strategy_handler($this->currentworkshop['strategy']);
        $handler->on_elements_end();

        // close the dimensions definition
        $this->xmlwriter->end_tag('subplugin_workshopform_'.$this->currentworkshop['strategy'].'_workshop');

        // as a temporary hack, we just write empty wrappers for the rest of data
        $this->write_xml('examplesubmissions', array());
        $this->write_xml('submissions', array());
        $this->write_xml('aggregations', array());
    }
1015552
function() {

        //update the padding
        this.padding = this.positionBlocks[this.relativePosition].padding;

        //update the position of our close box to new padding
        if (this.closeDiv) {
            // use the content div's css padding to determine if we should
            //  padd the close div
            var contentDivPadding = this.getContentDivPadding();

            this.closeDiv.style.right = contentDivPadding.right + 
                                        this.padding.right + "px";
            this.closeDiv.style.top = contentDivPadding.top + 
                                      this.padding.top + "px";
        }

        this.updateBlocks();
    }
958975
public function end() {
		list(, $options, $template) = $this->_defaults(__FUNCTION__, null, []);
		$params = compact('options', 'template');

		$result = Filters::run($this, __FUNCTION__, $params, function($params) {
			$this->_bindingOptions = [];
			return $this->_render('end', $params['template'], []);
		});
		unset($this->_binding);
		$this->_binding = null;
		return $result;
	}
553273
protected function handleTag_li()
    {
        if ($this->parent() == 'ol') {
            $parent =& $this->getStacked('ol');
            if ($this->parser->isStartTag) {
                $parent['num']++;
                $this->out(str_repeat(' ', 3 - strlen($parent['num'])) . $parent['num'] . '. ', true);
            }
        } else {
            if ($this->parser->isStartTag) {
                $this->out('  * ', true);
            }
        }
        $this->indent('    ', false);
        if (!$this->parser->isStartTag) {
            $this->setLineBreaks(1);
        }
    }
66746
def end_element(self, name):
        """"""
        self.in_tag = False
        if name == self.tag:
            self.add_url()
732822
function()
		{
			var startNode = this.startContainer,
				endNode = this.endContainer;

			if ( startNode.is && startNode.is( 'span' )
				&& startNode.data( 'cke-bookmark' ) )
				this.setStartAt( startNode, CKEDITOR.POSITION_BEFORE_START );
			if ( endNode && endNode.is && endNode.is( 'span' )
				&& endNode.data( 'cke-bookmark' ) )
				this.setEndAt( endNode,  CKEDITOR.POSITION_AFTER_END );
		}
1154297
public function end(): void
    {
        $this->current = $this->tail->prev();
        $this->offset = $this->count - 1;
    }
197651
protected function _collapse_margins() {
    $frame = $this->_frame;
    $cb = $frame->get_containing_block();
    $style = $frame->get_style();
    
    if ( !$frame->is_in_flow() ) {
      return;
    }

    $t = $style->length_in_pt($style->margin_top, $cb["h"]);
    $b = $style->length_in_pt($style->margin_bottom, $cb["h"]);

    // Handle 'auto' values
    if ( $t === "auto" ) {
      $style->margin_top = "0pt";
      $t = 0;
    }

    if ( $b === "auto" ) {
      $style->margin_bottom = "0pt";
      $b = 0;
    }

    // Collapse vertical margins:
    $n = $frame->get_next_sibling();
    if ( $n && !$n->is_block() ) {
      while ( $n = $n->get_next_sibling() ) {
        if ( $n->is_block() ) {
          break;
        }
        
        if ( !$n->get_first_child() ) {
          $n = null;
          break;
        }
      }
    }
    
    if ( $n ) {
      $n_style = $n->get_style();
      $b = max($b, $n_style->length_in_pt($n_style->margin_top, $cb["h"]));
      $n_style->margin_top = "0pt";
      $style->margin_bottom = $b."pt";
    }

    // Collapse our first child's margin
    /*$f = $this->_frame->get_first_child();
    if ( $f && !$f->is_block() ) {
      while ( $f = $f->get_next_sibling() ) {
        if ( $f->is_block() ) {
          break;
        }
        
        if ( !$f->get_first_child() ) {
          $f = null;
          break;
        }
      }
    }

    // Margin are collapsed only between block elements
    if ( $f ) {
      $f_style = $f->get_style();
      $t = max($t, $f_style->length_in_pt($f_style->margin_top, $cb["h"]));
      $style->margin_top = $t."pt";
      $f_style->margin_bottom = "0pt";
    }*/
  }