Thoughtful, detailed coverage of the Mac, iPhone, and iPad, plus the best-selling Take Control ebooks.

 

 

Pick an apple! 
 
Type an em-dash on an iPhone

Typography and punctuation geeks rejoice! It's easy to type an em-dash on the iPhone's or iPod touch's virtual keyboard. To do so, tap the .?123 key to switch to the numeric keypad. Then touch and hold on the Hyphen key to reveal a pop-up strip showing an em-dash. Slide to the em-dash and release your finger.

Note that this basic trick works with many other keys on the virtual keyboard.

Visit Take Control of iPhone OS 3

 
 

Developing for the MessagePad

Send Article to a Friend

If you want to develop Newton applications, you need the Newton Toolkit (NTK), which runs on a Mac. Minimally speaking, the Mac should be 68020-based Mac running System 7.0.1 with 3 MB RAM. You tether the MessagePad to the Mac via a null modem cable, and - after using the NTK to design the interface, write the code, and build the application - you download the resulting binary image into the MessagePad, where you can test it.

The Toolkit provides tools for project management, application building, editing, object-template browsing, and View layout design. (Views are visible objects.) For Views layout, the NTK provides a set of customizable prototype templates for buttons, icons, sliders, and other user interface objects. The layout tools also let you preview results in a Mac window the same size as the MessagePad screen.

The programming language for the MessagePad is the object-oriented NewtonScript. The NTK compiles a compressed bytecode representation of the source code, similar to p-code. This bytecode image is executed by a run-time interpreter in the MessagePad ROM. This design makes the code fully portable. Currently, there are two run-time interpreter implementations: an ARM610 version for the MessagePad, and a 680x0 version for debugging in the NTK environment.

NewtonScript is a high-level language that lets you manipulate objects. Such objects could be a soup of contact numbers, or a View object that changes in response to a user action. NewtonScript's syntax is an amalgam of Pascal and C, and it supports messages and exception handling. The language is powerful enough to serve as real code, and in fact, the MessagePad's user interface was implemented with about 47,000 lines of NewtonScript.

NewtonScript requires little memory, and importantly, does automatic memory management and garbage collection. There's no memory allocation calls and all references are to objects, not to handles or pointers. This makes the programmer's nightmare of memory leaks and dangling pointers a thing of the past. Also, objects have latent typing, and NewtonScript performs type checking on operations before they are performed. This nails argument errors as they occur, and not after the trashed stack causes problems dozens of instructions later. This simplifies debugging and makes the operating system more robust.

 

Mapbox: fast, beautiful maps for your app and Web site.
Swap out Apple Maps for our open source SDK in just a few steps.
Choose a map design that suits your app and wows your users.
Start developing today for free! <https://www.mapbox.com/mobile/>