anchor.diff:    IdControl: integer;
     Data: PPyObject;
   begin
  -  with GetPythonEngine do
  -  begin
  -    Data:= PyTuple_New(2);
  -    PyTuple_SetItem(Data, 0, PyInt_FromLong(Key));
  -    PyTuple_SetItem(Data, 1, PyString_FromString(PChar(ConvertShiftStateToString(Shift))));
  -  end;
  -
  -  Props:= TAppControlProps((Sender as TControl).Tag);
  -  IdControl:= FindControlIndexByOurObject(Sender);
  -  if DoEvent(IdControl, Props.FEventOnEditorKeyUp, Data)
  -    {
  -    Format('(%d, "%s")', [Key, ConvertShiftStateToString(Shift)])
  -    }
  -    = cPyFalse then
  -   Key:= 0;
  +  Props:= TAppControlProps((Sender as TControl).Tag);
  +  IdControl:= FindControlIndexByOurObject(Sender);
  +  Data:= Py_KeyAndShift(Key, Shift);
  +  if DoEvent(IdControl, Props.FEventOnEditorKeyUp, Data) = cPyFalse then
  +    Key:= 0;
   end;
   
   
  
positive.code:   DoEvent(IdControl, Props.FEventOnEditorCaret, nil);
  end;
  
  
  procedure TFormDummy.DoOnEditorKeyDown(Sender: TObject; var Key: Word; Shift: TShiftState);
  var
  
negative.code:   IdControl: integer;
    Data: PPyObject;
  begin
    Props:= TAppControlProps((Sender as TControl).Tag);
    IdControl:= FindControlIndexByOurObject(Sender);
    Data:= Py_KeyAndShift(Key, Shift);
    if DoEvent(IdControl, Props.FEventOnEditorKeyDown, Data) = cPyFalse then
      Key:= 0;
  end;
  
  procedure TFormDummy.DoOnEditorKeyUp(Sender: TObject; var Key: Word; Shift: TShiftState);
  