Dec 262017
 
Softkeys for wordperfect.
File WPFKEYS.ZIP from The Programmer’s Corner in
Category Word Perfect
Softkeys for wordperfect.
File Name File Size Zip Size Zip Type
FKEYTEXT.C 279 229 deflated
FKEYTEXT.LST 329 248 deflated
SHOFKEYS 171 134 deflated
SHOFKEYS.A 11676 3681 deflated
SHOFKEYS.COM 1094 746 deflated
SHOFKEYS.DOC 7221 3311 deflated
STRUX.EXE 12298 7181 deflated

Download File WPFKEYS.ZIP Here

Contents of the SHOFKEYS.DOC file


ShoFKeys --

I hate keyboard templates.They catch on your sleeve, they clutter the
typing area, you can never find them unless you Scotch-tape them to the
keyboard, and then it's a pain in the lobotomy to swap the right one in
place when you need it. Nuts.

Unfortunately, for mere mortal nerds like myself they are necessary.
I remember about six function keys (out of the forty possible ones using
SHIFT, ALT and CTRL) for each of the programs I use regularly.That is
equally true for tools where I'm stuck with the key choices (like CodeView)
and for editors that allow me to remap the keyboard (like MicroEMACS).

I spend a lot of time in CodeView, so that's the template permanently
affixed to my keyboard. MicroEMACS has help screens available, so I can
get along without a template there.

WordPerfect, however, drives me bonkers. As a document preparation
system, its power and flexibility are essential... but they use every
damned one of those 40 function key combinations, and I can't for the
life of me remember which is which at 3 in the morning.

A couple of nights ago, I got fed up with hitting F3 F3, and hacked
together ShoFKeys. It's a pretty simple-minded program, but it works for
me. Here's what it does:

1) When run from the prompt, ShoFKeys intercepts the "keypress"
interrupt (INT 9), redirects it through a "hotkey" test and
a test for change in shift status (i.e., is CTRL or SHIFT or
ALT pressed?), determines what kind of video adapter the
system is using, and terminates leaving the meat of itself
in memory, but dormant.

2) When the user hits the "hotkey" combination CTRL-LEFTSHIFT-F,
ShoFKeys toggles itself into the ACTIVE state. Another
CTRL-LEFTSHIFT-F will toggle it INACTIVE again.

3) When ACTIVE, the routine tests the shift state at every keypress
or keyrelease. If that shift state has CHANGED since the last
time ShoFKeys displayed a set of function keys, it saves the new
shift state and selects one of four 160-byte blocks of data.
Each of these blocks contains 80 words of screen data (in
character-plus-video attribute format), or a full 80-character
row. ShoFKeys determines the last row on the display (always
#24 on a monochrome or CGA system, might be #24, #42 or some
other value on an EGA) and copies the 160-byte block directly
into the video memory.

When ShoFKeys is activated, the bottom line of the display shows 10
sets of function key mnemonics, each 8 characters wide. The first character
of each eight is highlighted, the other seven are not.(On my screen, the
first -- highlighted -- character is a digit 1, 2, 3... 0 to indicate the
function key number, and the other seven characters contain the name of
the function distilled into a clever 7-letter abbrvtn.) (The colors I use
on my EGA -- bright blue highlight, grey normal -- happen to work nicely
on a monochrome monitor. The "highlight" is high-intensity underlined,
the rest is low-intensity. However, if you prefer reverse video, blinking,
or strange color combos, you need only change two equates and re-assemble
the source.)

Press any of the "shift" keys -- SHIFT, CTRL or ALT -- and the list
of "normal" function key mnemonics is replaced instantly with the appropriate
CTRL, SHIFT or ALT fkey list. Release ALT or whatever, and the unshifted
key mnemonics immediately re-appear.

Because ShoFKeys determines the number of rows on-screen at KEYPRESS
time rather than at LOAD time, you can change an EGA's characteristics and
the function keys will still appear at the bottom of the screen. This is real
handy if you like to edit in 43-line mode to see more of a document at one
time.

ShoFKeys works real well with WordPerfect (and some other editors I
use like MicroEMACS) because you can specify the number of on-screen rows
that WordPerfect uses.Run WP/S and set the screen characteristics.
Normally, you would tell WordPerfect that you have a 25-line screen. Say
instead that your screen is 24 lines long. WordPerfect configures itself
to put your document on rows 0-22, places its status line on row 23, and
leaves row 24 free for your function-key mnemonics. I edit with a "42-line"
WordPerfect screen, using 0-41 for WordPerfect and leaving row 42 free for
my function keys.

Like I said, ShoFKeys is dumb. It does NOT preserve the previous
contents of the last row on-screen, and it is not smart enough to stay out
of the way of programs that use that last row.In particular, if you drop
back to DOS and forget to de-activate it (via CTRL-LEFTSHIFT-F), you'll
see copies of the function key lists rolling up-screen as your prompt
reaches the last row.

However, it's easy enough to turn the thing off when you're not using
it, it only takes up about 1100 bytes of RAM, doesn't add any noticeable
overhead to typing speed, and it's saved me a few trips to the manual shelf.

Some ideas for enhancements that I might tackle someday, if someone
doesn't beat me to it (hint, hint...) --

-- prevent multiple copies of ShoFKeys from being loaded.

-- load a text for function key list from a command-line filename
(should REPLACE previously resident text in the FIRST
copy of ShoFKeys in RAM)

-- Display mnemonics as a pop-up block, rather than a single
line at the bottom. This would both allow fuller mnemonic
texts and not require specially-configured software that
doesn't use the last row. It would require watching the
keystrokes more closely than the present program does, though,
to know when to save and restore "real" screen contents.

Have fun!

================================================

ShoFKeys is written in a "structured assembly language". The following files
are included in this archive:

read.me -- you're doing it


strux.exe-- preprocessor for "structured" assembly language.
STRUX SHOFKEYS generates SHOFKEYS.ASM (MASM compatible)
from the structured source SHOFKEYS.A

shofkeys.-- MAKE file for SHOFKEYS. I use NDMAKE, an excellent
UNIX-compatible MAKE.

shofkeys.a-- source code for SHOFKEYS. see STRUX above.

shofkeys.com-- runnable form.

fkeytext.c-- generates the appropriate DB statements for inclusion
in SHOFKEYS.A for a set of 4 text lines, such as

fkeytext.lst-- text (4 text lines) for WordPerfect function keys


-- Two useful programs NOT included in this archive (because they're not mine)
are NDMAKE and EXE2COM. They are not absolutely necessary --
you can assemble and link "by hand" and use EXE2BIN instead --
but they're real convenient and recommended. You'll probably
find them on the same BBS you got this from, or one nearby.



If you like the program, have fun with it.

If you feel like modifying it, go ahead. It's in the public domain.

If you don't like it at all, I don't promise to be crushed by your criticism.




Davidson Corry
4610 SW Lander
Seattle, WA 98116

(206) 935-0244


 December 26, 2017  Add comments

Leave a Reply