Table Of Contents
WidgetsΒΆ
Widgets are elements of a graphical user interface that form part of the User Experience. The kivy.uix module contains classes for creating and managing Widgets. Please refer to the Widget class documentation for further information.
Kivy widgets can be categorized as follows:
UX widgets: Classical user interface widgets, ready to be assembled to create more complex widgets.
Layouts: A layout widget does no rendering but just acts as a trigger that arranges its children in a specific way. Read more on Layouts here.
Complex UX widgets: Non-atomic widgets that are the result of combining multiple classic widgets. We call them complex because their assembly and usage are not as generic as the classical widgets.
Behaviors widgets: These widgets do no rendering but act on the graphics instructions or interaction (touch) behavior of their children.
Screen manager: Manages screens and transitions when switching from one to another.
- Behaviors
- Behavior mixin classes
- Adding behaviors
ButtonBehaviorCodeNavigationBehaviorCompoundSelectionBehaviorCompoundSelectionBehavior.clear_selection()CompoundSelectionBehavior.deselect_node()CompoundSelectionBehavior.get_index_of_node()CompoundSelectionBehavior.get_selectable_nodes()CompoundSelectionBehavior.goto_node()CompoundSelectionBehavior.select_node()CompoundSelectionBehavior.select_with_key_down()CompoundSelectionBehavior.select_with_key_up()CompoundSelectionBehavior.select_with_touch()
CoverBehaviorDragBehaviorEmacsBehaviorFocusBehaviorHoverBehaviorMotionBlockBehaviorMotionCollideBehaviorToggleButtonBehaviorTouchRippleBehaviorTouchRippleButtonBehavior- Button Behavior
- Code Navigation Behavior
- Compound Selection Behavior
- Compound selection concepts
- Selection mechanics
- Example
CompoundSelectionBehaviorCompoundSelectionBehavior.clear_selection()CompoundSelectionBehavior.deselect_node()CompoundSelectionBehavior.get_index_of_node()CompoundSelectionBehavior.get_selectable_nodes()CompoundSelectionBehavior.goto_node()CompoundSelectionBehavior.select_node()CompoundSelectionBehavior.select_with_key_down()CompoundSelectionBehavior.select_with_key_up()CompoundSelectionBehavior.select_with_touch()
- Cover Behavior
- Drag Behavior
- Emacs Behavior
- Focus Behavior
- Hover Behavior
- Kivy Namespaces
- Motion Event Behaviors
- ToggleButton Behavior
- Touch Ripple
- RecycleView
- Viewclass State
RecycleViewRecycleViewBehavior- RecycleView Data Model
- RecycleView Layouts
- RecycleView Views
RecycleDataAdapterRecycleDataAdapter.attach_recycleview()RecycleDataAdapter.create_view()RecycleDataAdapter.detach_recycleview()RecycleDataAdapter.get_view()RecycleDataAdapter.get_visible_view()RecycleDataAdapter.invalidate()RecycleDataAdapter.make_view_dirty()RecycleDataAdapter.make_views_dirty()RecycleDataAdapter.refresh_view_attrs()RecycleDataAdapter.refresh_view_layout()RecycleDataAdapter.set_visible_views()
RecycleDataViewBehaviorRecycleKVIDsDataViewBehavior
- Accordion
- Action Bar
- Anchor Layout
- Box Layout
- Bubble
- Button
- Camera
- Carousel
- CheckBox
- Code Input
- Color Picker
- Drop-Down List
- EffectWidget
- FileChooser
- Float Layout
- Gesture Surface
- Grid Layout
- Image
- Label
- Layout
- ModalView
- PageLayout
- Popup
- Progress Bar
- RecycleBoxLayout
- RecycleGridLayout
- RecycleLayout
- Relative Layout
- reStructuredText renderer
- Sandbox
- Scatter
- Scatter Layout
- Screen Manager
- Basic Usage
- Changing Direction
- Advanced Usage
- Changing transitions
CardTransitionFadeTransitionFallOutTransitionNoTransitionRiseInTransitionScreenScreenManagerScreenManager.add_widget()ScreenManager.clear_widgets()ScreenManager.get_screen()ScreenManager.has_screen()ScreenManager.on_motion()ScreenManager.on_touch_down()ScreenManager.on_touch_move()ScreenManager.on_touch_up()ScreenManager.previous()ScreenManager.remove_widget()ScreenManager.switch_to()
ScreenManagerExceptionShaderTransitionSlideTransitionSwapTransitionTransitionBaseWipeTransition
- ScrollView
- Scrolling Behavior
- Limiting to the X or Y Axis
- Managing the Content Size and Position
- Overscroll Effects
- Nested ScrollViews
- Web-Style Boundary Delegation
- Wheel Behavior in Nested ScrollViews
ScrollViewScrollView.add_widget()ScrollView.convert_distance_to_scroll()ScrollView.on_motion()ScrollView.on_scroll_move()ScrollView.on_scroll_start()ScrollView.on_scroll_stop()ScrollView.on_touch_down()ScrollView.on_touch_move()ScrollView.on_touch_up()ScrollView.remove_widget()ScrollView.scroll_to()ScrollView.to_local()ScrollView.to_parent()ScrollView.update_from_scroll()
- Settings
- Slider
- Spinner
- Splitter
- Stack Layout
- Stencil View
- Switch
- TabbedPanel
- Text Input
- Usage example
- Selection
- Handles
- Filtering
- Default shortcuts
TextInputTextInput.cancel_selection()TextInput.copy()TextInput.cursor_index()TextInput.cursor_offset()TextInput.cut()TextInput.delete_selection()TextInput.do_backspace()TextInput.do_cursor_movement()TextInput.do_redo()TextInput.do_undo()TextInput.get_cursor_from_index()TextInput.get_cursor_from_xy()TextInput.get_max_scroll_x()TextInput.insert_text()TextInput.keyboard_on_key_down()TextInput.keyboard_on_key_up()TextInput.on_cursor()TextInput.on_cursor_blink()TextInput.on_double_tap()TextInput.on_quad_touch()TextInput.on_touch_down()TextInput.on_touch_move()TextInput.on_touch_up()TextInput.on_triple_tap()TextInput.paste()TextInput.pgmove_speedTextInput.reset_undo()TextInput.select_all()TextInput.select_text()
- Toggle button
- Tree View
- Video
- Video player
- VKeyboard
- Widget class
- Using Properties
- Basic drawing
- Widget touch event bubbling
- Usage of
Widget.center,Widget.right, andWidget.top WidgetWidget.add_widget()Widget.apply_class_lang_rules()Widget.clear_widgets()Widget.collide_point()Widget.collide_widget()Widget.export_as_image()Widget.export_to_png()Widget.get_parent_window()Widget.get_root_window()Widget.get_window_matrix()Widget.on_motion()Widget.on_touch_down()Widget.on_touch_move()Widget.on_touch_up()Widget.proxy_refWidget.register_for_motion_event()Widget.remove_widget()Widget.to_local()Widget.to_parent()Widget.to_widget()Widget.to_window()Widget.unregister_for_motion_event()Widget.walk()Widget.walk_reverse()
WidgetException