Icon View Thread

The following is the text of the current message along with any replies.
Messages 1 to 2 of 2 total
Thread Relative vs. Absolute positioning
Wed, Apr 29 2015 12:59 PMPermanent Link

Doug B

Tim,

In the general discussion thread I asked:

"Is there something like Delphi's ScreenToClient() and ClientToScreen() functions to convert back and forth from relative to 'absolute' screen coordinates?"

Matthew was kind enough to post a code snippet, but I was wondering if EWB 2 had a simple set of functions with similar behavior to the aforementioned Delphi routines?

Thanks,
Doug
Thu, Apr 30 2015 11:28 AMPermanent Link

Tim Young [Elevate Software]

Elevate Software, Inc.

Avatar

Email timyoung@elevatesoft.com

Doug,

<< Matthew was kind enough to post a code snippet, but I was wondering if
EWB 2 had a simple set of functions with similar behavior to the
aforementioned Delphi routines? >>

Yes, there is a function for converting a mouse point to a specific UI
element's coordinates in the WebUI unit:

  procedure PointToElement(APoint: TPoint; AElement: TElement);

I can't really get into the details of how the UI elements work relative to
the TControl descendants right now, but this will be covered in the manual.

Tim Young
Elevate Software
www.elevatesoft.com


Image