home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Shareware Overload
/
ShartewareOverload.cdr
/
windows
/
amimacro.zip
/
BIB3.SMM
next >
Wrap
INI File
|
1990-06-13
|
17KB
|
1,529 lines
[ver]
4
[sty]
[files]
[prn]
PCL / HP LaserJet
[lang]
1
[desc]
645306136
188
630876320
[fopts]
0
1
0
0
[lnopts]
3
Body Text
[docopts]
5
2
[tag]
Body Text
2
[fnt]
Courier
240
0
32768
[algn]
225
1
0
0
0
[spc]
17
201
1
0
72
1
100
[brk]
0
[line]
8
0
1
0
1
1
1
10
10
1
[spec]
0
0
0
1
0
0
0
0
0
[nfmt]
272
1
2
.
,
$
[tag]
footer
3
[fnt]
Tms Rmn
200
0
49152
[algn]
225
1
0
0
0
[spc]
17
273
1
0
0
1
100
[brk]
4
[line]
8
0
1
0
1
2
2
20
20
1
[spec]
0
0
0
1
0
0
1
0
0
[nfmt]
280
1
3
.
,
$
[lay]
Standard
513
[rght]
15840
12240
1
1080
360
1
1080
720
4
1
0
1
8
4
1
1080
11520
14
1
359
1
721
1
1084
1
1446
1
1792
1
2155
1
2517
1
2880
1
3242
1
3605
1
3967
1
4323
1
4683
1
5043
[hrght]
[lyfrm]
1
11200
0
0
12240
1080
1
1
3
1
5
0
0
[frmlay]
1080
12240
1
360
0
1
0
0
2
1
0
1
1
0
1
360
12240
3
1
365
2
6120
3
11162
[txt]
>
[frght]
[lyfrm]
1
13248
0
15480
12240
15840
1
1
3
1
5
0
0
[frmlay]
15840
12240
1
720
0
1
15480
720
2
1
0
1
1
0
1
720
11520
0
[txt]
>
[elay]
[l1]
0
[edoc]
FUNCTION MarkRef()
macpath = GetmacPath$()
boxfile = "{macpath}bib3.ext"
'singlestep(0)
ignorekeyboard(1)
DECLARE InitNames()
declare markit()
declare markbibpage()
declare startbibpage()
declare markbibref()
declare markbib()
go = 1
mem = AllocGlobalVar(444, 100)
bl = "<[><[>"
bl = mid$(bl 1 1)
while (go)
hourglass(1)
for i = 1 to 9000 ' load the list box
entry = GetGlobalArray$(444, i) ' get one
if ("" = entry) ' end of array?
break
endif
txt = strfield$(entry, 2, "*")
n = len(i)
switch n
case 2
txt = strcat$("{i} " txt)
case 1
txt = strcat$("{i} " txt)
default
txt = strcat$("{i} " txt)
endswitch
FillList(txt) ' add to list
next
hourglass(0)
stat = DialogBox("{boxfile}" "bib")
switch stat
case 1 ' mark it
entry = GetDialogField$(9007)
if ("" <<>> entry)
entry = mid$(entry 5 65)
fentry = entry
j = 1
while(fentry <<>> "") ' match text with time id
fentry = GetGlobalArray$(444, j)
txt = strfield$(fentry, 2, "*")
if txt = entry then ' here we match
entry = strfield$(fentry 1 "*") ' get id for txt
rtime = gettime()
entry = strcat$(entry "*{rtime}") 'make unique id for bookmark
break
endif
j = j + 1
wend
curtxt = curchar$()
if curtxt = "]" then
MarkBookMark(entry, AddBookMark)
type("##<[>right]")
else
type("{bl}##]")
type("<[>left]<[>left]<[>left]")
MarkBookMark(entry, AddBookMark)
type("<[>right]<[>right]<[>right]")
endif
go = 0
else
Message("Click on something!")
endif
case 3 ' add bibliography first
markbib()
case 4 ' update names array
InitNames()
default
go = 0
endswitch
wend
END FUNCTION
'**********************************************************
function markbib()
MarkBookMark("temp1", AddBookMark) ' save our spot
gone = MarkBookMark("Bibliography", FindBookMark) ' put the user on
bib page
if gone <<>> 1 then
markbibpage()
endif
type("<[>down]")
UserControl("Position Cursor & Type the bib entry:") ' wait for him
to type it
type("<[>home]")
usercontrol("Place cursor at the beginning of the entry")
type("#. <[>left]")
entry = gettime() 'get an id
MarkBookMark(entry, AddBookMark) ' mark it
MarkBookMark("temp1", FindBookMark) ' go back where he was
MarkBookMark("temp1", DeleteBookMark) ' delete the temp mark
initnames()
end function
'*********************************************************
FUNCTION MarkBibPage()
gone = MarkBookMark("Bibliography",FindBookMark)
if gone <<>> 1 then
type("<[>esc]<[>esc]<[>esc]<[>ctrlend] <[>enter]")
pagebreak(1)
MarkBookMark("Bibliography",AddBookMark)
type("Bibliography<[>enter]<[>up]")
center()
type("<[>down]<[>enter]")
else
message("Bibliography Page Already Exists!")
endif
END FUNCTION
'**********************************************************
FUNCTION UpdateRef()
DECLARE FindEntry(name)
messages(OFF)
InitNames() ' make sure names are up to date
type("<[>CTRLHOME]") ' go to beginning of the document
bl = "<[><[>"
bl = mid$(bl 1 1)
again:
hourglass(1)
while (1 = GotoCmd(GoMARK,0,GOBOOKMARK))
multiref:
current = GetMarkText$() ' get the bookmark name
if ("Bibliography" = current) ' Time to break?
break
endif
bibmark = strchr(1 current "*") 'check bookmark? is it ours?
if bibmark << 0 then ' we need to skip this one
type("<[>right]")
goto again
endif
number = FindEntry(current) ' whats is number?
while (1)
chr = curchar$()
if chr = "" then
type("<[>right]<[>left]")
chr = curchar$()
endif
chr# = isnumeric(chr)
if ((chr# = 1) or (chr = "#")) then ' del numbers and ##
Type("<[>DEL]") ' delete the old
else
break
endif
wend
type("{number}")
while(1)
chr = curchar$()
if chr = "," then
goto again
endif
if chr = "]" then
type("<[>right]")
chr = curchar$()
endif
if chr = bl then
type("<[>left]<[>del]<[>right]")
chr = curchar$()
if chr = "]" then
type("<[>left]]")
goto again
endif
type("<[>left],<[>del]")
goto multiref
endif
goto again
wend
wend
' Now take care of renumbering the bib entres
'type("<[>down]") ' skip past bib bookmark
number = 0
while (1 = GotoCmd(GoMARK,0,GOBOOKMARK))
number = number + 1
'
' The bookmark is kept after the period, so that is where the cursor
is now.
'
type("<[>left]") ' get to the left side of the period.
type("<[>shifthome]") ' shade all to the left
type("<[>del]") ' delete the old number
Type("{number}") ' enter the new
type("<[>end]") ' get past the current bookmark
wend
hourglass(0)
END FUNCTION
'***************************************************************
' Given a name, locate its offset (number)
FUNCTION FindEntry(name)
i = 1
while (i)
idtxt = GetGlobalArray$(444, i)
id = strfield$(idtxt 1 "*") 'strip off txt and keep id
current = strfield$(name 1 "*") 'strip off unique id
if (id = current)
return i
endif
if ("" = current)
return "**"
endif
i = i + 1
wend
END FUNCTION
'*************************************************************
' InitNames - init the name array.
FUNCTION InitNames()
MarkBookMark("temp", AddBookMark) ' save our spot
messages(off)
FreeGlobalVar(444) ' delete old array
<*'>globvar = AllocGlobalVar(444, 100)
if globvar = 0 then
message("Not Enough Memory For Global Array")
exit function
endif
globcnt = 0
alloccnt = 100
MarkBookMark("Bibliography" FindBookMark) ' find the bib page
hourglass(1)
while (1 = GotoCmd(GoMARK 0 GOBOOKMARK)) ' find the next bib entry
current = GetMarkText$() ' get bookmark name
if ("temp" = current) ' don't process temp
goto skip
endif
type("<[>right]") ' get past tab
type("<[>shiftend]")
txt = curshade$()
numchars = len(txt) ' check to see if chars >> 65
if numchars >> 65 then
num2 = numchars - 65 ' calculate amount over
for x = 1 to num2 ' unshade down to 65 chars
type("<[>shiftleft]")
next
endif
txt = curshade$() ' get the text associated with time id
current = strcat$("{current}*" txt)
type("<[>right]")
globcnt = globcnt + 1 ' next spot in array
if (alloccnt <<= globcnt) ' gotta increase?
alloccnt = alloccnt + 200 ' 200 more for now
mem = AllocGlobalVar(444 alloccnt)
if mem = 0 then
message("Not Enough Memory For Global Array")
exit function
endif
endif
SetGlobalArray(444, globcnt, current)
skip:
wend
hourglass(0)
globcnt = globcnt + 1
if (alloccnt <<= globcnt) ' gotta increase?
alloccnt = alloccnt + 200 ' 200 more for now
mem = AllocGlobalVar(444 alloccnt)
if mem = 0 then
message("Not Enough Memory For Global Array")
exit function
endif
endif
SetGlobalArray(444, globcnt, "") ' signal end of array
MarkBookMark("temp", FindBookMark) ' go back where we were
MarkBookMark("temp", DeleteBookMark) ' get rid of that mark
END FUNCTION
'***************************************************************
FUNCTION startBibPage()
gone = MarkBookMark("Bibliography",FindBookMark)
if gone <<>> 1 then
usercontrol("Place cursor at beginning of Bib Page")
go = decide("Mark Bookmark for beginning of Bib page here?")
if go = 0 then
exit function
endif
MarkBookMark("Bibliography",AddBookMark)
type("<[>enter]")
else
message("Bibliography Page Already Exists!")
endif
END FUNCTION
'***************************************************************
function markbib2()
UserControl("Position Cursor & Type the bib entry:") ' wait for him
to type it
type("<[>home]")
usercontrol("Place cursor at the beginning of the entry")
type("#. <[>left]")
entry = gettime() 'get an id
MarkBookMark(entry, AddBookMark) ' mark it
go = decide("Update Bib Entries Before Marking Text For Bib Reference.
Update Now?")
if go = 1 then
call initnames()
endif
end function
'***************************************************************
function automk()
usercontrol("Place cursor at beginning of Bib entry to begin")
ret = decide("Are There 2 Returns Between Each Bib Entry?")
markit()
hourglass(1)
while (0 = ateof())
type("<[>ctrldown]<[>right]")
if ret = 1 then
type("<[>right]")
endif
x = curchar$()
chkend = getmarktext$()
if (chkend = "" and x = "") then
break
endif
markit()
wend
endit:
hourglass(0)
go = decide("Update Bib Entries Before Marking Text For Bib Reference.
Update Now?")
if go = 1 then
initnames()
endif
end function
'***************************************************************
function markit()
type("#. <[>left]")
entry = gettime() 'get an id
MarkBookMark(entry, AddBookMark) ' mark it
end function
>
[macsum] 10
MarkRef 0 0 15 0
markbib 1341 0 3 80
MarkBibPage 1698 0 2 100
UpdateRef 1972 0 7 116
FindEntry 3024 1 5 194
InitNames 3277 0 10 214
startBibPage 4364 0 3 274
markbib2 4703 0 3 291
automk 5016 0 5 306
markit 5529 0 2 333
[macse]
14 MarkRef
0 295
13
8 1
7 "{1}bib3.ext"
8 2
0 32 1
5 1
8 3
0 271 444 100
13
8 4
7 "[["
8 5
0 15 "{5}" 1 1
13
8 5
6 3
11 00001329
0 296 1
5 1
8 6
5 9000
6 6
18 2
12 00000245
10 00000558
5 1
6 6
3 0
8 6
10 00000167
0 273 444 "{6}"
13
8 7
7 ""
6 7
18 0
11 00000314
10 00000558
0 20 "{7}" 2 "*"
13
8 8
0 14 "{6}"
13
8 9
5 2
6 9
18 0
11 00000433
0 16 "{6} " "{8}"
13
8 8
10 00000533
5 1
6 9
18 0
11 00000505
0 16 "{6} " "{8}"
13
8 8
10 00000533
0 16 "{6} " "{8}"
13
8 8
0 25 "{8}"
10 00000212
0 296 0
0 26 "{2}" "bib"
13
8 10
5 1
6 10
18 0
11 00001194
0 27 9007
13
8 7
7 ""
6 7
18 1
11 00001154
0 15 "{7}" 5 65
13
8 7
6 7
8 11
5 1
8 12
6 11
7 ""
18 1
11 00000961
0 273 444 "{12}"
13
8 11
0 20 "{11}" 2 "*"
13
8 8
6 8
6 7
18 0
11 00000926
0 20 "{11}" 1 "*"
13
8 7
0 276
13
8 13
0 16 "{7}" "*{13}"
13
8 7
10 00000961
6 12
5 1
3 0
8 12
10 00000723
0 282
13
8 14
6 14
7 "]"
18 0
11 00001057
2 466 1 "{7}" 4003
0 6 "##[39]"
10 00001131
0 6 "{5}##]"
0 6 "[37][37][37]"
2 466 1 "{7}" 4003
0 6 "[39][39][39]"
5 0
8 3
10 00001181
0 3 "Click on something!"
10 00001316
5 3
6 10
18 0
11 00001249
16 markbib
10 00001316
5 4
6 10
18 0
11 00001306
16 InitNames
10 00001316
5 0
8 3
10 00000130
6 0
15
9
14 markbib
2 466 1 "temp1" 4003
2 466 1 "Bibliography" 4002
13
8 1
6 1
5 1
18 1
11 00000117
16 markbibpage
0 6 "[40]"
0 7 "Position Cursor & Type the bib entry:"
0 6 "[36]"
0 7 "Place cursor at the beginning of the entry"
0 6 "#. [37]"
0 276
13
8 2
2 466 1 "{2}" 4003
2 466 1 "temp1" 4002
2 466 1 "temp1" 4004
16 initnames
6 0
15
9
14 MarkBibPage
2 466 1 "Bibliography" 4002
13
8 1
6 1
5 1
18 1
11 00000221
0 6 "[27][27][27][16419] [13]"
2 357 1 1
2 466 1 "Bibliography" 4003
0 6 "Bibliography[13][38]"
2 260 1
0 6 "[40][13]"
10 00000262
0 3 "Bibliography Page Already Exists!"
6 0
15
9
14 UpdateRef
0 30 0
16 InitNames
0 6 "[16420]"
7 "[["
8 1
0 15 "{1}" 1 1
13
8 1
0 296 1
5 1
2 452 1 4 0 12
13
18 0
11 00000883
0 261
13
8 2
7 "Bibliography"
6 2
18 0
11 00000213
10 00000883
0 13 1 "{2}" "*"
13
8 3
6 3
5 0
18 5
11 00000294
0 6 "[39]"
10 00000089
16 FindEntry "{2}"
13
8 4
5 1
11 00000544
0 282
13
8 5
6 5
7 ""
18 0
11 00000419
0 6 "[39][37]"
0 282
13
8 5
0 277 "{5}"
13
8 6
6 6
5 1
18 0
6 5
7 "#"
18 0
1 2
11 00000518
0 6 "[46]"
10 00000531
10 00000544
10 00000323
0 6 "{4}"
5 1
11 00000870
0 282
13
8 5
6 5
7 ","
18 0
11 00000633
10 00000089
6 5
7 "]"
18 0
11 00000692
0 6 "[39]"
0 282
13
8 5
6 5
6 1
18 0
11 00000844
0 6 "[37][46][39]"
0 282
13
8 5
6 5
7 "]"
18 0
11 00000814
0 6 "[37]]"
10 00000089
0 6 "[37],[46]"
10 00000142
10 00000089
10 00000555
10 00000098
5 0
8 4
5 1
2 452 1 4 0 12
13
18 0
11 00001031
6 4
5 1
3 0
8 4
0 6 "[37]"
0 6 "[4132]"
0 6 "[46]"
0 6 "{4}"
0 6 "[35]"
10 00000893
0 296 0
6 0
15
9
14 FindEntry
5 1
8 2
6 2
11 00000241
0 273 444 "{2}"
13
8 3
0 20 "{3}" 1 "*"
13
8 4
0 20 "{0}" 1 "*"
13
8 5
6 4
6 5
18 0
11 00000163
6 2
15
9
7 ""
6 5
18 0
11 00000208
7 "**"
15
9
6 2
5 1
3 0
8 2
10 00000024
6 1
15
9
14 InitNames
2 466 1 "temp" 4003
0 30 0
0 266 444
0 271 444 100
13
8 1
6 1
5 0
18 0
11 00000161
0 3 "Not Enough Memory For Global Array"
6 0
15
9
5 0
8 2
5 100
8 3
2 466 1 "Bibliography" 4002
0 296 1
5 1
2 452 1 4 0 12
13
18 0
11 00000824
0 261
13
8 4
7 "temp"
6 4
18 0
11 00000328
10 00000811
0 6 "[39]"
0 6 "[4131]"
0 24
13
8 5
0 14 "{5}"
13
8 6
6 6
5 65
18 3
11 00000553
6 6
5 65
3 1
8 7
5 1
8 8
6 7
6 8
18 2
12 00000526
10 00000553
5 1
6 8
3 0
8 8
10 00000451
0 6 "[4133]"
10 00000493
0 24
13
8 5
0 16 "{4}*" "{5}"
13
8 4
0 6 "[39]"
6 2
5 1
3 0
8 2
6 3
6 2
18 4
11 00000788
6 3
5 200
3 0
8 3
0 271 444 "{3}"
13
8 9
6 9
5 0
18 0
11 00000788
0 3 "Not Enough Memory For Global Array"
6 0
15
9
0 272 444 "{2}" "{4}"
10 00000221
0 296 0
6 2
5 1
3 0
8 2
6 3
6 2
18 4
11 00001013
6 3
5 200
3 0
8 3
0 271 444 "{3}"
13
8 9
6 9
5 0
18 0
11 00001013
0 3 "Not Enough Memory For Global Array"
6 0
15
9
0 272 444 "{2}" ""
2 466 1 "temp" 4002
2 466 1 "temp" 4004
6 0
15
9
14 startBibPage
2 466 1 "Bibliography" 4002
13
8 1
6 1
5 1
18 1
11 00000286
0 7 "Place cursor at beginning of Bib Page"
0 2 "Mark Bookmark for beginning of Bib page here?"
13
8 2
6 2
5 0
18 0
11 00000232
6 0
15
9
2 466 1 "Bibliography" 4003
0 6 "[13]"
10 00000327
0 3 "Bibliography Page Already Exists!"
6 0
15
9
14 markbib2
0 7 "Position Cursor & Type the bib entry:"
0 6 "[36]"
0 7 "Place cursor at the beginning of the entry"
0 6 "#. [37]"
0 276
13
8 1
2 466 1 "{1}" 4003
0 2 "Update Bib Entries Before Marking Text For Bib Reference. Update Now?"
13
8 2
6 2
5 1
18 0
11 00000301
16 initnames
6 0
15
9
14 automk
0 7 "Place cursor at beginning of Bib entry to begin"
0 2 "Are There 2 Returns Between Each Bib Entry?"
13
8 1
16 markit
0 296 1
5 0
0 278
13
18 0
11 00000362
0 6 "[16424][39]"
6 1
5 1
18 0
11 00000241
0 6 "[39]"
0 282
13
8 2
0 261
13
8 3
6 3
7 ""
18 0
6 2
7 ""
18 0
1 1
11 00000338
10 00000362
16 markit
10 00000146
0 296 0
0 2 "Update Bib Entries Before Marking Text For Bib Reference. Update Now?"
13
8 4
6 4
5 1
18 0
11 00000501
16 initnames
6 0
15
9
14 markit
0 6 "#. [37]"
0 276
13
8 1
2 466 1 "{1}" 4003
6 0
15
9
00011105