[Libreoffice] patch for preserving the table alignment

Caolán McNamara caolanm at redhat.com
Mon Jul 18 02:41:47 PDT 2011


On Fri, 2011-07-15 at 16:35 +0100, Noel Power wrote:
> Hi Caolán
> 
> could you have a look at this patch
> http://cgit.freedesktop.org/libreoffice/writer/commit/?id=95351a519bec2833f5d936c20e3916a4e283b0f6
> 
> This should be a nice stroll down memory lane for you as it seems 
> related to http://openoffice.org/bugzilla/show_bug.cgi?id=1291, yes 
> issue #1291 !!!

Hmm, well I don't remember the code, I do remember the document itself,
cause its a nasty.

My intent with the SetFmtAttr is apparently to get a floating frame
which shrinks right down the the size of the table contained in it,
reset the positioning of the table so the left of the table is 0 from
the left of the frame and the right 0 from the right of the frame so
that it completely fills it widthwise.

If "FULL" isn't actually "full width of the container", but automatic in
a full-width-of-the-container, but clip-to-the-page-width, sort of way,
that's a pain :-)

I think I'd prefer an explicit horizontal setting which does the right
thing, e.g. see if any of NONE/CENTER/LEFT do the right thing, rather
than re-use the current setting which might be something weird like
INSIDE, OUTSIDE or something and all we want is a table that completely
fills the floating frame.

FWIW, I suggest generally testing for changes in layout to existing docs
with export to pdf before/after and with

composite -compose difference old.pdf new.pdf - | identify -format %k -

where the output is the count of colours after subtracting the render
output of new from old and so "1" is "no change, all good", and anything
else is a fail.

C.



More information about the LibreOffice mailing list