Drawing a rectangle on a window

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

  • Drawing a rectangle on a window

    Hello,

    I am using emwin since past 3 weeks and looks very interesting. :)

    I have created a window and drawing a rectangle on a window using hard coded x and y coordinates and now, i want to get the x and y coordinates once after i created the rectangle. I tried using GUI_GetDispPosY() and GUI_GetDispPosX () functions to get the current x and y position, which is always returning me value as "0".

    Is there anyway to get the x and y coordinates after the rectangle is drawn??

    Thanks & Regards
    Dilip
  • Hello Dilip,

    Please note that you will need to use the WM API as you are working with windows.

    Please find detailed function descriptions for the WM_Get...() functions in the chapter "The Window Manager (WM)" in the emWin user manual.

    Best regards,
    Adrian
  • Hello Adrian,

    Thanks for the reply. I will be checking with the WM API in the window's manager section as you suggested, and will write back if i am in in need of some more help or if i got stuck in the middle.

    Thanks & Regards
    Dilip