• 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: AppleScript not sending my Cocoa app proper floats on Intel
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: AppleScript not sending my Cocoa app proper floats on Intel


  • Subject: Re: AppleScript not sending my Cocoa app proper floats on Intel
  • From: Ron Fleckner <email@hidden>
  • Date: Tue, 26 Jun 2007 16:21:43 +1000


On 26/06/2007, at 3:06 PM, Donald Hall wrote:

I would bet you are running into an endian issue. AppleScript uses big endian on both platforms. Is there a way to force your program to interpret the data it receives as big endian?

I had a similar problem with the Script Timer log file, which is a Unicode text file, fed by an AppleScript application. Everything was fine until I changed and resaved the file in a Cocoa program on an Intel Mac. After that it was gibberish. I had to force the program to interpret the data in the file as big endian. (In my case the string encoding had to be set to "kCFStringEncodingUTF16BE".)

Hope that helps,

Don
--
Donald S. Hall, Ph.D.
Apps & More Software Design, Inc.
email@hidden
http://www.appsandmore.com


Hi Don,

that was my immediate suspicion, too. I didn't know that AppleScript was big-endian on Intel. However, I'm hoping the problem is more easily addressed by substituting "double" for "float". Matt Neuburg has suggested this. So I've done that now (changed float to double, that is) and have sent Matt the newly compiled app. I'll soon know if that was the problem.

Thanks for your contribution,

Ron
_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


References: 
 >Re: AppleScript not sending my Cocoa app proper floats on Intel (From: Donald Hall <email@hidden>)

  • Prev by Date: Re: Core data accessors for structs
  • Next by Date: Re: AppleScript not sending my Cocoa app proper floats on Intel
  • Previous by thread: Re: AppleScript not sending my Cocoa app proper floats on Intel
  • Next by thread: Play a song with QTMovie
  • Index(es):
    • Date
    • Thread