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

            Bug ID: 173527
           Summary: Artificial DF and incorrect default paragraph style
                    when exporting HTML
           Product: LibreOffice
           Version: 26.2.5.2 release
          Hardware: All
                OS: All
            Status: UNCONFIRMED
          Severity: normal
          Priority: medium
         Component: filters and storage
          Assignee: [email protected]
          Reporter: [email protected]

When we:

1. Create a new Writer document.
2. Enter some text, e.g. "Hello world"
3. Open Format > Paragraph... on the menu and note the "Spacing below
paragraph" and "Line spacing" values
4. Edit the Default Paragraph style (e.g. via the sidebar) and note the
"Spacing below paragraph" and "Line spacing" values
5. Save to HTML

we get something like the following:

<!DOCTYPE html>
<html>
<head>
    <meta http-equiv="content-type" content="text/html; charset=utf-8"/>
    <title></title>
    <meta name="generator" content="LibreOfficeDev 27.2.0.0.alpha0 (Linux)"/>
    <meta name="created" content="2026-09-13T11:08:54.445384505"/>
    <meta name="changed" content="00:00:00"/>
    <style type="text/css">
        @page { size: 21cm 29.7cm; margin: 2cm }
        p { margin-bottom: 0.25cm; line-height: 115%; background: transparent }
    </style>
</head>
<body lang="en-IL" link="#000080" vlink="#800000" dir="ltr"><p
style="margin-bottom: 0cm; line-height: 100%">
Hello world</p>
<br/>

</p>
</body>
</html>

This bug is about the margin-bottom and line-height styling.

At steps (3.) and (4.), I noted 0 below-paragraph spacing of 0, and a line
spacing of 100%. I see this applied to the <p> element in the HTML, but - the p
style in the CSS has different values: margin-bottom of 0.25cm and line-height
of 115%.

This is a bug in two ways:

1. There is no relevant paragraph style, AFAICT, with 115% line spacing and
0.25cm spacing below. So, no such paragraph style definition should appear in
the HTML.

2. Given that I have not applied any DF, there should be no style attribute on
the paragraph I enter - it should follow the default <p> style - the default
paragraph style - for the HTML file.

Version info (nightly from 2026-08-26):

Version: 27.2.0.0.alpha0+ (X86_64)
Build ID: c49435178ea0e42d0a03bfec52e4990e88307f3b
CPU threads: 4; OS: Linux 6.12; UI render: default; VCL: gtk3
Locale: en-IL (en_IL); UI: en-US

-- 
You are receiving this mail because:
You are the assignee for the bug.

Reply via email to