2022.2

Table Of Contents
Field Description
ABSOLUTE
PlacesthePDFataspecificlocationonthepage.Setthebackground'stop(background.top)andleft(background.left)
measuredfromthetopandleftsideofthesection.
CENTERED
CentersthePDFonthepage,verticallyandhorizontally.
FIT_TO_MEDIA
StretchesthePDFtofitthepagesize.
Examples
Thisscriptappliesabsolute positioningtothebackgroundofaPrintsection.
var activeSection = merge.template.contexts.PRINT.sections['Section 1'];
activeSection.background.source = BackgroundResource.RESOURCE_PDF;
activeSection.background.position = MediaPosition.ABSOLUTE;
activeSection.background.left = "10mm";
activeSection.background.top = "10mm";
activeSection.background.url = "images/somepage.pdf";
ThenextscriptscalesthebackgroundofaPrintsectiontothesizeoftheMedia.
var activeSection = merge.template.contexts.PRINT.sections['Section 1'];
activeSection.background.source = BackgroundResource.RESOURCE_PDF;
activeSection.background.position = MediaPosition.FIT_TO_MEDIA;
activeSection.background.url = "images/somepage.pdf";
Post Pagination Script API
ThetablebelowliststhefunctionsandobjectsthatareonlyavailableinPostPaginationScripts.Click
throughtotheobjecttofindadescriptionandsamplescripts.
See"PostPaginationScripts"onpage850forinformationaboutthiskindofscripts,howtoinsertthem
andwhatyoucandowiththem.
Note: PostPaginationScriptsonlyapplytothePrintcontext.Thesefunctionsandobjectscannot
beusedwithothercontexts.
Tip: ItispossibletodefineafunctioninaControlScriptwhichcallsthesefunctions,aslongas
thatfunctionisonlyinvokedfromaPostPaginationScript.
Object or func-
tion
Usage
merge.context."query(selector)"
onpage1300
Callmerge.context.query(selector)torunaqueryacrossallsectionsinthePrintcontext.
Page 1297