Apple Newton Utilities Guide de l'utilisateur Page 122

  • 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 121
CHAPTER 3
Views
3-38 Using Views
Each of the three return values contains three elements:
Element 0: the subview that is highlighted. This subview is usually
a
clParagraphView, but you need to check to make sure. A
clPolygonView is not returned here even if HiliteOwner returns a
clEditView when a clPolygonView child is highlighted.
Element 1: the start position of the text found in the text slot of a
clParagraphView.
Element 2: the end position of the text found in the text slot of a
clParagraphView.
To verify that your view is a
clParagraphView, check the viewClass slot of
the view. The value returned (dynamically) sometimes has a high bit set so you
need to take it into consideration using a mask constant,
vcClassMask:
theviews.viewClass=clParagraphView OR
theView.viewClass - vcClassMask=clParagraphView
BAnd(thViews.viewClass, BNot(vcClassMask))=clParagraphView
If a graphic is highlighted and HiliteOwner returns a clEditView, check its
view children for non-
nil values of the 'hilites slot (the 'hilites slot is for
use in any view but its contents are private).
Complex View Effects 3
If you have an application that uses ViewQuitScript in numerous places, your
view may close immediately, but to the user the Newton may appear to be hung
during the long calculations. A way to avoid this is to have the view appear open
until the close completes.
You can accomplish this effect in one of two ways. First, put your code in
ViewHideScript instead of ViewCloseScript. Second, remove the view’s
ViewEffect and manually force the effect at the end of ViewQuitScript
using the
Effect method.
Making Modal Views 3
A modal view is one that primarily restricts the user to interacting with that view.
All taps outside the modal view are ignored while the modal view is open.
In the interest of good user interface design, you should avoid using modal views
unless they are absolutely necessary. However, there are occasions when you may
need one.
Vue de la page 121
1 2 ... 117 118 119 120 121 122 123 124 125 126 127 ... 941 942

Commentaires sur ces manuels

Pas de commentaire