Monday, December 11th 2017, 1:01am UTC+1

You are not logged in.

  • Login
  • Register

Dear visitor, welcome to SEGGER Forum. If this is your first visit here, please read the Help. It explains how this page works. You must be registered before you can use all the page's features. Please use the registration form, to register here or read more information about the registration process. If you are already registered, please login here.

jhgorse

Beginner

Date of registration: Jul 9th 2014

Posts: 13

1

Saturday, April 4th 2015, 11:16am

New dialog does not draw when it goes over the edge of parent

I cannot seem to get this dialog to draw completely unless it's area is within the immediate parent window. The attached figure shows the grandparent window (5 - 9 text), the parent dialog (message button), and the child dialog (Q button) which gets cut off at the end of the parent dialog.

Here is the relevant code for calling the child dialog:

C/C++ Source code

1
2
3
4
5
        hKeypad = CreateAlphaKeypad();
        WM_AttachWindow(hKeypad, pMsg->hWin);
        WM_MoveTo(hKeypad, 100, 200);            // Move dialog
        WM_MakeModal(hKeypad);                  // Make dialog modal
        GUI_ExecCreatedDialog(hKeypad);


How can I get the child dialog to draw completely?

Cheers,
Joe
jhgorse has attached the following image:
  • Capture.PNG

jhgorse

Beginner

Date of registration: Jul 9th 2014

Posts: 13

2

Saturday, April 4th 2015, 11:18am

The answer is to remove

C/C++ Source code

1
WM_AttachWindow(hKeypad, pMsg->hWin);

SEGGER - Adrian

Super Moderator

Date of registration: May 26th 2009

Posts: 994

3

Tuesday, April 14th 2015, 11:21am

Hello Joe,

Drawing a child window outside the borders of its parent window is not possible. Please consider creating the according window as child of the next "ancestor" window.

Best regards,
Adrian