Museum

Home

Lab Overview

Retrotechnology Articles

⇒ Online Manual

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

restartterm(3)

setupterm(3)  —  Subroutines

Digital

NAME

setupterm − perform low level terminal setup

SYNOPSIS

#include <curses.h>

setupterm(term, filenum, errret)
char ∗term;
int filenum;
int ∗errret;

DESCRIPTION

This function sets up the terminal from the terminfo database. The parameter term is the terminal type.  If this parameter is set to NULL, the environment variable TERM will be used. The filenum parameter is a file descriptor, not a stdio pointer.  It is used for all the output generated by setupterm. 

The terminfo boolean, numeric, and string values are stored in a structure of type TERMINAL. 

After setupterm returns successfully the variable cur_term is initialized. This variable points to the TERMINAL structure. The cur_term pointer can be saved before calling setupterm again as further calls to setupterm allocate new space; the space pointed to by cur_term is not overwritten. 

RELATED INFORMATION

restartterm(3)

Typewritten Software • bear@typewritten.org • Edmonds, WA 98026