[Date Prev][Date Next][Subject Prev][Subject Next][ Date Index][ Subject Index]

Re: Stack



** Reply to message from "Robert Holmgren"  on Mon, 12 Jan
2004 21:46:47 -0500


> Keep in mind that I am using Ansified XyWrite. Maybe some of the
> Ansified configuration changes have a collateral effect after installing
> STACK.

I doubt it. But you should keep the following in mind. The Stack itself (the
command stack) uses one reserved character to separate stacked strings from one
another: Ascii-190, which is a useless drawing character in CodePage 437, and
a Yen symbol in CP 850. But in ANSI CP 1252, it is "3/4". This reserved
character is just that: reserved. It **may not appear in any Stacked $tring**!
That means that you can't Stack a command line with a 3/4 symbol in it --
period. Stack will go crazy if you do, and you'll have to Quit and relaunch.
You'll also lose your Stack, by which I mean that you can't Save the stack and
reload it when you next relaunch XyWrite -- you'll have to clear it and start a
new stack up. Which is a total PITA. After all, one of the primary purposes
here is to be able to save your stack as a disk file when you Quit XyWrite, so
that when you next relaunch Stack, you reload your last 200 or however many
commands back into the stack, ready to go -- right?

Read STACK.DOC. There's a lot of power here. I consider three features to be
indispensable:

1) A "Hint" key.

2) Saving your Stack between XyWrite sessions.

3) Pre-Stacking (pushing) particularly important commands via STARTUP.INT, so
that they are always at the top of the Stack -- the first commands that you pop
off the Stack.

Example
=======
Suppose you have one text file that you refer to constantly (all your crucial
phone numbers, addresses, passwords, whatever) -- call it "D:\XY4\CRUCIAL.DAT".
You want it at your fingertips always.

1) Command "cru". The first (or second or third) match for this
case-insensitive "hint" (sub$tring) is "CALL D:\XY4\CRUCIAL.DAT"

2) If you SAve the Stack when you Quit, then that command will be there when
you fire up again tomorrow morning. Assign this to your Quit key:
 nn=NOJM(,2,.,f,i,n,i,t,o,)
U2 frame FINITO will save the Stack to a disk file before Quitting (default
filename is MY.STK in Editor's directory e.g. "d:\xy4"; it may be changed in
REG at Variable "Stored_Stack")

Then put this in STARTUP.INT, to reload the stored Stack when you launch:

 JM stack.intQ2 ;*; <== this should ALREADY be in INT -- it goes FIRST!!
 ;*; <== ADD these two lines
 JM 2.stackauxQ2 ;*; <== ADD

3) So far so good. But suppose you got involved in a project today, and you
issued 200 (or however many) commands without once looking at CRUCIAL.DAT. The
command "ca D:\XY4\CRUCIAL.DAT" has fallen out the bottom of the Stack and
disappeared, because the oldest commands are dropped first when you reach the
user-defined Stack size-limit e.g. 200. All you had to do was look at it
_once_, to pop it back up to the top of the Stack. But you didn't, you
schmuck, and now it's gone. Tomorrow morning comes, you fire up XyWrite. You
don't really suppose you are going to have to MANUALLY issue
"CALL D:\XY4\CRUCIAL.DAT" again -- god forbid! No, you preload it in
STARTUP.INT. (And even if it didn't disappear yesterday, preloading means that
it is now the *first* command in the Stack, instead of number 139 or 85. Which
is where it should be, because it is your most important command -- right?)

This is a preload command:
 $S ;*;
Read the sections called "User-Macro Loader" and "Using the Macro Switch" in
STACK.DOC. I preload about 25 commands in STARTUP.INT.

*DO* these three things! You'll begin to see why Stack is addictive.

-----------------------------
Robert Holmgren
holmgren@xxxxxxxx
-----------------------------