lout-users
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Dos line endings


From: Albert Kinderman
Subject: Dos line endings
Date: Mon, 21 Jan 2002 15:08:45 -0800

In late May of 2001, there was a thread about @SysPreprendGraphic
symbol out of place, a problem I have had many times.  

Example from the email lists:

Lout file "/usr/local/share/lout/include/bsf" (from "doc" line 19,
from
              "test.l" line 1):
              18,1: fatal error: @SysPrependGraphic symbol out of
place

On May 23, Efraim Yawitz identified the problem as involving Dos
line endings.

Today, I identified the problem more specifically as being caused
by a dos carriage return at the end of the line 

@SysInclude { doc }  or @Include { mydoc }

Recently, Sebastian Pierre wrote about 

49,16: fatal error: EndFontMetrics missing from font file 
/sw/share/lout/Fonts/ERASMUSL.afm

The problem was a carriage return in the afm file at the end of
the EndFontMetrics line.

When processing a file with Dos line endings on a unix system, if
Lout does not produce fatal errors, it issues the warning that the
character /015 has no representation in the font you are using (I
can't remember the exact message).

Just in the last week, I was bitten by both problems.  Luckily,
Sebastian's recent post had elicited the correct fix for the
EndFontMetrics problem, and, today, when I ran into the
@SysPreprendGraphic problem, I was using an editor that showed a
small box (some show ^M, some show nothing) for the carriage
return.  With the recent posts in my mind, I was able to deduce
that it was specifically the end of the @SysInclude { doc } line
that was the problem.

If you move files around by floppy or by ftp and use both unix and
Dos systems, you will run into these problems.  If it hasn't
happened to you lately, you will most likely have forgotten what
the solution is when it hits you again.  

Therefore, here is my wishlist (for Jeff to consider when he gets
back)

Either 

1) Lout should ignore the extra carriage returns when processing
files so that no errors are generated.  The linefeed would act as
the end of line character as far as lout was concerned for both
Dos and unix. (This might be a bad thing -- do carriage returns
have another use?  -- do some fonts use /015 octal for a
character?)

or 

2) The problem(s) and solution should be clearly documented.

In light of 2), are there other problems you have encountered with
lout caused by Dos line endings?


Al

-- 
Albert Kinderman  California State University, Northridge
    Department of Systems and Operations Management


reply via email to

[Prev in Thread] Current Thread [Next in Thread]