#!/usr/bin/perl -w
# $Id$
# Dieses Script (latex-symlist) wurde von Rdiger Beck erstellt
# Es ist freie Software
# Bei Fehlern wenden Sie sich bitte an mich.
# jeffbeck@web.de  oder  jeffbeck@gmx.de

# thist script reads a vapour-table from coolpack-output
# and converts it to a latex-table

# Bibliotheken

my $set_color=0;

open(IN,"<../coldformix-source/drawings/hx-diagram.fig") || die "$!";
open(OUT,">../coldformix-source/drawings/hx-diagram-bw.fig") || die "$!";

while (<IN>){

    my ($type, $two, $three, $four, $five, @parts)=split(/\s/);
   
    #print $_;
    print "$type\n";

    if ($type==4){
        #text
	$three=$set_color;
        print OUT "$type $two $three $four $five @parts\n";
    } elsif ($type==2 or $type==3){
	print "HIT\n";
        #spline
	$five=$set_color;
        print OUT "$type $two $three $four $five @parts\n";
    } else {
	print OUT $_;
    }

}


print "Done\n";


close(IN);
close(OUT);
