cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Dynamic header size and following content.

Highlighted
Regular Member

Dynamic header size and following content.

Hello, I've been tasked with adding a note to a page that displays in the header of a pageset. 

Everything was implemented and works, except that now the header size can be various heights, if the note is long enough. Previously the header was hard set to a certain height so that the content inside the tag would start immediately after the header. But now that the size of the header can be changed depending on what the document writer puts, this no longer works. Is there a way to set a header to be dynamic in height so that rather it's 1 or 3 lines the following content will start relative to this new header height?

 

We're using Arbortext 7.1 fosi.

3 REPLIES 3
Highlighted

Re: Dynamic header size and following content.

I'm not sure you can achieve that with FOSI. We have done that before with the APP engine - the header sits in a frame and you can enable frame "avoid" mode which pushes the main text down the page rather than having the header overprint. With FOSI maybe you could implement multiple pagesets and switch between them according to how long the header text is?

Highlighted

Re: Dynamic header size and following content.

What we ended up doing was removing part of the header from the page set. Then adding it as usetext for a custom tag placed in the contents of that pageset.

Highlighted

Re: Dynamic header size and following content.

I'm not exactly sure what you are trying to do, but using ACL with FOSI it is possible to have the font size for the header depend on the length of the header content. 
 
When the document is formatted, an ACL script is called by a SYSTEM-FUNC coded in the e-i-c that saves the content for the header. The ACL code determines the length of the content to be used for the header and based on that length sets an ACL variable to a value that indicates the appropriate font size. (You'll have to do a little testing to figure out good settings for content length and font size.)
 
Next the FOSI tests the ACL variable using specval and SYSTEM-VAR. Depending on the value of the variable, the content is saved to a FOSI string variable with the appropriate formatting pseudo-element. For example:
 
<savetext textid="header.txt" conrule="<font8pt>,#CONTENT,</font8pt>"
<savetext textid="header.txt" conrule="<font10pt>,#CONTENT,</font10pt>"
<savetext textid="header.txt" conrule="<font12pt>,#CONTENT,</font12pt>"
 
Arbortext Help has information on ACLSYSTEM-FUNC, specval, SYSTEM-VAR, etc. My book Practical FOSI covers them in depth and has multiple examples of this sort of thing.
 
Hope this helps!
 
Good luck!
Suzanne Napoleon
"WYSIWYG is last-century technology!"
Announcements