converting web view as image in Android 4.4 Web-view not working

China☆狼群 提交于 2019-12-04 20:16:54

I solved my problem by an alternative way.. Insted of setting the background image to web view i apply the background image to my D3 chart. And removed the background color also for my web view..

Here is the code:

     <WebView
        android:id="@+id/chartView"
        android:layout_width="fill_parent"
        android:layout_height="fill_parent"
        android:layout_weight=".10" >
       </WebView>

Web view properties

layoutView.getSettings().setJavaScriptEnabled( true );
layoutView.requestFocusFromTouch();
layoutView.getSettings().setBuiltInZoomControls( true );
layoutView.getSettings().setLoadWithOverviewMode(true);
layoutView.getSettings().setUseWideViewPort(true);

background i am applied through the HTML (chart input)

<style>  body { overflow-y:scroll;  background:url(css/date_input_bg.png) no-repeat; } </style>

Now it working for me.. But still i am amazing why the background and background color both are not working only for Android 4.4 which is working in below!

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!