Android
ComPDFKit PDF SDK
Guides

Customize the Display of Editing Mode

 

ComPDFKit offers the ability to customize the appearance in the editing mode. You can modify the display effect according to your requirements, such as the cursor color, cursor width, buoy that controls the cursor position, border color of the text block, and more.

 

The following code will show you how to do this.

//Get the configuration items of editing.
CPDFEditConfig.Builder builder = editManager.getEditConfigBuilder();
//Set the required configuration items.
CPDFEditConfig config = builder.setCursorColor(Color.BLUE)
						.setCursorWidth(10f)
						.setDefalutBoardWidth(5f)
						.setDefalutBoardColor(Color.RED)
						.build();
//Update the configuration items.
editManager.updateEditConfig(config);


Note: updateEditConfig needs to be used before using beginEdit to enter the editing mode, otherwise the current update will not take effect.