HPlogo MPE/iX Developer's Kit Reference Manual Volume 2: HP 3000 MPE/iX Computer Systems > Chapter 4 CURSES

tputs putp

» 

Technical documentation

Complete book in PDF
» Feedback

 » Table of Contents

 » Index

The tputs and putp routines are used to apply padding information and output string (interface to terminfo).

Syntax

   #include <curses.h>



   int tputs (char *str, int affcnt, int (*putc) (int));

   int putp (char *str);

Parameters

str

A pointer to a terminfo variable or return value from tparm() or tigetstr().

affcnt

The number of lines affected, or 1 if not relevant.

putc

The output function.

Return Values

OK

Successful completion.

ERR

An error occurred.

Description

The tputs() and putp() routines are low-level routines used outside of CURSES to deal directly with the terminfo database. The use of appropriate CURSES routines is recommended for most situations.

The tputs() routine adds padding information and then outputs str. The value for str must be the result value from tparm(), or tigetstr(), or a terminfo string variable.

The tputs() routine replaces the padding specification (if one exists) with enough characters to produce the specified delay. Characters are output one at a time to putc, a routine similar to putchar().

The putp() routine calls tputs() as follows:

   tputs(str, 1, _putchar)
NOTE: The output of putp() goes to stdout, not to the file descriptor, fildes, specified in setupterm().

Implementation Considerations

UNIX System V implementation

See Also

tigetstr(), tparm()

Portability

HP-UX, UNIX System V

Feedback to webmaster