1
0
mirror of https://github.com/dschmenk/PLASMA.git synced 2025-01-25 11:30:04 +00:00

Add optional goto line number to command line load filename

This commit is contained in:
David Schmenk 2019-12-19 20:42:37 -08:00
parent af90f40f32
commit 8df7cea4a0

View File

@ -430,6 +430,7 @@ def readtxt(filename, startline)#0
numlines++
fin
fin
putln
end
def writetxt(filename)#0
byte txtbuf[81], refnum
@ -456,6 +457,7 @@ def writetxt(filename)#0
if !(i & $0F); putc('.'); fin
next
fileio:close(refnum)
putln
end
//
// Screen routines
@ -1713,6 +1715,14 @@ if ^arg
strcpy(@filename, arg)
puts(@filename)
readtxt(@filename, 0)
arg = argNext(arg)
if ^arg
cursrow = strtonum(arg)
if cursrow
curshpos(0)
cursvpos(cursrow - 1)
fin
fin
fin
curschr = '+'
flags = flags | insmode | gutter