tal-1.9 Trailer Alignment Filter Program
(last updated for version 1.9)


  1. Description
  2. Legal Stuff
  3. Installation
  4. Examples
  5. Change Log, What's New                             
  Current Version:
- tal-1.9.tar.gz
- tal19-win32-src.zip
  (Win32 port by Bernard Martis)
- tal19-win32.zip
  (Win32 binary by Bernard Martis)
- tal19dos.zip
  (DOS binary by Bernard Martis)
Previous Versions:
- tal-1.8.tar.gz
- tal-1.7.tar.gz
- DOS binary of 1.7 (port by Y.C. Lee)
- tal-1.5.tar.gz

1. Description

This is the official tal home page.

tal is a filter that reads in a number of lines from standard input, then tries to determine an ending that all those lines have in common. Those common trailing characters (from now on called a 'trailer') are subsequently aligned, so that they all begin and end on the same column of text.
This can be used to repair 'broken boxes' or align the backslashes on long macro definitions in C programs. But for that matter, tal will work on any kind of common ending. tal is especially useful as a filter for the vim text editor.

Here's a very simple example with C comment tags:

  /* abracadabra*/                     /* abracadabra    */
  /* wow the sun is*/                  /* wow the sun is */
  /* shining */          ===tal===>    /* shining        */
  /* oooh yeah! */                     /* oooh yeah!     */
  /* so nice ...  */                   /* so nice ...    */
More examples can be found on the examples page.

tal offers many options that make it adjustable to almost any situation, like one to make the trailers end at a particular column, specify their length, add padding, and so on. Please review the man page that comes with the archive for an in-depth explanation of all options and the general usage of tal. If you want to view the manpage before installing it in your MANPATH, you may use the postscript version or the command

   nroff -man ./tal.1 | less
in order to have it formatted and displayed at the command line.

2. Legal Stuff

Let's make this short, so you actually read it. The author has never noticed any bugs, but still: If tal filters away your master's thesis that's your problem! You are using the program entirely at your own risk! On the other hand, it's free. You may even modify the code as long as the starting comment at the beginning of the C file clearly mentions the original author and just as clearly states the changes you have made. Same thing for the manpage.

3. Installation

Since the program uses only very basic C functions, installation should be quite easy.
  1. Download the tar'red and zip'ed archive using a link from the top of this page.

  2. Extract the files using
       gtar xfvz tal-1.9.tar.gz
    If you don't have gtar, use gunzip first and then tar, leaving out the z option.

  3. If you have the OS environment variable set correctly, just type make. Else type 'make youros' where youros is one of the following:
    • aix41
    • hpux9
    • hpux10
    • irix5 (for SGI)
    • irix6 (for SGI)
    • linux
    • osf1 (for DEC)
    • sunos4
    • sunos5
    If your platform is not on the list, try all of the ones that are on the list. You stand a good chance that one of them is working for you. Anyway, the program is so simple that compiling it really shouldn't be an insurmountable task.

  4. After you have successfully compiled it, copy the resulting binary into a directory that's in your PATH, and copy the man page into section 1 of a manpage location that's in the MANPATH.
    MS-DOS Users: The DOS binary you can download from the top of the page is ready "as is". Just download and use.

  5. For use with vim, it might be nice to add a line like
          vmap ,t !tal<CR>
     or   vmap ,t !tal -p 0<CR>
    to your ~/.vimrc. This way, you can select the lines using visual mode, then press ',t' to have the trailers aligned.
That's it. Enjoy!

4. Examples

The examples page provides some illustration on the man page. It does not replace the man page. :-)

5. Change Log, What's New

Please take a look at the change log in order to see what's new in each version.


Some people have requested new features to be added in future releases. Here ist a short list of the most important requests: These are features planned for future releases. Right now, I won't get around to doing it though - so ETA is fall of 1999.

SEE ALSO: boxes, the box drawing filter

tal © 1997 by Thomas Jensen <public(at)thomasjensen.com>
Page created May 04, 1997, last updated: 06/17/99. All rights reserved.