Signin/Signup with: 
Welcome, Guest
Username: Password: Remember me
Questions about Android development and PDF
  • Page:
  • 1

TOPIC:

PDF ZOOM (PDF FROM LINK/URL) 7 years 1 month ago #12015

  • Majid
  • Majid's Avatar Topic Author
  • Offline
  • New Member
  • New Member
  • Posts: 4
  • Thank you received: 0
Hello,
We are using standard license, here is pinch zoom already enabled but we need also tap zoom and zoom in/ zoom out buttons on pdf page bottom, Is any function available can we enable these?
And we need also remove top and bottom spacing from pdf page. can we?

Thanks you.

Please Log in or Create an account to join the conversation.

Last edit: by Majid.

PDF ZOOM (PDF FROM LINK/URL) 7 years 1 month ago #12018

  • nermeen
  • nermeen's Avatar
  • Offline
  • Platinum Member
  • Platinum Member
  • Posts: 962
  • Thank you received: 87
To implement the zoom on double tap, please check How to handle doubleTap gesture with zoomIn and zoomOut?

zoom in/ zoom out buttons, is not implemented, but you can add it as a custom implementation (based on your requirements), and the event that you should call to zoom in/out is:
m_layout.vZoomSet(vx, vy, m_layout.vGetPos(0,0), zoom);
for examples, check PDFLayoutView

top and bottom spacing, it depends on the view mode you are using and the pages size:
The default behavior, is to fit the page scale based on the document's largest page size, and use this scale for all the pages.
If you are using the dual mode (view mode = 6), the scale is calculated based on the dual page size(to fit page both horizontally and vertically), in this case you may see a top/bottom margin, if eliminated the page won't fit the screen width, and you will need to scroll horizontally to see all the page content.
You can though align the page to the top (eliminating the top margin), by changing the following in PDFLayoutView.PDFSetView:
layout.vSetLayoutPara(null, paras, m_rtol, false);
To
layout.vSetLayoutPara(null, paras, m_rtol, true);

Please Log in or Create an account to join the conversation.

  • Page:
  • 1
Powered by Kunena Forum