The Spinner is scrollable by default. Create a minimal runnable example that highlights your issue.
You can limit the maximum number of options by changing the max_height of the dropdown_cls. See the example below:
from kivy.app import App
from kivy.lang import Builder
from kivy.uix.spinner import Spinner
kv = """
AnchorLayout:
LimitSpinner:
size_hint: None, None
size: 200, 48
text: 'Value 0'
values: [f'Values {x}' for x in range(50)]
"""
class LimitSpinner(Spinner):
def __init__(self, **kwargs):
super().__init__(**kwargs)
self.dropdown_cls.max_height = 4 * 48 # number of options, times the height of each option
class SpinApp(App):
def build(self):
return Builder.load_string(kv)
SpinApp().run()
--
You received this message because you are subscribed to the Google Groups "Kivy users support" group.
To unsubscribe from this group and stop receiving emails from it, send an email to kivy-users+...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/kivy-users/CAKhKqCAOMo%2Bt9dCHVf1z%2B7G8p5gcGF2AYHA%3DX76Xfy5Gf9O0gw%40mail.gmail.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/kivy-users/633b88a3.050a0220.3c88c.fd02SMTPIN_ADDED_MISSING%40gmr-mx.google.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/kivy-users/25addde1-c290-4d28-bfe3-db739558a73en%40googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/kivy-users/25addde1-c290-4d28-bfe3-db739558a73en%40googlegroups.com.