home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Frozen Fish 2: PC
/
frozenfish_august_1995.bin
/
bbs
/
d07xx
/
d0770.lha
/
Uedit
/
Jenkins.LZH
/
config!F
< prev
next >
Wrap
Text File
|
1992-01-06
|
26KB
|
755 lines
config!F
------------------------------------------------------------------------------
Commands for loading, saving, and closing files
==== FILE REQUESTER ====
..<alt-z: Choose from device list or type in directoryPath, get directory listing
..<virtual-y: Get listing using dirpath in buf61
..<virtual-buttonDown: Mark region clicked with mouse
..<ctl-buttonDown: Load file or select directory that is ctl-clicked.
..====clicked in dir file, if <REDO> redo listing
..====clicked in dir file, if <PARENT> get new listing
..====clicked in dir file, if <MAKEDIR> make directory
..====clicked in dir file, form dirpath/name
..<shftCtl-buttonDown: Rename file or directory that is shftCtl-clicked
..<altCtl-buttonDown: Delete file that is altCtl-clicked
..<virtual-x: Clicked name to buf62, add to path taken from file name, delete "dir ", show
==== FILE OPEN & LOAD ====
..<ctl-f1: Open "Empty" file
..<alt-n: Rename the file in the window
..<alt-f1: Load a file
..<shftAlt-f5: Convert file to read-only status
..<shftCtl-f1: Restore current file to original
..<shftAlt-f1: Insert file at cursor
..<shftAlt-m: Map illegal ASCII (0 thru 3) characters to safe 128-131
==== FILE SAVE & CLOSE ====
..<normal-f2: Save (ask if not changed) file currently in window
..<altCtl-i: Make icons: Toggle. When "on", Workbench icons are created
..<shft-f2: Save file under different name
..<alt-f2: Save (ask) all changed files
..<shftCtl-f2: Save hilite as...
..<shftAltCtl-i: Idle-timer: Enter value (tenths of sec) after which idle command executed
..<ctl-f2: Idle: Turn on/off saving changes during idle periods
..<idle: Save changed files during idle periods, if their idle-save flag is set
..<shftAltCtl-f2: Backup: toggle auto-backup mode
..<altCtl-f2: ReBAK: Save and restore to reset internal backedUp flag
..<normal-closeBox: Save (ask) if changed
..<normal-f3: Save (ask) if changed
..<shft-f3: Save if changed, then close
==== SWITCH, SWAP, SCAN ====
..<alt-f: Favorite: toggle
..<normal-gadget2: Switch to next favorite document
..====Switch to next file via normal-gadget1 and shft-gadget1 are in config!E
..<normal-f1: Switch to next buffer with a file
..<shft-f1: Switch to previous buffer with a file
..<ctl-w: Swap the current file with file in buffer 41
..<alt-w: Swap current file to buffer 0 (the "home" buffer of Uedit)
..<shftAlt-f6: Type in the number of a buffer to edit
..<shftCtl-f6: Examine all buffers that aren't empty
==== QUIT ====
..<normal-f4: Quit: Save changed (ask), see stacks (ask), see profile (ask), quit (ask)
-----------------------------------------------------------------------------
GLOBAL
buf34 (GLOBAL) last dirpath entered from keyboard
buf41 (GLOBAL) swap buffer ctl-w
n58 (GLOBAL) buffer # containing directory listing
LOCAL
buf61 (LOCAL ) "Dir" + dirpath
buf62 (LOCAL ) path/name
buf63 (LOCAL ) filename
buf0
buf43 (LOCAL ) scratch (document names)
buf54 (LOCAL ) scratch
buf61 (LOCAL ) dir dirpath
buf62 (LOCAL ) scratch
buf63 (LOCAL ) scratch
buf64 (LOCAL ) scratch
buf[n0] (LOCAL ) scan buf
buf[n54] (LOCAL ) scan changed
buf[n58] (LOCAL ) buf with dir listing
n0 (LOCAL ) scratch
n1 (LOCAL ) scratch
n2 (LOCAL ) scratch
n3 (LOCAL ) scratch
n4 (LOCAL ) scratch
n5 (LOCAL ) scratch
n26 (GLOBAL) session profile
n10 (LOCAL ) scratch
n11 (LOCAL ) scratch
n12 (LOCAL ) scratch
n13 (LOCAL ) scratch
n14 (LOCAL ) scratch
------------------------------------------------------------------------------
==== FILE REQUESTER ====
Choose from device list or type in directoryPath, get directory listing
<alt-z:
..put dirPath in buf61
equateNum(n0,curFile)
text(" ",0,0,0,-2)
text("Type in directoryPath",1,1,0,0)
text("DF0:",2,1,0,0)
text("DF1:",3,1,0,0)
text("DF2:",4,1,0,0)
text("SYS:",5,1,0,0)
text("SYS:s",6,1,0,0)
text("SYS:s/env",7,1,0,0)
text("SYS:dev:",8,1,0,0)
text("TOOLS:",9,1,0,0)
text("Files:",10,1,0,0)
text("Uedit",11,1,0,0)
text("Uedit/EasyWriter_2.6",12,1,0,0)
text("Uedit/EasyWriter_2.7",13,1,0,0)
text("Uedit/Commands",14,1,0,0)
text("Uedit/Stacks",15,1,0,0)
text("Uedit/StdConfigs",16,1,0,0)
putMsg("ESC to abort. Ctl-leftMouse or leftMouse on device to list.")
freeBuf(buf61)
getKey(macroNum)
switch(macroNum) {
case(normal-buttonDown)
case(ctl-buttonDown) {
mouseXY(n3,n4) ..pixels
div(n4,n4,8) ..raw rows
sub(n4,n4,1) ..screen rows
..putMsg(n4) alertUser("clicked on this row")..debug
switch(n4) {
case(1) {
getKey(inputChar)
putMsg("Type in directory path: ")
.. if (isEmpty(buf34)) insertRgn(buf34,sFile,"Files:",all)
moveCursor(buf34,eFile)
inputString(buf34)
freeBuf(buf61)
insertRgn(buf61,sFile,buf34,all)
insertRgn(buf61,sFile,"Dir ",all)
runKey(virtual-y)
returnTrue }
case(2) {insertRgn(buf61,eFile,"DF0:",all) }
case(3) {insertRgn(buf61,eFile,"DF1:",all) }
case(4) {insertRgn(buf61,eFile,"DF2:",all) }
case(5) {insertRgn(buf61,eFile,"SYS:",all) }
case(6) {insertRgn(buf61,eFile,"SYS:s",all) }
case(7) {insertRgn(buf61,eFile,"SYS:s/env",all) }
case(8) {insertRgn(buf61,eFile,"SYS:devs",all) }
case(9) {insertRgn(buf61,eFile,"TOOLS:",all) }
case(10) {insertRgn(buf61,eFile,":",all) }
case(11) {insertRgn(buf61,eFile,"Uedit",all) }
case(12) {insertRgn(buf61,eFile,"Uedit/EasyWriter_2.6",all) }
case(13) {insertRgn(buf61,eFile,"Uedit/EasyWriter_2.7",all) }
case(14) {insertRgn(buf61,eFile,"Uedit/Commands",all) }
case(15) {insertRgn(buf61,eFile,"Uedit/Stacks",all) }
case(16) {insertRgn(buf61,eFile,"Uedit/StdConfigs",all) } }
insertRgn(buf61,sFile,"Dir ",all)
runKey(virtual-y)
returnTrue }
case(normal-esc)
default {
editBuf(buf[n0])
putMsg("File directory aborted")
refreshDisplay
returnFalse } }
>Friday 02-Aug-91 22:06:30
Get listing using dirpath in buf61
<virtual-y:
newFile
equateNum(n58,curFile) ..record buf# containing directory listing
setFileName(curFile,buf61)
if (!execute(curFile,buf61)) {
putMsg("Dir request failed") returnFalse }
moveCursor(curFile,sFile)
insertChar(curFile,eLine)
insertRgn(curFile,sFile,buf61,all)
moveCursor(curFile,sFile)
insertChar(curFile,eLine)
insertChar(curFile,eLine)
insertRgn(curFile,sFile," DELETE=AC-mouse",all)
insertRgn(curFile,sFile," RENAME=SC-mouse",all)
insertRgn(curFile,sFile," LOAD=C-mouse",all)
insertRgn(curFile,sFile,"<REDO> <PARENT> <MAKEDIR>",all)
vScroll(sFile)
putMsg("To load files, ctrl-click names with mouse.")
flipFlag(curFile,changed)
>Tuesday 18-Dec-90 21:52:53
Mark region clicked with mouse
<virtual-buttonDown:
while (mouseDown) putMsg("Enough...leggo the button")
putMsg(" ")
equateLoc(curFile,atCursor,mouseLoc)
equateLoc(curFile,eInvert,atCursor)
equateLoc(curFile,sInvert,atCursor)
while (mouseDown) inputKey(n14)
if (is(curFile,eFile) | is(curFile,whiteSpace)) returnFalse
..find start of non-white
while (!is(curFile,whiteSpace) & !is(curFile,sFile))
moveCursor(curFile,sChar)
if (is(curFile,whiteSpace)) moveCursor(curFile,eChar)
equateLoc(curFile,sInvert,atCursor)
..find end of non-white
while (!is(curFile,whiteSpace) & !is(curFile,eFile))
moveCursor(curFile,eChar)
equateLoc(curFile,eInvert,atCursor) .. einvert = end non-white
refreshDisplay
>Saturday 20-Jul-91 20:33:37
Load file or select directory that is ctl-clicked.
<ctl-buttonDown:
if (!runKey(virtual-buttonDown)) { ..clicked on white or eFile
..go to dir file or open dir
if (!getFileName(buf63,buf[n58])) { ..is dir list open?
..alertUser("dir listing is not open")..debug
while (mouseDown) nothing
runKey(alt-z) return }
..n58 might be corrupt, check file name for "dir "
moveCursor(buf63,eFile)
setSearch("Dir ")
if (!search(buf63,sHilite,eHilite,-1)) {
..alertUser("buf[n58] is open but is not dir listing")..debug
runKey(alt-z) return }
else {
editBuf(buf[n58]) ..go to dir listing
putMsg("CTRL-Click on file or directory name") return
return } }
..swallow buttonUp?
while (inputWaiting) inputKey(n0)
..====clicked in dir file, if <REDO> redo listing
freeBuf(buf63)
insertRgn(buf63,sFile,curFile,invert)
..editBuf(buf63) alertUser("clicked word, in <REDO>")..debug
setSearch("<REDO>")
if (search(buf63,sHilite,eHilite,-1)) {
..alertUser("<REDO>")..debug
freeBuf(buf61)
getFileName(buf61,curFile)
equateNum(n0,curFile)
runKey(virtual-y) ..get listing
freeBuf(buf[n0])
return }
..====clicked in dir file, if <PARENT> get new listing
..editBuf(buf63) alertUser("clicked word, in <PARENT>")..debug
setSearch("<PARENT>")
if (search(buf63,sHilite,eHilite,-1)) {
..alertUser("<PARENT>")..debug
freeBuf(buf61)
getFileName(buf61,curFile)
moveCursor(buf61,eFile) moveCursor(buf61,sChar)
if(is(buf61,":")) {
putMsg("In root directory")
return }
setSearch(":$/")
moveCursor(buf61,eFile)
if (!search(buf61,sHilite,sHilite,-1)) {
putMsg("ILLEGAL path")
return }
..editBuf(buf61) alertUser("found :$/ in filename")..debug
if (is(buf61,":")) { ..move off : so as to not delete
moveCursor(buf61,eChar)
equateLoc(buf61,sHilite,atCursor) }
equateLoc(buf61,eHilite,eFile)
..editBuf(buf61) alertUser("dir to delete")..debug
clearRgn(buf61,hilite)
..putMsg(buf61) alertUser("parent path")..debug
equatenum(n0,curFile)
runKey(virtual-y) ..get listing
freeBuf(buf[n0])
return }
..====clicked in dir file, if <MAKEDIR> make directory
..editBuf(buf63) alertUser("clicked word, in <MAKEDIR>")..debug
setSearch("<MAKEDIR>")
if (search(buf63,sHilite,eHilite,-1)) {
..alertUser("<MAKEDIR>")..debug
freeBuf(buf61)
getFileName(buf61,curFile)
moveCursor(buf61,eFile)
moveCursor(buf61,sChar)
if (!is(buf61,":")) {moveCursor(buf61,eChar) insertChar(buf61,"/") }
freeBuf(buf43)
putMsg("Type in directory:")
if (inputString(buf43)) {
insertRgn(buf61,eFile,buf43,all)
moveCursor(buf61,sFile) do(n0,1,4) clearChar(buf61)
insertRgn(buf61,sFile,"MAKEDIR ",all)
..putMsg(buf61) alertUser("Command")..debug
execute (" ",buf61)
putMsg("Made directory") }
return }
..====clicked in dir file, form dirpath/name
freeBuf(buf62)
getFileName(buf62,curFile)
moveCursor(buf62,eFile)
moveCursor(buf62,sChar)
if(!is(buf62,":")) { moveCursor(buf62,eChar) insertChar(buf62,"/") }
insertRgn(buf62,eFile,curFile,invert)
..putMsg(buf62) alertUser("formed path/name")..debug
..if dirname (followed by (dir)) get listing
getPageRowCol(n0,n1,n2)
moveCursor(curFile,eWord)
moveCursor(curFile,eChar)
equateLoc(curfile,eHilite,atCursor)
moveCursor(curFile,sWord)
moveCursor(curFile,sChar)
equateLoc(curFile,sHilite,atCursor)
getPageRowCol(n3,n4,n5)
if (eqNum(n1,n4)) { ..on same row as clicked word
freeBuf(buf63)
insertRgn(buf63,sFile,curFile,hilite) equateLoc(curFile,sHilite,eHilite)
setSearch("(dir)")
if (search(buf63,sHilite,eHilite,-1)) { ..clicked on dirname
..putMsg(buf62) alertUser("about to free and get new dir")..debug
freeBuf(curFile)
freeBuf(buf61)
insertRgn(buf61,sFile,buf62,all)
runKey(virtual-y) ..get listing
return } }
..was filename, load file
moveCursor(buf62,sFile) do(n0,1,4) clearChar(buf62)
..putMsg(buf62) alertUser("about to load file")..debug
if (loadFile(buf62)) {
if (isEmpty(curFile))
if (askYesNo("FILE NOT FOUND.... Close this empty buffer?")) {
freeBuf(curFile)
return }
downFlag(curFile,userLocalA) ..cancel = no save
downFlag(curFile,autoBackup) ..cancel = no backup
if (askYesNo("Set save on idle?"))
upFlag(curFile,userLocalA)
else
downFlag(curFile,userLocalA)
if (askYesNo("Set backup?"))
upFlag(curFile,autoBackup)
else
downFlag(curFile,autoBackup) }
>Saturday 20-Jul-91 20:31:21
Rename file or directory that is shftCtl-clicked
<shftCtl-buttonDown:
runKey(virtual-x) ..form path/name in buf62
freeBuf(buf64)
insertRgn(buf64,sFile,buf62,all)
insertChar(buf64," ")
insertRgn(buf64,sFile,"RENAME ",all)
putMsg("Change path/name:")
moveCursor(buf62,eFile)
if (!inputString(buf62)) { putMsg("File NOT renamed") return }
insertRgn(buf64,eFile,buf62,all)
..putMsg(buf64) alertUser("command formed")..debug
if (execute(" ",buf64)) putMsg("Dir or File renamed or moved")
>Saturday 20-Jul-91 19:22:45
Delete file that is altCtl-clicked
<altCtl-buttonDown:
runKey(virtual-x) ..form path/name in buf62
if (askYesNo(" DELETE....file or directory shown above?")) {
if (askYesNo(" ARE YOU SURE YOU WANT TO DELETE IT? ")) {
insertRgn(buf62,sFile,"DELETE ",all)
..putMsg(buf62) alertUser("delete command")..debug
if (execute(" ",buf62)) putMsg("File deleted") }
else {
putMsg("File NOT deleted")
return } }
>Tuesday 18-Dec-90 22:11:30
Clicked name to buf62, add to path taken from file name, delete "dir ", show
<virtual-x:
runKey(virtual-buttonDown)
..if not in dir file go to dir file or get dir
if (!runKey(virtual-buttonDown)) { ..clicked on white or eFile
if (!eqNum(curFile,n58)) { ..not in dir listing buf
if (!isEmpty(buf[n58]))
editBuf(buf[n58]) return ..go to dir listing
else
runKey(alt-z) } ..no dir listing open, make one
else {
putMsg("Click on name of file to erase or rename") return }
}
freeBuf(buf62)
getFileName(buf62,curFile)
moveCursor(buf62,eFile)
moveCursor(buf62,sChar)
if(!is(buf62,":")) { moveCursor(buf62,eChar) insertChar(buf62,"/") }
insertRgn(buf62,eFile,curFile,invert)
moveCursor(buf62,sFile) do(n0,1,4) clearChar(buf62)
putMsg(buf62)
>Saturday 15-Dec-90 12:58:41
==== FILE OPEN & LOAD ====
Open "Empty" file
<ctl-f1:
newFile
downFlag(curFile,userLocalA)
downFlag(curFile,autoBackup)
if (askYesNo("Set save on idle?"))
upFlag(curFile,userLocalA)
else
downFlag(curFile,userLocalA)
if (askYesNo("Set backup?"))
upFlag(curFile,autoBackup)
else
downFlag(curFile,autoBackup)
>Saturday 13-Jul-91 20:36:44
Rename the file in the window
<alt-n:
putMsg("Revise pathName:")
getFileName(buf43,curFile)
moveCursor(buf43,eFile)
if (inputString(buf43))
setFileName(curFile,buf43)
>Sunday 21-Jul-91 13:10:27
Load a file
<alt-f1:
putMsg("Type pathName:")
freeBuf(buf43)
if (inputString(buf43)) loadFile(buf43)
if (isEmpty(curFile))
if (askYesNo("FILE NOT FOUND.... Close this empty buffer?")) freeBuf(curFile)
if (askYesNo("Set save on idle?"))
upFlag(curFile,userLocalA)
else
downFlag(curFile,userLocalA)
if (askYesNo("Set backup?"))
upFlag(curFile,autoBackup)
else
downFlag(curFile,autoBackup)
>Sunday 07-Jul-91 18:57:51
Convert file to read-only status
<shftAlt-f5:
flipFlag(curFile,readOnly)
if (getFlag(curFile,readOnly))
putMsg("Now READ ONLY")
else
putMsg("Now editable")
>Saturday 08-Jun-91 20:34:03
Restore current file to original
<shftCtl-f1:
if (!askYesNo("Restore file to original?")) returnFalse
if (getFileName(buf43,curFile)) { freeBuf(curFile) loadFile(buf43) }
if (askYesNo("Set save on idle?"))
upFlag(curFile,userLocalA)
else
downFlag(curFile,userLocalA)
if (askYesNo("Set backup?"))
upFlag(curFile,autoBackup)
else
downFlag(curFile,autoBackup)
>Sunday 07-Jul-91 18:57:53
Insert file at cursor
<shftAlt-f1:
putMsg("Type pathNme to insert:")
freeBuf(buf43)
if (inputString(buf43)) insertFile(curFile,atCursor,buf43)
>Sunday 07-Jul-91 18:57:54
..
.. default 0-3 -> 128-131 See top of Config!
..
Map illegal ASCII (0 thru 3) characters to safe 128-131
<shftAlt-m:
flipFlag(curFile,mapChars)
>Monday 10-Jun-91 19:07:03
==== FILE SAVE & CLOSE ====
Save (ask if not changed) file currently in window
<normal-f2:
if (!getFlag(curFile,changed)) {
if (!askYesNo("NOT changed, save anyway?")) return }
saveFile(curFile)
>Friday 14-Dec-90 13:37:27
Make icons: Toggle. When "on", Workbench icons are created
<altCtl-i:
flipFlag(curFile,icons)
if (getFlag(curFile,icons))
putMsg("Making icons")
else
putMsg("NOT Making icons")
>Monday 10-Jun-91 19:11:04
Save file under different name
<shft-f2:
putMsg("Save file as:") ..freeBuf(buf43)
getFileName(buf43,curFile)
if (inputString(buf43) & setFileName(curFile,buf43))
saveFile(curFile)
>Wednesday 12-Dec-90 23:43:18
Save (ask) all changed files
<alt-f2:
equateNum(n0,curFile)
getMaxFiles(n2)
decNum(n2)
putMsg("NO changed files")
do (n4,0,n2)
if (getFlag(buf[n4],changed)) {
editBuf(buf[n4])
putMsg(" ")
if(askYesNo("CHANGED...Save it?")) saveFile(buf[n4]) }
..might have swapped into buf41
if (getFlag(buf41,changed)) {
editBuf(buf41)
putMsg(" ")
if(askYesNo("CHANGED...Save it?")) saveFile(buf41) }
editBuf(buf[n0])
>Tuesday 30-Jul-91 16:21:48
Save hilite as...
<shftCtl-f2:
freeBuf(buf43)
insertRgn(buf43,sFile,buf34,all)
moveCursor(buf43,sChar)
if (!is(buf43,":")) {
moveCursor(buf43,eChar)
insertChar(buf43,"/") }
moveCursor(buf43,eFile)
putMsg("Save hilite as:")
if (!inputString(buf43)) return
freeBuf(buf54)
insertRgn(buf54,efile,curFile,hilite)
setFileName(buf54,buf43)
saveFile(buf54) freeBuf(buf54)
>Saturday 06-Jul-91 16:04:25
Idle-timer: Enter value (tenths of sec) after which idle command executed
<shftAltCtl-i:
putMsg("Type in idle time (tenths of a second)")
if (inputNum(n14)) equateNum(idleTime,n14)
>Monday 24-Dec-90 18:58:02
Idle: Turn on/off saving changes during idle periods
<ctl-f2:
flipFlag(curFile,userLocalA)
>Wednesday 12-Dec-90 23:43:19
Save changed files during idle periods, if their idle-save flag is set
<idle:
getMaxFiles(n12)
decNum(n12)
do (n14,0,n12) {
if (!inputWaiting
& getflag(buf[n14],changed)
& getflag(buf[n14],userLocalA)) {
incNum(n26) ..profile
saveFile(buf[n14]) }
..may have switched changed file to buf41 without pause
if (!inputWaiting
& getflag(buf41,changed)
& getflag(buf41,userLocalA)) {
incNum(n26) ..profile
saveFile(buf41) } }
>Friday 05-Jul-91 15:34:51
Backup: toggle auto-backup mode
<shftAltCtl-f2:
flipFlag(curFile,autoBackup)
>Tuesday 18-Dec-90 12:38:46
ReBAK: Save and restore to reset internal backedUp flag
<altCtl-f2:
if (!getFlag(curFile,autoBackup))
putMsg("Backups not requested. NO ACTION TAKEN.")
else {
runKey(normal-f2)
runKey(shftCtl-f1) }
>Thursday 20-Dec-90 21:40:27
Save (ask) if changed
<normal-closeBox:
if (getFlag(curfile,changed) &
askYesNo("Save changes?") &
!saveFile(curFile)) return
freeBuf(curFile)
if (isEmpty(curFile)) {
equateNum(n1,0)
getMaxFiles(n2)
decNum(n2)
do (n0,0,n2) if (!isEmpty(buf[n0])) equatenum(n1,1)
if (eqNum(n1,0) & askYesNo("Really quit?")) quit(0)
}
>Wednesday 12-Dec-90 23:43:20
Save (ask) if changed
<normal-f3:
if (!isEmpty(curFile)
& getFlag(curFile,changed)
& askYesNo("Save changes before closing?")
& !saveFile(curFile)) returnFalse
freeBuf(curFile)
>Wednesday 01-May-91 21:40:39
Save if changed, then close
<shft-f3:
if (getFlag(curFile,changed)) {
if (saveFile(curFile)) {
freeBuf(curFile)
delay (1) ..prevent msg from being erased
putMsg("That file was saved and closed") } }
else {
freeBuf(curFile)
delay (1)
putMsg("That file was not changed, so not saved, just closed") }
>Wednesday 01-May-91 21:49:35
==== SWITCH, SWAP, SCAN ====
Favorite: toggle
<alt-f:
flipFlag(curFile,favorite)
if (getFlag(curFile,favorite))
putMsg("Now favorite")
else
putMsg("Now NOT favorite")
>Thursday 11-Jul-91 12:05:42
Switch to next favorite document
<normal-gadget2:
if (!toggle(favorite))
if (getFlag(curFile,favorite))
putMsg("Only favorite")
else
putMsg("No favorite")
>Friday 14-Dec-90 19:32:52
..====Switch to next file via normal-gadget1 and shft-gadget1 are in config!E
Switch to next buffer with a file
<normal-f1:
if (!toggle(curFile)) { putMsg("No other files") returnFalse }
>Wednesday 12-Dec-90 23:43:20
Switch to previous buffer with a file
<shft-f1:
getMaxFiles(n1)
if (geNum(1,n1)) {
editBuf(buf0)
putMsg("maxFiles =1")
returnFalse }
decNum(n1)
equateNum(n0,curFile)
..if curFile is a buffer start with maxFiles-1
if (gtNum(n0,n1)) equateNum(n0,n1)
LABEL(0)
decNum(n0) ..go back one
..if now at neg buffer number, go to maxFiles-1
if (gtNum(0,n0)) equateNum(n0,n1)
..if file exists (trick), see it, else loop
if (getFileName(buf50,buf[n0])) {
editBuf(buf[n0]) returnTrue }
goto label(0)
>Thursday 11-Jul-91 12:49:07
Swap the current file with file in buffer 41
<ctl-w:
swapBuf(curFile,buf41)
>Wednesday 12-Dec-90 23:43:21
Swap current file to buffer 0 (the "home" buffer of Uedit)
<alt-w:
swapBuf(buf0,curFile)
editBuf(buf0)
>Wednesday 12-Dec-90 23:43:21
Type in the number of a buffer to edit
<shftAlt-f6:
putMsg("Type in number of buffer to edit:")
if (inputNum(n14)) {
editBuf(buf[n14])
vScroll(sFile) }
>Friday 19-Jul-91 22:36:54
Examine all buffers that aren't empty
<shftCtl-f6:
getMaxFiles(n12)
do (n14,n12,99) if (!isEmpty(buf[n14])) {
editBuf(buf[n14])
vScroll(sFile)
updateDisplay
putMsg("F1=continue, F2=edit this one, F3=stop:")
getKey(n13)
if (eqNum(n13,normal-f2)) { putMsg(" ") return }
if (eqNum(n13,normal-f3)) goto label(1) }
label(1)
toggle(curFile)
putMsg(" ")
>Thursday 13-Dec-90 16:15:12
==== QUIT ====
Quit: Save changed (ask), see stacks (ask), see profile (ask), quit (ask)
<normal-f4:
getMaxFiles(n12)
if (eqNum(n12,1) & isEmpty(curFile)) quit(0)
decNum(n12)
do(n14,0,n12) if (!isEmpty(buf[n14])) goto label(0)
if (!isEmpty(buf41)) goto label(0)
quit(0) ..all buffers are empty.
LABEL(0)
equateNum(n13,0)
do(n14,0,n12)
if (!isEmpty(buf[n14]) & getFlag(buf[n14],changed)) equateNum(n13,1)
..might have swapped into buf41
if (!isEmpty(buf[n14]) & getFlag(buf41,changed)) equateNum(n13,1)
if (eqNum(n13,1) & askYesNo("Save any changed files before quitting?"))
runKey(alt-f2)
equateNum(n0,49) ..copy cut buffer A
equateNum(n1,0) ..n1=number stack to test
getStacKSize(n0,n1,n2)
if (gtNum(n0,0)) {
if (askYesNo("Do you want to examine copy cut stack?")) {
do(n5,1,n0) {
newFile
equateNum(n5,curFile)
setFileName(curFile,"Copy_Cut_Stack")
pop(buf47,curFile)
editBuf(buf[n5])
moveCursor(curFile,sFile)
putMsg("d=discard this file, k=keep and look for more")
getKeyVal(macroNum,inputChar)
switch(macroNum) {
case("d") {freeBuf(curFile) }
default {nothing} } } } }
if (askYesNo("Show session profile before quitting?")) runKey(shftAltCtl-f1)
if (askYesNo("Quit now?")) quit(0)
>Thursday 11-Jul-91 22:48:10