mirror of
https://github.com/curioustorvald/tsvm.git
synced 2026-03-07 19:51:51 +09:00
edit.js to shitty newline
This commit is contained in:
@@ -217,6 +217,16 @@ function appendText(code) {
|
||||
gotoText();
|
||||
}
|
||||
|
||||
function appendLine() {
|
||||
textbuffer.push("");
|
||||
cursorRow += 1;
|
||||
cursorCol = 0;
|
||||
drawLnCol();
|
||||
gotoText();
|
||||
|
||||
// TODO touch screen scroll vars
|
||||
}
|
||||
|
||||
reset_status();
|
||||
drawMain();
|
||||
drawTextbuffer();
|
||||
@@ -238,6 +248,11 @@ while (!exit) {
|
||||
writeout();
|
||||
displayBulletin(`Wrote ${textbuffer.length} lines`);
|
||||
}
|
||||
else if (key == 8) { // Bksp
|
||||
}
|
||||
else if (key == 13) { // Return / ^M
|
||||
appendLine();
|
||||
}
|
||||
else if (key >= 32) { // printables (excludes \n)
|
||||
if (bulletinShown) {
|
||||
dismissBulletin();
|
||||
|
||||
Reference in New Issue
Block a user