[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]
Subject: MCT challenge #1 - some observations on Apache OpenOffice 3.4.1
Hi, regarding MCT challenge #1 and our discussion in the last SC call I did some observations on Apache OpenOffice (AOO), version 3.4.1 on how it behaves. I think such observations on current applications will help us to figure out what we need to specify for the Change Tracking action "Merge of two paragraphs". Thus the following behavior is what I observed in AOO 3.4.1 - you will see that certain things might does not make sense or are implementated wrong: Some words on the used "terms": - "paragraph style" means a named style which is stored in ODF in styles.xml - "direct formatting" means a paragraph or character attribute which is set directly at a paragraph resp. at all its characters. All direct formattings are stored in ODF in an automatic paragraph style in content.xml (A) Ways to merge two adjacent paragraphs: (1) Make a text selection starting inside first paragraph and ending inside the second paragraph and delete the selected text (2) Place cursor at end of first paragraph and hit delete-key (3) Place cursor at start of second paragraph and hit backspace-key The intrinsic merge is in all ways the same. In way (1) before the paragraphs are merged the selected text is deleted from each paragraph --> My hint for MCT: Way (1) can be split into an CT "Delete" and an CT "Merge of two paragraphs" (B) When merging two paragraphs with CT enabled the resulting merged paragraph will have applied the paragraph style of the first paragraph. This differs from the behavior when CT is disabled. When CT is disabled and the first paragraph does not contains any character content the merged paragraph will have applied the paragraph style of the second paragraph. This use case is in my opinion not a "Merge of two paragraphs" - it is a "Deletion of a paragraph". But, AOO treats it as a "Merge of two paragraphs" and thus, has no possibility to express the "losing of first paragraph's style" in ODF. --> My hint for AOO: Improved implementation needed in case that a merge happens with an empty paragraph. --> My hint for MCT: The MCT undo stack should keep the paragraph style information of the second paragraph in order to be able to restore it when rejecting the merge. (C) The following happens when merging two paragraphs with CT enabled which have direct formattings applied: The resulting merged paragraph will have applied the direct formattings which are paragraph attributes. The direct formattings from the first and the second paragraph which are character attributes are applied via text spans to the corresponding character portions. The character attributes applied via direct formatting are kept at the text portions as they are before the merge - no character attributes applied via direct formatting at the characters of the first paragraph will be applied to characters of the second paragraph after the merge has finished. It is possible that the resulting merged paragraph will not have any direct formattings (resp. automatic paragraph style in ODF) applied, if the direct formattings of the first paragraph only contain character attributes. [AOO implementation detail: The deleted text portions are stored in ODF with the correct former direct formattings resp. automatic paragraph style, but AOO is not able to restore the direct formattings correctly when rejecting the "Merge of two paragraphs".] --> My hint for MCT: The MCT undo stack should keep the automatic paragraph style information of the first and the second paragraph in order to be able to restore it when rejecting the merge. --> My hint for MCT: The MCT undo stack should contain information about the applied direct formattings (text spans) in order to be able to remove them when rejecting the merge. Testing the given example document of the MCT challenge #1 in AOO 3.4.1 results in an Change Tracking result as described in (C). Mit freundlichen Grüßen / Best regards Oliver-Rainer Wittmann -- Advisory Software Engineer ------------------------------------------------------------------------------------------------------------------------------------------- IBM Deutschland Beim Strohhause 17 20097 Hamburg Phone: +49-40-6389-1415 E-Mail: orwitt@de.ibm.com ------------------------------------------------------------------------------------------------------------------------------------------- IBM Deutschland Research & Development GmbH / Vorsitzende des Aufsichtsrats: Martina Koederitz Geschäftsführung: Dirk Wittkopp Sitz der Gesellschaft: Böblingen / Registergericht: Amtsgericht Stuttgart, HRB 243294
[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]