FoxitPDFSDKforWeb v10.0.0
Foxit PDF SDK for Web
CreateFreeTextCalloutService Class Reference

This is a class that encapsulates the function of creating callout annotations. It is usually used to customize the state handler for creating callout annotations. It can easily implement the process of creating callouts without having to care about more details. More...

Inheritance diagram for CreateFreeTextCalloutService:
CreateAnnotationService Disposable CreateAnnotationService Disposable

Public Member Functions

Promise< Annot[]> complete ()
 This method is called at the end of the creation operation, at this time a real callout annotation will be created. More...
 
 prepare (pageRender:PDFPageRender)
 This method accepts a pageRender parameter and performs initialization. It should only be executed once. More...
 
 start (point:DevicePoint)
 This method is called at the beginning of creation, it will record a starting point. More...
 
void update (point:DevicePoint, options?:Record< string, any >)
 Update the current coordinate point, usually called when the mouse is dragged. More...
 
- Public Member Functions inherited from Disposable
 addDestroyHook (...hooks)
 
 destroy ()
 

Detailed Description

This is a class that encapsulates the function of creating callout annotations. It is usually used to customize the state handler for creating callout annotations. It can easily implement the process of creating callouts without having to care about more details.

Since
8.1.0

Member Function Documentation

◆ complete()

Promise<Annot[]> complete ( )

This method is called at the end of the creation operation, at this time a real callout annotation will be created.

Since
8.1.0
Returns
Promise<Annot[]> -
See also
PDFPage.addAnnot

◆ prepare()

CreateFreeTextCalloutService::prepare ( pageRender:PDFPageRender  )
inline

This method accepts a pageRender parameter and performs initialization. It should only be executed once.

Parameters
pageRenderPDFPageRender -
Since
8.1.0
Returns
void

Implements CreateAnnotationService.

◆ start()

CreateFreeTextCalloutService::start ( point:DevicePoint  )

This method is called at the beginning of creation, it will record a starting point.

Parameters
pointDevicePoint - The start point
Since
8.1.0

◆ update()

void CreateFreeTextCalloutService::update ( point:DevicePoint  ,
options?:Record< string, any >   
)

Update the current coordinate point, usually called when the mouse is dragged.

Parameters
pointDevicePoint - Current mouse position relative to left-top corner of the PDFPage.
[options]Record<string, any> - more options to create callout
See also
PDFPage.addAnnot
Since
8.1.0

Foxit Software Corporation Logo
@2024 Foxit Software Incorporated. All rights reserved.