new Print( [options])
Parameters:
| Name | Type | Argument | Description | |||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
options |
Object |
<optional> |
Control options. Properties
|
Extends
Methods
-
copyMap(options, callback)
-
Helper function to copy result to clipboard
Parameters:
Name Type Description optionsany print options
callbackfunction a callback function that takes a boolean if copy
-
fastPrint(options)
-
Fast print
Parameters:
Name Type Description options* print options
Properties
Name Type Argument Description canvasHTMLCanvasElement | undefined <optional>
if none create one, only for ol@6+
-
print(options)
-
Print the map
Parameters:
Name Type Description optionsObject Properties
Name Type Argument Default Description imageTypestring A string indicating the image format, default the control one
qualitynumber Number between 0 and 1 indicating the image quality to use for image formats that use lossy compression such as image/jpeg and image/webp
immediateboolean true to prevent delay for printing
sizeboolean <optional>
[210,297] formatboolean <optional>
a4 orientboolean <optional>
default control orientation
marginboolean <optional>
10 any* any options passed to the print event when fired