Bug 57488 - Problems with import and editing of user style based TOC
Summary: Problems with import and editing of user style based TOC
Status: RESOLVED WORKSFORME
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Writer (show other bugs)
Version:
(earliest affected)
3.5.2 release
Hardware: Other macOS (All)
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-11-24 16:13 UTC by Matt Rosin
Modified: 2014-05-04 10:45 UTC (History)
1 user (show)

See Also:
Crash report or crash signature:


Attachments
Word doc with English user style chapter headings and some Japanese body text (41.00 KB, application/msword)
2012-11-24 16:13 UTC, Matt Rosin
Details
ToC displayed correctly in 4.2.3.3 (54.30 KB, image/png)
2014-05-04 10:45 UTC, retired
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Matt Rosin 2012-11-24 16:13:25 UTC
Created attachment 70524 [details]
Word doc with English user style chapter headings and some Japanese body text

Summary:
1) LO fails to import Word doc Table of Contents based on user-defined style.
2) Attempts to resolve this are ultimately successful, but only after revealing intense UI dissonance and results that appear illogical to the user.

Recommendation:
1) Import user-based style TOC correctly. (if not fixed in later LO version)
2) Review Edit Index/Table interface as it is cryptic, misleading, and a total user hell-maze from Hades. :(

LibreOffice version: 
3.5.2.2 

Expected operation:
LO should open .doc displaying TOC correctly.
Logical use of Edit Index/Table interface should have logical effects
No hair-pulling would be desirable.

Observed operation:
LO imports .doc file and recognizes TOC as an updatable field but cannot update it.
Edit Index/Table interface has many apparently illogical effects and no helpful guidance.
By starting all over again but ignoring the Styles tab and using the Additional Styles "…" dialog instead, the desired operation was finally achieved after much hair-pulling.

Detailed operations:
I have a Microsoft Word document with a table of contents based on a user defined style.

When LibreOffice opens the document, the TOC does not display. Instead, a one-line blank grey field is shown. This field does not update when I try to do so with the context menu or Tools menu field update items.

In LibreOffice, if I delete the Word created TOC, and create a new one based on the same user-defined styles, I can save as .doc and Word will open it and display the TOC correctly.

However resaving it from Word and opening in LibreOffice again loses the TOC.

If I right click on the field and select Edit Index/Table, under Styles tab the user style is displayed in the Paragraph Styles column on the right side, but not in the left column.

Next I then click on Level 1 in left column and the user style in right column, and click the "<" button to assign the user style to Level 1, and click Okay. No change. Then right click -> update index/table. Still no change. This is not expected behavior

Next I click the Index/Table tab. check the Additional Styles check box, and click the … button. The user style I just set is displayed but not part of the outline. This is not expected behavior

Under "Create from", the Outline box cannot be unchecked. This is not expected behavior

The Additional Styles check box is not checked. This is not expected behavior.

I check the Additional Styles check box, and click the "…" button which becomes enabled. The user style is shown but is not applied. I would expect it to be at Level 1, considering my work in the Styles tab. This is not expected behavior.

I click the user style, and click the ">>" button and OK to set the style to Level 1 again. Now the "…" button has a blinking excalamation point. This is not expected behavior.

Now I click the "…" button again, but there is no error message displayed which I would expect if there is a blinking exclamation point. This is not expected behavior.

Now I have to guess what is wrong. Okay the most logical reason seems to be that the user style should be at level 2, despite what the Styles tab says, with level 1 being reserved for the heading "Table of Contents" or some such (i.e. the "Contents Heading" style shown for Title (i.e. level 0) in the Styles tab).
- If Title is indeed level 0 it should be shown in the "…" button dialog you would think though. This is not expected behavior.
So now I set "Index Heading" style to Level 1 and the user style to Level 2 and hit OK. This did not work; the exclamation mark is still blinking in the "…" button. This is not expected behavior.

I set user style to level 1, "Default" style to level 2 and hit ok. That doesn't work. 

Okay now I think maybe it is because the default says it will look up to level 9. So I just set user style to level 1, and no other styles/levels set. Then I change look up to level 1 only.

The result is the field is updated, but in a very strange, broken way.
The field I was updating remains a blank grey line, and the table of contents entries that should be listed there are instead listed one per page, so that several pages each including one TOC line are inserted after the original TOC page. This is not expected behavior.

I hit command-z to undo it but no change! This is not expected behavior.

I click edit index/table again and uncheck the Outline checkbox which now can be unchecked. The preview area now shows no TOC entries. I hit OK, but the multipage field is unchanged. This is not expected behavior.

I click update Index/Table. No change. This is not expected behavior.

Finally I decide I really want to delete this whole TOC! What I do is click on Edit Index/Table, then click Styles tab, then click on Level 1 user style, and click the Default button. I figure this will revert to the way it used to be, i.e. a blank TOC.

Guess what happens. When I hit OK, a proper TOC listing is displayed on one page!! How demented! Needless to say, This is not expected behavior.

Finally, I resave it from MS Word (this is Word for mac 2004 11.6.3 build 101208) to a .doc again, and open it in LibreOffice. Again, LO fails to display a TOC just shows a blank grey field.

Since I want to use LO to save my hands by using autocorrect to reduce typing, I decide to just work in LO and export to MS Word at the end.

* Now I try it all over again with the knowledge I built up.
Open MS .doc in LO. Shows blank field.
Edit Index/Table -> Check Additional Style checkbox. Click "…" button.
Select user style and set to level 1.
This works.
Comment 1 Matt Rosin 2012-11-24 16:19:25 UTC
The blinking exclamation point that appears inside the "..." button next to the Additional Styles checkbox in the Edit Index/Table dialog is difficult to understand.

"What did I do wrong?" the user thinks.

On clicking the button, no error message appears. 

"There is some error important enough to show an exclamation point, but it doesn't tell me what!"

This kind of UI interaction stems from an apparent intention to be helpful, but there is a hidden logic tree used to check validity of the inputted outline styles setting yet the user is not notified of which point in the tree caused a failure. This should be fixed.

And the "..." button and dialog should be renamed so people can talk about it without grimacing, and search for help about it.

Also, this "..." button and the Styles tab in the same dialog seem to have conflicting purposes but it is mysterious to the user. Why would a user style being set to level 1 in the Styles tab not be reflected in the "..."? How strange.

Why would setting user style in the "..." dialog work, but setting it in the Styles tab not work? Again strange.

This Edit Index/Table interface is a byzantine mess, and I am sorry if it was fixed in a later version but somehow I doubt it, hence the bug report.

Thank you for your time.
Comment 2 Emir Sarı 2012-11-27 09:22:17 UTC
I can reproduce this using both 4.0.0.0 alpha1 and 3.6.4.1 under OS X 10.7.5, the ToC is not shown.

I also agree that the ToC interface is very complex, the whole process should be simplified.
Comment 3 retired 2014-05-04 10:44:54 UTC
WORKSFORME

I do see a ToC. Opening the test file in Word 2011 on OS X and LO 4.2.3.3 shows identical ToC.

If I'm missing something, please re-open and point out exactly where the file differs and what you want to be fixed.
Comment 4 retired 2014-05-04 10:45:32 UTC
Created attachment 98411 [details]
ToC displayed correctly in 4.2.3.3