0

I am trying to make a string on multiple lines in a windows desktop wizard with c++. I have absolutely no clue how to do it, as \n didn't work. No errors, it just doesn't make a new line.

Here is the section of the code where i'm trying to do it.

TCHAR message0[] = _T("hello \n world");

    switch (message)
    {
    case WM_PAINT:
        hdc = BeginPaint(hWnd, &ps);

        //print text
        TextOut(hdc,
            5, 5,
            message0, _tcslen(message0));
  • 2
    `TextOut` only ever produces a single line of text. There's a more complex function called `DrawText` that can produce multiline output. – john Sep 21 '22 at 18:17

0 Answers0