Skip Menu |
 

This queue is for tickets about the LaTeX-Table CPAN distribution.

Report information
The Basics
Id: 49422
Status: resolved
Priority: 0/
Queue: LaTeX-Table

People
Owner: LIMAONE [...] cpan.org
Requestors: REHSACK [...] cpan.org
Cc:
AdminCc:

Bug Information
Severity: Normal
Broken in:
  • 0.9.16
  • v0.9.17
Fixed in: (no value)



Subject: Alignment & Width of longtables are wrong generated
Download (untitled) / with headers
text/plain 712b
Hi Markus, I wonder why generated longtables weren't aligned as expected, so I took the LaTeX Companion and compared the description to the generated code - and later against the template. The longtable is documented (http://tug.ctan.org/cgi-bin/ctanPackageInformation.py?id=longtable) to be used like: Show quoted text
> \begin{longtable}[align]{cols} rows \end{longtable}
The attached patch correct this - and removes the \begin{flushleft} etc., because this doesn't affect longtables. The width is controlled using Show quoted text
> \setlength\LTleft{...} \setlength\LTright{...}
but I didn't add code for this, because I didn't completely understand how to translate the width-parameters into both length parameters. Best regards, Jens
Subject: LaTeX-Table-Longtable.patch
--- lib/LaTeX/Table/Types/Longtable.pm.orig 2009-09-04 10:54:48.799112000 +0200 +++ lib/LaTeX/Table/Types/Longtable.pm 2009-09-04 10:59:29.714913000 +0200 @@ -19,10 +19,7 @@ RULES_WIDTH_GLOBAL_CODE %][% RULES_COLOR_GLOBAL_CODE %][% IF FONTSIZE %]\[% FONTSIZE %] [% END %][% IF FONTFAMILY %]\[% FONTFAMILY %]family [% END %][% IF SIDEWAYS %]\begin{landscape}[% END -%][% IF CENTER %]\begin{center} -[% END %][% IF LEFT %]\begin{flushleft} -[% END %][% IF RIGHT %]\begin{flushright} -[% END %][% RESIZEBOX_BEGIN_CODE %]\begin{[% TABULAR_ENVIRONMENT %][% IF STAR %]*[% END %]}[% IF WIDTH %]{[%WIDTH %]}[% END %]{[% COLDEF %]} +%][% RESIZEBOX_BEGIN_CODE %]\begin{[% TABULAR_ENVIRONMENT %][% IF STAR %]*[% END %]}[% IF CENTER %][c][% END %][% IF LEFT %][l][% END %][% IF RIGHT %][r][% END %]{[% COLDEF %]} [% IF CAPTION %][%IF CAPTION_TOP %]\caption[%IF SHORTCAPTION %][[% SHORTCAPTION %]][% END %]{[% CAPTION %][% IF CONTINUED %] [% CONTINUEDMSG %][% END %][% IF LABEL %]\label{[% LABEL %]}[% END %]}\\ @@ -37,8 +34,7 @@ END %][% IF LABEL %]\label{[% LABEL %]}[% END %]}\\ [% END %][% END %]\endlastfoot [% DATA_CODE %]\end{[% TABULAR_ENVIRONMENT %][% IF STAR %]*[% END %]} -[% RESIZEBOX_END_CODE %][% IF CENTER %]\end{center}[% END %][% IF LEFT -%]\end{flushleft}[% END %][% IF RIGHT %]\end{flushright}[% END %][% IF +[% RESIZEBOX_END_CODE %][% IF SIDEWAYS %]\end{landscape}[% END %] } EOT
Download (untitled) / with headers
text/plain 540b
Hi Jens, thanks for your bugreport and patch! I've applied your alignment patch and released a new developer version (0.99_3). Hm, it seems that one has to specify the margin in longtable instead of the width of the table. That makes it quite difficult to translate the width option. For example, "0.8\textwidth, left" would be something like "\setlength\LTright{0.2\textwidth}", right? It's probably easier to just use the ltxtable package as described in width_environment. It should give better results anyway. Best regards, Markus
Subject: Re: [rt.cpan.org #49422] Alignment & Width of longtables are wrong generated
Date: Tue, 08 Sep 2009 10:13:53 +0000
To: bug-LaTeX-Table [...] rt.cpan.org
From: Jens Rehsack <rehsack [...] web.de>
Download (untitled) / with headers
text/plain 775b
LIMAONE via RT wrote: Show quoted text
> <URL: https://rt.cpan.org/Ticket/Display.html?id=49422 > > > Hi Jens, > > thanks for your bugreport and patch! I've applied your alignment patch > and released a new developer version (0.99_3). > > Hm, it seems that one has to specify the margin in longtable instead of > the width of the table. That makes it quite difficult to translate the > width option. For example, "0.8\textwidth, left" would be something like > "\setlength\LTright{0.2\textwidth}", right? It's probably easier to just > use the ltxtable package as described in width_environment. It should > give better results anyway.
Yes, I think so. That's why I didn't touch the code there - maybe a hint in the POD should be added, that width is unsupported for 'longtable'. Jens
Download signature.asc
application/pgp-signature 834b

Message body not shown because it is not plain text.

From my point of view this can be resolved/closed.
I added another comment to the documentation of the width option.


This service is sponsored and maintained by Best Practical Solutions and runs on Perl.org infrastructure.

Please report any issues with rt.cpan.org to rt-cpan-admin@bestpractical.com.