| MGPrintingObserver.onBeginLayout |
|
public void onBeginLayout (MGPageSetup pgSetup, MGPrintInfo info)
The begin layout printing observer method. This event is fired right before the Autodesk MapGuide Viewer uses the internal algorithm to lay out the page elements.
This topic describes this event for Plug-In and Java Edition only. For ActiveX Control, see onBeginLayout.
Plug-In and Java Edition only
pgSetup - An MGPageSetup object representing the current page layout settings.
info - An MGPrintInfo object containing information about the current printing operation.
none
To handle this event from the Plug-In or Java Edition, a Java object that implements the MGPrintingObserver interface must be established with a call to the setPrintingObserver method. The observer Java object should include the following:
<class_definition> implements MGPrintingObserver
{
// ...
public void onBeginLayout (MGPageSetup pgSetup, MGPrintInfo info)
{
// event handling code here...
}
// ...
}
The simplest way to include the observer object in a Web page is to implement it as an applet. See Advanced Examples for a fully functional observer object that supports all of the observer interfaces by forwarding the events back to JavaScript functions that have identical semantics to the ActiveX Control event handlers.
onEndLayout, enablePrintingEvents, disablePrintingEvents, getPrintingObserver, setPrintingObserver