Path: utzoo!utgpu!water!watmath!clyde!att!osu-cis!tut.cis.ohio-state.edu!mailrus!ames!pasteur!ucbvax!decwrl!hplabs!hpda!hpcupt1!hpcuhb!hpcllla!hpclisp!hpclscu!shankar From: shankar@hpclscu.HP.COM (Shankar Unni) Newsgroups: comp.lang.c Subject: Re: How do I get printf to move to a tab position? Message-ID: <660010@hpclscu.HP.COM> Date: 26 May 88 17:27:42 GMT References: <242@tahoma.UUCP> Organization: HP NSG/ISD Computer Language Lab Lines: 33 Or even uglier and simpler, try programming direct escape sequences if it is a terminal application: printf ("\033&a%dC%s", column, text); /* HP escape sequences here.. */ Drawbacks: 1. Non-portable. 2. Ugly. If you *really* want to do a portable terminal-based application, use "curses" or any of its equivalents. If you want to do this rigmarole with disc files, try some dorktran-like carriage-control mechanism: printf ("%cRESTofFORMAT", CCTL, ...); /* * where CCTL == * ' ' for normal pre-spacing (i.e. start next line) * '0' for normal double-spacing * '+' for overstrike (write over current line with * NON-DESTRUCTIVE spacing.. * '1' for page eject * any other char implies a ' ' (may or may not be eaten up). * or anything else that strikes your fancy */ Then, write a post-processor to translate all this to simple text files (should be pretty simple). Can even be built in to your application... Shankar Unni.