Merge branch 'master' of git.timshomepage.net:tutorials/php-kilo
This commit is contained in:
commit
deaed33b90
@ -348,6 +348,17 @@ class Editor {
|
||||
}
|
||||
}
|
||||
|
||||
protected function rowInsertChar(Row $row, int $at, string $c)
|
||||
{
|
||||
if ($at < 0 || $at > $row->size)
|
||||
{
|
||||
$at = $row->size;
|
||||
}
|
||||
|
||||
$row->chars[$at] = $c;
|
||||
$this->updateRow($row);
|
||||
}
|
||||
|
||||
// ------------------------------------------------------------------------
|
||||
// ! File I/O
|
||||
// ------------------------------------------------------------------------
|
||||
|
Loading…
Reference in New Issue
Block a user