anchor.diff:    Ed1.Strings.EncodingDetectDefaultUtf8:= UiOps.DefaultEncUtf8;
   
     EncodingName:= AppEncodingShortnameToFullname(UiOps.NewdocEnc);
  -  Lexer:= AppManager.FindLexerByName(UiOps.NewdocLexer);
  +  LexerName:= UiOps.NewdocLexer;
   
     FNotif:= TATFileNotif.Create(Self);
     FNotif.Timer.Interval:= 1000;
  
positive.code: 
  procedure TEditorFrame.DoSaveHistoryEx(c: TJsonConfig; const path: string);
  var
    lexname: string;
    caret: TATCaretItem;
    items, items2: TStringList;
    bookmark: TATBookmarkItem;
    i: integer;
  begin
    if Lexer=nil then
      lexname:= ''
    else
      lexname:= Lexer.LexerName;
  
    c.SetValue(path+cHistory_Lexer, lexname);
    c.SetValue(path+cHistory_Enc, EncodingName);
    c.SetValue(path+cHistory_Top, Editor.LineTop);
    c.SetValue(path+cHistory_Wrap, Ord(Editor.OptWrapMode));
  
negative.code:   if Editor.Strings.Count=0 then exit;
  
    //restore props
    //LexerName:= PrevLexer;
    PrevCaretY:= Min(PrevCaretY, Editor.Strings.Count-1);
    if PrevTail then
    begin
  