;   In order to be effective, changes to this file must be acted upon
;   by PK.EXE.
;
;   PK.EXE should be executed in the pE directory (where pe.exe is)
;
;   PK [key.txt]
;
;     one can also specify wp.txt or ws.txt.  Output will always be
;     KEY.PED in the same directory where the .txt file was found.
;
; 
;          IF YOU'RE NOT SURE OF WHAT YOU'RE DOING - PLEASE MAKE A         
;                 COPY OF KEY.PED BEFORE YOU RUN PK.EXE                    
; 
;
;   If you're in to wordstar commands - take a look at ws.txt.
;
;   Registered users also receive wp.txt (WordPerfect keystroke emulation)
;
;   Data following semi-colons are treated as commentary
;
;   Key names are defined as follows
;
;          f1 - means function key F1
;         ^f1 - means control key and F1
;         f1 - means shift key and F1
;         @f1 - means alt key and F1
;
;   two (or more) keys can be used for a single command as
;   long as the keys in the sequence are joined with an
;   underscore character, like this: ^a_c
;
;   note, however, that the first key in a two key sequence cannot
;         then be used as a single key.  So, in the above sequence,
;         ^a (alone) could not also be assigned a function.  It would have
;         no effect.
;
;   one or more spaces follow each field and are field separators
;
;   The ordering of keys in this file is arbitrary, put it in whatever
;   order you feel is logical.
;
;   While a function may have more than one key assigned, the same key
;   cannot be used for more than one function.
;
;   Note that key names go in field one, functions in field two.
;
; 1      2    ;and these are comments just as any line that begins with a ;

^^_^a   ^a              ;these assignments allow the keyin
^^_^b   ^b              ;of any literal control character by
^^_^c   ^c              ;first typing ^ (control circumflex)
^^_^d   ^d              ;followed by the control character you
^^_^e   ^e              ;want.
^^_^f   ^f
^^_^g   ^g
^^_^h   ^h
^^_^i   ^i
^^_^j   ^j
^^_^k   ^k
^^_^l   ^l
^^_^m   ^m
^^_^n   ^n
^^_^o   ^o
^^_^p   ^p
^^_^q   ^q
^^_^r   ^r
^^_^s   ^s
^^_^t   ^t
^^_^u   ^u
^^_^v   ^v
^^_^w   ^w
^^_^x   ^x
^^_^y   ^y
^^_^z   ^z
^^_^[   ^[
^^_^\   ^\
^^_^]   ^]
^^_^^   ^^
^^_^_   ^_

