7#ifndef NBGL_LAYOUT_INTERNAL_H
8#define NBGL_LAYOUT_INTERNAL_H
26#define INTERNAL_MARGIN 8
28#ifdef SCREEN_SIZE_WALLET
29#if SMALL_BUTTON_RADIUS == 32
30#define SMALL_BUTTON_HEIGHT 64
31#define SMALL_BUTTON_RADIUS_INDEX RADIUS_32_PIXELS
32#elif SMALL_BUTTON_RADIUS == 20
33#define SMALL_BUTTON_HEIGHT 40
34#define SMALL_BUTTON_RADIUS_INDEX RADIUS_20_PIXELS
42#define LAYOUT_OBJ_POOL_LEN 16
44#define KEYBOARD_FOOTER_TYPE 99
45#define KEYPAD_FOOTER_TYPE 98
125 tune_index_e tuneId);
147 return smallCaseForValue ? SMALL_BOLD_FONT : LARGE_MEDIUM_FONT;
161 return &MINI_PUSH_ICON;
200 if (forceEllipsis != NULL) {
API of the Advanced BOLOS Graphical Library, for predefined layouts.
#define VALUE_ICON_INTERVALE
nbgl_layoutUpFooterType_t
The different types of area on top of footer.
nbgl_layoutHeaderType_t
The different types of extended header.
nbgl_layoutFooterType_t
The different types of extended footer.
@ SWIPE_USAGE_SUGGESTIONS
static nbgl_font_id_e layoutGetTagValueFont(bool smallCaseForValue)
returns the font used to display the values of a list of tag/value pairs
void layoutNavigationPopulate(nbgl_container_t *navContainer, const nbgl_layoutNavigationBar_t *navConfig, uint8_t layer)
This function creates a full navigation bar "object", with buttons and returns it as a container.
static uint8_t layoutGetTagValueMaxLines(uint8_t listMaxLines, const nbgl_contentTagValue_t *pair, bool *forceEllipsis)
returns the max number of lines of the value of the given tag/value pair, which is the smallest non-z...
static uint16_t layoutGetTagValueWidth(const nbgl_icon_details_t *icon)
returns the width of the value of a tag/value pair. Shared by the layout and the use cases,...
bool keyboardSwipeCallback(nbgl_layoutInternal_t *layoutInt, nbgl_obj_t *obj, nbgl_touchType_t eventType)
static const nbgl_icon_details_t * layoutGetTagValueIcon(const nbgl_contentTagValue_t *pair)
returns the icon displayed on the right of the value of the given tag/value pair
void layoutAddObject(nbgl_layoutInternal_t *layout, nbgl_obj_t *obj)
adds the given obj to the main container
void layoutUpdateCallbackObjToken(nbgl_layoutInternal_t *layout, nbgl_obj_t *obj, uint8_t token)
Update the token associated with a specific object in a layout.
#define LAYOUT_OBJ_POOL_LEN
Max number of complex objects with callback retrievable from pool.
bool layoutNavigationCallback(nbgl_obj_t *obj, nbgl_touchType_t eventType, uint8_t nbPages, uint8_t *activePage)
function to be called when any of the controls in navigation bar is touched
struct nbgl_layoutInternal_s nbgl_layoutInternal_t
Structure containing all information about the current layout.
layoutObj_t * layoutAddCallbackObj(nbgl_layoutInternal_t *layout, nbgl_obj_t *obj, uint8_t token, tune_index_e tuneId)
void(* nbgl_layoutTouchCallback_t)(int token, uint8_t index)
prototype of function to be called when an object is touched
struct PACKED__ nbgl_text_area_s nbgl_text_area_t
struct to represent a text area (TEXT_AREA type)
struct PACKED__ nbgl_container_s nbgl_container_t
struct to represent a container (CONTAINER type)
struct PACKED__ nbgl_obj_s nbgl_obj_t
Common structure for all graphical objects.
struct nbgl_animation_s nbgl_animation_t
Represents all information about an animation (succession of icons).
nbgl_touchType_t
The different types of Touchscreen events.
struct PACKED__ nbgl_icon_details_s nbgl_icon_details_t
Represents all information about an icon.
This structure contains a [tag,value] pair and possible extensions.
uint8_t nbMaxLinesForValue
const nbgl_icon_details_t * valueIcon
Structure containing all information about the current layout.
uint8_t nbUsedCallbackObjs
nbgl_container_t * footerContainer
container used to store footer (buttons, nav....)
uint8_t activePage
index of active page for navigation bar
uint8_t layer
layer in screen stack
nbgl_obj_t ** children
children for main screen
struct nbgl_layoutInternal_s * top
layout above this one, in stack
nbgl_swipe_usage_t swipeUsage
nbgl_layoutTouchCallback_t callback
user callback for all controls
struct nbgl_layoutInternal_s * bottom
layout under this one, in stack
uint8_t invertedColors
if true, means that background is black
nbgl_container_t * container
uint8_t iconIdxInAnim
current icon index in animation
nbgl_container_t * headerContainer
container used to store header (progress, back, empty space...)
uint8_t isUsed
if true, means this layout is in use
nbgl_layoutFooterType_t footerType
type of footer
nbgl_layoutHeaderType_t headerType
type of header
nbgl_container_t * upFooterContainer
uint8_t incrementAnim
if true, means that animation index is currently incrementing
uint8_t nbPages
number of pages for navigation bar
nbgl_layoutUpFooterType_t upFooterType
type of up-footer
uint8_t modal
if true, means the screen is a modal
layoutObj_t callbackObjPool[LAYOUT_OBJ_POOL_LEN]
nbgl_text_area_t * tapText
const nbgl_animation_t * animation
current animation (if not NULL)
This structure contains info to build a navigation bar at the bottom of the screen.