On this page
Form Toolbar
The form toolbar in ComPDFKit can be flexibly configured to enable form types and tools. This section explains how to customize the form toolbar.
Default ToolBar
The default form toolbar contains the following form types and tools:
Android | iOS |
---|---|
Customizing the Toolbar Buttons
You can enable or hide specific editing types by setting the availableTypes
property in the formsConfig
object. The following example demonstrates how to adjust the form types to only enable text fields and list boxes.
tsx
let config = ComPDFKit.getDefaultConfig({
formsConfig: {
availableTypes: [
CPDFFormType.TEXT_FIELD,
CPDFFormType.LISTBOX
],
availableTools: [
CPDFConfigTool.UNDO,
CPDFConfigTool.REDO,
]
}
});
ComPDFKit.openDocument(_document, '', config);
1
2
3
4
5
6
7
8
9
10
11
12
13
2
3
4
5
6
7
8
9
10
11
12
13
The customized toolbar will look like what’s shown below.
Android | iOS |
---|---|
Available Toolbar Customization Options
Type |
---|
TEXT_FIELD |
CHECKBOX |
RADIO_BUTTON |
LISTBOX |
COMBOBOX |
SIGNATURES_FIELDS |
PUSH_BUTTON |
Note: Please refer to
CPDFFormType
for the relevant options.
Available Toolbar Tool Customization Options
Tool | Description |
---|---|
SETTING | Set button, corresponding to open the selected annotation, text or picture property panel. |
UNDO | Undo annotation, content editing, form operations. |
REDO | Redo an undone action |