Insert command by replacing the current input buffer and display it on the text edit.
483244
def _insert_command(self, command):
        
        self._clear_user_buffer()
        tc = self.edit.textCursor()
        tc.insertText(command)
        self.edit.setTextCursor(tc)
932320
def enter_command_mode(self):
        
        self.application.layout.focus(self.command_buffer)
        self.application.vi_state.input_mode = InputMode.INSERT

        self.previewer.save()
1219184
def insertFromMimeData(self, source):
        
        lines = projex.text.nativestring(source.text()).splitlines()
        for i in range(1, len(lines)):
            if not lines[i].startswith('... '):
                lines[i] = '... ' + lines[i]
        
        if len(lines) > 1:
            lines.append('... ')
        
        self.insertPlainText('\n'.join(lines))
83809
public MultiChangeBuilder<PS, SEG, S> insertText(int position, String text) {
        return replaceText(position, position, text);
    }
1249515
def insert(self, s):
        '''
        
        '''
        for c in s:
            self.text.insert(self.cursor_loc, c)
            self.cursor_loc += 1
1311153
def _insert(self, bs, pos):
        """"""
        assert 0 <= pos <= self.len
        if pos > self.len // 2:
            # Inserting nearer end, so cut off end.
            end = self._slice(pos, self.len)
            self._truncateend(self.len - pos)
            self._append(bs)
            self._append(end)
        else:
            # Inserting nearer start, so cut off start.
            start = self._slice(0, pos)
            self._truncatestart(pos)
            self._prepend(bs)
            self._prepend(start)
        try:
            self._pos = pos + bs.len
        except AttributeError:
            pass
        assert self._assertsanity()
1185227
def _readline_insert(self, char, echo, insptr, line):
        """"""
        if not self._readline_do_echo(echo):
            return
        # Write out the remainder of the line
        self.write(char + ''.join(line[insptr:]))
        # Cursor Left to the current insert point
        char_count = len(line) - insptr
        self.write(self.CODES['CSRLEFT'] * char_count)
61444
public void insertNewRow() {

        // reset all fields
        for (int i = 0; i < komponente.length; i++) {
            komponente[i].clearContent();
        }    // end of for (int i=0; i<komponente.length; i++)

        // reset the field for the primary keys
        for (int i = 0; i < primaryKeys.length; i++) {
            komponente[pkColIndex[i]].setEditable(true);
        }

        ZaurusEditor.printStatus("enter a new row for table " + tableName);
    }
380295
public synchronized void insert_cmd(String cmd,String host)
	{

//
// Insert elt in the box
//

		box[insert_elt].req_type = Req_Operation;
		box[insert_elt].attr_type = Attr_Unknown;
		box[insert_elt].op_type = Op_Command_inout;
		box[insert_elt].cmd_name = cmd;
		box[insert_elt].host = host;
		box[insert_elt].when = new Date();
	
//
// manage insert and read indexes
//

		inc_indexes();
	}
431257
def insertPreviousCommand(self):
        
        self._currentHistoryIndex -= 1
        if 0 <= self._currentHistoryIndex < len(self._history):
            cmd = self._history[self._currentHistoryIndex]
        else:
            cmd = '>>> '
            self._currentHistoryIndex = len(self._history)
        
        self.replaceCommand(cmd)
609496
def _put_input(self, input_source: str) -> None:
        """"""
        input_cmd = shlex.split(str(input_source))
        if len(input_cmd) > 1:
            self._argv.extend(input_cmd)
        else:
            self._argv.extend(["-i", input_source])
1323426
def self_insert(self, e): # (a, b, A, 1, !, ...)
         """
        if e.char and ord(e.char)!=0: #don't insert null character in buffer, can happen with dead keys.
            self.insert_text(e.char)
        self.finalize()
769622
def do_edit(self, args: argparse.Namespace) -> None:
        """"""
        if not self.editor:
            raise EnvironmentError("Please use 'set editor' to specify your text editing program of choice.")

        command = utils.quote_string_if_needed(os.path.expanduser(self.editor))
        if args.file_path:
            command += " " + utils.quote_string_if_needed(os.path.expanduser(args.file_path))

        self.do_shell(command)
236528
function insert(str, key, valu) {
    const re = new RegExp("\\$\\{" + key + "\\}", 'g');
    return str.replace(re, valu);
  }
411916
private void insert(String binding) {
		currentInput.insert(cursorPos, binding);
		cursorPos += binding.length();

		// reset view
		resetMainPart();
	}
1370517
def OnReplace(self, event):
        """"""

        find_string = event.GetFindString()
        flags = self._wxflag2flag(event.GetFlags())
        replace_string = event.GetReplaceString()

        gridpos = list(self.grid.actions.cursor)

        findpos = self.grid.actions.find(gridpos, find_string, flags,
                                         search_result=False)

        if findpos is None:
            statustext = _(u"'{find_string}' not found.")
            statustext = statustext.format(find_string=find_string)

        else:
            with undo.group(_("Replace")):
                self.grid.actions.replace(findpos, find_string, replace_string)
            self.grid.actions.cursor = findpos

            # Update statusbar
            statustext = _(u"Replaced '{find_string}' in cell {key} with "
                           u"{replace_string}.")
            statustext = statustext.format(find_string=find_string,
                                           key=findpos,
                                           replace_string=replace_string)

        post_command_event(self.grid.main_window, self.grid.StatusBarMsg,
                           text=statustext)

        event.Skip()
281939
def __insert(self):
        
        if len(self.__buffer) > 0:
            # Insert data
            statement = self.__table.insert()
            if self.__autoincrement:
                statement = statement.returning(
                    getattr(self.__table.c, self.__autoincrement))
                statement = statement.values(self.__buffer)
                res = statement.execute()
                for id, in res:
                    row = self.__buffer.pop(0)
                    yield WrittenRow(row, False, id)
            else:
                statement.execute(self.__buffer)
                for row in self.__buffer:
                    yield WrittenRow(row, False, None)
            # Clean memory
            self.__buffer = []