home *** CD-ROM | disk | FTP | other *** search
Text File | 1991-01-17 | 63.7 KB | 2,155 lines |
- ****************************************************************
- * *
- * C - W I N D O W *
- * *
- * screen formatting system for *
- * *
- * MS C, MS Quick C, Turbo C, Lattice C *
- * *
- ****************************************************************
-
-
-
- Release 1.0
-
-
- (C) 1991, Ebnet Software
-
-
- D - 8000 München 70, Passauer Strasse 2 b, Tel. 089/7698755
- - Germany -
-
-
-
-
-
- 1 Shareware
- -----------
-
- This package contains release 1.0 of the utility C-WINDOW.
- All Rights are reserved.
-
- This software is being distributed as shareware. The release you
- have is free to use and to copy.
-
- Disclaimer of warranty.
-
- This software is provided without any express or implied war-
- ranties whatsoover. Because of the diversity of conditions and
- hardware under which this software may be used, no warranty
- for a particular purpose is offered. You are advised to test
- this software utility thoroughly before relying on it. The user
- must assume the entire risk of using this software.
-
- If you agree with the software tool C-WINDOW you should become
- a registered user for a charges of $ 49.--. If you do it you will
- get the following performances
-
- - the right to use C-WINDOW
- - the full release of C-WINDOW (with all C-memory-models)
- - user support
- - update service for the following releases for a charges of
- only $ 25.--.
- - an extensive user manual
-
- Just when there are fair users it will be possible to do a further
- development of C-WINDOW.
-
- You have the chance to test the software tool C-WINDOW. If you
- will use it in future you are expected to become a registered user.
-
- A registration form you can find in the file REGIST.FOR. You can
- get it by the DOS command PRINT.
-
- The release you have isn't a cripple ware. You can use the comple-
- te functions of C-WINDOW.
-
- In the shareware release you have, there is a copyright note at
- line 24 of all screen formats.
-
-
- 2 Format generator system UniForm
- ---------------------------------
-
- To generate the screen formats for C-WINDOW release 3.0 of the
- universal format generator UniForm is in this package.
-
- UniForm is an universal format generator for the application with
-
- C-WINDOW MS C, MS Quick C, Turbo C, Lattice C
-
- BASIC-WINDOW MS Basic, MS Quick Basic, Turbo Basic, Power Basic
- GW Basic, MS Basic Interpreter, Basica
-
- PASCAL-WINDOW MS Pascal, MS Quick Pascal, Turbo Pascal
-
- COBOL-WINDOW MS Cobol, MF VS Cobol, MF Level2 Cobol,
- MF Personal Cobol, MF Professional Cobol,
- Noweck Cobol (Shareware compiler)
-
- ASSEMBLER-WINDOW MS Assembler, MS Quick Assembler, Turbo Assembler
-
- FORTRAN-WINDOW MS Fortran
-
- CLIPPER-WINDOW Clipper 87, Clipper V5
-
- Each of that products is available in a shareware release.
- You can get the full release for a charge of $49 for each product.
-
-
- Contents
- --------
-
- 3 why C-WINDOW
- 4 how to use C-WINDOW
- 5 a simple sample
- 6 line up
- 6.1 system requirements
- 6.2 disc contents
- 6.3 software installation
- 7 format generation with UniForm
- 7.1 run mode
- 7.1.1 invoke format generator
- 7.1.2 adapt options
- 7.1.3 define format name and format size
- 7.1.4 edit format layout
- 7.1.5 define field names and attributes
- 7.1.6 format management
- 7.2 functional overview
- 7.2.1 main menu
- 7.2.2 adapt options
- 7.2.3 format layout
- 7.2.4 field names/attributes
- 7.2.5 show format
- 7.2.6 show source code
- 7.2.7 format contents
- 8 format application with C-WINDOW
- 8.1 run mode
- 8.1.1 source file
- 8.1.1.1 standard include file
- 8.1.1.2 variables definition file
- 8.1.1.3 layout file
- 8.1.1.4 parameters for subroutine
- 8.1.1.5 call subroutine UNIF
- 8.1.1.6 analyze return field
- 8.1.2 compile/link
- 8.1.3 program call
- 8.2. run compilerspecific
- 8.2.1 run in MS C, MS Quick C
- 8.2.2 run in Turbo C
- 8.2.3 run in Lattice C
- 9 run in an example
- 9.1 example "order" in MS C, MS Quick C
- 9.2 example "order" in Turbo C
- 9.3 example "order" in Lattice C
- 10 example for "dynamic attribute modification"
- 10.1 example "dynamic" in MS C, MS Quick C
- 10.2 example "dynamic" in Turbo C
- 10.3 example "dynamic" in Lattice C
- 11 cursor adressing
- 12 register form
-
-
- 3 Why C-WINDOW
- --------------
-
- Its all the same. A comfortable user surface is absolutely necessary
- today. User programs as well as system programs needs with a monochrome
- display or a colour monitor a good layout to get a professional image.
-
- But - to program windows, menus and so on is relatively difficult and
- takes a lot of time. Moreover such routines should be implemented in a
- quick assembler coding. Indeed - a lot of reasons to integrate the
- screen layout into the program by a conform help.
-
- However, it is not so easy to find a conform tool. Often the tool
- is hardly to handle, the function extent is not sufficent, the
- user guide is bad or there are other reasons to be unsatisfied.
- And you can be shure that you can use the tool just in one
- compiler.
-
- C-WINDOW as an universal formatting system will help you in the future.
- The implemantation of a professional screen layout into your C programs
- will take at best a moment of time. C-WINDOW generates automatically a
- source code example when you generate a screen format. It's a help for
- professionals and beginners in C programming, too.
-
- Because of it's universal subroutine interface C-WINDOW can be used in
- all the usual C compiler.
-
- C-WINDOW is a complete solution for a screen management system and offers
- you the following highlights
-
- format generation
-
- - interactive format generation
- - mouse support
- - a lot of edit functions
- - alphanumeric numeric and selectable fields
- - variable field, text, frame and shadow attributes
- - format managemant options
-
- format application
-
- - format application in all important C compiler
- - format application with one subroutine call
- - automatic source example
- - windows, menus, popups, pulldowns ...
- - dynamic attibute modification
- - mouse support in the program
- - return of function key
- - support of monochrome and colour display
-
-
- 4 How to use C-WINDOW
- -------------------------
-
- You define the format with the UniForm format generator
- (UNIFORM.EXE) in an interactive mode...
-
- in menu "main menu"
- - the format name
- - the format size
-
- in menu "options"
- - the compiler you want to work with
- - the directory for the format files
- - standard field names and attributes for fields, text, frame
- and shadow
-
- in menu "format layout"
- - the format layout with (without) variable fields
-
- in menu "field names/ attributes"
- - the field names and attributes of the variable fields
-
- You include into the source code
- - the standard include file for the used compiler
- - the variables definition file for the variable fields
- - the subroutine call with parameters
-
- You compile the source code and link it with the respective
- C-WINDOW interface module and start the program.
-
- In future in all your programs there will be a professional screen
- layout. A professional one like in the following example.
-
- - example for screen layout
-
- ╔════════════════════════════════════════════════════════════════╗
- ║ Compilieren Programm BEISPIEL ║
- ║ ╔═════════════════════════════════════════════════════════════╗║
- ║ ║░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░║║
- ║1║░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ Datum 10 01 89 ░░░░║║
- ║ ║░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░║║
- ║2║░░░░░░░╔══════════════════════════════════════╗░░░░░░░░░░░░░░║║
- ║ ║░ Suchf║──────────────────────────────────────║░░░░░░░░░░░░░░║║
- ║ ║░░░░░░░║ ║░░░░░░░░░░░░░░║║
- ║ ║░ Datei║ Treffer 12╔═════════════════════╩═══════╗░░░░░░║║
- ║ ║░░░░░░░║ ║░░░░░░░░░░░░░░░░░░░░░░░░░░░░░║░░░░░░║║
- ║ ║░ Feldk║ Kataloge 4║░░░░░░░░░░░░░░░░░░░░░░░░░░░░░║░░░░░░║║
- ║ ║░░░░░░░║ ║░░░░░ I n f o !!!!!!! ░░░░░░║░░░░░░║║
- ║ ║░░░░░░░║────────────────║░░░░░░░░░░░░░░░░░░░░░░░░░░░░░║░░░░░░║║
- ║ ║░░░░░░░╚════════════════╣─────────────────────────────║░░░░░░║║
- ║ ╚════════════════════════╣░░░░░░░░░░░░░░░░░░░░░░░░░░░░░║══════╝║
- ║ ║░░ Schwere Fehler ░░░ 22 ░░░░║ ║
- ╔══╩══════════════════════════╩═════╗░░░░░░░░░░░░░░░░░░░░░░░║ 123 ║
- ║░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░║chte Fehler ░░░ 1 ░░░░║ ║
- ║░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░║░░░░░░░░░░░░░░░░░░░░░░░║ 000 ║
- ║░░░░░░ ░░░░░░░░║ Warnungen ░░░ 0 ░░░░╠═══════╝
- ║░░░░░░ Fehler !!! ░░░░░░░░║░░░░░░░░░░░░░░░░░░░░░░░║
- ║░░░░░░ ░░░░░░░░╠═══════════════════════╝
- ║░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░║
- ║░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░║
- ╚═══════════════════════════════════╝
-
- The screen formats in the manual are like on a monochrome monitor.
-
-
- 5 A simple sample
- -----------------
-
- Mr. Adam plans to administrate his goods received in a little data base.
- Mr. Adam has visited a short traning in the C program language and
- intends to implement the program with the MS Quick C compiler.
-
- As a proud owner of the universal formatting system C-WINDOW Mr. Adam
- would like to have a screen format in the program ...
-
- Format generation
-
- After invoking UNIFORM.EXE Mr. Adam comes into the menu "main menu". He
- takes function key F8 and comes to the menu "options". There he defines
-
- - path c:\adam
- - compiler MS Quick C
- - field specifications
- for input field alphanumeric !
- for input field numeric "
- for output field alphanumeric
- for output field numeric $
- for selectable field %
- - standard attributes
- for input field alphanumeric bright white on black
- for input field numeric bright white on black
- for output field alphanumeric white on black
- for output field numeric white on black
- for selectable field white on black
- - Standard attributes
- for text black on white
- for frame black on white
-
- After saving the options with F1 he returns to menu "main menu" by F8.
-
- The format name and format size he defines with ORDER, line 3 to 18 and
- column 5 to 70.
-
- After F1 Mr. Adam comes to menu "format layout". There is an empty
- screen with the choosen attributes for text and frame. He forms the
- screen layout with the key input and key functions like making vertical
- or horizontal lines, delete lines or columns or put on/off the frame
- around the picture. The variable fields he defines by the field
- specifications. Because Mr. Adam is not an experienced operator of
- UniForm sometimes he takes function key F9 to see the functional
- overview and the edit functions.
-
- Finally Mr. Adam saves the screen layout with F1 and comes into menu
- "field names/ attributes". Mr. Adam can modify the automatically defined
- field names and attributes of the variable fields. The first field gets
- the field name "product" and the attributes green on reed. He saves the
- field attribute with function key F2. The remaining variable fields get
- the field names "orderdate", "nr", "quantity" and "price" and the colour
- attributes white on red. After a check (F3 and F4) Mr. Adam is
- satisfied. He saves the screen format with function key F1.
-
- Mr. Adam comes back into menu "main menu". Now he can define new formats
- or use one of the format managemant functions like show formats, change
- formats, print formats, copy formats or look for a table of contents.
-
- Mr. Adam looks for the generated source example (function key ALT F3)
- and is surprised because of just a view lines of code. He omits for
- further functions and finishes the dialog with the UniForm format
- generator.
-
- In the defined directory he can find the generated format file
- (ORDER.BLD), the variables definition file (ORDER.H) and the layout
- file (ORDER.I) in the syntax of MS Quick C
-
- Format application
-
- Mr. Adam edits the program source. The source example is a great
- help for him.
-
- #include "_UFC01.H"
- #include "order.H"
- main()
- { FKZ=2;
- SM=0;
- memcpy(FMT,"order ",8);
- while(RET != 110)
- { #include "order.i"
- UNIF(&FKZ,FMT,order.&order.product,&RET,&SM,Daten);
- DB-PROCESSING
- FKZ=3;
- } }
-
- Following he compiles the program with the standard include file
- _UFC01.H and the include files ORDER.H and ORDER.I. The program
- "ORDER.EXE" will be generated.
-
- Mr. Adam calls the program ORDER.
-
- ╔══════════════════════════════════════════════════════════╗
- ║░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░║
- ║░░░░░░░░░░░░░░░░ o r d e r ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░║
- ║░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░║
- ║──────────────────────────────────────────────────────────║
- ║░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░║
- ║░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░║
- ║░░░░ articel ░░░░░ PC TYP 123456-789 ░░░░░░░░║
- ║░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░║
- ║░░░░ date ░░░░░░░░░░░░░░ 10 02 89 ░░░░░░░░║
- ║░░░░ nr ░░░░░ BST-3443344443 ░░░░░░░░║
- ║░░░░ quantity ░░░░░░░░░░░░░░ 2 ░░░░░░░░║
- ║░░░░ price ░░░░░░░░░░░░░░ 9123 38 ░░░░░░░░║
- ║░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░║
- ║░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░║
- ║░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░║
- ║░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░║
- ║ ENTER save ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░║
- ║ ESC ignore ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░║
- ║ F10 program end ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░║
- ║░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░║
- ╚══════════════════════════════════════════════════════════╝
-
- The first time Mr. Adam made a program within a screen format!
-
- 6 Line up
- ---------
-
- 6.1 System requirements
-
- The minimal configuration is ...
-
- - IBM personal computer or 100 % compatible
- - 1 disc drive
- - MS-DOS, PC-DOS release 2.1 und higher or DR-DOS
- - C-WINDOW supports all the screen modes and all usual printers
-
-
- 6.2 Disc contents
-
- components for format generator
- UNIFORM.EXE format generator program
- UNIFORM.CFG configuration file
-
- components for MS C, MS Quick C
- UFC01S.OBJ interface module - model small
- _UFC01.H standard include file
- UFC013.C source example "order"
- UFC014.C source example "easy"
- UFC015.C source example "dynamic"
-
- components for Turbo C
- UFC02S.OBJ interface module - model small
- _UFC02.H standard include file
- UFC023.C source example "order"
- UFC024.C source example "easy"
- UFC025.C source example "dynamic"
-
- components for Lattice C
- UFC03S.OBJ interface module - model small
- _UFC03.H standard include file
- UFC033.C source example "order"
- UFC034.C source example "easy"
- UFC035.C source example "dynamic"
-
- for source examples
- ORDER.BLD Format file "order"
- MESSAGE.BLD Format file "message"
- TESTFMT.BLD Format file "testfmt"
-
- others
- REGIST.FOR register form
- HELP.TXT documentation (this file)
-
-
- 6.3 Software installation
-
- You can invoke the UniForm format generator form any directory on hard
- disc or floppy disc. We recommend to install the directory uniform (MD
- \uniform). Copy the files UNIFORM.EXE and UNIFORM.CFG into that
- directory.
-
- The components of C-WINDOW you copy into the C directory.
-
-
- 7 Format generation with UniForm
- --------------------------------
-
- The format generation in UniForm is realized in an interactive mode. In
- every processing step there is a functional overview you can see by
- function key F9.
-
-
- 7.1 Run mode
-
- - Invoke format generator
- - Adapt options
- - Define format name and format size
- - Edit format layout
- - Define field names and attributes for variable fields
- - Start format management functions (option)
-
-
- 7.1.1 Invoke format generator
-
- UniForm always is to call from the installation directory. The
- configuration file UNIFORM.CFG must be in the same directory.
-
- We reccommend directory \UNIFORM.
-
- call: CD \UNIFORM
- UNIFORM
-
-
- 7.1.2 Adapt options
-
- With function key F8 you come to menu "options". In that processing step
- you modify the actual parameters and save it with F1. With F8 you return
- to menu "main menu". The configuration file UNIFORM.CFG will be updated
- with your change order.
-
- Options:
- path
- compiler
- printer
-
- field specification for alphanumeric input fields
- field specification for numeric input fields
- field specification for alphanumeric output fields
- field specification for numeric output fields
- field specification for selectable fields
-
- standard attributes for alphanumeric input fields
- standard attributes for numeric input fields
- standard attributes for alphanumeric output fields
- standard attributes for numeric output fields
- standard attributes for selectable fields
-
- standard attributes for text
- standard attributes for frame
- standard attributes for shadow
-
- For more information see 7.2.2.
-
-
- 7.1.3 Define format name and format size
-
- In the menu "main menu" you define the format name and save it with F1.
- If the format name is syntactical ok you have to define the format size.
- Save it with F1, too.
-
- For more information see 7.2.1.
-
-
- 7.1.4 Edit format layout
-
- In menu "format layout" you form the layout of the format, inside the
- defined borders. The variable fields you define with the appropriate
- field specification signs.
-
- For more information see 7.2.3.
-
-
- 7.1.5 Define field names and attributes
-
- In menu "field names/ attributes" you modify the field names and
- attributes of the defined variable fields. If there is an empty format
- (no variable field) that program step is not necessary.
-
- For more information see 7.2.4.
-
-
- 7.1.6 Format management
-
- Besides the function "new format" (F1) in menu "main menu" there are
- some more functions for format management. Take them whenever you want
- to.
-
- Format change and new attributes
- Format change and old attributes
- Format show
- Source code show
- Format print
- Source code print
- Format copy
- Format delete
- Format contents
-
- For more information see 7.2.1 to 7.2.7.
-
-
- 7.2 Functional overview
-
- 7.2.1 Main menu
-
- In menu "main menu" you take the function for format generation or
- format management. You have to define the format name and the format
- size.
-
-
- F1 Format new
-
- Creates a new screen format.
-
- The format name can be 8 bytes long. See for DOS conventions for file names.
-
- For the format size the following parameters are allowed.
- start line 0 to 22
- end line 2 to 24
- start column 0 to 77
- end column 2 to 79
-
- F2 Format change and new attributes
-
- Changing an existing format in the option directory. The attributes for
- text, frame and shadow in menu "options" are taken.
-
- ALT F2 Format change and old attributes
-
- Changing an existing format in the option directory. The attributes for
- text, frame and shadow in menu "options" are ignored.
-
- F3 Format show
-
- Display menu "format show".
-
- Shows the layout of an existing format in the option directory.
-
- ALT F3 Source code show
-
- Display menu "source code show"
-
- Shows a simple source sample in the syntax of the respective compiler. The source sample is generated in the file <format>.SMP.
-
- F4 Format print
-
- Printing an existing format in the option directory.
-
- The created print file has the name <format>.PRN. The output device you
- define in menu "options" (see 7.2.2).
-
- Logfile contents
- format name
- format directory
- column ruler
- format layout
- text area with field attributes
- frame area with field attributes
- variable fields with
- field name
- field size
- field attributes
- field length
- field type
- number of decimal digits
-
- F5 Format delete
-
- Deletes an existing format in the option directory.
-
- You have to acknowledge with F7.
-
- The following files will be deleted
- format file <format>.BLD
- variable fields file <format>.xxx (depending from compiler)
- layout file <format>.xxx (depending from compiler)
- print file <format>.PRN
-
- F6 Format copy
-
- Copies an existing format in the option directory. See for DOS
- conventions for file names.
-
- F7 Format contents
-
- Displays menu "format contents".
-
- Shows you all the existing formats in the actual option directory.
-
- F8 Options
-
- Displays menu "options".
-
- F9 Menu on/off
-
- Blank in/out the functional overview for menu "main menu".
-
- F10 Program end
-
- Stop UNIFORM.EXE. Return to DOS.
-
-
- 7.2.2 Adapt options
-
- In menu "options" you define all parameters for the UniForm format
- generator.
-
- In the following all the parameters are described.
-
- path
-
- Defines the option directory. All the format files, variables definition
- files, layout files and print files will be created in that directory.
- The input have to be an absolute path.
-
- compiler
-
- All the following compiler are supported.
-
- MS C
- MS Quick C
- Turbo C
- Lattice C
-
- printer
-
- Defines the printer interface for the functions "format print" and
- "source code print".
-
- LPT1 1. parallele printer interface
- LPT2 2. parallele printer interface
- LPT3 3. parallele printer interface
- COM1 1. serial printer interface
- COM2 2. serial printer interface
- COM3 3. serial printer interface
-
- input field alphanumeric
-
- Field specification, foreground and background attributes for
- alphanumeric input fields. In a monochrome mode only the foreground
- attribute is necessary.
-
- input field numeric
-
- Field specification, foreground and background attributes for numeric
- input fields. In a monochrome mode only the foreground attribute is
- neccesary.
-
- output field alphanumeric
-
- Field specification, foreground and background attributes for
- alphanumeric output fields. In a monochrome mode only the foreground
- attribute is necessary.
-
- output field numeric
-
- Field specification, foreground and background attributes for numeric
- output fields. In a monochrome mode only the foreground attribute is
- necessary.
-
- selectable field
-
- Field specification, foreground and background attributes for selectable
- fields. In a monochrome mode only the foreground attribute is necessary.
-
- text area
-
- Foreground and background attributes for text area. In a monochrome mode
- only the foreground attribute is necessary.
-
- frame area
-
- Foreground and background attributes for frame area. In a monochrome
- mode only the foreground attribute is necessary.
-
- shadow area
-
- Foreground and background attributes for shadow area. In a monochrome
- mode only the foreground attribute is neccessary.
-
- The following attributes for text, frame, shadow and variable fields are
- available.
-
- monochrome attributes
- invisible
- underlined
- normal
- bright, underlined
- bright
- invers
- blinking, underlined
- blinking
- blinking, bright, underlined
- blinking, invers
-
- colour attributes
- black
- blue
- green
- cobalt blue
- red
- violet
- brown
- white
- grey
- bright blue
- bright green
- bright cobalt blue
- bright red
- bright violet
- yellow
- bright white
-
- For the text area in the monochrome mode only the attributes "normal" or
- "invers" are allowed.
-
-
- F1 Save options
-
- Saving the actual screen options.
-
- The configuration file UNIFORM.CFG will be updated.
-
- F8 Main menu
-
- Return to menu "main menu".
-
- There is no backup of the options in the configuration file UNIFORM.CFG.
-
- F9 Menu on/off
-
- Blank in/out the functional overview for menu "options".
-
- F10 Program end
-
- Stop UNIFORM.EXE. Return to DOS.
-
-
- 7.2.3 Format layout
-
- In menü "format layout" you edit the format layout with the normal
- cursor functions and special edit functions. Mouse support is realized,
- too.
-
- A format composes of text and field specifications for the variable
- fields (option).
-
- text area
-
- Text can be all signs of the ASCII-code (ALT 0 bis ALT 255) without the
- actually defined specifications for the variable fields.
-
- variable fields
-
- You define variable fields with the appropriate field specifications.
- You can modify the field specifications in menu "options". There is a
- maximum in field length for every type of a variable field.
-
- input field alphanumeric
-
- Alphanumeric input fields can be provided by the program and the
- keyboard. All the signs of the ASCII-code are permitted.
-
- generation
- standard field specification: !
- lenght 80 signs in maximum
-
- examples
- ! 1 byte alphanumeric field
- !!!!! 5 byte alphanumeric field
- !!!!!!!!!! 10 byte alphanumeric field
-
- input field numeric
-
- Numeric input fields can be provided by the program and the keyboard.
- All digits and - (minus) are permitted.
-
- generation
- standard field specification: "
- lenght 16 signs in maximum for integers
- lenght 17 signs in maximum for floats (with decimal point)
-
- examples
- " 1 byte numeric field
- """"" 5 byte numeric field
- """""""""""""""" 16 byte numeric field
- ". " 3 byte numeric field, 1 decimal number
- """"".""""" 11 byte numeric field, 5 decimal numbers
- "".""""""""" 12 byte numeric field, 9 decimal numbers
-
- output field alphanumeric
-
- Alphanumeric output fields can be provided only by the program. All the
- signs of the ASCII-code are permitted.
-
- generation
- standard field specification:
- lenght 80 signs in maximum
-
- examples
- 1 byte alphanumeric field
- 5 byte alphanumeric field
- 10 byte alphanumeric field
-
- output field numeric
-
- Numeric output fields can be provided only by the program. All digits
- and - (minus) are permitted.
-
- generation
- standard field specification: $
- lenght 16 signs in maximum for integers
- lenght 17 signs in maximum for floats (with decimal point)
-
- examples
- $ 1 byte numeric field
- $$$$$ 5 byte numeric field
- $$$$$$$$$$ 10 byte numeric field
- $.$ 3 byte numeric field, 1 decimal number
- $$.$$$$$ 8 byte numeric field, 5 decimal numbers
- $$$$$$$$$.$$ 11 byte numeric field, 2 decimal numbers
-
- selectable field
-
- Selectable fields can be provided only by the program. All the signs of
- the ASCII-code are permitted.
-
- With selectable fields pull-downs or pop-ups can be realized. They have
- the text attribute, only when there is the cursor (or mouse) at this
- field, it will have the generated field attribute.
-
- generation
- standard field specification: %
- lenght 80 signs in maximum
-
- examples
- % 1 byte selectable field
- %%%%% 5 byte selectable field
- %%%%%% 6 byte selectable field
-
- You can see the functional overview and all the edit functions by
- function key F9.
-
-
- F1 Layout save
-
- Saves the format layout.
-
- A format composes of text and field specifications for variable fields.
- If there is an empty format (no variable field) you will return to menu
- "main menu." If there is a format within variable fields you will come
- to menu "field names/ attributes".
-
- F2 Show format size
-
- Shows you the format name and format size for the actual screen format.
-
- F3 Show cursor position
-
- Shows you the actual cursor position.
-
- F8 Main menu
-
- Returns to menu "main menu" without saving the format.
-
- F9 Menu on/off
-
- Blank in/out the functional overview for menu "format layout".
-
- F10 Program end
-
- Stop UNIFORM.EXE. Return to DOS.
-
-
- Edit functions
-
- Besides the described functions you can use a lot of edit
- functions. You get an overview with function key F9.
-
-
- ALT A Delete picture
-
- Deletes all the characters by SPACE. A frame retains. You have to
- acknowledge that function by F2.
-
- ALT B Delete picture from cursor
-
- Deletes in the rectangle after the actual cursor position all the
- characters by SPACE. A frame retains. You have to acknowledge that
- function by F2.
-
- ALT C Delete picture to cursor
-
- Deletes in the rectangle before the actual cursor position all the
- characters by SPACE. A frame retains. You have to acknowledge that
- function by F2.
-
- ALT D Delete line
-
- Deletes the whole line by SPACE. A frame in this line retains.
-
- ALT E Delete line from cursor
-
- Deletes the line after the actual cursor position by SPACE. A
- right frame in this line retains.
-
- ALT F Delete line to cursor
-
- Deletes the line before the actual cursor position by SPACE. A
- left frame in this line retains.
-
- ALT G Copy line
-
- Copies the actual line into the next line.
-
- ALT H Insert line
-
- Inserts a line (SPACE) after the actual line. All the following
- lines will be moved down. The last line is lost.
-
- ALT I Outsert line
-
- Outserts the actual line. All the following lines will be moved
- up. The last line is moved by SPACE.
-
- ALT J Delete column
-
- Deletes the actual column. A frame in this column retains.
-
- ALT K Delete column from cursor
-
- Deletes the actual column after the actual cursor position. A
- bottom frame in this column retains.
-
- ALT L Delete column to cursor
-
- Deletes the actual column before the actual cursor position. A top
- frame in this column retains.
-
- ALT M Copy column
-
- Copies the actual column into the next column.
-
- ALT N Insert column
-
- Inserts a column (SPACE) after the actual cursor position. All the
- following columns will be moved right. The last column is lost.
-
- ALT O Outsert column
-
- Outserts the actual column. All the following columns will be
- moved left. The last column is moved by SPACE.
-
- ALT P Horizontal Line
-
- Moves the actual line sign into the actual line. A frame retains.
-
- ALT Q Horizontal line from cursor
-
- Move after the actual cursor position the actual line sign into
- the actual line. A right frame retains.
-
- ALT R Horizontal line to cursor
-
- Moves before the actual cursor position the actual line sign into
- the actual line. A left frame retains.
-
- ALT S Vertical line
-
- Moves the actual line sign into the actual column. A frame retains.
-
- ALT T Vertical line from cursor
-
- Move after the actual cursor position the actual line sign into
- the actual column. A bottom frame retains.
-
- ALT U Vertical line to cursor
-
- Moves before the actual cursor position the actual line sign into
- the actual column. A top frame retains.
-
- ALT V Frame on/off
-
- Makes a frame around the picture or deletes it. The function
- "on/off" depends of the signs "┌" (single line) or "╔" (double
- line) at position <start line/<end line>.
-
- ALT W Shadow on/off
-
- Makes a shadow at th right side and the bottom of the format or
- deletes it.
-
- ALT X Single/ double lines
-
- Defines the actual line sign (single or double line). You can see
- the actual line sign in menu "edit functions".
-
- ALT YZ Make rectangle
-
- Makes a rectangle in the actual line sign. Put the cursor into the
- first coordinate and acknowledge with ALT Y. Then put the cursor
- into the second coordinate and acknowledge with ALT Z.
-
-
- 7.2.4 Field names/ attributes
-
- In menu "field names/ attributes" you can modify the field names
- and attributes of the variable fields.
-
- The function is an optional one. UniForm generates default field
- names and attributes. Youe can modify them, if you want to.
-
- default field name
- fld# (# is the field number beginning with 0).
-
- default attibutes in a monochrome display
- input field alphanumeric - bright
- output field alphanumeric - normal
- input field numeric - bright
- output field numeric - normal
- selectable field - normal
-
- default attributes in a colour display
- input field alphanumeric - bright white on black
- output field alphanumeric - bright white on black
- input field numeric - bright white on black
- output field numeric - bright white on black
- selectable field - bright white on black
-
- The maximal length for a field name is 15 characters. All the
- alphanumeric signs, - (minus) and _ (underline) are permitted.
- Please consider restrictions of the appropriate compiler.
-
- Dependig of the video mode you can modify the field attributes
- like the text and frame attributes.
-
-
- F1 Format save
-
- Saves the actual format and returns to menu "main menu".
-
- Creates the format file format.BLD, the variables definition file
- and the layout file (depending of the compiler) in
- the option directory. Updates the table of contents (UNIFORM.INH).
- If the format is the first one in the option directory UNIFORM.INH
- will be installed.
-
- F2 Field save
-
- Saves the field name and attributes for the actual variable field
- (marked by *) and goes to the next field.
-
- F3 Next field
-
- Goes to next field.
-
- F4 Previous field
-
- Goes to previous field.
-
- F5 Standard attributes all fields
-
- Moves the standard attributes for all fields depending of the
- field specification.
-
- F6 Standard attributes actual fields
-
- Moves the standard attributes for the actual field depending of
- the field specification.
-
- F8 Main menu
-
- Return to menu "main menu" without saving the format.
-
- F9 Menu on/off
-
- Blank in/out the functional overview for menu "field names/
- attributes".
-
- F10 Program end
-
- Stop UNIFORM.EXE. Return to DOS.
-
-
- 7.2.5 Show format
-
- Im menu "show format" a screen format is shown with the text,
- frame, shadow and field attributes.
-
-
- F1 Show field significants/ layout
-
- Shows alternate the format layout or the field names and
- attributes of the actually selected field.
-
- F3 Next field
-
- Goes to next field.
-
- F4 Previous fueld
-
- Goes to previous field.
-
- F8 Main menu
-
- Return to menu "main menu".
-
- F9 Menu on/off
-
- Blank in/out the functional overview for menu "show format".
-
- F10 Program end
-
- Stop UNIFORM.EXE. Return to DOS.
-
-
- 7.2.6 Show source code
-
- In menu "show source code" an easy source sample in the syntax of
- the compiler you have generated a format will be
- displayed. If you want to have a source example in a different
- compiler you have to generate the format for this compiler, again.
-
- UniForm moves the source sample into the file <format>.SMP.
-
- The only function in the easy source sample is to display the
- format onto the monitor. You have to compile and link the example
- and start the program in the normal way.
-
-
- F8 Main menu
-
- Return to menu "main menu".
-
- F9 Menu on/off
-
- Blank in/out the functional overview for menu "show source code".
-
- F10 Program end
-
- Stop UNIFORM.EXE. Return to DOS.
-
-
- 7.2.7 Format contents
-
- In menu "format contents" a table of all existing formats in the
- option directory is shown. In every option directory there is
- a file UNIFORM.INH.
-
-
- F8 Main menu
-
- Return to menu "main menu".
-
- F9 Menu on/off
-
- Blank in/out the functional overview for menu "format contents".
-
- F10 Program end
-
- Stop UNIFORM.EXE. Return to DOS.
-
-
- 8 Format application with C-WINDOW
- --------------------------------------
-
- The display of a screen format with C-WINDOW you have created with
- UniForm is realized in just one subroutine call (subroutine UNIF).
- The subroutine is written in a quick assembler coding. As a result the run
- time is extremely short. All the functions which are necessary for a complete
- formatting system are implemented in this subroutine. It is output formatting,
- display output, cursor adressing, mouse adressing, input formatting and
- the return of the pressed function key code.
-
- All the files which are necessary are generated by UniForm. You have to
- integrate that include files into your program source.
-
- 8.1 Run mode
-
- You have to put the include files into your program source, then to
- provide the subroutine parameters and to call the universal subroutine
- UNIF. Further you have to compile and link the program with the
- respective interface module.
-
-
- 8.1.1 Source file
-
- - include standard include file
-
- - include variables definition file
-
- - include layout file
-
- - supply subroutine parameters
-
- - call subroutine UNIF
-
- - analyse return code
-
-
- 8.1.1.1 Standard include file
-
- There is a standard include file for every C compiler. It
- contains of the definitions for subroutine parameters and the subroutine
- by itself (if it's necessary).
-
- For more information see 8.2.
-
-
- 8.1.1.2 Variables definition file
-
- The variables definition file contains the definitions of all variable
- fields of a format in syntax of the appropriate compiler.
- UniForm creates this file whenever you define a format with the format
- generator (when there is at least one variable field).
-
- For more information see 8.2.
-
-
- 8.1.1.3 Layout file
-
- The layout file contains the format layout of a screen format. UniForm
- creates this file whenever you define a format.
-
- To include the layout file into the program source is optional. All the
- format files <format>.BLD have to be in the run directory when you
- haven't an include for the layout file in the program source. The format
- layout is read form the format files <format>.BLD then.
-
- For more information see 8.1.3.
-
-
- 8.1.1.4 Parameters for subroutine
-
- Before you call the subroutine you have to supply the parameters in the
- following order.
-
- function identifier FKZ
- format name FMT
- field name 1. variable field
- return feld RET
- cursor position SM
- format layout Daten
-
- function identifier FKZ
-
- You tell UNIF the function which is to do. The field FKZ is defined in
- the standard include file as a two byte integer field.
-
- 0 save actual screen
- return to the calling program
-
- 1 clear screen
- display format layout
- display variable fields
- wait for input
- return to the calling program after ENTER/ ESC/ f-key
-
- 2 display format layout
- display variable fields
- wait for input
- return to the calling program after ENTER/ ESC/ f-key
-
- 3 display variable fields
- wait for input
- return to the calling program after ENTER/ ESC/ f-key
-
- 4 display format layout of an empty format
- wait for input
- return to the calling program after ENTER/ ESC/ f-key
-
- 5 display saved screen
-
- 6 display format layout
- display variable fields
- return to the calling program
-
- 7 display variable fields
- return to the calling program
-
- 11 display format layout to LPT1
- display variable fields to LPT1
- return to the calling program
-
- 12 display format layout to LPT2
- display variable fields to LPT2
- return to the calling program
-
- 13 display format layout to LPT3
- display variable fields to LPT3
- return to the calling program
-
- 14 display format layout to COM3
- display variable fields to COM3
- return to the calling program
-
- 15 display format layout to COM3
- display variable fields to COM3
- return to the calling program
-
- 16 display format layout to COM3
- display variable fields to COM3
- return to the calling program
-
-
- 20 dynamic modification of a field attribute
- return to calling program
-
- 21 dynamic modification of the text attribute
- return to calling program
-
- 22 dynamic modification of the frame attribute
- return to calling program
-
-
- When you take function 11 to 16, print control characters in a format
- are possible.
-
- examples (for usual 9 needle printers)
-
- ALT 14 wide print for 1 line on
- ALT 20 wide print for 1 line off
- ALT 15 compound print for 1 line on
- ALT 18 compound print for 1 line off
- ALT 10 line feed
- ALT 13 carriage return
-
-
- If you want to change text-, frame, or field attributes (functions
- 20 to 22) the new attribute you have to provide in the parameter RET.
- The field number (function 20) you have to provide in the parameter SM
- (start with 0).
-
- example (attributes "red on white" for 5. variable field)
-
- FKZ = 20 FKZ for dynamic change of field attribute
- SM = 4 5. variable field
- RET = 244 code for "red on white"
-
- example (attributes "black on green" for Text area)
-
- FKZ = 21 FKZ for dynamic change of text area
- RET = 32 code for "black on green"
-
- example (attributes "blue on red" for frame area)
-
- FKZ = 22 FKZ for dynamic change frame area
- RET = 65 code for "blue on red"
-
- You can use the dynamic attribute modification only when you put the
- layout include file into your source file. All the possible attributes
- for the monochrome and colour mode you can find in appendix A3.
-
- format name FMT
-
- You tell UNIF the format name with the parameter FMT. The field FMT is
- defined in the standard include file as an eight byte character field.
- It must be justied right and paded by SPACE.
-
- field name of the first variable field
-
- You tell UNIF the first variable field with that parameter. If you take
- function 0, 4 or 5 you can take any variable field.
-
- Return field RET
-
- You get back the pushed botton selection or an error information in the
- parameter RET. The field RET is defined in the standard include file as
- a two byte integer field.
-
- Cursor position SM
-
- You tell UNIF the cursor position or get back it with the parameter SM.
- The field SM is defined in the standard include file as a two byte integer
- field.
-
- Put the number of the variable field into SM. Only unprotected fields
- (input fields and selectable fields) you have to count (start with 0).
- It's not possiple to adress the cursor to an output field.
-
- example (cursor to 1. input/selectable field)
-
- SM = 0
-
- example (cursor to 5. input/selectable field)
-
- SM = 4
-
- Further the parameter SM is used to tell the field number to UNIF when
- function 20 (change attribute of an variable field) is used.
- In this case you have to count all variable fields.
-
- Field Daten (format layout)
-
- You tell UNIF the format layout with the parameter Daten. The field
- Daten is defined in the standard include file as a four kilobyte
- character field. Uniform creates an include file to provide that field.
- You are not allowed to modify it!
-
-
- 8.1.1.5 Call subroutine UNIF
-
- You have to call the subroutine UNIF in the syntax of the C compiler you use.
-
- For more information see 8.2.
-
-
- 8.1.1.6 Analyse return field
-
- In the parameter RET there is the pushed botton selection after calling
- the subroutine UNIF. If there was an error there will be an error
- number.
-
- - key assignment
-
- ESC 99 ENTER 100
- F1 101 SH - F1 111
- F2 102 SH - F2 112
- F3 103 SH - F3 113
- F4 104 SH - F4 114
- F5 105 SH - F5 115
- F6 106 SH - F6 116
- F7 107 SH - F7 117
- F8 108 SH - F8 118
- F9 109 SH - F9 119
- F10 110 SH - F10 120
-
- ^ - F1 121 ALT - F1 131
- ^ - F2 122 ALT - F2 132
- ^ - F3 123 ALT - F3 133
- ^ - F4 124 ALT - F4 134
- ^ - F5 125 ALT - F5 135
- ^ - F6 126 ALT - F6 136
- ^ - F7 127 ALT - F7 137
- ^ - F8 128 ALT - F8 138
- ^ - F9 129 ALT - F9 139
- ^ - F10 130 ALT - F10 140
-
- ALT - 1 141 ALT - 6 146
- ALT - 2 142 ALT - 7 147
- ALT - 3 143 ALT - 8 148
- ALT - 4 144 ALT - 9 149
- ALT - 5 145 ALT - 10 150
-
- ALT - A 151 ^ - A 177
- ALT - B 152 ^ - B 178
- ALT - C 153 ^ - C 179
- ALT - D 154 ^ - D 180
- ALT - E 155 ^ - E 181
- ALT - F 156 ^ - F 182
- ALT - G 157 ^ - G 183
- ALT - H 158 ^ - H 184
- ALT - I 159 ^ - I 185
- ALT - J 160 ^ - J 186
- ALT - K 161 ^ - K 187
- ALT - L 162 ^ - L 188
- ALT - M 163 ^ - M 189
- ALT - N 164 ^ - N 190
- ALT - O 165 ^ - O 191
- ALT - P 166 ^ - P 192
- ALT - Q 167 ^ - Q 193
- ALT - R 168 ^ - R 194
- ALT - S 169 ^ - S 195
- ALT - T 170 ^ - T 196
- ALT - U 171 ^ - U 197
- ALT - V 172 ^ - V 198
- ALT - W 173 ^ - W 199
- ALT - X 174
- ALT - Y 175
- ALT - Z 176
-
- If there was pressed ESC (99) all the modifications of variable fields
- will be rejected.
-
- For pull-downs and pop-ups use selectable fields, please. There is the
- following rule. If there was ENTER or ESC from a selectable field
- (cursor position on that selectable field) there will be the return
- number n+200 (n = number of the unprotected (input fileld ord selectable field)
- variable field in the actual format). If you put a function key
- onto a markable field you get the return code of the key assignment.
-
- - Error returns
-
- format file not accessable 2
- error in output formatting 3
- wrong function identifier 4
- printer not ready 6
- transmission error to printer 7
- paper end 8
- printer busy 9
-
-
- 8.1.2 Compile/ link
-
- You have to compile your source code within the standard include file,
- the variables definition file(s) and the layout file(s). After this you
- have to link your object file(s) within the appropriate interface module
- of C-WINDOW.
-
-
- 8.1.3 Program call
-
- There are two possibilities to start a program with UniForm.
-
- variant 1
-
- In variant 1 you put the format files <format>.BLD into the run
- directory. It's not necessary to put the layout include(s) into the
- source code. You cannot use the functions 20 to 22 (dynamic attribute
- modification).
-
- variant 2
-
- in variant 2 you put the layout include files into your source code
- (<format>.xxx (depending from the used compiler)). The format layout is
- read from this area. It's not necessary to have the format files
- <format>.BLD in the run directory.
-
-
- 8.2 Run compiler specific
-
- In the following you see all the important notes for all supported
- C dialects.
-
- An easy source sample shows you how C-WINDOW works. In that example the
- format "order" is displayed. After a function key input the program is
- finished.
-
-
- 8.2.1 Run in MS C/ MS Quick C
-
- Standard include file
-
- _UFC01.H
-
- format specific include files
-
- <format>.H variables file
- <format>.I format layout file
-
- UNIF subroutine call
-
- #include "<format>.I"
- UNIF(&FKZ,FMT,&<format>.field,&RET,&SM,Daten);
-
- compile
-
- compile with the include files
-
- link
-
- link within UFC01S.OBJ - model Small
- link within UFC01M.OBJ - model Medium
- link within UFC01C.OBJ - model Compact
- link within UFC01L.OBJ - model Large
- link within UFC01H.OBJ - model Huge
-
- source sample "ORDER.C" - display format ORDER
-
- compile: msc order /AS
- qcl /AS order.c
- link: link order ufc01s
- program call: order
-
- #include "_UFC01.H"
- #include "order.h"
- main()
- { FKZ=2;
- SM=0;
- memcpy(FMT,"order ",8);
- #include "order.i"
- UNIF(&FKZ,FMT,order.product,&RET,&SM,Daten);
- }
-
- variables file ORDER.H
-
- struct order {
- unsigned char product[20];
- unsigned char orderdate[8];
- unsigned char nr[20];
- long quantity;
- float price;
- } order;
-
- Notes
-
- The variables you have to define global.
-
- Structure compression is not allowed (compiler directive /Zp).
-
- If you want to call your program in variant 2 you cannot take the
- characters ALT 0 and ALT 255.
-
-
- 8.2.2 Run in Turbo C, Turbo C++
-
- Standard include file
-
- _UFC02.H
-
- format specific include files
-
- <format>.H variables file
- <format>.I format layout file
-
- UNIF subroutine call
-
- #include "<format>.I"
- UNIF(&FKZ,FMT,&<format>.field,&RET,&SM,Daten);
-
- compile
-
- Compile with the include files
-
- link
-
- link within UFC02S.OBJ - model Small
- link within UFC02M.OBJ - model Medium
- link within UFC02C.OBJ - model Compact
- link within UFC02L.OBJ - model Large
- link within UFC02H.OBJ - model Huge
-
- source sample "ORDER.C" - display format ORDER
-
- compile: tcc -ms -c order
- link: tlink c0s order ufc01s, order,order,,cs.lib
- program call: order
-
- #include "_UFC02.H"
- #include "order.h"
- main()
- { FKZ=2;
- SM=0;
- memcpy(FMT,"order ",8);
- #include "order.i"
- UNIF(&FKZ,FMT,order.product,&RET,&SM,Daten);
- }
-
- variables file ORDER.H
-
- struct order {
- unsigned char product[20];
- unsigned char orderdate[8];
- unsigned char nr[20];
- long quantity;
- float price;
- } order;
-
- Notes
-
- The variables you have to define global.
-
- If you want to call your program in variant 2 you cannot take the
- characters ALT 0 and ALT 255.
-
-
- 8.2.3 Run in Lattice C
-
- Standard include file
-
- _UFC03.H
-
- format specific include files
-
- <format>.H variables file
- <format>.I format layout file
-
- UNIF subroutine call
-
- #include "<format>.I"
- _UNIF(&FKZ,FMT,&<format>.field,&RET,&SM,Daten);
-
- compile
-
- compile with the include files
-
- link
-
- link within UFC03S.OBJ - model Small
- link within UFC03P.OBJ - model Medium
- link within UFC03D.OBJ - model Compact
- link within UFC03L.OBJ - model Large
-
- source sample "ORDER.C" - display format ORDER
-
- compile: lc -ms order
- link: link s\c order ufc03s,order,order,s\lc
- program call: order
-
- #include "_UFC03.H"
- #include "order.h"
- main()
- { FKZ=2;
- SM=0;
- memcpy(FMT,"order ",8);
- #include "order.i"
- _UNIF(&FKZ,FMT,order.product,&RET,&SM,Daten);
- }
-
- variables file ORDER.H
-
- struct order {
- unsigned char product[20];
- unsigned char orderdate[8];
- unsigned char nr[20];
- long quantity;
- float price;
- } order;
-
- Notes
-
- The variables you have to define global.
-
- If you want to call your program in variant 2 you cannot take the
- characters ALT 0 and ALT 255.
-
-
- 9 Run in an example
- --------------------
-
- We want a little bit upgrade the example of chapter 5.
-
- After registering an item in menu ORDER a second screen format
- MESSAGE informs about the correct update in the data base. After
- ESC the last input is ignored. After F10 the program is finished.
- You will see the screen layout before calling the program again.
-
- How to generate format ORDER you can see in chapter 5. Some
- remarks to generate format MESSAGE. It is an empty format (there
- is no variable field). As a result there is no processing step
- "field names/ attributes". The subroutine have to be called by
- function identifier 4.
-
- The printed source code in the following listings represents a
- special release of the compiler. If there is some
- discrepance in your compiler it may be you have a
- different release. Look into your program user guide for more
- information.
-
- Because of a better understanding of the source codes there is a
- generally disclaim of the principle of structured programming.
-
- You can find the source samples and the format file ORDER.BLD and
- MESSAGE.BLD on your disc (see 6.3).
-
- So you can test the program in an easy way. The format layout is
- printed in the next figure.
-
- ╔════════════════════════════════════════════════════════════════╗
- ║░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░║
- ║░░FORMAT ORDER░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░║
- ║░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░║
- ║ ║
- ║ ║
- ║ ║
- ║ article ████████████████████████████ ║
- ║ ║
- ║ price ████╔═════════════════════════════╗ ║
- ║ ║░░░░░░░░░░░░░░░░░░░░░░░░░░░░░║ ║
- ║ quantity ████║░FORMAT MESSAGE░░░░░░░░░░░░░░║ ║
- ║ ║░░░░░░░░░░░░░░░░░░░░░░░░░░░░░║ ║
- ║ date ████║░░░░░░░░░░░░░░░░░░░░░░░░░░░░░║ ║
- ║ ║░░░░░░░░░░░░░░░░░░░░░░░░░░░░░║ ║
- ║ number ████║░░░░░░░░database ok░░░░░░░░░░║ ║
- ║ ║░░░░░░░░░░░░░░░░░░░░░░░░░░░░░║ ║
- ║ ║░░░░░░░░░░░░░░░░░░░░░░░░░░░░░║ ║
- ║ ╚═════════════════════════════╝ ║
- ║ ║
- ╚════════════════════════════════════════════════════════════════╝
-
-
- 9.1 Example "order" in MS C/ MS Quick C
-
- /* variable fields */
- #include "_UFC01.h"
- #include "order.h"
- main() {
- /* save screen */
- FKZ = 0;
- UNIF (&FKZ, FMT, FMT, &RET, &SM, Daten);
- /* clear screen and display new format */
- FKZ = 1;
- ORDER:
- memcpy(FMT, "order ", 8);
- #include "order.i"
- UNIF (&FKZ, FMT, order.product, &RET, &SM, Daten);
- /* same format when ESC */
- if(RET == 99)
- { FKZ = 3; goto ORDER; }
- /* program end when F10 */
- if(RET == 110) goto ENDE;
- /* display empty format */
- FKZ = 4;
- memcpy(FMT, "message ", 8);
- #include "message.i"
- UNIF (&FKZ, FMT, FMT, &RET, &SM, Daten);
- /* display new format without clear screen */
- FKZ = 2;
- goto ORDER;
- /* display saved screen */
- ENDE:
- FKZ = 5;
- UNIF (&FKZ, FMT, FMT, &RET, &SM, Daten);
- }
-
-
- 9.2 Example "order" in Turbo C, Turbo C++
-
- /* variable fields */
- #include "_UFC02.h"
- #include "order.h"
- main() {
- /* save screen */
- FKZ = 0;
- UNIF (&FKZ, FMT, FMT, &RET, &SM, Daten);
- /* clear screen and display new format */
- FKZ = 1;
- ORDER:
- memcpy(FMT, "order ", 8);
- #include "order.i"
- UNIF (&FKZ, FMT, order.product, &RET, &SM, Daten);
- /* same format when ESC */
- if(RET == 99)
- { FKZ = 3; goto ORDER; }
- /* program end when F10 */
- if(RET == 110) goto ENDE;
- /* display empty format */
- FKZ = 4;
- memcpy(FMT, "message ", 8);
- #include "message.i"
- UNIF (&FKZ, FMT, FMT, &RET, &SM, Daten);
- /* display new format without clear screen */
- FKZ = 2;
- goto ORDER;
- /* display saved screen */
- ENDE:
- FKZ = 5;
- UNIF (&FKZ, FMT, FMT, &RET, &SM, Daten);
- }
-
-
- 9.3 Example "order" in Lattice C
-
- /* variable fields */
- #include "_UFC03.h"
- #include "order.h"
- main() {
- /* save screen */
- FKZ = 0;
- _UNIF (&FKZ, FMT, FMT, &RET, &SM, Daten);
- /* clear screen and display new format */
- FKZ = 1;
- ORDER:
- memcpy(FMT, "order ", 8);
- #include "order.i"
- _UNIF (&FKZ, FMT, order.product, &RET, &SM, Daten);
- /* same format when ESC */
- if(RET == 99)
- { FKZ = 3; goto ORDER; }
- /* program end when F10 */
- if(RET == 110) goto ENDE;
- /* display empty format */
- FKZ = 4;
- memcpy(FMT, "message ", 8);
- #include "message.i"
- _UNIF (&FKZ, FMT, FMT, &RET, &SM, Daten);
- /* display new format without clear screen */
- FKZ = 2;
- goto ORDER;
- /* display saved screen */
- ENDE:
- FKZ = 5;
- _UNIF (&FKZ, FMT, FMT, &RET, &SM, Daten);
- }
-
-
- 10 Example "dynamic attribute modification"
- -------------------------------------------
-
- With the functions 20 to 22 a dynamic change of the attributes for text,
- frame and variable fields is possible. You can use "dynamic attribute
- modification" only in variant 2 (run within the format layout file(s) in
- the source code).
-
- You have to make an include to the layout file. Then you make the
- statements for dynamic attribut modification.
-
- How that function works you can see in the following example.
-
- Format TESTFMT is displayed in the generated attributes for text, frame
- and the both variable fields fld0 and fld1 (black on white) first. The
- attributes for text, frame and the second variable field (fld1) are
- changed into "white on black". Finally the format is displayed with the
- changed attributes.
-
- In the follwowing you can see the respective source code for all
- supported compiler).
-
- You can find the source code and the format file TESTFMT.BLD on your
- disc, too.
-
- In the next figure you can see the format TESTFMT.
-
- ▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄
- ║ ║
- ║ ║
- ║ TESTFMTareallysimplesample ║
- ║ ║
- ║ ║
- ║ ╔══════════════════════════════╗ ║
- ║ ║ The uniform format generator ║ ║
- ║ ║ system <UNIFORM.EXE> creates ║ ║
- ║ ║ for every screen format a ║ ║
- ║ ║ source file automatically... ║ ║
- ║ ╚══════════════════════════════╝ ║
- ║ ║
- ║ In this example there are two variable input fields. ║
- ║ An alphanumeric and a numeric one. ║
- ║ ║
- ║ !!!!!!!!!!!! """"""" ║
- ║ ║
- ║▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄║
- ║ You return to DOS with ENTER or any other function key ║
- ▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
-
-
- 10.1 Example "dynamic" in MS C/ MS Quick C
-
- #include "_ufc01.h"
- #include "testfmt.h"
- main()
- {
- #include "testfmt.i"
- /* normal output */
- memcpy(FMT,"testfmt ",8);
- FKZ = 2;
- SM = 0;
- UNIF(&FKZ, FMT, testfmt.fld0, &RET, &SM, Daten);
- /* change attribute of field fld1 */
- FKZ = 20;
- SM = 1;
- RET = 15;
- UNIF(&FKZ, FMT, testfmt.fld0, &RET, &SM, Daten);
- /* output with changed field attributes */
- FKZ = 3;
- UNIF(&FKZ, FMT, testfmt.fld0, &RET, &SM, Daten);
- /* change text attribute and frame attribute */
- FKZ = 21;
- RET = 15;
- UNIF(&FKZ, FMT, testfmt.fld0, &RET, &SM, Daten);
- FKZ = 22;
- RET = 15;
- UNIF(&FKZ, FMT, testfmt.fld0, &RET, &SM, Daten);
- /* output with changed text and frame attribute */
- FKZ = 2;
- UNIF(&FKZ, FMT, testfmt.fld0, &RET, &SM, Daten);
- }
-
-
- 10.2 Example "dynamic" in Turbo C, Turbo C++
-
- #include "_ufc02.h"
- #include "testfmt.h"
- main()
- {
- #include "testfmt.i"
- /* normal output */
- memcpy(FMT,"testfmt ",8);
- FKZ = 2;
- SM = 0;
- UNIF(&FKZ, FMT, testfmt.fld0, &RET, &SM, Daten);
- /* change attribute of field fld1 */
- FKZ = 20;
- SM = 1;
- RET = 15;
- UNIF(&FKZ, FMT, testfmt.fld0, &RET, &SM, Daten);
- /* output with changed field attribute */
- FKZ = 3;
- UNIF(&FKZ, FMT, testfmt.fld0, &RET, &SM, Daten);
- /* change text attribute and frame attribute */
- FKZ = 21;
- RET = 15;
- UNIF(&FKZ, FMT, testfmt.fld0, &RET, &SM, Daten);
- FKZ = 22;
- RET = 15;
- UNIF(&FKZ, FMT, testfmt.fld0, &RET, &SM, Daten);
- /* output with changed text and frame attribute */
- FKZ = 2;
- UNIF(&FKZ, FMT, testfmt.fld0, &RET, &SM, Daten);
- }
-
-
- 10.3 Example "dynamic" in Lattice C
-
- #include "_ufc03.h"
- #include "testfmt.h"
- main()
- {
- #include "testfmt.i"
- /* normal output */
- memcpy(FMT,"testfmt ",8);
- FKZ = 2;
- SM = 0;
- _UNIF(&FKZ, FMT, testfmt.fld0, &RET, &SM, Daten);
- /* change attribute of field fld1 */
- FKZ = 20;
- SM = 1;
- RET = 15;
- _UNIF(&FKZ, FMT, testfmt.fld0, &RET, &SM, Daten);
- /* output with changed field attribute */
- FKZ = 3;
- _UNIF(&FKZ, FMT, testfmt.fld0, &RET, &SM, Daten);
- /* change text attribute and frame attribute */
- FKZ = 21;
- RET = 15;
- _UNIF(&FKZ, FMT, testfmt.fld0, &RET, &SM, Daten);
- FKZ = 22;
- RET = 15;
- _UNIF(&FKZ, FMT, testfmt.fld0, &RET, &SM, Daten);
- /* output with changed text and frmae attribute */
- FKZ = 2;
- _UNIF(&FKZ, FMT, testfmt.fld0, &RET, &SM, Daten);
- }
-
-
- 11 Cursor adressing
- -------------------
-
- There is the following setting for cursor and mouse in C-WINDOW.
-
- - left arrow key Cursor left
- - right arrow key Cursor right
-
- - home Cursor to field beginning
- - end Cursor to field end
-
- - down arrow key Cursor to next field
- - up arrow key Cursor to previous field
- - page down Cursor to next field
- - page up Cursor to previous field
-
- - back slash Delete character
-
- - del Delete character
-
- - ins (Mode) Insert character
-
-
- - mouse key left Cursor to mouse pointer
-
- - mouse key right Cursor to mouse pointer and return to the
- calling program (return ENTER (RET = 100))
-
-
- - sign at field end Cursor to next varaible Field
-
- - SPACE in numeric fields Accepted before decimal point
- Replaced by 0 after decimal point
-
- To
- Ebnet Software
- D-8000 München 70
- Passauer Strasse 2 b
- West Germany
-
- REGISTRATION/ PURCHASE ORDER - Software utility C-WINDOW
- ------------------------------------------------------------
-
- Please send me (us) the software utility C-WINDOW for a charge
- of $ 49.--.
-
-
- I take the folowing payment:
-
- ( ) cheque payment
- ( ) transfer to the following bank account:
- Postgiroamt München
- West Germany
- bank number 700 100 80
- account number 418194-800
- ( ) cash on deliver
- ( ) in Germany $ 3.--
- ( ) from abroad $ 6.--
-
- disc format:
- ( ) 5.25 inch disc
- ( ) 3.5 inch disc $ 2.--
-
- For a registrated user you will get an information of a new
- program release automatically. You can order it in an update
- service for the special price of $ 25.--.
-
- User support is possible for registrated users exclusively.
-
- Sender:
-
-
-
-
-
- Date/signature:
-
- .............................
-