oveRTOS C++ API
C++20 RAII wrappers for the oveRTOS C API
Loading...
Searching...
No Matches
Public Member Functions | Static Public Member Functions | List of all members
ove::lvgl::Group Class Reference

RAII wrapper for an LVGL input focus group (lv_group_t). More...

#include <lvgl.hpp>

Public Member Functions

 Group (lv_group_t *g)
 Takes ownership of an existing lv_group_t *.
 
 Group (const Group &)=delete
 
Groupoperator= (const Group &)=delete
 
 Group (Group &&other) noexcept
 Move constructor — transfers ownership; source becomes empty.
 
Groupoperator= (Group &&other) noexcept
 Move-assignment — releases current group, then takes other's.
 
lv_group_t * get () const
 Raw lv_group_t * for FFI interop.
 
Groupset_as_default ()
 Marks this group as the default — new focusable widgets will auto-join it at creation time.
 
Groupadd (ObjectView obj)
 Adds a widget to the group's focusable list.
 
Groupremove_all ()
 Removes all widgets from this group.
 
Groupfocus_next ()
 Moves focus to the next member.
 
Groupfocus_prev ()
 Moves focus to the previous member.
 
Groupfocus_freeze (bool freeze)
 Freezes/unfreezes focus movement.
 
ObjectView focused () const
 Returns the currently focused widget, or a null view.
 
Groupedit_mode (bool enable)
 Enables/disables edit mode (relevant for encoder input).
 
bool is_editing () const
 Returns the current edit-mode flag.
 
uint32_t obj_count () const
 Returns the number of widgets in the group.
 

Static Public Member Functions

static Group create ()
 Creates a fresh focus group.
 
static lv_group_t * get_default ()
 Returns the default group (set via set_as_default()).
 
static void focus_obj (ObjectView obj)
 Static helper: focus a specific widget regardless of its group membership.
 
static void remove_obj (ObjectView obj)
 Static helper: remove a widget from whatever group it's in.
 

Detailed Description

RAII wrapper for an LVGL input focus group (lv_group_t).

Groups route keyboard / encoder / button events to a focused member widget. Essential for non-touch targets where pointer input isn't available. Create a group, add widgets with add(), then connect your input device to the group (outside the scope of this wrapper — see backend-specific input device registration).

Note
Non-copyable, movable. Owns the underlying lv_group_t *.

The documentation for this class was generated from the following file: