anchor.diff:  begin
     inherited HandleLMouseDown(x, y, shiftstate);
   
  -  cp := CursorPosToCharPos(x, y);
  +  cp := PointToCharPos(x, y);
   
     FMouseDragPos := cp;
     FCursorPos    := cp;
  +  AdjustVisibleText;
   
     if (ssShift in shiftstate) then
       FSelOffset := FCursorPos - FSelStart
  
positive.code:   if (btnstate and MOUSE_LEFT) = 0 then
      Exit;
      
    cp := CursorPosToCharPos(x, y);
  
    //FMouseDragPos := cp;
    FSelOffset := cp - FSelStart;
    if FCursorPos <> cp then
    begin
      FCursorPos := cp;
      AdjustCursor;
      Repaint;
    end;
  end;
  
negative.code:   end;
  end;
  
  procedure TfpgCustomEdit.HandleResize(awidth, aheight: TfpgCoord);
  begin
    inherited HandleResize(awidth, aheight);
    AdjustVisibleText;
  end;
  
  procedure TfpgCustomEdit.HandleKeyChar(var AText: TfpgChar;
    var shiftstate: TShiftState; var consumed: Boolean);
  var
  