Why image loads on text in webview in android?
web= (WebView)findViewById(R.id.webview);
WebSettings webSettings = web.getSettings();
webSettings.setTextSize (WebSettings.TextSize.NORMAL) ;
web.setBackgroundColor(0);
webSettings.setLoadsImagesAutomatically(true);
webSettings.setSupportMulti开发者_运维技巧pleWindows(true);
webSettings.setSupportZoom(true);
webSettings.setBuiltInZoomControls(true);
web.loadDataWithBaseURL("", "<p dir=\"rtl\" align=\"right\">" + desc + "</p>", "text/html", "utf-8", "");
`
i have a problem in the webview that when it loads the image it's loaded on the text which makes the text corrupted as shown in the image knowing that both i get them by connection to service any ideas how to solve this
It's a problem with android webviews ,You can solve it with putting the height to tag. --> height="imageHeight" ..or a margin-bottom equal to his height.. this is not a good solution but is the is the only one I found.
精彩评论