开发者

Resizing the webview content

I am loading image url on to webview it fetching the image as well bu开发者_运维技巧t i need to display it in resizeable it means te height to be reduced,help me to get reduced height of the image.


The cleanest, I think is:

myWebView.getSettings().setBuiltInZoomControls(true); 


you can use the zoom to show the image zoomed out:

this.getWebView ().getSettings ().setSupportZoom ( true );
View zoom = this.getWebView ().getZoomControls ();
FrameLayout contentView = (FrameLayout) getWindow ().getDecorView ().findViewById ( android.R.id.content );
contentView.addView ( zoom, ZOOM_PARAMS );
zoom.setVisibility ( View.GONE );
// set the initial scale that it should display at. the value is the scale percent
this.getWebView ().setInitialScale ( 75 );
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