To comment on the following update, log in, then open the issue:
http://www.openoffice.org/issues/show_bug.cgi?id=103681
                 Issue #|103681
                 Summary|different results when editing bookmark content after 
                        |save + reload of document
               Component|Word processor
                 Version|OOo 3.1
                Platform|All
                     URL|
              OS/Version|All
                  Status|UNCONFIRMED
       Status whiteboard|
                Keywords|
              Resolution|
              Issue type|DEFECT
                Priority|P3
            Subcomponent|editing
             Assigned to|writerneedsconfirm
             Reported by|shenmux09





------- Additional comments from [email protected] Tue Jul 21 07:45:18 
+0000 2009 -------
Sorry, the description to reproduce this problem is a bit lengthy because I
can't just attach an example document since the problem lies exactly in the fact
that the document behaves differently after having been saved and loaded again.

Steps to reproduce:
1. Open a new writer document
2. Enter the text "abcdef"
3. Select "abc" and insert a new bookmark on the selection (using
Insert->Bookmark), name the bookmark "bookmark1"
4. Select "def" and insert a new bookmark on the selection (using
Insert->Bookmark), name the bookmark "bookmark2"
5. Open the navigator (F5) and in it click on "bookmark1". The text "abc" should
now be selected.
6. Hit the Del-Key thus deleting "abc" (but not bookmark1)
7. Save the document (but don't close the document or reload it!)

Now execute the following macro which changes the contents of bookmark1 to 
"xyz":

Sub Main
  bookmark1 = ThisComponent.getBookmarks().getByName("bookmark1")
  bookmark1.getAnchor().setString("xyz")
End Sub

The document now contains the text "xyzdef". "xyz" is inside of bookmark1, "def"
is inside of bookmark2. This is the expected behaviour.

Now (without saving) close the document and open it again (or just use
File->Reload).
Execute the same macro as above. Since the document should be in the same state
as above the results should be the same, right? Well, no. After executing the
macro the document now only contains the text "xyz" which now lies inside of
bookmark1 as well as bookmark2. "def" was deleted.


The problem seems to be (described in pseudo-XML) that after step 7 the state of
the bookmarks is:
<bookmark1></bookmark1><bookmark2>def</bookmark2>
But after reloading the document the state is:
<bookmark2><bookmark1>def</bookmark2></bookmark1>

---------------------------------------------------------------------
Please do not reply to this automatically generated notification from
Issue Tracker. Please log onto the website and enter your comments.
http://qa.openoffice.org/issue_handling/project_issues.html#notification

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to