ncurses 6.0 - patch 20160730 · mirror/ncurses@aa70bf3 (original) (raw)
`@@ -27,7 +27,7 @@
`
27
27
` * sale, use or other dealings in this Software without prior written *
`
28
28
` * authorization. *
`
29
29
` ****************************************************************************
`
30
``
`-
- @Id: tput.1,v 1.36 2016/04/02 23:41:08 tom Exp @
`
``
30
`+
- @Id: tput.1,v 1.42 2016/07/30 21:01:09 tom Exp @
`
31
31
`-->
`
32
32
`
`
33
33
`
`
`@@ -53,6 +53,7 @@
tput 1
`
53
53
``
54
54
`
SYNOPSIS
`
55
55
`tput [-Ttype] capname [parameters]
`
``
56
`+
tput [-Ttype] clear
`
56
57
`tput [-Ttype] init
`
57
58
`tput [-Ttype] reset
`
58
59
`tput [-Ttype] longname
`
`@@ -268,7 +269,7 @@
tput 1
`
268
269
` tab settings for some terminals, in a format appro-
`
269
270
` priate to be output to the terminal (escape
`
270
271
` sequences that set margins and tabs); for more
`
271
``
`-
information, see the "Tabs and Initialization" sec-
`
``
272
`+
information, see the Tabs and Initialization, sec-
`
272
273
` tion of terminfo(5)
`
273
274
``
274
275
``
`@@ -324,10 +325,56 @@
tput 1
`
324
325
` ---------------------------------------------------------------------
`
325
326
``
326
327
``
``
328
`+
HISTORY
`
``
329
`+
The tput command was begun by Bill Joy in 1980. The ini-
`
``
330
`+
tial version only cleared the screen.
`
``
331
+
``
332
`+
Keith Bostic replaced this in 1989 with a new implementa-
`
``
333
`+
tion based on the AT&T SystemV program tput. Like the
`
``
334
`+
AT&T program, Bostic's version accepted some parameters
`
``
335
`+
named for terminfo capabilities (clear, init, longname and
`
``
336
`+
reset). However (because he had only termcap available),
`
``
337
`+
it accepted termcap names for other capabilities.
`
``
338
+
``
339
`+
At the same time, Bostic added a shell script named
`
``
340
`+
"clear", which used tput to clear the screen.
`
``
341
+
``
342
`+
Both of these appeared in 4.4BSD, becoming the "modern"
`
``
343
`+
BSD implementation of tput.
`
``
344
+
``
345
+
327
346
`
PORTABILITY
`
328
``
`-
The longname and -S options, and the parameter-substitu-
`
329
``
`-
tion features used in the cup example, are not supported
`
330
``
`-
in BSD curses or in AT&T/USL curses before SVr4.
`
``
347
`+
This implementation of tput differs from AT&T tput in two
`
``
348
`+
important areas:
`
``
349
+
``
350
`+
o tput writes to the standard output. That need not be
`
``
351
`+
a regular terminal.
`
``
352
+
``
353
`+
The AT&T implementation's init and reset commands use
`
``
354
`+
the tset source, which manipulates terminal modes. It
`
``
355
`+
successively tries standard output, standard error,
`
``
356
`+
standard input before falling back to "/dev/tty" and
`
``
357
`+
finally just assumes a 1200Bd terminal. When updating
`
``
358
`+
terminal modes, it ignores errors.
`
``
359
+
``
360
`+
o AT&T tput guesses the type of its capname operands by
`
``
361
`+
seeing if all of the characters are numeric, or not.
`
``
362
+
``
363
`+
Most implementations which provide support for capname
`
``
364
`+
operands use the tparm function to expand parameters
`
``
365
`+
in it. That function expects a mixture of numeric and
`
``
366
`+
string parameters, requiring tput to know which type
`
``
367
`+
to use.
`
``
368
+
``
369
`+
This implementation uses a table to determine the
`
``
370
`+
parameter types for the standard capname operands, and
`
``
371
`+
an internal library function to analyze nonstandard
`
``
372
`+
capname operands.
`
``
373
+
``
374
`+
The longname and -S options, and the parameter-substitu-
`
``
375
`+
tion features used in the cup example, were not supported
`
``
376
`+
in BSD curses before 4.3reno (1989) or in AT&T/USL curses
`
``
377
`+
before SVr4 (1988).
`
331
378
``
332
379
` IEEE Std 1003.1/The Open Group Base Specifications Issue
`
333
380
` 7 (POSIX.1-2008) documents only the operands for clear,
`
`@@ -368,22 +415,12 @@
tput 1
`
368
415
` curses implementation provide a tput utility which
`
369
416
` does not provide the capname feature.
`
370
417
``
371
``
`-
Most implementations which provide support for capname op-
`
372
``
`-
erands use the tparm function to expand parameters in it.
`
373
``
`-
That function expects a mixture of numeric and string
`
374
``
`-
parameters, requiring tput to know which type to use.
`
375
``
`-
This implementation uses a table to determine that for the
`
376
``
`-
standard capname operands, and an internal library func-
`
377
``
`-
tion to analyze nonstandard capname operands. Other
`
378
``
`-
implementations may simply guess that an operand contain-
`
379
``
`-
ing only digits is intended to be a number.
`
380
``
-
381
418
``
382
419
`
SEE ALSO
`
383
420
`clear(1), stty(1), tabs(1), tset(1), terminfo(5),
`
384
421
`
385
422
``
386
``
`-
This describes ncurses version 6.0 (patch 20160723).
`
``
423
`+
This describes ncurses version 6.0 (patch 20160730).
`
387
424
``
388
425
``
389
426
``
`@@ -404,6 +441,7 @@
tput 1
`
404
441
`
`
405
442
`
`
406
443
`
`
``
444
`+
`
407
445
`
`
408
446
`
`
409
447
`
`