PurePointY (Window.l)

Top  Previous  Next

Returns Vertical Position of PurePoint in specified Window.

 

Use:

Y=PurePointY(Window)

 

 

 

Example:

 

#Main=0

#Text=1

 

If OpenWindow(#Main,0,0,400,300,#PB_Window_SystemMenu|#PB_Window_ScreenCentered,"Demo")

If CreateGadgetList(WindowID(#Main))

TextGadget(#Text,10,10,200,20,"")

EndIf

 

hPoint=PurePoint("PP.pvp")

 

quitMain=0

Repeat

UsePurePoint(hPoint)

 

x=PurePointX(#Main)  

y=PurePointY(#Main)    ;<-- Return Vertical Position of PurePoint  

SetGadgetText(#Text,"X="+Str(x)+"   Y="+Str(y))

 

Select WaitWindowEvent()

Case #PB_Event_CloseWindow

quitMain=1

EndSelect

Until quitMain

 

FreePurePoint(hPoint)

EndIf

End