Customize Text Selection Menu #385
Replies: 2 comments
-
If you want to add a new entry in the text selection menu, you can add a new custom editing action when initializing the navigator: swift-toolkit/TestApp/Sources/Reader/EPUB/EPUBViewController.swift Lines 42 to 46 in efba3a0 Then implement the callback in the responder chain (so usually a parent view controller of the navigator), with swift-toolkit/TestApp/Sources/Reader/EPUB/EPUBViewController.swift Lines 94 to 100 in efba3a0 As far as I know, you cannot customize the style of the native iOS text selection menu. However, you can prevent it from appearing and design your own menu by implementing this delegate method: swift-toolkit/Sources/Navigator/SelectableNavigator.swift Lines 34 to 37 in efba3a0 You can use |
Beta Was this translation helpful? Give feedback.
-
Mickael, Hey, sorry for the delay, but I'm really grateful for this breakdown and guidance. I'll be working to implement this ASAP and will let you know if there are any issues. Hoping your work on this thread will help guide others, too. Really appreciative! Have a great day! -Patrick |
Beta Was this translation helpful? Give feedback.
-
Hi!
New to Readium, but very impressed with everything. Can't thank this community enough for what has been built. I'm working on a new EPUB reader app, and I need to customize the native iOS text selection menu (add new customized buttons and change the style of it. I know injecting Java into WKWebView is a bit tricky for this - do you all have any guidance on how best to do this? Couldn't find relevant discussions here addressing.
Let me know if you have any questions, and thanks in advance for any help.
Beta Was this translation helpful? Give feedback.
All reactions