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

Bug#225833: 225833: letter vs A4 in TeX



On Sun, 2007-01-28 at 00:33 +0100, Florent Rougon wrote:
> Hi,
> 
> First, I agree with Frank (who wrote that several times in the related
> bug reports) that the paper size should be explicitely specified in each
> document, because the formatting depends a lot on it.
> 
> Therefore, from my POV, working "out of the box" in this context does
> *not* mean "using whatever size is defined in /etc/papersize, even when
> no paper size is specified in the document". If the papersize is not
> specified in the document, I consider it broken.

I explicitly specified the papersize (as letterpaper) in the document
and used the geometry package, and still ended up with A4 coming out,
both when using pdflatex and when using latex and dvips or xdvi.  To
answer your question below, I'm using
ii  tetex-base        3.0.dfsg.3-5   Basic TeX input files of teTeX
ii  tetex-bin         3.0-28         The teTeX programs
It may be I need to specify the dvi driver explicitly to geometry.  But
that raises a couple problems for me.  First, I use pdflatex, and I'm
not even sure what driver (if any) it uses.  Second, I'm processing the
same document with both pdflatex and latex -> dvips or xdvi, so it looks
as if I might need to edit the driver specification for each run.

Before getting into the discussion of how the Debian packages should
behave,  I'd just like to underline that my main point was "please put
something in the README explaining what users need to do if they want a
certain papersize."

This has two parts: what to do if a document does not explicitly set the
papersize, and what to do if it does.

I disagree with the position that documents should have an explicit
papersize, for reasons I'll get to, but even if one accepts that there
seem to be some issues with getting it to work.  It would be nice if
specifying papersize in the documentclass were enough; failing that it
would be nice if it could be specified without having to indicate the
driver.  Maybe things work more smoothly in TeXLive.

Given that upstream is a bit of a mess handling papersizes (the FAQ at
(http://www.tex.ac.uk/cgi-bin/texfaq2html?label=papersize says of the
situation "This is (of course) pretty unsatisfactory.") it's quite
understandable that the Debian package also displays those features.  My
concern is that this practical problem seems elevated to a principle in
some of the discussion.

One of the main arguments seems to be that if Debian makes things work
by using papersize, people will prepare documents that don't work right
outside of Debian.  The FAQ seems to indicate one must specify the
papersize explicitly to the post-processing tools (dvi*, xdvi,...); if
that's the way other systems are, there's nothing Debian can do about
it.  Even if the geometry class allows specification of multiple drivers
(which I suspect it doesn't), it seems unreasonable to expect those
preparing the LaTeX source file to anticipate every driver that might be
used.

The discussion appears to use portable in a particular way, namely that
everyone everywhere should get the same format from the same source
document.  However, another sense is that everyone can process the file
and get it formatted appropriately for them; the document comes out as
A4 or letter or something else.  So I go latex foo and foo comes out as
letter; you do latex foo and it comes out as A4. (Some of the discussion
appears to suggest format conversions can be done from the dvi file; I'm
not expecting that, since it can't be done reasonably.  Rather, one .tex
file produces various .dvi files.)

It may be that LaTeX 3 will require or recommend explicitly setting the
paper size, but as far as I know LaTeX2(e) does not.  Such a requirement
seems to contradict the thrust of LaTeX to work in terms of content, not
layout.  I see no recommendation to specify a paper size in "The LaTeX
Companion."

Finally, one of the advantages of Debian as a distribution is that some
things are made easier.  In particular, here's what the man says about
papersize:
The  papersize  file is used to specify the preferred paper size to use
by available commands and programs generating documents.

It seems reasonable to expect that the Debian TeX packages fit the
expectation that sets.

To Recap:
1) Please document what a Debian user/admin needs to do with the current
packages to get a document, including all the postprocessing commands,
to use a certain papersize.  Please include how to get documents that
lack an explicit papersize to come out using a particular default, where
that default is used for all post-processing tools.
2) It would be nice if specifying the papersize in the document carried
over to the post-processing without further intervention.
3) It would be nice if /etc/papersize controlled what happens when there
is no explicit papersize setting.  This has a neat solution (if #2 is
working, it's just a matter of setting the default when the .tex file is
processed) and an ugly one (use a default, ignoring the original
document specification).


> 
> Ross Boylan <ross@biostat.ucsf.edu> wrote:
> 
> > I tried using geometry 
> > -----------------------------------
> > \documentclass[letterpaper]{article}
> > \usepackage[paper=letterpaper]{geometry}
> >
> > \begin{document}
> > This is a little test of the paper size.
> > \end{document}
> > ----------------------------------
> 
> >From my reading of geometry's documentation, the two letterpaper
> settings are redundant.
> 
> > The reference to specifying the size explicitly was puzzling, since I
> > thought that's what \documentclass[letterpaper]{article} did. (I think
> > I now understand the issue is writing an appropriate special).
> 
> I think '\documentclass[letterpaper]{article}' should be enough,
> *provided* that you also use geometry.sty. The reason is, \documentclass
> options are passed to the packages when they support the options in
> question, and 'letterpaper' is a valid option for geometry.sty
> (according to its documentation from teTeX 3). But you do need
> geometry.sty to write the specials.
> 
> If that doesn't work, you can try explicitely specifying the driver
> (dvips, pdftex, etc.) to geometry. I always do that in my documents
> (actually: I have a Makefile doing that) because of habit, but I'm not
> sure it's still needed nowadays, as geometry's documentation seems to
> imply there is (at least some) autodetection for the driver.
> 
> Disclaimer: advice not tested, as I mainly use A4 paper.
> 
> PS: you don't tell which TeX distribution you're using.
>       -> teTeX 2, 3? (seems to be one of these, since you mention tetex-base)
>       -> TeX Live?
> 
>     This is important, as geometry.sty had significant changes between
>     teTeX 2 and {teTeX 3, TeX Live 2005}, IIRC.
> 
-- 
Ross Boylan                                      wk:  (415) 514-8146
185 Berry St #5700                               ross@biostat.ucsf.edu
Dept of Epidemiology and Biostatistics           fax: (415) 514-8150
University of California, San Francisco
San Francisco, CA 94107-1739                     hm:  (415) 550-1062




Reply to: