moving a widget within a window

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

  • moving a widget within a window

    Hello to everybody,

    is there anyone who knows if it is possible to move a widget within a window?

    I am developing an application where there is an image widget inside the window
    and I would like to move the image object around the window area.

    Since I do not know how to move the widget I am trying to use the GUI_DrawBitmap
    function as a workaround but the image is not visible, it seems it is rendered 'under'
    the window as if GUI_* functions were not able to draw over the currently visible window.

    Thanks a lot to whom that can provide some hints.

    Ezio
  • Hello Ezio,

    Have you tried using the function WM_SetWindowPos()?

    Please note that drawing functions should be called from within a callback function as a reaction to the WM_PAINT event. Details can be found in the chapter "The Window Manager (WM)" in the emWin user manual.

    Best regards,
    Adrian