TVision Library

TVision 0.7 (UNIX port of Borland's Turbo Vision 2.0)

Sergio Sigala


Overview

Turbo Vision (or TV, for short) is a library that provides an application framework. With TV you can write a beautiful object-oriented character-mode user interface in a short time.

TV is available in C++ and Pascal and is a product of Borland International. It was developed to run on MS-DOS systems, but today it is available for many other platforms (ported by independent programmers).

This port is based on the Borland 2.0 version with fixes.

See the section Credits section for a list of useful sites.

Copyright

Warning: the BSD-style copyright is applicable only to the modifications brought by Sergio Sigala to the original code.

Borland has released the code to the public, but still owns the original copyright (see `lib/tv.h' for instance).

Other contributors have their respective copyright.

If you like this program, send me a postcard from your home-town.

Portability

The TV library was originally written to run on 80x86 processor. These processors are little-endian. The library assumes this as a premise. In fact, a lot of code will not run properly on big-endian machines. This means it requires a big effort to make the library fully portable across all Unix machines.

Recently I made some changes in the code to make it run correctly under big-endian machines. I tested it with a PowerPC running Linux and it works fine (maybe some other minor changes are required).

Another problem is the massive usage of the pc-specific character set.

Keyboard

In the library, ncurses functions are used to perform keyboard input.

Under FreeBSD: ALT sequences aren't currently supported. You can emulate them with ESC combinations (see below).

Under Linux: ALT combinations are usable only when you run the library from the system console. In this mode the library can detect the state of ALT, CTRL and SHIFT keys, so combinations like kbCtrlLeft are possible.

To perform an ALT emulation you can press ESC followed by the required letter key within 0.4 seconds (see `system.cc' for further details). For example to generate Alt-X press ESC X. To generate ESC press it once and wait 0.4 seconds or press it twice.

The Environment Variables

By setting an environment variable named `TVLOG' you can force TVision to write a log file. For example, `TVLOG=mylog' will produce a log file named `mylog'.

You can modify the behavior of the library by defining another environment variable named `TVOPT'. This variable is a set of strings separated by a space character. Valid strings are:

`cyrillic'
enable cyrillic character set mapping (Linux and VCS only)
`latin'
enable latin character set mapping (Linux and VCS only)
`noarrow'
disable the arrow pointer (FreeBSD only)
`nogpm'
disables support for the gpm mouse driver (Linux only)
`novcs'
inhibits the use of vcs to do video output (Linux only)

Examples for the Bourne shell:

`export TVOPT=nogpm'
does not use gpm
`export TVOPT="nogpm novcs"'
disables both gpm and vcs
`export TVOPT='
cleans the variable

Examples for the C shell:

`setenv TVOPT nogpm'
does not use gpm
`setenv TVOPT "nogpm novcs"'
disables both gpm and vcs
`unsetenv TVOPT'
cleans the variable

Compiling TVision

For more informations please read the `INSTALL' file that can be found in the source package.

TVision for FreeBSD

FreeBSD Port Overview

The install process is automated because a port is already provided (you don't need to recompile it by yourself). You should find the already compiled package at:

@url{ftp.freebsd.org/pub/FreeBSD/packages-current/devel/tvision-0.3.tgz}

or the port:

@url{ftp.freebsd.org/pub/FreeBSD/ports-current/devel/tvision}

FreeBSD Mouse Support

The library requires the `moused' daemon to be loaded. See the moused man page for more details (`man moused').

For example, if you have a Microsoft compatible mouse connected to COM1, you should issue this command:

moused -p /dev/cuaa0 -t microsoft

By using the `TVOPT' environment variable you can modify the shape of the cursor. See the section The Environment Variables section.

If you need to change some timing see the `system.cc' file.

Miscellaneous Informations

The port now works pretty with the mouse, but still needs some fixes:

TVision for Linux

Linux Port Overview

This library is to be considered stable.

Display Usage

Every program can run in two ways:

In both virtual console and remote modes SIGWINCH signal is hooked so we can resize the screen at runtime (especially useful in X-Window).

Linux Mouse Support

The library requires Gpm. I tested it with version 1.10. The package is available at:

If you need to change some timing see the `system.cc' file.

Credits

My address:

Sergio Sigala @email{ssigala@globalnet.it}
Viale De Gasperi, 8
25041 Boario Terme (BS)
Italy

Contributors in chronologic order:

Here is a list of addresses you can find useful


This document was generated on 10 Febuary 1999 using the texi2html translator version 1.51.