https://bugs.documentfoundation.org/show_bug.cgi?id=33713
--- Comment #21 from Dhiraj Holden <dhiraj.hol...@gmail.com> --- (In reply to David Tardon from comment #16) > 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 "%". This may be more complicated than just doing the changes listed here. I made some changes and ran into the following warning: warn:sw.core:34192:36628:sw/source/core/unocore/unostyle.cxx:3632: SwXAutoStyleFamily::insertStyle: Unknown property: ParaBottomMarginRelative This suggests that there is other code that needs to be changed to make percentages work. I'm not sure how to proceed from here. -- You are receiving this mail because: You are the assignee for the bug.