Apple Newton Utilities Guide de l'utilisateur Page 302

  • Télécharger
  • Ajouter à mon manuel
  • Imprimer
  • Page
    / 942
  • Table des matières
  • MARQUE LIVRES
  • Noté. / 5. Basé sur avis des utilisateurs
Vue de la page 301
CHAPTER 8
Text and Ink Input and Display
8-10 Using Text
IMPORTANT
You store view templates (not view objects) in the
viewChildren array of an edit view.
Paragraph Views 8
The clParagraphView class displays text or accepts text input. It includes the
following features:
Text recognition
Text correction
Text editing, including scrubbing, selection, copying to the clipboard, pasting
from the clipboard, and other gestures, including duplicating, as controlled by
the setting of the
viewFlags slot.
Automatic word-wrapping.
Support for the caret gesture, which adds a space or splits a word.
Clipping of text that won’t t in the view. (An ellipsis is shown to indicate text
beyond what is visible.)
Use of ink and different text fonts (styles) within the same paragraph.
Tab-stop alignment of text.
Automatic resizing to accommodate added text (when this view is enclosed in a
clEditView). This feature is controlled by the vCalculateBounds flag in
the
viewFlags slot.
Automatic addition of new words written near the view when this view is
enclosed in a
clEditView and caret insertion writing mode is disabled.
The slots of
clParagraphView are described in “Paragraph View
(clParagraphView)” (page 7-15) in Newton Programmers Reference.
Note that you don’t need to create paragraph views yourself if you are accepting
user input inside a
clEditView. Just provide a clEditView and when the user
writes in it, the view automatically creates paragraph views to hold text.
The following is an example of a template dening a view of the
clParagraphView class:
dateSample := {...
viewClass: clParagraphView,
viewBounds: {left:50, top:50, right:200, bottom:70},
viewFlags: vVisible+vReadOnly,
viewFormat: vfFillWhite,
viewJustify: oneLineOnly,
text: "January 24, 1994",
Vue de la page 301
1 2 ... 297 298 299 300 301 302 303 304 305 306 307 ... 941 942

Commentaires sur ces manuels

Pas de commentaire