2022.2

Table Of Contents
Function Description
"replaceWith()"on
page811
ReplacesanHTMLelementorasetofHTMLelements(withasnippet,forexample).Returnstheresultset.
"show()"onpage812 ShowstheHTMLelementorasetofHTMLelements.
size() Getsthenumberofelementsinthisresultset.Equivalenttothelengthproperty.
"tagName()"on
page812
ReturnstheHTMLtagnameofthefirstelementinthisresultset,inuppercase.Foranexamplesee:"CreatingaTableOfCon-
tents"onpage411.
"text()"onpage813 ReplacesthetextcontentofanHTMLelementorofeachelementinasetofHTMLelementswiththesuppliedvalue,orreturnsthe
textcontentofthefirstelementifnovalueissupplied.
"width()"onpage813 Getsorsetstheouterwidthofanelement,includingpaddingandborders.
info()
ReturnspaginationinformationforoneHTMLelementorforthefirstelementinaresultset(see"res-
ults"onpage844)ofaqueryacrossallsectionsinaPrintcontext(see"query(selector)"onpage843).
ThereturnedinformationisofthetypePaginationInfo(see"PaginationInfo"onpage843).
ThisfunctioncanonlybeusedinaPostPaginationScript;see"PostPaginationScriptAPI"on
page840.
Foranexamplesee:"CreatingaTableOfContents"onpage411.
overflows()
Theoverflows()methodreturnsabooleanvalueindicatingwhetheranHTMLelementoverflowsits
boxboundaries.
Thisfunctioncouldforinstancebeusedinadesignwherecontentneedstoflowseparatelyfromthe
maintextflow,orwhereanew,full-page,multi-columnboxshouldbeinsertedwhenthecurrentone
overflows.
NotethatwhencalledinaStandardscript,thismethodrunsbeforethepaginationofPrintoutput.After
pagination-intheoutput,andinPreviewmode-theelement'soverflowmayhavechanged,especially
whentheelementiscombinedwithfloatingelements(i.e.elementsthathavetheCSSstylefloat)and
locatednearapage-break.
Topreventthisfromhappening,itmayhelptosettheelement'sCSSstyletooverflow:hidden.
Theoverflows()methodcanalsobeusedinaPostPaginationscript.
Page 846