admin管理员组文章数量:1435859
We have a JavaFX WebView that needs to load a simple HTML page containing a tinymce v4 editor. This works fine in older versions of Java (Java 11). But in Java 21, tinymce v4 doesn't load in the jfx webview at all. We have also tried with tinymce 7.5, and that doesn't work in Java 11 or Java 21.
We even see this issue if we point the webview at the TinyMCE demo page (the page renders, but the editor pane in it does not take on tinymce functionality): /docs/tinymce/latest/full-featured-premium-demo
Code is simple:
public class Main extends Application {
public static void main(String[] args) {
launch(args);
}
public void start(Stage primaryStage) {
primaryStage.setTitle("JavaFX WebView Example");
WebView webView = new WebView();
webView.getEngine().setJavaScriptEnabled(true);
webView.getEngine().setUserAgent("Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/131.0.0.0 Safari/537.36");
webView.getEngine().load("/docs/tinymce/latest/full-featured-premium-demo");
VBox vBox = new VBox(webView);
Scene scene = new Scene(vBox, 960, 600);
primaryStage.setScene(scene);
primaryStage.show();
}
}
The demo page works fine in regular browsers.
There is no console output. I have confirmed that there are no Javascript exceptions being thrown.
Does anyone have any guidance on how to proceed? WebView is so opaque that I don't have any ideas on how to even diagnose what might be different between JFX and a regular browser.
本文标签: Load tinymce in JavaFX WebviewStack Overflow
版权声明:本文标题:Load tinymce in JavaFX Webview - Stack Overflow 内容由网友自发贡献,该文观点仅代表作者本人, 转载请联系作者并注明出处:http://www.betaflare.com/web/1745641415a2667882.html, 本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容,一经查实,本站将立刻删除。
发表评论