`       LastAscii       ;this character will produce the last character the
                        ;ascii window was set to - if ascii window is never
                        ;called it will be itself.
;
; f1 - f10
;

f1      ExecuteCommand  ;provides a menu of all commands and keystrokes
f2      JumpNext        ;jump (cycle) to next window number
f3      InsertDelLine   ;undeletes the just deleted line
f4      DeleteLine      ;deletes the current line
f5      FindForward     ;find a string from cursor towards "bottom"
f6      FindBackward    ;find a string from cursor towards "top"
f7      FloatBlock      ;move a column block of text with arrow keys or mouse
f8      PrevMark        ;position cursor to saved location (SetMarks)
f9      GoTo            ;go to line number, offset (hex edit), or bookmark
f10     Menu            ;another way to get to menu

; extended keyboard only

f11     OpenDosWindow   ;open a window with the text from DOS screen
f12     StackWin        ;minimize all windows into 'stacks'

; shift f1 - f10

f1     MatchBrace      ;locate the corresponding { ( or [
f2     JumpPrev        ;jump to previous window
f3
f4
f5     FoundList       ;Build a list of found items and put into FIND.PED
f6
f7
f8
f9     ToggleDecHex    ;set either decimal or hex offsets (hex edit only)
f10    SetParagraphStyle   ;set left, right, indent and paragraph alignment

f11    ToggleBorders   ;allow/disallow borders
f12    JumpZoom        ;maximize a window when jumped to

; control f1 - f10

^f1     RecordMacro     ;assign multiple keystrokes/commands to a single key
^f2     SaveOptions     ;save all settings (including macros) to env.ped
^f3     InsertDelSeg    ;Undo delete to end of line
^f4     DeleteToEol     ;delete to end of line
^f5     ToggleCase      ;make fine case sensitive or not
^f6     ToggleWordprocess ;sets automatic paragraph alignment as you type
^f7     SetTabs         ;set tab stops, detab increment and tabs/blanks
^f8     SetMarks        ;store position of cursor
^f9
^f10    UndoPara        ;will undo last paragraph alignment

; extended keyboard only

^f11    SetLineLength   ;allows word wrap at specified margin
^f12    Minimize        ;minimize current window

; alt f1 - f10

@f1  AsciiChart      ;allows you to choose any ASCII character
@f2  Calendar        ;dates
@f3
@f4
@f5  RegularExp      ;turns "regular expression" (patterns) on/off
@f6  AllWindows      ;search and replace across all windows when set
@f7  ToggleAutoTab   ;when on, tabs/shifttabs after { or }
@f8
@f9
@f10 StartUp         ;can be assigned a series of commands to be executed
                     ;when pE begins

; extended keyboard only

@f11 ShowMacros      ;shows any currently assigned macros
@f12 Maximize        ;maximizes current window

; alt a-z

@a  AlignParagraph   ;formats paragraph
@b  BlockMarkColumn  ;marks a rectangular area of file
@c  CascadeWin       ;arranges windows in overlapped fashion
@d  DosCommand       ;goes to DOS to execute specified command
@e  EditFile         ;edits an existing file in new window
@f  DefineFind       ;defines find string (and initiates search)
@g  ToggleGraphics   ;redefines qwerty keyboard into graphics characters
@h  ToggleHex        ;file is edited in "hex dump" mode
@i  EditIncludeFile  ;opens a file enclosed in < > on current cursor row
@j  JumpList         ;shows all open windows, allows selection
@k  KloseWindow      ;closes current window
@l  BlockMarkLines   ;marks a range of lines
@m  MergeFile        ;merges a specified file into current file
@n  NewFile          ;clears current window to edit a "new file"
@o  OpenFile         ;opens a file in current window
@p  PrintLines       ;prints file to printer or file (F3 after @p)
@q  QuickExit&Save   ;Saves file and exits (if changed)
@r  DefineReplace    ;Sets search and replace strings
@s  SaveFileAs       ;Allows filename change before saving
@t  TileWindows      ;Arranges windows in 2, 3, or 4 'Tiles'
@u  UnmarkBlock      ;Un mark a block
@v  ViewOnly         ;Open a file in uneditable window.
@w  OpenWindow       ;Opens a new window called "NO_NAME"
@x  Exit             ;Exits with prompt to save changed files
@y  DefineTag        ;Allows saving of 26 'bookmarks' for later goto
@z  ZoomWindows

; alt 1 - 0

@1  SingleLineBox    ;draws a single line box around a marked rectangle
@2  DoubleLineBox    ;draws a double line box around a marked rectangle
@3  TwoDownBox       ;double down single across
@4  TwoAcrossBox     ;double across single down
@5  ThickLineBox     ;'fat' box
@6  ASCIIOneBox      ;/
@7  ASCIITwoBox      ;|various styles of boxes without use of graphic
@8  ASCIIThreeBox    ;|characters
@9  ASCIIFourBox     ;\
@0  UndoBlock        ;Undoes last box draw and last block search&replace

@-  ManifestFilename  ;inserts current filename at cursor
@=  ManifestCalcValue ;inserts calculater register at cursor

; numeric keypad

Home    Home            ;cursor moves to beginning of line/edge of window
End     End             ;cursor moves one character past end of line
^Home   PageTop         ;cursor moves to top line of window, column stays same
^End    PageBottom      ;cursor moves to bottom line, column doesn't change

Ins     Ins             ;characters typed are inserted/replaced
Del     Del             ;the character above the cursor is deleted

Up      Up              ;cursor moves one line up, same column
Right   Right           ;cursor moves one character right, same row
Down    Down            ;cursor moves one line down, same column
Left    Left            ;cursor moves one character right, same row

^i      TabRight        ;cursor moves one tab stop to right
tab    TabLeft         ;cursor moves one tab to left
                        ;if ins is on, tab will "push" all characters to right
                        ;of cursor one tab stop, if off only cursor moves

                        ;if block is marked, all lines in block move one tab


Grey-   Cut             ;"cuts" the marked block (or a single line) to "scrap"
                        ;also called clipboard, buffer....

Grey+   Paste           ;"pastes" the contents of the "scrap" into file;
                        ;the effect differs depending on Ins/Replace mode.
                        ;cut and paste are not user assignable keys
                        ; OutputBlock and InsertDelBlock are the names of the
                        ; commands (see ^q_c and ^q_b)

                        ;Cut cuts text to file pb$$$$.ped(no affect on scrap)
                        ;Paste pastes text from  pb$$$$.ped (not from scrap)

Grey*   CopyToScrap     ;copies block to scrap, replacing

PgUp    PgUp            ;displays previous screen of file
PgDn    PgDn            ;displays next screen
^PgUp   FileTop         ;positions to first line of file
^PgDn   FileBottom      ;positions to last line of file


^Right  WordRight       ;moves cursor to start of next word
^Left   WordLeft        ;moves cursor to start of prev word

; control key combinations

^a_c    Center          ;center text in block or between margins
^a_l    LeftFlush       ;left flush text
^a_r    RightFlush      ;right flush text

^c      Calculator      ;call calculator
^d_d    DateEntry       ;enter the date into file at cursor
^d_t    TimeEntry       ;enter the time into file at cursor

^Del    UndeleteBlock   ;deleted with del key

^e      RightEdge       ;move cursor to right edge of window (east)
^w      LeftEdge        ;move cursor to left edge of window (west)

^h      BackSpace       ;delete the character to the left of the cursor


^k_k    BlockMarkStream ;marks a block beginning at the current cursor
                        ;position one character at a time
                        ;holding the control key while dragging the mouse
                        ;will also mark this kind of block
                        ;shift and arrow keys will also work
                        ;this command is provided a key sequence primarily
                        ;for macro assignment.

^k_f    FillBlock       ;allows filling a block with a specified character

^k_d    SingleSpace     ;deletes blank lines from cursor on or within block
^k_l    LowerCase       ;lower cases all characters in block
^k_u    UpperCase       ;upper cases all characters in block
^k_m    MoveBlock       ;moves the specified block to new location
                        ; - does a cut from old location and a paste in new
^k_n    DoubleSpace     ;inserts a blank line between each line
^k_s    SaveFile        ;writes file from memory to disk (uses assigned name)
^k_t    MarkWord        ;marks a single word
^k_w    WriteBlock      ;allows a range of marked lines to be written to file
^k_x    RestoreLine     ;restores line if edit has not been "committed"

^m      Enter           ;action depends on Ins/Replace; generally moves
                        ;one line down in file

^n      InsertLine      ;inserts a blank line and positions cursor on it

^q_c    OutputBlock     ;cuts block to pb$$$$.ped (see cut and paste)
^q_b    InsertDelBlock  ;merges text from pb$$$$.ped (only)

^q_l    LeaveEditorNow  ;exits editor - NO SAVES or PROMPTS, just exits.

^q_n    WordCount       ;counts words within spaces.

^t      DeleteWord      ;deletes next word
^q_t    InsertDelWord   ;inserts a word deleted with DeleteWord

^q_j    JoinLine        ;concatenates next line onto current line
^q_u    DupLine         ;duplicates from cursor on and inserts that text onto
                        ;next line, will also replace if Replace is on.

^q_w    ParagraphUp     ;moves cursor to paragraph above this one
                        ; also pgup (shift page up)
^q_z    ParagraphDown   ;moves cursor to paragraph below this one
                        ; also pgdn (shift page down)
^q_y    DeleteToEol     ;deletes from the cursor to end of line

^r      RepeatChar      ;repeats a character or command a specified number
                        ;of times
^s      SortBlock       ;sorts a block in ascending ascii order.

^bs     DeletePrevWord  ;deletes the word to the left of the cursor

^y      DeleteLine      ;deletes the current line
^u      InsertDelLine   ;undeletes the just deleted line

^Up     CursorToTop     ;positions line cursor is on to the top of the window
^5      CursorToCtr     ;positions line cursor is on to center of window
^Down   CursorToBot     ;positions line cursor is on to bottom row of window

^v_h    HorizontalRuler ;puts a horizontal ruler on the screen
^v_v    VerticalRuler   ;puts a vertcal ruler on screen
^v_u    ToggleUnixLines ;allows Unix ASCII files to be read and written
^v_x    ToggleLines     ;changes video display from 25 to 43/50 lines & back

^v_t    CursorToTop     ;positions line cursor is on to the top of the window
^v_c    CursorToCtr     ;positions line cursor is on to center of window
^v_b    CursorToBot     ;positions line cursor is on to bottom row of window

^v_a    ASCIIChart      ;calls ASCII window

^[      CancelOp        ;ESC key generally cancels operation

^\      ToggleMacro     ;turns macro processing on/off
^_      ClearMacro      ;undefines a macro

; extended keyboard extra keys

@Enter  OpenLine     ;remaining characters on line are pushed to next line
                        ;cursor remains stationary

^Grey/                  ;this is the grey / on the numpad
^Grey-
^Grey+  WrapLines       ;wraps long lines on input (only)
^Grey*  AppendToScrap   ;marked text is added to current contents of scrap
^Ins    VisibleSpaces   ;Makes blanks visible/invisible

@Home   SizeWindow   ;allows window to be sized
@End    MoveWindow   ;allows window to be moved

@Up     ScrollUp     ;scrolls text down (not the cursor)
@Down   ScrollDown   ;scrolls text up
@Left   ScrollLeft   ;etc, etc, etc,
@Right  ScrollRight  ;etc, etc, etc,

@PgUp                ;grey one
@PgDn                ;grey one
@Ins    LeaveBlanks  ;do NOT trim blanks from end of lines
@Del
@/      Delay        ;sets execution delay in macros
@Tab    OptionMenu   ;calls up the option menu to set different flags


;
; commands below are not assigned to any keys
;

SetColors               ;changes the colors of windows, menus and messages
SetInsRpl               ;sets Ins/Rpl mode on startup
DisplayOwner            ;displays name of user who installed pE
SetBackup               ;sets backup directory path
SetCursor               ;sets cursor size and shape
ToggleMenu              ;turns menu line on/off
