X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 10bba1,3e61ec7c8619c37a X-Google-Attributes: gid10bba1,public X-Google-Thread: fbb9d,3e61ec7c8619c37a X-Google-Attributes: gidfbb9d,public From: winston@merk.com (Winston Smith) Subject: Answer: Text in shapes Date: 1995/06/15 Message-ID: <3rp7qh$7kq@miso.wwa.com> X-Deja-AN: 104432736 approved: boba@wwa.com sender: boba@miso.wwa.com references: <3qj6b7$r0m@miso.wwa.com> <3qn8e4$ogd@miso.wwa.com> organization: Technology Partners, Inc. keywords: pasteup, multiple, columns, NROFF, EMACS newsgroups: comp.text,rec.arts.ascii On Wednesday, May 31, 1995 at 20:49:27 -0500 (1:49am Thu Jun 1 GMT ?), dianne@news.seattleu.edu (Dianne Duncan) wrote: DD> I'm interested in some software The trick is, I don't want to DD> that would make it easy to 'pour' output to paper at all; this DD> text into shapes, and do double would be for internet traffic DD> columns. (usenet and email) *only* DD> DD> Being a computer novice, I'm DD> not very familiar with what's DD> available. There's got to be DD> something that's not overloaded DD> with features, yet will make it DD> easier to create a post like this(?) DD> DD> Am I dreaming, or what? No, you are not dreaming. This can be done under an operating system such as UNIX by using lexical tools such as AWK and PERL. I will leave it up to another programmer to post the AWK or PERL "line merge" program. I use a simple "quick-and-dirty" method for two-column output by combining UNIX "PR" -- a program that prints in multiple columns -- and UNIX "NROFF" -- a simple text-processor of the WordStar(tm) variety. (See the end of this article for suggestions on how to get EMACS to do the same thing.) The example follows. First let us deal with the two paragraphs you wish to place in double columns: = = = = = I'm interested in some software that would make it easy to 'pour' text into shapes, and do double columns. The trick is, I don't want to output to paper at all; this would be for internet traffic (usenet and email) *only* = = = = = You would place the text in "NROFF -ME" format (i.e. NROFF using the "-ME" macro package, first with a "dot command" to adjust the column "flush left" with a "ragged right" border and then using the built-in "dot command" for two columns, starting each new paragraph with a line space, thusly: = = = = = .ad l .2c I'm interested in some software that would make it easy to 'pour' text into shapes, and do double columns. .sp The trick is, I don't want to output to paper at all; this would be for internet traffic (usenet and email) *only* = = = = = Take this file and run "NROFF -ME" on it, diverting standard output into a file. This will create a file of the following single column of formatted text: = = = = = I'm interested in some software that would make it easy to 'pour' text into shapes, and do double columns. The trick is, I don't want to output to paper at all; this would be for internet traffic (usenet and email) *only* = = = = = Now, take the column of text and send it to "PR", specifying the number of columns of output and the number of lines in the text, diverting the output into an output capture file. (You might have to adjust the line figure so as not to count blank lines.) For example, the command: pr -2 -l10 infile >outfile ...would create the following double column: = = = = = I'm interested in some The trick is, I don't want software that would make it to output to paper at all; easy to 'pour' text into this would be for internet shapes, and do double traffic (usenet and email) columns. *only* = = = = = The major work is now done. The next step is to surround the double column as an NROFF -ME "unformatted list" in order to protect it from formatting. The column of text that you wish to have centered is defined as a "flush left block" of text that has "centering" turned on. The whole NROFF -ME page would look like the following: = = = = = .ll 80 .(l I'm interested in some The trick is, I don't want software that would make it to output to paper at all; easy to 'pour' text into this would be for internet shapes, and do double traffic (usenet and email) columns. *only* .)l .(b L .(c Being a computer novice, I'm not very familiar with what's available. There's got to be something that's not overloaded with features, yet will make it easier to create a post like this(?) .)c .)b Am I dreaming, or what? = = = = = The output of this "NROFF -ME infile" command would look like: = = = = = I'm interested in some The trick is, I don't want software that would make it to output to paper at all; easy to 'pour' text into this would be for internet shapes, and do double traffic (usenet and email) columns. *only* Being a computer novice, I'm not very familiar with what's available. There's got to be something that's not overloaded with features, yet will make it easier to create a post like this(?) Am I dreaming, or what? = = = = = Anyhow, that is how to do what you ask by using NROFF. You could do the same thing in EMACS by first creating a single column of text by setting up the line length boundaries and then "auto-filling" a paragraph at a time. Once you have the text column, you would then do the "page layout" by placing the editor into "picture mode" and using the "cut-rectangular-region" command to pick up a column of text and then "Paste-rectangular-region" to drop the text column at its location. It is a bit hard to explain over the network, but the approach is the same. First you build a single column of text, then you place the columns. It isn't all that difficult. If you need instructions for pasting up columns under EMACS, just give a holler on the network. Have Fun!