Can I make webview only part of the screen?

I am trying to open a webview at the bottom of the app to display a little information, but it keeps the whole screen and covers other widgets with information. Is there a way to make it have a specific size and space in the application?

+2


source to share


1 answer


Oh, you have to provide part of your xml layout so that we can see how you wrap the webview inside. Whether your webview is the root element of your app layout than will always use full screen. But try wrapping it inside a frame or something ...



<FrameLayout
android:layout_height="fill_parent"
android:layout_width="fill_parent"
android:gravity="bottom">
  <WebView
  android:layout_height="100dp"
  android:layout_width="fill_parent"/>
</FrameLayout>

      

0


source







All Articles