Issue 26330 - Dynamic height of footer doesn't work with hidden paras in footer
Summary: Dynamic height of footer doesn't work with hidden paras in footer
Status: CLOSED DUPLICATE of issue 33182
Alias: None
Product: Writer
Classification: Application
Component: ui (show other issues)
Version: OOo 1.1
Hardware: PC Windows NT
: P3 Trivial (vote)
Target Milestone: ---
Assignee: h.ilter
QA Contact: issues@sw
Keywords: needmoreinfo, oooqa
Depends on:
Reported: 2004-03-11 09:05 UTC by eberlein
Modified: 2004-08-19 14:38 UTC (History)
1 user (show)

See Also:
Issue Type: DEFECT
Latest Confirmation in: ---
Developer Difficulty: ---

template with hidden paras in footer (stw,sxw and jpg) (42.72 KB, application/octet-stream)
2004-03-15 13:00 UTC, eberlein
no flags Details
basic error doc (12.35 KB, application/vnd.sun.xml.writer)
2004-03-21 14:55 UTC, flibby05
no flags Details
file to reproduce behaviour of footer (13.93 KB, application/vnd.sun.xml.writer)
2004-03-22 07:18 UTC, eberlein
no flags Details

Note You need to log in before you can comment on or make changes to this issue.
Description eberlein 2004-03-11 09:05:31 UTC
I have a document (template) with the following pagestyle properties:

footerIsOn = true
footerHeight = 0,5cm
footerIsDynamicSpacing = false
footerIsDynamicHeight = true

The footer contains some paras with fields(HiddenParagraphs). All paras are 
visible. The height of the footer is about 3cm.
By creating a new document based on the template, a macro (event: on_Create) 
sets the values of different textfields(SetExpression), so therefore some paras 
in the footer are now hidden, others are not.
The height of the footer should now decrease to optimal height (and so it did 
in Star 5.2!!). But is does not (also not by refreshing).
And now:
If I set footerIsDynamicSpacing manually to true and back to false then the 
footer gets its optimal height.
So I think there is a coherence with this new feature (to avoid 
misunderstanding, in German ("Dynamischen Abstand verwenden").
If desired, I can post the relevant documents.

Comment 1 flibby05 2004-03-11 16:32:17 UTC
Hi Peter,

>>If desired, I can post the relevant documents.

yes, please do so. this would make it a lot easier for us to reproduce your issue.

Thanks, Max

Comment 2 eberlein 2004-03-15 13:00:47 UTC
Created attachment 13800 [details]
template with hidden paras in footer (stw,sxw and jpg)
Comment 3 eberlein 2004-03-15 13:24:07 UTC
Hi Max,
please take a look at the attachment.
The sxw-file doesn't show the real appearance after loading "AsTemplate" 'cause 
saving the document and reloading sets the footer to optimal height.
That's why I've posted the jpg.

To reproduce the behaviour, load the sxw-file, set the content of the 
variable "Sprechzeiten_Infozentrale" to "xxx". Look at the footer. The hidden 
paras are visible.
Set the content back to an empty string (oops, that cannot be done with GUI, so 
take the following code):

Sub For_Max()
End Sub

Sub ChangeVariable(oDoc as Object,byVal Feldname as String,byVal 
Feldinhalt as String)
On local Error Goto ErrorHandler
Dim oField, oFieldMaster as Object
Dim sFieldName as String
Dim sServiceArray()
oFieldEnumeration = oDoc.TextFields.createEnumeration

Do While oFieldEnumeration.hasMoreElements()
oField = oFieldEnumeration.nextElement
sServiceArray() = oField.SupportedServiceNames

If Instr( sServiceArray(0), "TextField.SetExpression" ) > 0 Then
If oField.VariableName = Feldname then
oField.Content = Feldinhalt
End If
End IF



Exit Sub

MsgBox Error & " in Zeile " & erl & " der Sub ChangeVariable"
End Sub

The hidden paras now should be hidden. But they are visible until changing and 
commiting a value in format / page / footer dialog.

Comment 4 flibby05 2004-03-21 14:54:27 UTC
Hi Peter,

sorry, the macro "For_Max()" does not work here with a 1.1.1rc3 linux build.

"Variable not defined in Zeile 96 der Sub ChangeVariable".

I will attach the document.

Comment 5 flibby05 2004-03-21 14:55:29 UTC
Created attachment 13961 [details]
basic error doc
Comment 6 eberlein 2004-03-22 07:14:36 UTC
Hi Max,
'Option Explicit' must be commented out. Please see the following document.
Comment 7 eberlein 2004-03-22 07:18:22 UTC
Created attachment 13970 [details]
file to reproduce behaviour of footer
Comment 8 eberlein 2004-07-29 15:53:16 UTC
Do you need more info?

Comment 9 michael.ruess 2004-08-19 14:37:42 UTC
I close this one in favour of issue 33182, which is more precise and much shorter.

*** This issue has been marked as a duplicate of 33182 ***
Comment 10 michael.ruess 2004-08-19 14:38:12 UTC