[BUG] Display bug in Button Monitor page with Fix

More
10 Oct 2015 13:50 #38689 by richardclli
When I play around Lydros's Red Black Devo12 theme in current nighty, I found that the text is not display correctly in the Button Monitor page, this is due to the changes of the LabelDesc structure and forgot to change the code here for the right align LabelDesc definition.

Normally all the properties should be copied from DEFAULT_FONT except the alignment.

Here is the fix that I have done to solve the problem. This fix is quite obvious, but I think it will be even better to move all font definitions to a central place.

# This patch file was generated by NetBeans IDE
# It uses platform neutral UTF-8 encoding and \n newlines.
--- Base (BASE)
+++ Locally Modified (Based On LOCAL)
@@ -150,7 +150,7 @@
OFFSET_Y = ((LCD_HEIGHT - 240) / 2),
};
enum {X = 0, Y = 1};
- struct LabelDesc alignRight = { DEFAULT_FONT.font, 0, 0, DEFAULT_FONT.font_color, LABEL_RIGHT };
+ struct LabelDesc alignRight = { DEFAULT_FONT.font, LABEL_RIGHT, DEFAULT_FONT.font_color, DEFAULT_FONT.fill_color, DEFAULT_FONT.outline_color };
const int label_pos[NUM_TX_BUTTONS][2] = CHANTEST_BUTTON_PLACEMENT;
cp->is_locked = 3;
GUI_CreateLabelBox(&gui->lock, OFFSET_X, 34, 320, 20, &NARROW_FONT, lockstr_cb, NULL, NULL);

Please Log in or Create an account to join the conversation.

More
11 Oct 2015 01:49 #38704 by richardclli
Replied by richardclli on topic [BUG] Display bug in Button Monitor page with Fix
I have created an issue in bug tracker, see if anybody can help to create a pull request for this simple fix.

Please Log in or Create an account to join the conversation.

More
21 May 2020 22:33 #76350 by billmester
Replied by billmester on topic [BUG] Display bug in Button Monitor page with Fix
Hello, I tried it today and got the same error of the missing text. Did anything happen to this topic in the past 5 years? :)

Please Log in or Create an account to join the conversation.

Time to create page: 0.028 seconds
Powered by Kunena Forum