source: trunk/minix/lib/curses/tabsize.c@ 20

Last change on this file since 20 was 9, checked in by Mattia Monga, 14 years ago

Minix 3.1.2a

File size: 1.7 KB
Line 
1/****************************************************************/
2/* Tabsize() routines of the PCcurses package */
3/* */
4/****************************************************************/
5/* This version of curses is based on ncurses, a curses version */
6/* Originally written by Pavel Curtis at Cornell University. */
7/* I have made substantial changes to make it run on IBM PC's, */
8/* And therefore consider myself free to make it public domain. */
9/* Bjorn Larsson (...mcvax!enea!infovax!bl) */
10/****************************************************************/
11/* 1.0: Release: 870515 */
12/****************************************************************/
13/* Modified to run under the MINIX operating system by Don Cope */
14/* These changes are also released into the public domain. */
15/* 900906 */
16/****************************************************************/
17
18#include <curses.h>
19#include "curspriv.h"
20
21/****************************************************************/
22/* Wtabsize(win,ts) sets the tabsize of window 'win' to 'ts', */
23/* And returns the original value. */
24/****************************************************************/
25
26int wtabsize(win, ts)
27WINDOW *win;
28int ts;
29{
30 int origval;
31
32 origval = win->_tabsize;
33 win->_tabsize = ts;
34 return(origval);
35} /* wtabsize */
36
37/****************************************************************/
38/* Tabsize(ts) sets the tabsize of stdscr to 'ts', and returns */
39/* The original value. */
40/****************************************************************/
41
42int tabsize(ts)
43int ts;
44{
45 int origval;
46
47 origval = stdscr->_tabsize;
48 stdscr->_tabsize = ts;
49 return(origval);
50} /* tabsize */
Note: See TracBrowser for help on using the repository browser.