Description: EXPORT DOCX: Page style names not preserved & new styles added Steps to Reproduce: 1. Open attachment 161273 [details] 2. Inspect Styles panel -> Page styles 2. Export to DOCX 3. File Reload 4. Check again Actual Results: * New styles are added * Style names are lost (everything is called converted + number) Expected Results: * Should retain style names * Should not add new styles Reproducible: Always User Profile Reset: No Additional Info: Version: 7.0.0.0.alpha1+ (x64) Build ID: 21875558f6c478f07d68ff39e025d7ffd451674f CPU threads: 4; OS: Windows 6.3 Build 9600; UI render: Skia/Raster; VCL: win Locale: nl-NL (nl_NL); UI: en-US Calc: CL
repro Version: 6.4.4.2 (x64) Build-ID: 3d775be2011f3886db32dfd395a6a6d1ca2630ff CPU-Threads: 4; BS: Windows 10.0 Build 18363; UI-Render: GL; VCL: win; Gebietsschema: de-DE (de_DE); UI-Sprache: de-DE Calc: CL
@Justin Feel free to ignore, but seen the all to docx fixes recently and the styles being quite heavy promoted by Libreoffice.....
Microsoft formats don't have names for page styles. And there is nothing like a one-to-one mapping of features, so I don't expect that we could add in our own meta-data to round-trip anything either. Not possible AFAIK.
So the only way this could be implemented would be to: 1) add your own metadata to describe significant parts of the Writer page styles (perhaps including those settings changed from defaults), 2) make a "nearest page style" (or none) to one of the Writer page styles Those things sound tricky, I agree, and perhaps not worth the effort given you could at best achieve a partial success. Would it be possible instead for Writer to reuse existing page styles (including the name) it creates during the conversion process, when all the properties match? You could use a hash of the properties to make the equality comparison ("Is the current page style the same as an already generated one?") efficient. At present a book of e.g. 500 pages can convert across into 180 page styles (Convert1 to Convert180), all mostly the same as each other. I.e. they could be expressed in perhaps 4 or 6 distinct page styles. Tidying up such messy converted .docx-sourced books into a neat .odt file is tedious at present.
repro 7.3+. This 18 page document (with massive graphics) has 15 converted page styles. I don't foresee any improvements since this is ridiculously complicated especially since page styles contain headers and footers.