From 982d4cc0f99d5a81c28b990bb3f9149ed022c574 Mon Sep 17 00:00:00 2001 From: Alexander Batalov Date: Fri, 23 Dec 2022 10:30:31 +0300 Subject: [PATCH] Truncate long names in file picker dialog --- src/dbox.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/dbox.cc b/src/dbox.cc index 68cdc62..3ddd801 100644 --- a/src/dbox.cc +++ b/src/dbox.cc @@ -1390,7 +1390,7 @@ static void fileDialogRenderFileList(unsigned char* buffer, char** fileList, int for (int index = 0; index < fileListLength; index++) { int color = index == selectedIndex ? _colorTable[32747] : _colorTable[992]; - fontDrawText(buffer + pitch * y + FILE_DIALOG_FILE_LIST_X, fileList[pageOffset + index], pitch, pitch, color); + fontDrawText(buffer + pitch * y + FILE_DIALOG_FILE_LIST_X, fileList[pageOffset + index], FILE_DIALOG_FILE_LIST_WIDTH, pitch, color); y += lineHeight; } }