Foxit PDF SDK

Public Member Functions | List of all members
com.foxit.sdk.addon.xfa.WidgetMenu Class Reference
Inheritance diagram for com.foxit.sdk.addon.xfa.WidgetMenu:

## Public Member Functions
| WidgetMenu (XFAWidget xfa_widget) throws com.foxit.sdk.PDFException
| Constructor, from XFA widget object. More...
| WidgetMenu (WidgetMenu other)
| Constructor, with another widget menu object. More...
boolean | bold () throws com.foxit.sdk.PDFException
| (Only useful for rich text) Make the rich text bold. More...
boolean | canCopy () throws com.foxit.sdk.PDFException
| Check if the text of related XFA widget can be copied. More...
boolean | canCut () throws com.foxit.sdk.PDFException
| Check if the text of related XFA widget can be cut. More...
boolean | canDelete () throws com.foxit.sdk.PDFException
| Check if the text of related XFA widget can be deleted. More...
boolean | canDeSelect () throws com.foxit.sdk.PDFException
| Check if the selection of the text in related XFA widget can be canceled. More...
boolean | canPaste () throws com.foxit.sdk.PDFException
| Check if the text of related XFA widget can be pasted. More...
boolean | canRedo () throws com.foxit.sdk.PDFException
| Check if the operation of related XFA widget can be redone. More...
boolean | canSelectAll () throws com.foxit.sdk.PDFException
| Check if the text of related XFA widget can be selected all. More...
boolean | canUndo () throws com.foxit.sdk.PDFException
| Check if the operation of related XFA widget can be undone. More...
boolean | clearStyle () throws com.foxit.sdk.PDFException
| (Only useful for rich text) Clear the style of the rich text. More...
String | copy () throws com.foxit.sdk.PDFException
| Copy the text of related XFA widget. More...
String | cut () throws com.foxit.sdk.PDFException
| Cut the text of related XFA widget. More...
synchronized void | delete ()
| Clean up related C++ resources immediately. More...
boolean | deleteMenu () throws com.foxit.sdk.PDFException
| Delete all the text of related XFA widget. More...
boolean | deSelect () throws com.foxit.sdk.PDFException
| Cancel the selection of the text in related XFA widget. More...
boolean | isEmpty ()
| Check whether current object is empty or not. More...
boolean | italic () throws com.foxit.sdk.PDFException
| (Only useful for rich text) Make the rich text italic. More...
boolean | paste (String text) throws com.foxit.sdk.PDFException
| Paste the text to related XFA widget. More...
boolean | redo () throws com.foxit.sdk.PDFException
| Redo the operation of related XFA widget. (No effect for rich text) More...
boolean | selectAll () throws com.foxit.sdk.PDFException
| Select all the text of related XFA widget. More...
boolean | subscript () throws com.foxit.sdk.PDFException
| (Only useful for rich text) Make the rich text as subscript. More...
boolean | superscript () throws com.foxit.sdk.PDFException
| (Only useful for rich text) Make the rich text as superscript. More...
boolean | underline () throws com.foxit.sdk.PDFException
| (Only useful for rich text) Underline the rich text. More...
boolean | undo () throws com.foxit.sdk.PDFException
| Undo the operation of related XFA widget. (No effect for rich text) More...
Public Member Functions inherited from com.foxit.sdk.common.Base
synchronized void | delete ()
| Clean up related C++ resources immediately. More...

## Detailed Description

Class WidgetMenu represents the menu of an XFA widget.

## Constructor & Destructor Documentation

## ◆ WidgetMenu() [1/2]

com.foxit.sdk.addon.xfa.WidgetMenu.WidgetMenu | ( | XFAWidget | xfa_widget | ) | throws com.foxit.sdk.PDFException

Constructor, from XFA widget object.

Parameters

  [in] | xfa_widget | A valid XFA widget object.

## ◆ WidgetMenu() [2/2]

com.foxit.sdk.addon.xfa.WidgetMenu.WidgetMenu | ( | WidgetMenu | other | ) |

Constructor, with another widget menu object.

Parameters

  [in] | other | Another widget menu object.

## Member Function Documentation

## ◆ bold()

boolean com.foxit.sdk.addon.xfa.WidgetMenu.bold | ( |  | ) | throws com.foxit.sdk.PDFException

(Only useful for rich text) Make the rich text bold.

Returns
  true means success, while false means failure.

## ◆ canCopy()

boolean com.foxit.sdk.addon.xfa.WidgetMenu.canCopy | ( |  | ) | throws com.foxit.sdk.PDFException

Check if the text of related XFA widget can be copied.

Returns
  true means the text can be copied, while false means the text cannot be copied.

## ◆ canCut()

boolean com.foxit.sdk.addon.xfa.WidgetMenu.canCut | ( |  | ) | throws com.foxit.sdk.PDFException

Check if the text of related XFA widget can be cut.

Returns
  true means the text can be cut, while false means the text cannot be cut.

## ◆ canDelete()

boolean com.foxit.sdk.addon.xfa.WidgetMenu.canDelete | ( |  | ) | throws com.foxit.sdk.PDFException

Check if the text of related XFA widget can be deleted.

Returns
  true means the text can be deleted, while false means the text cannot be deleted.

## ◆ canDeSelect()

