简体   繁体   中英

How to implement a search function in my Android pdf reader app?

I am willing to add search functionality to my pdf reader.I dont know how do i achieve this functionality.Any help would be appreciated. Note:I am using third party library to read the pdf file. Here is the library link: https://github.com/barteksc/AndroidPdfViewer

Is it possible to implement search functionality using this library?If not then what should be the other approach(like any java library or java code for achieving this).

After doing some investigation about the library you provided, I found out that there have been multiple users requesting the search functionality inside of the library.

I am not familiar with the library in any way, however, if there was a way to get the text of the pdf, you can search using an EditText with a addTextChangedListener , which will iterate through the entire text of the pdf searching for the text entered.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM