https://bugs.documentfoundation.org/show_bug.cgi?id=33713

David Tardon <[email protected]> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |[email protected]
           Keywords|                            |difficultyMedium, easyHack,
                   |                            |skillCpp

--- Comment #16 from David Tardon <[email protected]> ---
This shouldn't be hard to do. The relevant information is already parsed, it
just isn't used...

Some high-level info about LWP import code: The code resides in lotuswordpro.
Parsing is two-step, with ODF as an intermediate format, i.e., the parser reads
a LWP document, produces an (internal) ODF document, which is then imported.
The parser itself is in lotuswordpro/source/filter. In general, each concept of
the file format is represented by a separate class, with names starting with
Lwp. ODF export is in lotuswordpro/source/filter/xfilter. In general, there is
a class for each ODF element, but there are some that just group together a
bunch of related arguments (e.g., XFMargins). Class names start with XF or IXF.
The construction of the ODF is done in ToXml() functions.

Now to the task at hand: LwpParaStyle::ApplySpacing() needs to handle
LwpSpacingCommonOverride::SPACING_DYNAMIC (and possibly also SPACING_LEADING)
for abovepara and belowpara. Then the additional info that the margin size is
relative (percentual) needs to be passed through XFParaStyle::SetMargins() down
to XFMargins (Maybe change the SetMargins() arguments to std::variant? That
would also remove the need for a special value meaning "not set".). Finally,
XFMargins::ToXml needs to emit values with a proper unit: either "cm" (the only
possibility now) or "%".

-- 
You are receiving this mail because:
You are the assignee for the bug.
_______________________________________________
Libreoffice-bugs mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/libreoffice-bugs

Reply via email to