anchor.diff:          begin
             Buffer[0] := Chr;
             Result := 1;
  +          break;
           end;
   
         {two byte codes / 94 character sets}
         bjsX0208_1978,
         bjsX0208_1983:
  +      begin
           Result := GetAsShiftJis(Chr, GetNext, Buffer);
  +        break;
  +      end;
       end;
     end;
   end;
  
positive.code: 
  //-- BG ---------------------------------------------------------- 14.12.2010 --
  procedure TBuffer.DetectCodePage;
  
    function IsIso2022JP: boolean;
    {look for iso-2022-jp Japanese file}
    const
      EscSequence: array [0..3] of AnsiString = (
        #$1b'$@', #$1b'$B', #$1b'(J', #$1b'(B');
    var
      DocS: AnsiString;
      I, J, K, L: integer;
    begin
      Result := False;
      DocS := FPos.AnsiChr;
      I := AnsiPos(EscSequence[0], DocS); {look for starting sequence}
      J := AnsiPos(EscSequence[1], DocS);
      I := Max(I, J); {pick a positive value}
      if I > 0 then
      begin {now look for ending sequence after the start}
        K := AnsiPosX(EscSequence[2], DocS, I);
        L := AnsiPosX(EscSequence[3], DocS, I);
        K := Max(K, L); {pick a positive value}
        if K > 0 then {start and end sequence found}
          Result := True;
      end;
    end;
  
  var
    ByteCount: Integer;
  begin
    ByteCount := FEnd.AnsiChr - FPos.AnsiChr;
    if ByteCount >= 2 then
  
negative.code:       if FPos.AnsiChr < FEnd.AnsiChr then
        begin
          Len := GetNextEucAsShiftJis(Buffer2);
          MultiByteToWideChar(932, 0, PAnsiChar(@Buffer2[0]), Len, @Result, 1);
        end
        else
          Result := TBuffChar(0);
  