Question about something in ASObj-C database #2

Shane,

I have added something called the “Quick DB Help” button to the database in the top middle of the"Item List" window. This displays things that are particular to this database, and some things that are hard to figure out where else to put.

08%20AM

There are 2 places in the “Quick DB Help” that I’m not sure about. I just copied the screen on the database and uploaded it to the discourse site. But the image first appears appears pretty small when opening the topic. But there is a button (shown below) that appears when the mouse hovers over the large image at the end of the post, that when clicked will expand the image to full size so it can be read. It takes it a while to load that last image.

The first problem is “Tip 2: Parameter & Return Type Display” section. This is about the button that “shows” and “hides” the information, about what “goes into” a method and what is “returned” from ASObj-C methods. Is the part in “Tip 2” actually helpful? It is tuff to make that stuff simple and easy to read without using very much text to explain. The part I’m asking about is down about 14 lines down from the start of tip 2 where the paragraph starts out “In reguards to the information on the classes.”

In my previous post “Question about something in ASObj-C database #1,” I included all the stuff about knew about bridging in ASObj-C which has been added to the “Extra info” topics under the topic name “Bridging in ASObj-C.” I provided a link below to the post.

The second thing was The about data accuracy. Basically how accurate are mathematical computation in AppleScript as compared to ASObj-C. I am under the impression that pretty as far as math calculations that ASObj-C is more accurate that AppleScript. That date calculations are more accurate than AppleScript. That for the most the most part anything where accuracy and precision in a calculation is import that ASObj-C is better. Would you say that is true? I have also been under the impression that this is true because ASObj-C use more bits in there calculations. It has proven more difficult then I thought it would be to confirm this in any truly complete way. What are your thoughts on this.

Bill

Generally Objective-C uses doubles for floating-point stuff, which are the same as AppleScript reals. However, AppleScript integers are still 32-bit, which limits their range.

But Objective-C is just C in terms of most maths, so it can use whatever C number type suits the situation. If something needs more precision, it can be given it.

They’re not more accurate, but finer grained. AppleScript essentially uses integers since a reference date, whereas NSDates store a floating-point value. That means the latter deals in fractions of a second.