[Top][All Lists]

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

Re: [lmi] do_compute_column_widths_if_necessary()

From: Greg Chicares
Subject: Re: [lmi] do_compute_column_widths_if_necessary()
Date: Mon, 23 Apr 2018 00:45:11 +0000
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.6.0

On 2018-04-22 16:21, Greg Chicares wrote:
> But now I see that only a single em of bilateral margin is added in
> add_column, so that removing a few points in do_compute_column_widths()
> is merely a microscopic adjustment--a desperate and heroic effort to
> make everything fit, which is wonderful if it works, but can work only
> if the overflow is rather small (because presumptive margins of only
> one em are close to minimal).

That was misleading: it's not microscopic at all.

For testing, I've created an input file 'large-supp-rpt.ill' (and shared
copies of it in personal email) that selects twelve supplemental-report
columns. If I run it (with ' --pyx=only_new_pdf' to suppress XSL-FO), I
get a messagebox warning that two hundred more pixels would be needed,
and it prints a PDF with nine of the twelve columns on the last page.
(I suppose it's just an accident that nine whole columns took up all
the space, leaving no room for a truncated piece of a tenth.)

If I change the last supplemental-report column to "[none]" and rerun,
I get a PDF with all eleven columns on the last page.

When we try to fit all twelve columns...
  the column margin is seven pixels on each side
  7 * 2 * 12 = 168 pixels
but a page is 576 pixels wide (eight inches * 72 points per inch),
so column margins total 168/576 = 29% of the available width, which
isn't really "microscopic".

I was hoping I could use this deeper insight to fit all twelve columns,
but 200 is still greater than 168. Reducing the margins to small
negative numbers does make everything "fit", but only by forcing
columns to overlap, which is of course unacceptable--yet some columns
still take way more space than they need because their headers are
wider than necessary:
[empty] Policy
[empty..] Year
[empty....] 99
so I'm going to look into narrowing such columns tomorrow.

reply via email to

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