Bug 163656 - Incorrect preview of SDT fields when the field has specific Style formatting
Summary: Incorrect preview of SDT fields when the field has specific Style formatting
Status: UNCONFIRMED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: LibreOffice (show other bugs)
Version:
(earliest affected)
24.8.1.2 release
Hardware: All All
: medium normal
Assignee: Not Assigned
URL:
Whiteboard: QA:needsComment
Keywords:
Depends on:
Blocks:
 
Reported: 2024-10-28 10:28 UTC by Majd Azzam
Modified: 2024-11-12 03:13 UTC (History)
1 user (show)

See Also:
Crash report or crash signature:


Attachments
Test file contains fields, which has specific style (4.36 MB, application/vnd.openxmlformats-officedocument.wordprocessingml.document)
2024-10-28 10:29 UTC, Majd Azzam
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Majd Azzam 2024-10-28 10:28:43 UTC
Description:
I created a Docx file that contains a field with a specific formatting style (Formatvorlage4).
When I open the Docx file with LibreOffice, the formatting of the SDT fields appears incorrect.

Please check the file in attachment.
The field should have the Formatvorlage4 style, but it doesn't appear in the preview.
But in Microsoft Word, I can see the correct formatting (Formatvorlage4).

This is the SDT block:

      <w:sdt>
        <w:sdtPr>
          <w:rPr>
            <w:rStyle w:val="Formatvorlage4" />
            <w:rFonts w:ascii="Arial" w:hAnsi="Arial" w:cs="Arial" />
          </w:rPr>
          <w:alias w:val="Author" />
          <w:tag w:val="" />
          <w:id w:val="519431896" />
          <w:placeholder>
            <w:docPart w:val="477E5E5C83E2482C8987F073F30706BF" />
          </w:placeholder>
          <w:dataBinding
            w:prefixMappings="xmlns:ns0='http://purl.org/dc/elements/1.1/' xmlns:ns1='http://schemas.openxmlformats.org/package/2006/metadata/core-properties' "
            w:xpath="/ns1:coreProperties[1]/ns0:creator[1]"
            w:storeItemID="{6C3C8BC8-F283-45AE-878A-BAB7291924A1}" />
          <w15:color w:val="FF00FF" />
          <w:text />
        </w:sdtPr>
        <w:sdtEndPr>
          <w:rPr>
            <w:rStyle w:val="Formatvorlage4" />
          </w:rPr>
        </w:sdtEndPr>
        <w:sdtContent>
          <w:r w:rsidRPr="00545C0B">
            <w:rPr>
              <w:rStyle w:val="Formatvorlage4" />
              <w:rFonts w:ascii="Arial" w:hAnsi="Arial" w:cs="Arial" />
            </w:rPr>
            <w:t>Steinhofer, Melanie</w:t>
          </w:r>
        </w:sdtContent>
      </w:sdt>

Despite having the Formatvorlage4 rStyle in the run properties (rPr), it does not display correctly in the preview!

Steps to Reproduce:
1. Opening the attached Word Document

Actual Results:
"Steinhofer, Melanie" is displayed in normal style

Expected Results:
"Steinhofer, Melanie" is displayed in Formatvorlage4 style


Reproducible: Always


User Profile Reset: No

Additional Info:
The software should display the field with the correct formatting style, which in this example is Formatvorlage4.
Comment 1 Majd Azzam 2024-10-28 10:29:03 UTC
Created attachment 197271 [details]
Test file contains fields, which has specific style