🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

1 total messages Started by Rich Brennan Tue, 28 Mar 1989 03:11
bug in "pr".
#996
Author: Rich Brennan
Date: Tue, 28 Mar 1989 03:11
54 lines
1668 bytes
It seems "pr" has a problem with formfeeds when printing in two
columns. First, it prints the form feed line as a blank line, but
worse, it drops a line at the bottom of a column *for each form
feed* in that column!

I'm running on Xenix, and printing on an HP Laserjet in landscape mode.
The command I'm using is:

	pr -2 -n -w180 -f <file> | lpr -oL -dlj
                                        ^^
                                 This sets landscape mode on printer.

The "-w180" might be a little large, but it doesn't affect the outcome.

Compile and run the two programs, and redirect the output to two
files. Then print both files in two column mode. The file with
form feeds every 44 lines will skip lines as described above.

This problem also seems to exist on a client's 4.3BSD system which has
sys5 extensions.

--------
generate test1.out:
main()
{
	int lineno;

	lineno = 1;
	while (lineno < 300) {
		printf("This is line\t\t#%d\n", lineno);
		++lineno;
	}
}
------
generate test2.out:
main()
{
	int lineno;

	lineno = 1;
	while (lineno < 300) {
		if ((lineno % 44) == 0)
			printf("This line has a FF\t#%d\n", lineno);
		else
			printf("This is line\t\t#%d\n", lineno);
		++lineno;
	}
}


Rrrrich
----
...!{uunet,linus!alliant}!merk!root			Rich Brennan
Thread Navigation

This is a paginated view of messages in the thread with full content displayed inline.

Messages are displayed in chronological order, with the original post highlighted in green.

Use pagination controls to navigate through all messages in large threads.

Back to All Threads