From 479d1226faaa937ef6820b14f36099ef3f575883 Mon Sep 17 00:00:00 2001 From: Jonas Kümmerlin Date: Sat, 18 Apr 2020 17:34:55 +0200 Subject: implement background color reduce flickering by keeping pixels if we know the background didn't change panel text is now gone, it would require us to redraw every transparent widget on top, which is a bad tradeoff since that panel text isn't very useful anyway. --- widgetfactory.cpp | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'widgetfactory.cpp') diff --git a/widgetfactory.cpp b/widgetfactory.cpp index 5ef96f1..eed7909 100644 --- a/widgetfactory.cpp +++ b/widgetfactory.cpp @@ -208,6 +208,9 @@ WinMain ALF_SetText(hwndTabPanel2, TEXT("Panel Text Demo Test Test Test")); + HWND l = ALF_AddLabel(win, (WORD)-1, 3, 7, TEXT("Hello There")); + SendMessage(l, ALF_WM_LBL_SETSTYLE, 0, ALF_LABEL_ALIGN_HCENTER | ALF_LABEL_ALIGN_VCENTER); + ALF_SetDefaultButton(win, ID_B2); ALF_ComboBoxSetText(hwndCombo2, TEXT("Goodbye World!")); @@ -216,6 +219,8 @@ WinMain ALF_LayoutSetColumnExpandNumerator(win, 1, 4); ALF_LayoutSetColumnExpandNumerator(win, 3, 1); + //SendMessage(win, ALF_WM_SETBGCOLOR, (WPARAM)RGB(0, 0, 255), 0); + EnableWindow(ALF_WidgetHwndById(win, ID_LBL3), FALSE); ALF_ResizeWindow(win, 1, 1); -- cgit v1.2.3