• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Coercing a long point
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Coercing a long point


  • Subject: Re: Coercing a long point
  • From: Philip Aker <email@hidden>
  • Date: Sat, 07 Dec 2002 16:42:17 -0800

On Friday, Dec 6, 2002, at 05:38 US/Pacific, ehsan saffari wrote:

Here's a post from a.c.l.a, can anyone shed any light?

I'm getting a peice of data cak from an application that looks like this in the event log: <<data lpnt00000852FFFFFFA3>> If I get the class of the data it is a long point. How do I get at the X and Y values of this point? Or how can I coerce this long point into a list of numbers?

there is no mention of 'long point' in ALSG.
Anyone have a TMPL for long point?


'cLongPoint' and 'typeLongPoint' are mentioned in AERegistry.h. Since it doesn't appear to be defined as a Macintosh type elsewhere, I'd guess that LongPoint would be simply a Point type with the coordinates in 32 bit integers. Something like:

typedef struct LongPoint {
SInt32 v;
SInt32 h;
} LongPoint;

But maybe the fields are reversed.

It also looks like you're getting the value back in hex. If you're on OS X I have a dog slow script which can convert these values. The data you quote comes out to 2130 and -93. Normally, I'd think these are bogus values if they refer to screen coordinates.


Philip Aker
http://www.aker.ca
_______________________________________________
applescript-users mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/applescript-users
Do not post admin requests to the list. They will be ignored.

References: 
 >Coercing a long point (From: ehsan saffari <email@hidden>)

  • Prev by Date: Re: Script the UNSCRIPTABLE
  • Next by Date: Re: Which shell?
  • Previous by thread: Re: Coercing a long point
  • Next by thread: My Bad, Idle Handler question fixed & asked again
  • Index(es):
    • Date
    • Thread