home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
World of A1200
/
World_Of_A1200.iso
/
programs
/
commodity
/
magiccx
/
rexx
/
scripts.lha
/
PASRevision.ttx
< prev
Wrap
Text File
|
1994-08-12
|
2KB
|
76 lines
/*
$VER: PASRevision.ttx 1.0 (12.8.94)
Revises an Pascal/Modula source code
The default Port of MagicCX is assumed to be MagicCX.
This script was written for CygnusED II Pro, but I think it can
be easily ported to other editors having an ARexx-Port.
Written by : Kai Iske
Brucknerstrasse 18
63452 Hanau
GERMANY
Tel.: +49-(0)6181-850181
THIS SCRIPT IS PUBLIC DOMAIN
Modified for use with TurboText by Joachim Worringen 10.01.93
FIDO: 2:242/7.3
E-Mail: Joachim_Worringen@mowgli.fido.de
The cursorpositioning looks a little bit complicated, but the
"Bookmark"-funtion couldn`t be used in this case since TurboText
forgets all the old bookmarks if you load a new file (exactly what
happens here) so I had to choose this method.
*/
OPTIONS RESULTS
/*
Standard defines for INITIALVER INITIALREV INSERTBEFORE AND INSERTAFTER
(Please add complete paths for the files!)
*/
INITVER = 1
INITREV = 0
INSBEFORE = PASInsertBeforeHeader
INSAFTER = PASInsertAfterHeader
GetFileInfo
parse var RESULT lines_old ' ' modified ' ' name
if name = "" then
do
SetStatusBar "No file name -- aborting"
exit 0
end
IF modified = YES THEN SaveFile
GetCursorPos
parse var RESULT line . .
GetFilePath
RevName = RESULT
QUOTE = '22'X
ADDRESS 'MCX' REVISE 'FILE='QUOTE''RevName''QUOTE 'MODE=PAS' 'PUBSCREEN=TurboText' 'INITIALVER='INITVER 'INITIALREV='INITREV 'INSERTBEFORE='INSBEFORE 'INSERTAFTER='INSAFTER
RevDone = RESULT
Screen2Front
IF RevDone = 'TRUE' THEN
DO
OpenFile RevName
GetFileInfo
parse var RESULT lines_new . .
Move line + lines_new - lines_old
CenterView
END
ELSE
SetStatusBar "Error on revising !"
exit