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?
-
Declaration
Swift
public override init(frame: CGRect) -
Declaration
Swift
public func setup(withReaderContainer readerContainer: FolioReaderContainer) -
Declaration
Swift
required public init?(coder aDecoder: NSCoder) -
Declaration
Swift
override open func layoutSubviews()
-
Declaration
Swift
open func webViewDidFinishLoad(_ webView: UIWebView) -
Declaration
Swift
open func webView(_ webView: UIWebView, shouldStartLoadWith request: URLRequest, navigationType: UIWebView.NavigationType) -> Bool
-
Declaration
Swift
open func gestureRecognizer(_ gestureRecognizer: UIGestureRecognizer, shouldRecognizeSimultaneouslyWith otherGestureRecognizer: UIGestureRecognizer) -> Bool -
Declaration
Swift
@objc open func handleTapGesture(_ recognizer: UITapGestureRecognizer)
-
Scrolls the page to a given offset
Declaration
Swift
open func scrollPageToOffset(_ offset: CGFloat, animated: Bool)Parameters
offsetThe offset to scroll
animatedEnable 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
anchorThe #anchor
avoidBeginningAnchorsSometimes the anchor is on the beggining of the text, there is not need to scroll
animatedEnable or not scrolling animation
-
Declaration
Swift
override open func canPerformAction(_ action: Selector, withSender sender: Any?) -> Bool
-
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.
View on GitHub
Install in Dash
FolioReaderPage Class Reference