anchor.diff:      override x.IsValidInContext(context) =
           context :? FsiDocumentContext
   
  +    /// hacks to work with fake prompt
       override x.KeyPress (descriptor:KeyDescriptor) =
           match FSharpInteractivePad.Fsi with
           | Some fsi -> 
  
positive.code: 
              let line = IdeApp.Workbench.ActiveDocument.Editor.CaretLine
              let text = IdeApp.Workbench.ActiveDocument.Editor.GetLineText(line)
              //let file = IdeApp.Workbench.ActiveDocument.FileName
              //let sel = String.Format("{2};;", line, file.FullPath, text)
              x.SendCommand (text + ";;")
              //advance to the next line
              if PropertyService.Get ("FSharpBinding.AdvanceToNextLine", true)
              then IdeApp.Workbench.ActiveDocument.Editor.SetCaretLocation (line + 1, Mono.TextEditor.DocumentLocation.MinColumn, false)
  
negative.code:             |> editor.GetLineText
          getLineWithoutPrompt lineStr
  
      let setCaretLine s =
          let line = editor.GetLineByOffset editor.CaretOffset
          editor.ReplaceText(line.Offset, line.EndOffset - line.Offset, prompt + s)
  
      
      let resetFsi intent =
          killIntent <- intent
          session |> Option.iter (fun ses -> ses.Kill())
          if intent = Restart then session <- setupSession()
  
      member x.SendText s = 
          editor.InsertAtCaret s
          x.SendCommand (s + ";;")
  
      member x.Session = session
      member x.Shutdown()  =
  