To comment on the following update, log in, then open the issue:
http://www.openoffice.org/issues/show_bug.cgi?id=77637
                 Issue #|77637
                 Summary|hide/unhide of text sections is not reliable
               Component|Word processor
                 Version|OOo 2.2
                Platform|All
                     URL|
              OS/Version|All
                  Status|NEW
       Status whiteboard|
                Keywords|
              Resolution|
              Issue type|DEFECT
                Priority|P3
            Subcomponent|code
             Assigned to|mru
             Reported by|clutz





------- Additional comments from [EMAIL PROTECTED] Mon May 21 07:48:07 +0000 
2007 -------
There's an example (created out of a real-word usecase) that shows that unhiding
a text section that previously was hidden doesn't work reliable. With the help
of a short macro it is possible to produce a text section with the property
IsVisible=true, that is not visible in fact.

I've got a textdocument that contains some text sections where all but one text
sections should be invisible. The visible one represents a part of a text
written in a specific language and our letterhead system controls the
hiding/unhiding of the textsections depending on the language that is currently
set in a variable of our letterhead system. After some cycles of hiding and
unhiding the textsections, the problem occurs. The following macro simulate the
cycles of hiding and unhiding the text sections:

Sub showHideSections
  dim str as String
  str = ""
  sections = ThisComponent.getTextSections()
  for k=1 to 2
    for i=0 to sections.getCount()-1
      s = sections.getByIndex(i)
      s.IsVisible = true
      str = str & s.getName() & chr(10)
      s.IsVisible = false
    next i
  next k
  s.IsVisible = true
  msgbox str
End Sub

The macro iterates twice through all textsections in a document and switches
their visibility states from IsVisible=true to IsVisible=false. The last
textsection is set to be visible in the end, but the textsection is not shown in
fact where it's property IsVisible=true.

I will attach an example which could be used to reproduce the bug:

1) open the file showHideSectionsProblem.odt (YES to macros)
2) run the above macro (it's already included in the document as
Standard.Module1.showHideSections)
3) you can see that the second table gets hidden as the respective textsection
is hidden. But the last textsection called "Berenglisch GROUPS ('england')"
should be visible in that place.
4) open the navigator (F5) and see that the textsection "Berenglisch GROUPS
('england')" is grey'ed to mark a invisible textsection. 
5) in the navigator: call edit... on this textsection and see that the flag
"hidden" is not set for the textsection "Berenglisch GROUPS ('england')". So
this textsection should be visible.

---------------------------------------------------------------------
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