Writer doesn't preserve Style after saving to Microsoft Word 2007-2013 XML (.docx), close, and reopening file

Bug #1649295 reported by Richard on 2016-12-12
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
libreoffice (Ubuntu)
Low
Unassigned

Bug Description

1. Open https://bugs.launchpad.net/ubuntu/+source/libreoffice/+bug/1649295/+attachment/4794230/+files/Linux%20Operations.docx

2. Put caret on first line noting “Linux Operations”, which has style “Default Style”. Change to style “Title” using the Apply Paragraph Style of the Formatting toolbar.

3. Save as docx.

4. Close, reopen, and notice that the style is now "Default Style" instead of "Title".

WORKAROUND: Save file as .odt.

ProblemType: Bug
DistroRelease: Ubuntu 16.10
Package: libreoffice 1:5.2.2-0ubuntu2
ProcVersionSignature: Ubuntu 4.8.0-30.32-generic 4.8.6
Uname: Linux 4.8.0-30-generic x86_64
ApportVersion: 2.20.3-0ubuntu8
Architecture: amd64
CurrentDesktop: GNOME
Date: Mon Dec 12 06:44:49 2016
SourcePackage: libreoffice
UpgradeStatus: Upgraded to yakkety on 2016-11-16 (25 days ago)

Richard (ismail-a) wrote :
Richard (ismail-a) wrote :

Output during failing recovery:

(soffice:32742): GLib-GObject-WARNING **: /build/glib2.0-55kQfG/glib2.0-2.50.0/.
/gobject/gsignal.c:3492: signal name 'selection_changed' is invalid for instance
 '0x7fae58017860' of type 'OOoAtkObjCompTxt'

(soffice:32742): Gdk-WARNING **: Couldn't map as window 0x564402d83e60 as popup because it doesn't have a parent

(soffice:32742): GLib-GObject-WARNING **: g_object_weak_unref: couldn't find weak ref 0x7fae80482d80(0x56440182e0f8)

(soffice:32742): Gdk-WARNING **: Couldn't map as window 0x564403f7a8a0 as popup because it doesn't have a parent

(soffice:32742): Gdk-WARNING **: Couldn't map as window 0x564404752e60 as popup because it doesn't have a parent

(soffice:32742): Gdk-WARNING **: Couldn't map as window 0x5644078b28a0 as popup because it doesn't have a parent

(soffice:32742): Gdk-WARNING **: Couldn't map as window 0x5644081522e0 as popup because it doesn't have a parent

(soffice:32742): Gdk-WARNING **: Couldn't map as window 0x564402d83e60 as popup because it doesn't have a parent

(soffice:32742): Gdk-WARNING **: Couldn't map as window 0x564403f7a8a0 as popup because it doesn't have a parent

(soffice:32742): Gdk-WARNING **: Couldn't map as window 0x564404752e60 as popup because it doesn't have a parent

(soffice:32742): Gdk-WARNING **: Couldn't map as window 0x5644078b28a0 as popup because it doesn't have a parent

(soffice:32742): Gdk-WARNING **: Couldn't map as window 0x5644081522e0 as popup because it doesn't have a parent

(soffice:32742): Gdk-WARNING **: No grabbed seat found, using the default one in order to map popup window 0x5644081522e0. You may find oddities ahead, gdk_seat_grab() should be used to simultaneously grab input and show this popup

Sebastien Bacher (seb128) wrote :

Thank you for your bug report. Do you have steps to trigger the issue and/or an example document which can be used? You said that before the feature was not functional, do you know if there is a bug report about that?

Changed in libreoffice (Ubuntu):
importance: Undecided → High
Richard (ismail-a) wrote :

This happens in regular load/svae, too

so it is probably a broken docx import/export.

summary: - LibreOffice Recovery docx lose styles 20%
+ LibreOffice docx lose styles in 20% of cases

1. Open the attached Linux Operations.docx document in
LibreOffice Writer
Version: 1:5.2.2-0ubuntu2

Note first line “Linux Operations” has style “Default Style”

2. Put the caret on this line, change to sryle “Title” using the Apply Paragraph Style of the Formatting toolbar (typically located in top left)

3. File - Save All

4. Close and reopen Linux Operations.docx

BUG
The style is now Default Style

EXPECTED
Style to be Title

Richard (ismail-a) wrote :

Probably a half dozen of my documents has reached this state where Default Style is applied to most of the document

Richard (ismail-a) wrote :

There seems to be some problem with loading styles

- The Apply Paragraph Style control is blank until you click something that is not Default Style, eg. a Heading 1 text

The fix every time a document is loaded is:
1. Click on non-Default Style text so that Apply Paragraph Style populates
2. Set first line to Title
3. Reload styles using Styles - Load Styles…
4. Replace Table of Contents if the document has that
5. Replace all Default Style with Text Body using Edit - Find & Replace…, Other Options: check Paragraph Styles, Find Dfeault Style, Replace: Text Body, click Replace All
6. Repeat for other broken documents
7. File Save All
8. Pray that the next LibreOffice crash is far, far away

Richard (ismail-a) wrote :

This also happens for newly created documents

docx style read is broken

summary: - LibreOffice docx lose styles in 20% of cases
+ LibreOffice Writer docx fails to load styles

Something that can be pasted over from one docx to another
fails loading of styles on document open

I have an increasing collection of such zombie documents, and it is unknown how to fix it.

Will Cooke (willcooke) wrote :

Removing wayland-session tag as I don't think it's related.

tags: removed: wayland-session

Richard, the issue you are reporting is an upstream one. Could you please send the bug to the developers of the software by following the instructions at http://wiki.documentfoundation.org/BugReport ? Please provide the upstream URL so it may be added as a bugwatch that will advise about the status. Thanks in advance.

description: updated
tags: added: bionic
Changed in libreoffice (Ubuntu):
importance: High → Low
status: New → Triaged
summary: - LibreOffice Writer docx fails to load styles
+ Writer doesn't preserve Style after saving to Microsoft Word 2007-2013
+ XML (.docx), close, and reopening file
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers