       hex = "0" + hex if hex.length is 1
       '\\x' + hex
     '"' + escaped.replace('"', '\\"') + '"'
+
+  paste: (event) =>
+    KD.utils.stopDOMEvent event
+    @server.input event.originalEvent.clipboardData.getData "text/plain"
+    @setKeyFocus()

        @setKeyFocus() unless event.ctrlKey or event.metaKey
        @utils.defer =>
          @mousedownHappened = false

    @outputbox.on "drop", (event) =>
      @server.input event.originalEvent.dataTransfer.getData "text/plain"

      tagName   : 'input'
      attributes: type: 'text'
      cssClass  : 'offscreen'
      bind      : 'keydown keyup keypress paste'
      keydown   : @bound 'keyDown'
      keypress  : @bound 'keyPress'
      keyup     : @bound 'keyUp'
    @keyInput.appendToDomBody()
    @keyInput.on "paste", @bound "paste"

    containerView.on 'KDObjectWillBeDestroyed', @keyInput.bound 'destroy'

