| FoxitPDFSDKforWeb v11.1.0 Archives Foxit PDF SDK for Web

Public Member Functions | List of all members
IFloatingTooltip Class Reference
PDFViewCtrl » viewerui

An abstract class used to implement floating box components displayed after text selection or other operations. More...

Inheritance diagram for IFloatingTooltip:

## Public Member Functions
| destroy ()
| Override this method to implement the destruction logic of tooltip.
| disable ()
| Override this method to implement the logical to make tooltip unusable.
| enable ()
| Override this method to implement the logical to make tooltip usable.
| hide ()
| Override this method to implement to hide the tooltip.
| showAt (x, y, text, rects, pageRender=this.pageRender)
| Override this method to implement the logical to display the tooltip at specified position which relative to the top left of the currently operatering PDF page. More...
Public Member Functions inherited from Disposable
| addDestroyHook (...hooks)
| Add a function to destroyHooks list, which will be called during destroy. More...
| destroy ()
| ownsTo (owner)
| Establishes an ownership relationship where this instance will be destroyed when the owner is destroyed. Additionally, the owner will be automatically removed from the destroyHooks list when this instance is destroyed. More...

## Detailed Description

An abstract class used to implement floating box components displayed after text selection or other operations.

See also
  IViewerUI.createTextSelectionTooltip

## Member Function Documentation

## ◆ showAt()

IFloatingTooltip::showAt | ( |  | x,
|  |  | y,
|  |  | text,
|  |  | rects,
|  |  | pageRender = `this.pageRender`
| ) |  |
| inline

Override this method to implement the logical to display the tooltip at specified position which relative to the top left of the currently operatering PDF page.

Parameters

  pageX | number - The x-axis coordinate relative to the top left corner of the page in pixel
  pageY | number - The y-axis coordinate relative to the top left corner of the page in pixel
  text | string - selected text (This parameter is only available when selecting text operation)
  rects | Array<{left:number,right:number,top:number,bottom:number}> - The selected text rects, relatives to the left top corner of the page in pixel. (This parameter is only available when selecting text operation)
  pageRender | PDFPageRender - The render object of the page where rects are located (only available when selecting text)

@2026 Foxit Software Incorporated. All rights reserved.