问题
I am using one Github library for view PDF file. https://github.com/barteksc/AndroidPdfViewer
i want to set scroll direction RTL. please help to change scroll direction of this library.
I have tried solution from below link https://github.com/JoanZapata/android-pdfview/issues/60
but its not worked for me.
回答1:
I have found a hack. Rotate your pdf by 180 degress and then add following line in your code
pdf_activity_read_quraan.rotation = 180F
where is pdf_activity_read_quraan
is reference of com.github.barteksc.pdfviewer.PDFView
回答2:
Try adding android:supportsRtl="true"
in Application
tag of the manifest file.
Source : https://developer.android.com/guide/topics/manifest/application-element.html
Possible workaround would be acquiring the scroll and force move like this :
mScrollView.postDelayed(new Runnable() {
public void run() {
scrollView.fullScroll(HorizontalScrollView.FOCUS_RIGHT); // or scrollTo
}
}, 100L);
来源:https://stackoverflow.com/questions/43183645/set-rtl-scroll-direction-for-pdfview-android