Dec 192017
 
Modify QEdit parameters from a text file.
File QPATCH.ZIP from The Programmer’s Corner in
Category Word Processors
Modify QEdit parameters from a text file.
File Name File Size Zip Size Zip Type
QPATCH.C 4604 1393 deflated
QPATCH.DOC 3982 1765 deflated
QPATCH.EXE 25273 11472 deflated
QPATCH.H 358 163 deflated
ROUTINES.C 1874 574 deflated
SCRATTR.EXE 38271 20691 deflated
STRUCTS.C 6204 1817 deflated

Download File QPATCH.ZIP Here

Contents of the QPATCH.DOC file


QPATCH
------
Qpatch.exe is a means of reconfiguring QEDIT ver 2.15,
copyrighted (1985-1991) by Semware, from a text file. QPATCH is not
copyrighted. QPATCH has no connection of any sort to Semware.

The input file to QPATCH consists of a series of specifications
of the form

QUESTION : ANSWER

one per line.

For example:

Amount of memory to reserve from DOS (in paragraphs) [0,8..32767] [] : 0
Code generated by ALT numeric keypad [0..255] [] : 0
Do you want the ESCAPE command to invoke the menus (Y/N)? [] : Y
Should the editor restore the starting drive/dir on program exit (Y/N)? [] : Y
Should the editor change the DOS PROMPT during a shell (Y/N)? [] : N

QPATCH reads these question-answer pairs, and then patches
q.exe accordingly.

A "form" for the input file can be generated by executing

Qpatch -printform >FILENAME

If QEDIT is named something other than "q.exe" than that name
must appear on the command line as well:

Qpatch -printform >FILENAME QNAME.EXE

This form, redirected to the file called FILENAME, will consist of the
questions, a specification of the current settings of "q.exe" (in
square brackets before the colon), the colon, but no answers will be
given after the colon. QPATCH must be run in the directory that q.exe
is in, though QPATCH itself can be in any directory in the PATH. You
then can edit the file FILENAME, putting in answers to questions after
each colon. You do not have to specify answers to all the questions,
just for those items that you want to change. Then execute:

Qpatch
and QPATCH will change those items for which you have supplied
answers. It also produces a report of the changes made, which can
be redirected to a file.

Scrattr.exe is a program that displays all the possible screen
attributes. You may refer to its output in deciding what screen
attributes to choose for the questions about screen attributes.

I wrote QPATCH.exe for people like myself who don't like menus,
and would rather edit text files. It duplicates the job of part of the
program "QCONFIG.EXE" supplied with QEDIT; it handles all of the
"Special Options", "Advanced Options", "Printer Options" and "Tab
Options", and "Color Options" of that program. QPATCH does not
handle the "Help" or "Key" configurations, so QCONFIG should still
be used for that.

The problem with QCONFIG is that there is no way to store
several sets of answers to the questions that QCONFIG asks; every
reconfiguration session with QCONFIG consists of typing in anew all the
values to be changed; not only that, but it is often necessary to go
through long lists of irrelevant questions to get to the one you want
to change the answer to. The Qpatch patch files, on the other hand,
allow several alternative configurations to be stored (as patch files),
and to change one question, you need merely search for it (With SEARCH
in QEDIT of course) and then put in the new answer.

Since a patch file does not have to answer (or even contain)
every question, you might save modular patch files, with, for example,
only color attributes, or only printer settings.

QPATCH does some minimal type checking, so that if the answer
is meant to be 'Y' or 'N' Qpatch will not accept a number, but it does
not, for example, check whether a numerical answer falls within an
acceptible range. Each question specifies the range of its answer, and
it is up to you to do right.

I wrote QPATCH rapidly, and cannot warrant that it works
properly for every configuration. It is up to you to determine this
yourself. I have included the source code for this purpose. QPATCH.exe
was compiled from this source using Microsoft Quick C 2.0: "QCL
QPATCH.C structs.c routines.c".












 December 19, 2017  Add comments

Leave a Reply