[英]JavaFX - How to disable/turn off WebViews HTML Renderer
如標題中所示:是否可以停用/關閉JavaFx WebViews HTML渲染引擎?
我想在同一WebView-Component中看到原始的HTML代碼。
將contentType
更改為text
,將導致空的WebView:
String content = "<HTML><b>test</b></HTML>";
String contentType = "text"; // text/html
webEngine.loadContent(content, contentType);
純文本的mime類型為text/plain
,因此您需要:
String contentType = "text/plain";
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.