I need to find what style/theme is used by the webview for the view that pops when the user clicks a combo box in the html page.
On certain phones, the text gets chopped and I need to reduce the text size or allow each line to span multiple lines.
I have tried 5 styles so far, without success:
<style name="teststyle1" parent="@android:style/Widget.DropDownItem.Spinner">
<item name="android:singleLine">false</item>
<item name="android:textStyle">bold</item>
<item name="android:textColor">#FF00FF</item>
<item name="android:checkMark">@drawable/another_btn_radio</item>
</style>
<style name="teststyle2" parent="@android:style/Widget.TextView.SpinnerItem">
<item name="android:singleLine">false</item>
<item name="android:textStyle">bold</item>
<item name="android:textColor">#FF00FF</item>
<item name="android:checkMark">@drawable/another_btn_radio</item>
</style>
<style name="teststyle3" parent="@android:style/Widget.DropDownItem">
<item name="android:singleLine">false</item>
<item name="android:textStyle">bold</item>
<item name="android:textColor">#FF00FF</item>
<item name="android:checkMark">@drawable/another_btn_radio</item>
</style>
<style name="teststyle4" parent="@android:style/Widget.Spinner">
<item name="android:singleLine">false</item>
<item name="android:textStyle">bold</item>
<item name="android:textColor">#FF00FF</item>
<item name="android:checkMark">@drawable/another_btn_radio</item>
</style>
<style name="teststyle5" parent="@android:style/Widget.Spinner">
<item name="android:singleLine">false</item>
<item name="android:textStyle">bold</item>
<item name="android:textColor">#FF00FF</item>
<item name="android:checkMark">@drawable/another_btn_radio</item>
</style>
Any help would be greatly appreciated.
The WebView class is an extension of Android's View class that allows you to display web pages as a part of your activity layout. It does not include any features of a fully developed web browser, such as navigation controls or an address bar. All that WebView does, by default, is show a web page.
The loadUrl() and loadData() methods of Android WebView class are used to load and display web page.
Android WebView is used to display HTML in an android app. We can use android WebView to load HTML page into android app.
Allow Multiple lines would be better. If you only set the size. It would be changed if you want to add some words sometime.
This change is actually going to be done on the HTML side of things not in android. Use the webkit-appearance CSS tag to specify an appearance style then you can work with the wrapping using CSS.
URL: http://css-infos.net/property/-webkit-appearance
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With