Antialiasing with WM

This site uses cookies. By continuing to browse this site, you are agreeing to our Cookie Policy.

  • Antialiasing with WM

    Hi,

    Could you tell me how I can use for example

    C Source Code

    1. GUI_SetColor(GUI_GREEN); GUI_SetPenSize(5); GUI_AA_DrawRoundedRect(10, 10, 50, 50, 5);



    in a callback function static void _cbDialog(WM_MESSAGE * pMsg).

    I try draw GUI_AA_DrawRoundedRect() without WM - result success. But with Window Manager I can't reach success result. Is there a way using 2D graphics or antialiasing functions with WM?


    And why when I using this I have no draw rectangle
    case WM_USER:
    hItem = WM_GetDialogItem(pMsg->hWin, ID_TEXT_0);
    TEXT_SetTextColor(hItem, GUI_WHITE);
    TEXT_SetText(hItem, pMsg->Data.p);
    TEXT_SetFont(hItem, &GUI_FontArialNarrow16);

    GUI_SetColor(GUI_GREEN);
    GUI_SetPenSize(5);
    GUI_AA_DrawRoundedRect(10, 10, 50, 50, 5); break;



    But If I using in next way I see success draw rectangle(why it's happen, what differences)?
    case WM_USER:
    hItem = WM_GetDialogItem(pMsg->hWin, ID_TEXT_0);
    TEXT_SetTextColor(hItem, GUI_WHITE); TEXT_SetText(hItem, pMsg->Data.p);
    TEXT_SetFont(hItem, &GUI_FontArialNarrow16);
    break;
    case WM_PAINT:
    GUI_SetColor(GUI_GREEN);
    GUI_SetPenSize(5);
    GUI_AA_DrawRoundedRect(10, 10, 50, 50, 5);
    break;

    The post was edited 4 times, last by krufter ().