home *** CD-ROM | disk | FTP | other *** search
-
- OVERVIEW OF WINDOWS FOR C
-
- Windows for C provides an integrated set of window-based functions that
- simplify all common screen display tasks.
-
- Capabilities include:
-
- * Unlimited windows and files
- * Horizontal and vertical scrolling
- * Pop-up windows, menus, and help files
- * Status line management
- * Off-screen buffers
- * Rapid screen changes
- * Frugal memory use
- * Logical video attributes
- * Color-control
- * Highlighting
- * Window names
- * String output with word wrap and auto scroll
- * Formatted string output
- * Print windows
- * Keyboard input
- * Read screen attributes and characters
- * Plus a library of over 80 building
- block subroutines
-
- Managing windows: There is no limit to the number of windows that can
- be established. Each window is controlled by a C-language structure
- that contains all the information needed for managing the window.
- Reference to the window structure substitutes for long parameter lists
- in function calls. This simplifies coding, reduces errors, and saves
- time.
-
- Displaying files: Routines are provided for reading ASCII files into
- memory and viewing them through windows. A cursor-pad interpreter
- permits scrolling through the file horizontally or vertically. These
- routines, for which source is provided, will be especially helpful for
- providing users with access to help files. Context-sensitive help
- systems are easily implemented.
-
- Pop-up windows: Windows can either pop-up onto or overwrite the
- screen. Pop-up windows are implemented simply by setting a switch in
- the window structure. Underlying screen contents are automatically
- saved and restored for pop-up windows.
-
- Pop-up menus: Ready-to-use routines are provided for pop-up menus.
- The menu can be larger than the window. The cursor keys are used to
- select an item. Selections are highlighted. Source is provided so
- that the routines can be modified and enhanced to meet individual
- needs.
-
- Status-line management: Status lines are easily maintained as
- single-line windows. Special options in the string output functions
- simplify the task of updating information in the status line.
-
- Off-screen buffers: Facilities are provided for managing and
- displaying memory files. These files, which can be of any size, can be
- updated dynamically. They provide a superior alternative to virtual
- screens for the capture and display of real-time information.
-
- Display speed: Writing to the screen is done via our own interface
- routines that have been designed to achieve speed without sacrificing
- clarity.
-
- Memory usage: The only memory initially required by a window is that
- required by the window structure -- about 50 bytes.
-
- Memory is used only when needed. All functions are in separate
- modules; so only those used are linked into the executable
- program. Because of efficient design, the code is compact.
- Typically, programs that make extensive use of the Windows library
- will increase in size by 15 to 20 kilobytes.
-
- Memory is allocated for window buffers only when off-screen
- storage of window contents is needed, such as when a pop-up window
- is displayed. Only the amount of memory needed at the moment is
- allocated. When no longer needed, buffer memory is released.
-
- Logical video attributes: Professional programmers will appreciate the
- availability of logical video attributes in Windows for C. A single
- program can be written that uses the full color capabilities of the IBM
- Enhanced Graphics Adapter and the more limited colors available with
- the standard Color/Graphics adapter, while still being completely
- legible on monochrome displays.
-
- Color-control: Functions provide complete control over color
- capabilities of the IBM PC family. The colors of window borders and
- contents can be set individually. A Window will automatically be
- cleared to the background attribute specified for that window.
-
- Highlighting: Highlighting is easily accomplished using a function
- that changes the attribute without affecting the character contents of
- specified portions of a window.
-
- Writing to windows: A variety of string and character output functions
- are available. Switches are provided to control word wrap, auto
- scrolling on full screen, automatic updating of the cursor, screen
- cursor placement, and auto clearing to the end of a row.
-
- Formatted output: Formatted string output, equivalent to printf(), is
- provided. Screen output is much faster than that provided by
- compiler-supplied printf() routines, which utilize DOS function calls
- to write to the screen.
-
- Printing windows: Contents of windows can be copied to standard ASCII
- files or to the printer. The print-window function simplifies printing
- text in unusual formats.
-
- Reading the keyboard: A function is provided that reads the keyboard
- and returns the entire IBM Extended ASCII key set with a single call.
- The keyboard buffer can also be checked for an available keystroke.
-
- Reading the screen: Characters and attributes can be read
- singly, or the character-attribute contents of specified parts of a
- window can be read in a single call.
-
- TopView Compatibility: Programs that rely on Windows for C for screen
- output are fully compatible with TopView, IBM's multi-tasking operating
- system. The programs can operate in background mode under TopView and
- can make use of TopView's windowing functions.
-
- IBM Enhanced Graphics Adapter support: A global variable is set when
- the IBM EGA is the active display adapter. When the EGA is active,
- output to the screen in color modes is as fast as with the Monochrome
- Display Adapter.
-
- Building blocks: A library of over 65 building-block subroutines
- allows you to modify the supplied modules and to construct new
- integrated routines to suit your needs.
-
- PRACTICAL ROUTINES AND LEARNING AIDS
-
- In addition to tutorials and code examples included in the reference
- manual, several integrated routines are provided that can be used
- without modification to accomplish common tasks of window management.
- These routines are incorporated in demonstration programs that
- illustrate their use and serve as teaching tools for the use of Window
- functions. C source to the library level is provided for these
- programs.
-
- * demo_wn reads multiple ASCII files into memory, displays them in
- multiple windows, and provides the user with cursor-pad control
- for viewing the files. Complete C source is provided for the
- file-input and cursor-control routines.
-
- * dem_menu reads an ASCII file into memory and provides the user
- with the ability to call up a menu and select an item. Cursor pad
- commands are used to move through the menu, which can be larger
- than the menu-display window. Menu items pointed to are
- highlighted with reverse video. After selection, the menu is
- automatically removed and the original screen contents replaced.
- The item selected is reported on a status line.
-
- * dem_cmov demonstrates the color management and window storage
- and movement capabilities of Windows for C. Colored windows are
- moved rapidly around the screen. The movement of images is useful
- for games, but the rapid speed with which windows can be stored
- and restored is also valuable for business applications.
-
- * prt_labl reads addresses stored sequentially in a file and
- places them on the screen in side-by-side format. A print-window
- function is then used to print the windows in this format. This
- program illustrates how Window functions can be use to simplify
- printing in unusual formats.
-
- * dem_grph illustrates the use of the graphing functions included
- in Windows for C. Vertical and horizontal bar graphs are drawn.
-