I use mupdf to view pdf files. I built Android project using this instructions

However I can't click on the link in the text, e.x. url (it's highlighted but viewer doesn't react on click)

How could I jump through link in pdf file when click on it?

I'm also interested in alternative free pdf libraries for Android that supports hyperlinks.

有帮助吗?

解决方案

We have a similar feature in our Android customizable magazine app, using muPDF: it is possible to "tap" on the links in the text, either external links, or links to other pages. This app is open source and available on Github. It should be easy for you to review the code, and see how we implemented this feature.

其他提示

"https://github.com/libreliodev/android" this link provides you pdf library which suppourts hyperlinks but it has lot other stuff, 
what you need to do is after downloading the zip from the link extract it and load it in eclipse  

1) create a activity and declare it in manifest 
public class MyActivity extends BaseActivity /** base activity is available in library itself **/


{
    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);

        Intent resultIntent = new Intent(this, MuPDFActivity.class);
        resultIntent.setAction(Intent.ACTION_VIEW);
        resultIntent.setData(Uri.parse("give the path of your pdf location"));
        resultIntent.putExtra(Magazine.FIELD_TITLE, "Title");
        startActivity(resultIntent);
    }

}
it will load the pdf
许可以下: CC-BY-SA归因
不隶属于 StackOverflow
scroll top