AsmFunc is a collection of support programs and
utilities.

INDEX
   1.  asmedit_config    - configure AsmEdit options
   2.  echo_key          - echo key strings
   3.  file_browse       - directory browse and file selection
   4.  file_info         - show file information and set attributes
   5.  format_doc        - format text file
   6.  show_sys_err      - expand kernel error numbers to descriptions
   7.  a.f3              - asmedit "make" function key script
   8.  a.f4              - asmedit "debug" function key script
   9.  a.f5              - asmedit "spell" function key script
   10. a.f6              - asmedit "compare" function key script
   11. a.f7              - asmedit "print" function key script

--------------------------------------------------------------------------

1.0 asmedit_config - configure AsmEdit options

    Changes "a.ini" file used by AsmEdit to control
    margins, edit modes, search case, etc.

1.1 Purpose

    Asmedit_config allows AsmEdit to be configured
    both inside the program and externally before
    executing the editor.  It reduces the AsmEdit
    executable size and makes coding more modular.

1.2 Inputs

    No parameters are passed to asmedit_config.
    Once the program is executing a form is diplayed
    which call be filled out using the keyboard keys.
    Also fields can be selected and set using a mouse
    if asmedit_config is running in a xterm.

1.3 Ouptuts

    The file "a.ini" is stored in users home directory
    at:  ~/.asmide/edit/a.ini
    If an existing "a.ini" file is found it will be
    updated with any changes made.

1.4 Install Location

    Since asmedit_config is only used by AsmEdit it is
    placed at ~/.asmide/edit/asmedit_setup

1.5 Design

    Asmedit_config is a ELF binary written in assembler.
    It is released as a tar.gz source file and uses the
    nasm assembler for compiles.  It is considered beta
    software and is not portable beyond x86 Linux.

                        
--------------------------------------------------------------------------

2.0  echo_key          - echo key strings

    Displays keys typed on keyboard.


2.1 Purpose

    Echo_key is used to find key strings when writing
    keyboard handlers.  It will show what each key
    reports when pressed.

2.2 Inputs

    No parameters are passed to echo_key.
    The "q" is used to terminate (exit).

2.3 Ouptuts

    The display of each key press includes the
    hex key string along with the name of key.

2.4 Install Location

    Echo_key is installed in local /bin driectory or
    /usr/bin 

2.5 Design

    Echo_key is a ELF binary written in assembler.
    It is released as a tar.gz source file and uses the
    nasm assembler for compiles.  It is considered beta
    software and is not portable beyond x86 Linux.

--------------------------------------------------------------------------

3.0  file_browse       - directory browse and file selection

    Displays file selection window on right side of screen.

3.1 Purpose

    File selection is very common operation used in application.
    File_browse is intended to provide a common module which can
    be used by programs to select files.  This reduces the size
    of applications and speeds coding.

3.2 Inputs

    No parameters are passed to echo_key.
    The "arrow" keys are used to select files
    and move back or forward in directory tree.
    Files can be selected by pressing "enter" or
    the program aborted by  typing "ESC"

    The mouse is not utilized.

3.3 Ouptuts

    The selected file is written to the file "tmp.dir"
    at location ~/.asmide/tmp.dir
    The full path of selected file will be stored and
    the string terminated with a zero byte.

3.4 Install Location

    File_browse is installed at ~/.asmide/edit/file_browse

3.5 Design

    File_browse is a ELF binary written in assembler.
    It is released as a tar.gz source file and uses the
    nasm assembler for compiles.  It is considered beta
    software and is not portable beyond x86 Linux.



--------------------------------------------------------------------------

4.0  file_info       - show file information and set attributes

    Displays form showing file state a allows setting of attributes,
    and ownership.

4.1 Purpose

    File_info is a utility for use by programs or by users.  It
    provides a quick and easy way to set attributes or check
    status of files.

4.2 Inputs

    The file name is passes as an input to file_info.

    The "arrow" keys are used to select text entry fields.
    All other keys are described on the form.  The
    mouse can be used to select attributes or push
    buttons (xterm only).
 
4.3 Ouptuts

    The selected file is updated if changes are entered.
    If root premission is needed to make updates or other
    problems occur the update will not appear when the
    apply button is pressed.

4.4 Install Location

    File_info is installed in local /bin driectory or
    /usr/bin 

4.5 Design

    File_info is a ELF binary written in assembler.
    It is released as a tar.gz source file and uses the
    nasm assembler for compiles.  It is considered beta
    software and is not portable beyond x86 Linux.

--------------------------------------------------------------------------

5.0  format_doc        - format text file

    Process's a text file by replacing strings and lines.

5.1 Purpose

    Format_doc was written to reformat text in a standard
    format to another format.  It can work with any text
    document to produce a new format and could also be used
    to change strings in source files.

5.2 Inputs

    usage format_doc <in-file> <out-file>

    a format_doc.ini file must also exist in
    the local directory. format_doc.ini is a text
    file describing the changes needed.  Each change
    is a one line command and all commands are called
    a table.

    table entries are repetitiions of the following
    three fields:
    "match-string" "replacement-string" "actions"

    the code \n in strings can be used for new-line (0ah)
 
    The actions available are:
     1 replace the match string with replace-string
     2 move up one line
     3 move down one line
     4 replace whole llne rather than just the match-string
       (line needs 0ah at end)
     5 insert line above current line
       (line needs 0ah at end)
     6 insert line below current line
       (line needs 0ah at end)
     7 insert replace-string at front of current line
     8 delete right to end of line
       (place at start of actions to remove match ->)
     9 do actions till end of file reached
 
    if program hangs or aborts this is almost always due
    to infinite loops caused by impossible actions. Most
    problems can be avoided by keeping the match string
    pointer beyond last action. This avoids finding the
    same string over and over when repeating actions.
    Use the code 3 to move match pointer down.

5.3 Ouptuts

    the out-file will written with all match-strings
    replaced with replace-strings

5.4 Install Location

    Format_doc is installed in local /bin driectory or
    /usr/bin 

5.5 Design

    format_doc first finds the match string and then
    begins executing the actions at end of each entry
    in format_doc.ini
 
    If repeat code is placed at end of actions, they
    are repeated till the match string is not found.
    It is important to keep the match string beyond
    its last match to avoid infinite loops when using
    the repeat action.

    Format_doc is a ELF binary written in assembler.
    It is released as a tar.gz source file and uses the
    nasm assembler for compiles.  It is considered beta
    software and is not portable beyond x86 Linux.

--------------------------------------------------------------------------

6.0  show_sys_err      - expand kernel error numbers to descriptions

    Displays a descripition of error and wait for key press.

6.1 Purpose

    Show_sys_err is a utility for use by programs or by users.  It
    provides a quick and easy way to expand error numbers into text.

6.2 Inputs

    The error number is passed as a numeric string to
    show_sys_err.  For example:  "show_sys_error 5"

6.3 Ouptuts

    A text string is displayed describing the error.
    This is followed by the message: "press any key".
    It is assumed the keyboard is in raw mode at this
    point.  It show_sys_err is called from the console
    will not be in "raw" mode and the <enter> key will
    be needed to terminate the program.

6.4 Install Location

    show_sys_err is installed in local /bin driectory or
    /usr/bin 

6.5 Design

    show_sys_err is a ELF binary written in assembler.
    It is released as a tar.gz source file and uses the
    nasm assembler for compiles.  It is considered beta
    software and is not portable beyond x86 Linux.


------------------------------------------
7.  a.f3              - asmedit "make" function key script

a.f3 - example compiler interface
 INPUTS
$1  is name of program being edited. The parmaeter can be used to call
compiler  or  makefiles  can  be  called.  The  example scripts call a
makefile.
 OUTPUT
The  output  of  any  make  or  compile  operation  can  be  piped  to
$HOME/.a/tmp.2 for display. This puts the compile messages in a window
on the right side of edit screen.
------------------------------------------
8.  a.f4              - asmedit "debug" function key script

a.f4 - example debugger interface
 INPUTS
$1  is  base  name of program being edited. It can be used to envoke a
debugger or the debug target can be coded into the a.f4 script.
 OUTPUT
nothing is output.
 NOTES
   file: a.f4 <- tied to function key f4
------------------------------------------
9.  a.f5              - asmedit "spell" function key script

a.f5 - example spell check script
 INPUTS
$1  is  base  name of program being edited. It can be used to envoke a
spell program
 OUTPUT
The file name in $1 is read back and used as current edit file.
 NOTES
   file: a.f5 <- tied to function key f5
------------------------------------------
10. a.f6              - asmedit "compare" function key script

a.f6 - example file compare script
 INPUTS
The  two files need to be loaded as file1 and file2. Then function key
f6 pressed. The two files enter here as temp files in $1 and $2
 OUTPUT
The  two  temp  files  are  read back into asmedit and any changes are
included.
 NOTES
   file: a.f6 <- tied to function key f6
*     several  good compare programs exist and can be called * here. *
------------------------------------------
11. a.f7              - asmedit "print" function key script

a.f7 - example print script
 INPUTS
$1 is base name of file to print.
 OUTPUT
printer is called, but edit file unouched.
 NOTES
   file: a.f7 <- tied to function key f7
*     This example script only works for the HP 500 * printer. It does
show how enscript can be used * with a menu program to print two pages

