[NTLK] Further newton press sillyness

From: James Nichols <smilr_at_mac.com>
Date: Sun May 28 2006 - 15:38:56 EDT

I've come to the conclusion that the developers of Newton Press were
complete idiots.

In addition to the minutes vs seconds issue, and the odd choice of
where / how to specify the three names of a newton book, they've also
broken the newton package specification with regards to maps.

Inside a newton package Part one finds several objects, two of these
are Frame, and Arrays. An array is a list of items. A frame is a list
of items, and a special type of array called a "Map" which holds the
names of the items in the frame.

Every object (this includes Arrays) has a "Class Ref" - this class
ref is often either a set of flags, on/off switches with special
meaning for the object (in particular, one of these specifies whether
or not a map is sorted), or a pointer to the "name" of the object. In
the case of a map - this Class Ref, according to Newton Formats 1.1,
MUST be a set of flags, and not a pointer to a name. At first, I
thought Newton Press followed this correctly.

That is, until I encountered a SuperMap situation. In order to save
space, the first item in a Map's list of names can be a pointer to
another Map, which we call a SuperMap, rather than a pointer to a
name. The idea is that if you have a Map with a supermap, you treat
it as if it's list of names were tacked onto the end of the
SuperMap's list. This lets you have any number of maps that start
with the same first few names, without taking up space to repeatedly
spell out those names.

When you have a custom Icon in your book package, Newton Press tacks
that information on by adding another item to the Main Frame of the
book, at the same time it also makes the Map for this Frame longer by
one. To do this it makes the frame's map be a 1 item long map (for
the new icon) with a supermap pointing to the map which describes the
other 14 entries in the Frame. So far so good.

The problem is that this extra map, which is tacked onto the end of
the regular list of items in a book, doesn't have the right class
ref. It's class Ref is supposed to be a list of flags, but instead,
it's a pointer to the name "Array". NOTHING in Newton Formats says
that any Map can have a name, it specifically claims that maps have
lists of flags! Part of my original algorithm for reading frames and
their maps out of a package relied on this fact, and I must now find
some other method of differentiating between Maps and regular Arrays.
GRRRR.

That's two fairly big deviations from the published standard, and a
very odd choice with regards to package/book names. That this
software was released to the public as is boggles my mind.

-- 
This is the NewtonTalk list - http://www.newtontalk.net/ for all inquiries
Official Newton FAQ: http://www.chuma.org/newton/faq/
WikiWikiNewt for all kinds of articles: http://tools.unna.org/wikiwikinewt/
Received on Mon Jun 5 03:55:41 2006

This archive was generated by hypermail 2.1.8 : Mon Jun 05 2006 - 15:30:00 EDT