From owner-freebsd-questions Thu Nov 23 7:56:17 2000 Delivered-To: freebsd-questions@freebsd.org Received: from mail2.rdc1.az.home.com (mail2.rdc1.az.home.com [24.1.240.76]) by hub.freebsd.org (Postfix) with ESMTP id F19A537B4C5 for ; Thu, 23 Nov 2000 07:56:15 -0800 (PST) Received: from home.com ([24.1.247.6]) by mail2.rdc1.az.home.com (InterMail vM.4.01.03.00 201-229-121) with ESMTP id <20001123155615.ZTIU29905.mail2.rdc1.az.home.com@home.com>; Thu, 23 Nov 2000 07:56:15 -0800 Message-ID: <3A1D3D65.7A93451@home.com> Date: Thu, 23 Nov 2000 08:53:09 -0700 From: Joel Mc Graw X-Mailer: Mozilla 4.73 [en] (X11; I; FreeBSD 4.1-RELEASE i386) X-Accept-Language: en MIME-Version: 1.0 To: Steve the teco Cc: freebsd-questions@FreeBSD.ORG Subject: Re: removing escape chr (printer) References: Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG Steve the teco wrote: > > Hi All, > > I have about 200 files to convert to plain text or better still html. > > The problem is the text is full of printer codes > > ^[^[&a8R^[^[&f0S^[^[&a4C^[^[&f0S^[*c2221A^[*c95B^[*c15G^[*c2P^[*c4A^[*c1852B^[*c0P^[*c2221A^[*c4B^[*c0P^[*p+59Y^[*p > +200X^[^[(s0p10h0s3b4099TPROJECT > COST^[*p+330X^[*p-20Y^[^[(s0p17h0s3b4099T1999^[*p+40Y^[*p-85XActual^[*p-40Y^[*p+70 > X2000^[*p+40Y^[*p-89XBudget^[*p-40Y^[^[&f0S > > > Do I need a port or something to clean up this mess. > > hope someone can help. > > Thanks for your time. > > Steve Hutson. > Steve, These appear to be PCL codes--which is HP's printer control language (kinda like PostScript). Notice that they appear to always begin with an escape character and end with a capital letter. Using this info, writing a program/script to remove the codes should be fairly trivial. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message