Android开发中通过WebView加载html数据并采用解决方案去除Webview滚动条
发布时间
阅读量:
阅读量
传统方式观察图像:

此页面是通过webview组件加载HTML源代码后呈现的网页内容,其具体实现方式如下:
webview.loadDataWithBaseURL(null, htmlData, "text/html", "utf-8", null);
实现滚动条隐藏功能的途径共有两种方式:
第一种方式:通过在xml文件中将scrollbars属性设置为none,即可达成相应效果
<WebView
android:id="@+id/wv_read_msg_content"
android:layout_width="match_parent"
android:layout_height="300dp"
android:layout_marginBottom="10dp"
android:scrollbars="none" />
全部评论 (0)
还没有任何评论哟~
