RMGui 0.15.0
C11 retained-mode UI library: layout kernel, style schema, widget painters, fonts, software framebuffer
Loading...
Searching...
No Matches
rmgui_tab_t Struct Reference

Retained strip state, caller-owned, written by rmgui_tab_init, rmgui_tab_viewport, rmgui_tab_select and rmgui_tab_input; the host reads selected, first_visible, visible_count, sets or clears RMGUI_STYLE_STATE_DISABLED in states, and may set or clear bytes of disabled (disabling the selected tab leaves it selected). More...

#include <tab.h>

Data Fields

const rmgui_tab_item_t * items
uint64_t * saved_focus
uint8_t * disabled
size_t count
size_t selected
size_t first_visible
size_t visible_count
size_t hover
size_t pressed
uint8_t states

Detailed Description

Retained strip state, caller-owned, written by rmgui_tab_init, rmgui_tab_viewport, rmgui_tab_select and rmgui_tab_input; the host reads selected, first_visible, visible_count, sets or clears RMGUI_STYLE_STATE_DISABLED in states, and may set or clear bytes of disabled (disabling the selected tab leaves it selected).

Invariants after a successful init: 1 <= count <= INT_MAX (input result index ceiling); selected < count; 1 <= visible_count <= count; first_visible + visible_count <= count; hover/pressed are a tab index or RMGUI_TAB_NONE. Init/selection/viewport reveal the selected tab; explicit overflow-strip scrolling may temporarily move it outside the viewport.

rmgui_tab_t.items

borrowed identity array

rmgui_tab_t.saved_focus

focus to restore per panel, 0 none

rmgui_tab_t.disabled

byte i: tab i disabled

rmgui_tab_t.hover

tab under the pointer

rmgui_tab_t.pressed

tab the held press began on

rmgui_tab_t.states

strip FOCUSED (input), DISABLED (host)

Field Documentation

◆ items

const rmgui_tab_item_t* rmgui_tab_t::items

◆ saved_focus

uint64_t* rmgui_tab_t::saved_focus

◆ disabled

uint8_t* rmgui_tab_t::disabled

◆ count

size_t rmgui_tab_t::count

◆ selected

size_t rmgui_tab_t::selected

◆ first_visible

size_t rmgui_tab_t::first_visible

◆ visible_count

size_t rmgui_tab_t::visible_count

◆ hover

size_t rmgui_tab_t::hover

◆ pressed

size_t rmgui_tab_t::pressed

◆ states

uint8_t rmgui_tab_t::states

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