function DiffFormatter::_block_header

1 call to DiffFormatter::_block_header()
DiffFormatter::_block in drupal/core/lib/Drupal/Component/Diff/DiffEngine.php
1 method overrides DiffFormatter::_block_header()
DrupalDiffFormatter::_block_header in drupal/core/lib/Drupal/Component/Diff/DiffEngine.php

File

drupal/core/lib/Drupal/Component/Diff/DiffEngine.php, line 895
A PHP diff engine for phpwiki. (Taken from phpwiki-1.3.3)

Class

DiffFormatter
A class to format Diffs

Code

function _block_header($xbeg, $xlen, $ybeg, $ylen) {
  if ($xlen > 1) {
    $xbeg .= "," . ($xbeg + $xlen - 1);
  }
  if ($ylen > 1) {
    $ybeg .= "," . ($ybeg + $ylen - 1);
  }
  return $xbeg . ($xlen ? $ylen ? 'c' : 'd' : 'a') . $ybeg;
}