FolioReaderPage

open class FolioReaderPage : UICollectionViewCell, UIWebViewDelegate, UIGestureRecognizerDelegate
  • The index of the current page. Note: The index start at 1!

    Declaration

    Swift

    open var pageNumber: Int!
  • Declaration

    Swift

    open var webView: FolioReaderWebView?
  • Scrolls the page to a given offset

    Declaration

    Swift

    open func scrollPageToOffset(_ offset: CGFloat, animated: Bool)

    Parameters

    offset

    The offset to scroll

    animated

    Enable or not scrolling animation

  • Scrolls the page to bottom

    Declaration

    Swift

    open func scrollPageToBottom()
  • Handdle #anchors in html, get the offset and scroll to it

    Declaration

    Swift

    open func handleAnchor(_ anchor: String, avoidBeginningAnchors: Bool, animated: Bool)

    Parameters

    anchor

    The #anchor

    avoidBeginningAnchors

    Sometimes the anchor is on the beggining of the text, there is not need to scroll

    animated

    Enable or not scrolling animation

  • Runs a JavaScript script and returns it result. The result of running the JavaScript script passed in the script parameter, or nil if the script fails.

    Declaration

    Swift

    open func performJavaScript(_ javaScriptCode: String) -> String?

    Return Value

    The result of running the JavaScript script passed in the script parameter, or nil if the script fails.