code: function () {
        var range = this.el.ownerDocument.getSelection().getRangeAt(0).cloneRange();
        var wrapperNode = range.endContainer.parentNode;
        var node = this.el.ownerDocument.createElement('span');
        range.insertNode(node);
        range.selectNodeContents(node);
        range.deleteContents();
        setTimeout(function() { wrapperNode.normalize(); }, 0);
        var $node = $(node);
        var position = $node.offset();
        position.left -= this.$el.offset().left;
        position.top += $node.height() - this.$el.offset().top;
        position.lineHeight = $node.height();
        
        // special positioning logic for iframes
        // this is typically used for contenteditables such as tinymce or ckeditor
        if (this.completer.$iframe) {
          var iframePosition = this.completer.$iframe.offset();
          position.top += iframePosition.top;
          position.left += iframePosition.left;
          // We need to get the scrollTop of the html-element inside the iframe and not of the body-element,
          // because on IE the scrollTop of the body-element (this.$el) is always zero.
          position.top -= $(this.completer.$iframe[0].contentWindow.document).scrollTop();
        }
        
        $node.remove();
        return position;
      }
docs: Returns the caret's relative position from the contenteditable's left top corner.  Examples  this._getCaretRelativePosition() //=> { top: 18, left: 200, lineHeight: 16 }  Dropdown's position will be decided using the result.