col 中文man页面

系统
Col 过滤掉反向(以及半反向)换行符(LF: line feed or NL: new line), 这样输出按正常顺序,即只包括正向和半正向换行符, 而且在可能的地方使用tab替换白空格.这对 nroff(1) 和 tbl(1) 的输出处理很有用处.

NAME(名称)

col - 过滤掉输入中的反向换行符  

SYNOPSIS(总览)

col [-bfx ] [ Fl l Ar num ]  

DESCRIPTION(描述)

Col 过滤掉反向(以及半反向)换行符(LF: line feed or NL: new line), 这样输出按正常顺序,即只包括正向和半正向换行符, 而且在可能的地方使用tab替换白空格.这对 nroff(1) 和 tbl(1) 的输出处理很有用处.

col 从标准输出读入,并写出到标准输出上.

选项如下:

-b
不输出任何退格符,在每列的位置上只打印***写的那个字符.
-f
允许正向半换行符(``fine''模式). 通常,处于半行分界线上的字符打印在下一行.
-x
输出多个空格以替换tab.
-l num
在内存中至少缓冲 num 行. 默认情况下,缓冲128行.

col 所能理解的用于回车操作的控制序列以及它们的十进制值都列在下面的表中:

ESC-7
反向换行符(escape后接7)
ESC-8
反向半换行符(escape后接8)
ESC-9
正向半换行符(escape后接9)
backspace
反向移动一列(8);在***列则忽略.
carriage return
(13)
newline
正向换行符(10);同时执行回车(carriage return)操作
shift in
转到正常字符集(15)
shift out
转到备选的字符集(14)
space
正向移动一列(32)
tab
正向移动到下一个tab(9)
vertical tab
反向换行符(11)

丢弃所有不被承认的控制字符和escape序列.

当读取字符时, Col 保持着与字符集的联系,而且在输出时确保字符集是正确的.

如果输入设备试图回复到最近被刷新的行, col 会显示一条警告消息.  

SEE ALSO(另见)

expand(1), nroff(1), tbl(1)  

#p#

NAME

col - filter reverse line feeds from input  

SYNOPSIS

col [-bfpx ] [-l num ]  

DESCRIPTION

Col filters out reverse (and half reverse) line feeds so the output is in the correct order with only forward and half forward line feeds, and replaces white-space characters with tabs where possible. This can be useful in processing the output of nroff(1) and tbl(1).

Col reads from standard input and writes to standard output.

The options are as follows:

-b
Do not output any backspaces, printing only the last character written to each column position.
-f
Forward half line feeds are permitted (``fine'' mode). Normally characters printed on a half line boundary are printed on the following line.
-p
Force unknown control sequences to be passed through unchanged. Normally, col will filter out any control sequences from the input other than those recognized and interpreted by itself, which are listed below.
-x
Output multiple spaces instead of tabs.
-l num
Buffer at least num lines in memory. By default, 128 lines are buffered.

The control sequences for carriage motion that col understands and their decimal values are listed in the following table:

ESC-7
reverse line feed (escape then 7)
ESC-8
half reverse line feed (escape then 8)
ESC-9
half forward line feed (escape then 9)
backspace
moves back one column (8); ignored in the first column
carriage return
(13)
newline
forward line feed (10); also does carriage return
shift in
shift to normal character set (15)
shift out
shift to alternate character set (14)
space
moves forward one column (32)
tab
moves forward to next tab stop (9)
vertical tab
reverse line feed (11)

All unrecognized control characters and escape sequences are discarded.

Col keeps track of the character set as characters are read and makes sure the character set is correct when they are output.

If the input attempts to back up to the last flushed line, col will display a warning message.  

SEE ALSO

expand(1), nroff(1), tbl(1)  

责任编辑:韩亚珊 来源: CMPP.net
相关推荐

2011-08-24 16:48:36

man中文man

2011-08-15 10:21:09

man中文man

2011-08-11 16:11:49

at中文man

2011-08-25 10:21:56

man.conf中文man

2011-08-25 15:09:38

clearerr中文man

2011-08-25 15:19:39

dirname中文man

2011-08-25 15:21:53

execl中文man

2011-08-25 16:28:50

fread中文man

2011-08-25 16:52:54

getchar中文man

2011-08-25 17:27:58

rewind中文man

2011-08-25 18:41:31

vprintf中文man

2011-08-23 10:03:40

useradd中文man

2011-08-23 10:29:02

chpasswd中文man

2011-08-23 10:34:22

convertquot中文man

2011-08-23 16:24:57

smbmnt中文man

2011-08-23 15:39:34

rpmbuild中文man

2011-08-23 18:00:21

LDP中文man

2011-08-25 09:40:49

UPDATE中文man

2011-08-24 15:11:15

explain中文man

2011-08-24 15:29:06

grant中文man
点赞
收藏

51CTO技术栈公众号