background image
C H A P T E R 1 0
Recognition: Advanced Topics
Using Advanced Topics in Recognition
Normally, slot values in the system's user configuration
data are set by the user from various preference slips.
It is strongly recommended that you do not change any
user preferences without first obtaining confirmation from
the user.
Modifying or Replacing the Correction Picker
Views that recognize text can provide an optional
method that modifies or replaces the picker displayed when a recognized word is
double-tapped. For more information, see "ViewCorrectionPopupScript" (page 8-75)
in Newton Programmer's Reference.
Using Stroke Bundles
The system provides functions that allow you to retrieve or manipulate stroke data,
such as the tablet points from each stroke. You can access these points in one of
two resolutions: screen resolution or tablet resolution. In screen resolution, each
coordinate value is rounded to the nearest screen pixel. In tablet resolution, each
coordinate has an additional three bits of data.
To access the ink in a view, use one of the functions documented in "Text and Ink
Input and Display Reference" (page 7-1) in Newton Programmer's Reference.
Functions that allow you to manipulate ink include the
, and
To perform deferred recognition on the strokes in a stroke bundle, pass the stroke
bundle to one of the
functions. For more information, see "Deferred Recognition" on page 10-5.
The system software provides a number of functions for working with stroke
bundles. These functions allow you to extract information from a stroke bundle and
convert the information in stroke bundles into other forms. The stroke bundle
functions are documented in "Stroke Bundle Functions and Methods" (page 8-83)
in Newton Programmer's Reference.
Stroke Bundles Example
This section shows an example of working with stroke bundles before they are
passed to the view performing recognition. One way to do this, as shown in the
following code fragment, is to implement the
of an input view. The
method is described in
"ViewInkWordScript" (page 7-56) in Newton Programmer's Reference.
© 2007-2024, o7 studio » при воспроизведении материала сайта ссылка обязательна