boolean com.foxit.sdk.addon.xfa.WidgetMenu.canDeSelect | ( |  | ) | throws com.foxit.sdk.PDFException

Check if the selection of the text in related XFA widget can be canceled.

Returns
  true means the selection can be canceled, while false means the selection cannot be canceled.

## ◆ canPaste()

boolean com.foxit.sdk.addon.xfa.WidgetMenu.canPaste | ( |  | ) | throws com.foxit.sdk.PDFException

Check if the text of related XFA widget can be pasted.

Returns
  true means the text can be pasted, while false means the text cannot be pasted.

## ◆ canRedo()

boolean com.foxit.sdk.addon.xfa.WidgetMenu.canRedo | ( |  | ) | throws com.foxit.sdk.PDFException

Check if the operation of related XFA widget can be redone.

Returns
  true means the operation can be redone, while false means the operation cannot be redone.

## ◆ canSelectAll()

boolean com.foxit.sdk.addon.xfa.WidgetMenu.canSelectAll | ( |  | ) | throws com.foxit.sdk.PDFException

Check if the text of related XFA widget can be selected all.

Returns
  true means the text can be selected all, while false means the text cannot be selected all.

## ◆ canUndo()

boolean com.foxit.sdk.addon.xfa.WidgetMenu.canUndo | ( |  | ) | throws com.foxit.sdk.PDFException

Check if the operation of related XFA widget can be undone.

Returns
  true means the operation can be undone, while false means the operation cannot be undone.

## ◆ clearStyle()

boolean com.foxit.sdk.addon.xfa.WidgetMenu.clearStyle | ( |  | ) | throws com.foxit.sdk.PDFException

(Only useful for rich text) Clear the style of the rich text.

Returns
  true means success, while false means failure.

## ◆ copy()

String com.foxit.sdk.addon.xfa.WidgetMenu.copy | ( |  | ) | throws com.foxit.sdk.PDFException

Copy the text of related XFA widget.

Returns
  The copied text.

## ◆ cut()

String com.foxit.sdk.addon.xfa.WidgetMenu.cut | ( |  | ) | throws com.foxit.sdk.PDFException

Cut the text of related XFA widget.

Returns
  The cut text.

## ◆ delete()

synchronized void com.foxit.sdk.addon.xfa.WidgetMenu.delete | ( |  | ) |

Clean up related C++ resources immediately.

Returns
  None.

Note
  Once this function is called, current object cannot be used anymore.

## ◆ deleteMenu()

boolean com.foxit.sdk.addon.xfa.WidgetMenu.deleteMenu | ( |  | ) | throws com.foxit.sdk.PDFException

Delete all the text of related XFA widget.

Returns
  true means success, while false means failure.

## ◆ deSelect()

boolean com.foxit.sdk.addon.xfa.WidgetMenu.deSelect | ( |  | ) | throws com.foxit.sdk.PDFException

Cancel the selection of the text in related XFA widget.

Returns
  true means success, while false means failure.

## ◆ isEmpty()

boolean com.foxit.sdk.addon.xfa.WidgetMenu.isEmpty | ( |  | ) |

Check whether current object is empty or not.

When the current object is empty, that means current object is useless.

Returns
  true means current object is empty, while false means not.

## ◆ italic()

boolean com.foxit.sdk.addon.xfa.WidgetMenu.italic | ( |  | ) | throws com.foxit.sdk.PDFException

(Only useful for rich text) Make the rich text italic.

Returns
  true means success, while false means failure.

## ◆ paste()

boolean com.foxit.sdk.addon.xfa.WidgetMenu.paste | ( | String | text | ) | throws com.foxit.sdk.PDFException

Paste the text to related XFA widget.

Parameters

  [in] | text | A text string to be pasted.

Returns
  true means success, while false means failure.

## ◆ redo()

boolean com.foxit.sdk.addon.xfa.WidgetMenu.redo | ( |  | ) | throws com.foxit.sdk.PDFException

Redo the operation of related XFA widget. (No effect for rich text)

Returns
  true means success, while false means failure.

## ◆ selectAll()

boolean com.foxit.sdk.addon.xfa.WidgetMenu.selectAll | ( |  | ) | throws com.foxit.sdk.PDFException

Select all the text of related XFA widget.

Returns
  true means success, while false means failure.

## ◆ subscript()

boolean com.foxit.sdk.addon.xfa.WidgetMenu.subscript | ( |  | ) | throws com.foxit.sdk.PDFException

(Only useful for rich text) Make the rich text as subscript.

Returns
  true means success, while false means failure.

## ◆ superscript()

boolean com.foxit.sdk.addon.xfa.WidgetMenu.superscript | ( |  | ) | throws com.foxit.sdk.PDFException

(Only useful for rich text) Make the rich text as superscript.

Returns
  true means success, while false means failure.

## ◆ underline()

boolean com.foxit.sdk.addon.xfa.WidgetMenu.underline | ( |  | ) | throws com.foxit.sdk.PDFException

(Only useful for rich text) Underline the rich text.

Returns
  true means success, while false means failure.

## ◆ undo()

boolean com.foxit.sdk.addon.xfa.WidgetMenu.undo | ( |  | ) | throws com.foxit.sdk.PDFException

Undo the operation of related XFA widget. (No effect for rich text)

Returns
  true means success, while false means failure.