Skip to content

Commit 3e1eb08

Browse files
Fix character loss in detail pairs with text wrapping enabled
1 parent a041acd commit 3e1eb08

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

lib_nbgl/src/nbgl_use_case.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1053,8 +1053,8 @@ static void displayDetailsPage(uint8_t detailsPage, bool forceFullRefresh)
10531053
currentPair.value = detailsContext.nextPageStart;
10541054
}
10551055
detailsContext.currentPage = detailsPage;
1056-
uint16_t nbLines
1057-
= nbgl_getTextNbLinesInWidth(SMALL_BOLD_FONT, currentPair.value, AVAILABLE_WIDTH, false);
1056+
uint16_t nbLines = nbgl_getTextNbLinesInWidth(
1057+
SMALL_BOLD_FONT, currentPair.value, AVAILABLE_WIDTH, detailsContext.wrapping);
10581058

10591059
if (nbLines > NB_MAX_LINES_IN_DETAILS) {
10601060
uint16_t len;
@@ -1063,7 +1063,7 @@ static void displayDetailsPage(uint8_t detailsPage, bool forceFullRefresh)
10631063
AVAILABLE_WIDTH,
10641064
NB_MAX_LINES_IN_DETAILS,
10651065
&len,
1066-
false);
1066+
detailsContext.wrapping);
10671067
len -= 3;
10681068
// memorize next position to save processing
10691069
detailsContext.nextPageStart = currentPair.value + len;

0 commit comments

Comments
 (0)