Embedded SDK
Embedded SDK
Public Attributes | List of all members
nbgl_button_s Struct Reference

struct to represent a button (BUTTON type) that can contain a text and/or an icon More...

#include <nbgl_obj.h>

Collaboration diagram for nbgl_button_s:
Collaboration graph
[legend]

Public Attributes

nbgl_obj_t obj
 common part More...
 
color_t innerColor
 color set inside of the button More...
 
color_t borderColor
 color set to button's border More...
 
color_t foregroundColor
 
nbgl_radius_t radius
 radius of the corners, must be a multiple of 4. More...
 
nbgl_font_id_e fontId
 id of the font to use, if any More...
 
bool localized
 unused, kept for compatibility More...
 
const char * text
 single line UTF-8 text (NULL terminated) More...
 
onTextDrawCallback_t onDrawCallback
 
uint8_t token
 token to use as param of onDrawCallback More...
 
const nbgl_icon_details_ticon
 buffer containing icons bitmap. Set to NULL when no icon More...
 

Detailed Description

struct to represent a button (BUTTON type) that can contain a text and/or an icon

Note
border width is fixed (2 pixels)

Definition at line 395 of file nbgl_obj.h.

Member Data Documentation

◆ borderColor

color_t nbgl_button_s::borderColor

color set to button's border

Definition at line 398 of file nbgl_obj.h.

◆ fontId

nbgl_font_id_e nbgl_button_s::fontId

id of the font to use, if any

Definition at line 402 of file nbgl_obj.h.

◆ foregroundColor

color_t nbgl_button_s::foregroundColor

color set to '1' bits in icon, and text. '0' are set to innerColor color.

Definition at line 399 of file nbgl_obj.h.

◆ icon

const nbgl_icon_details_t* nbgl_button_s::icon

buffer containing icons bitmap. Set to NULL when no icon

Definition at line 408 of file nbgl_obj.h.

◆ innerColor

color_t nbgl_button_s::innerColor

color set inside of the button

Definition at line 397 of file nbgl_obj.h.

◆ localized

bool nbgl_button_s::localized

unused, kept for compatibility

Definition at line 403 of file nbgl_obj.h.

◆ obj

nbgl_obj_t nbgl_button_s::obj

common part

Definition at line 396 of file nbgl_obj.h.

◆ onDrawCallback

onTextDrawCallback_t nbgl_button_s::onDrawCallback

function called if not NULL, with above token as parameter to get the text of the button

Definition at line 405 of file nbgl_obj.h.

◆ radius

nbgl_radius_t nbgl_button_s::radius

radius of the corners, must be a multiple of 4.

Definition at line 401 of file nbgl_obj.h.

◆ text

const char* nbgl_button_s::text

single line UTF-8 text (NULL terminated)

Definition at line 404 of file nbgl_obj.h.

◆ token

uint8_t nbgl_button_s::token

token to use as param of onDrawCallback

Definition at line 407 of file nbgl_obj.h.


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