Is it possible to adjust height of Spinner
dropdown to fill the entire screen. Right now i have 3 items that i dynamically add into the spinner adapter but these only cover half of the screen. What i have right now is something like this:
What i want is something like this:
I could add empty items but that won't solve the problem for different screen sizes
I tried to implement a style on the spinner but it didn't work
<style name="MyCustomSpinner" parent="Widget.AppCompat.Spinner.DropDown">
<item name="android:dropDownHeight">match_parent</item>
</style>
UPDATE
I have a view between action bar and spinner so i cannot use layout_weight=1
for my spinner
try using this with your adapter.
adapter.setDropDownViewResource(android.R.layout.simple_spinner_dropdown_item);
The only way to achieve this is by writing your own view that works like a spinner.
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